10 ms·
CLaSH: A functional hardware description language
- mikhael 12y agowithout having looked at it in much detail, does anyone know how/whether this is related at all to bluespec (http://en.wikipedia.org/wiki/Bluespec,_Inc. http://en.wikipedia.org/wiki/Bluespec,_Inc.)?
- knz42 12y agoIt's not related to bluespec. (cf my other comment in this thread)
- akuma73 12y agoThere's already a commercial functional hardware description language called Bluespec. http://en.wikipedia.org/wiki/Bluespec,_Inc http://en.wikipedia.org/wiki/Bluespec,_Inc.
- knz42 12y agoBluespec has a strange story: initially it was developed like Clash, as a subset of Haskell that could be translated to a HDL. However its users hated the Haskell syntax, so the Bluespec designers added a layer of syntax on top to make it look like more a HDL, and they also downplayed the powerful type system for adoption. Since then, Bluespec has not become too popular, but Haskell has. Clash may have a chance.
- aninhumer 12y agoI work with Bluespec. It's miles better than Verilog, but coming from a Haskell background, I can't help but feel disappointed with the limitations their alternative syntax puts on my ability to abstract things. (No lambdas, no do-notation, needlessly verbose sum types) I'm also not really convinced by their hardware model (Guarded Atomic Actions). In practice, I've found that it leads to very disjointed flow control, and forbids what seem like intuitive designs.
- sshine 12y agoI did my bachelor's project on translation between functional HDLs that were also reversible, i.e. only describing total, bijective functions. The idea of functional HDLs goes back to at least the 1970s, and the coolest language I found was 𝜇FP by Mary Sheeran. It was an algebraic VLSI design language where logical gates as combinators are the only language constructs.
- jberryman 12y agoThat sounds cool. I don't know anything about HDLs, but can you explain why you might want your functions to be bijective? What does that give you in hardware?
- pseudonom- 12y agoMaybe for reversible computing? [0] [0] https://en.wikipedia.org/wiki/Reversible_computing https://en.wikipedia.org/wiki/Reversible_computing
- sitkack 12y agoCool. Could you fill your post in with relevant links. I really dig this stuff. http://scholar.google.com/citations?user=zQ49M2sAAAAJ&hl=en http://scholar.google.com/citations?user=zQ49M2sAAAAJ&hl=en http://www.cs.ox.ac.uk/publications/publication3787-abstract.html http://www.cs.ox.ac.uk/publications/publication3787-abstract...
- sitkack 12y agoThis looks really interesting http://www.cs.ru.nl/P.Achten/IFL2013/symposium_proceedings_IFL2013/ifl2013_submission_7.pdf http://www.cs.ru.nl/P.Achten/IFL2013/symposium_proceedings_I...
- psychometry 12y agoI think we have a winner for the most poorly named programming language of the last decade. I thought that "Go" and "Hack" were bad, but at least I could type those on my keyboard.
- Dorian-Marie 12y agoThe command-line tool / url / package name / ... are all "CLaSH"
- Dewie 12y agoI am able to get about 4 decent/good results by googling "clash language". Though I got more results with "CλaSH language".
- elliotec 12y agoSeriously. I spent more time trying to figure out how to read/say it than reading about it. C(lambda)aSH? clambdaash? Oh, CLaSH.
- dllthomas 12y agoClam-dash. It makes your shellfish go fast, or your car smell.
- jonemo 12y agoSquirrel is also high up on that list.
- cottonseed 12y agoI think ClaSH is the proper romanization.
- mathieuh 12y agoClash? C-lambda-ash? C-lambda-a-ess-aitch? C-lash?
- ZenoArrow 12y agoInteresting language, I'll be interested to see how Clash develops.
- blueintegral 12y agoIs this meant for hardware people or software people? Because I'm a hardware guy and I don't know Haskell. None of my EE friends know Haskell either. I really don't see a serious hardware engineer using this over VHDL or Verilog, even if it is more beautiful or provably better or whatever.
- zhemao 12y agoStrangely enough, alternative HDLs embedded in Haskell seem to be a thing. Besides this, there is also Bluespec and Lava. http://wiki.bluespec.com/ http://wiki.bluespec.com/ http://raintown.org/lava/ http://raintown.org/lava/
- sitkack 12y agoTom Hawkins is probably around here somewhere. http://en.wikipedia.org/wiki/Atom_(programming_language) http://en.wikipedia.org/wiki/Atom_(programming_language)
- marcosdumay 12y agoImmutability looks too much like hardware.
- pipeep 12y agoFrom the limited amount of VHDL I did in my Digital Design class at my university, I found hardware description similar to functional programming. State is expensive to represent in hardware (you need latches, flip-flops, etc), and so VHDL's concept of signals is similar to constants, and components map well to pure functions. With an intelligent enough compiler, I think this is totally feasible. From a more short-term practical standpoint, no, I don't expect anyone to use this. Hardware engineers are incredibly stubborn when it comes to software. Their work typically involves large time investments with lots of costs and risks. For better or worse, they typically don't ever want to add more risk by using an "untrusted" tool, creating a chicken-and-egg problem. In the second paragraph, the author admits that there's not yet a good way to represent a recursive algorithm in his language. I think this is more of a proof-of-concept that could eventually become useful.
- helpbygrace 12y agoI am hardware engineer in this industry. And I know Haskell and made my site with Haskell language. But I do not understand why Haskell is used to hardware design. Designing hardware is much more important than describing hardware logic itself. IMO, VISIO and Excel are the tools to design hardware logic not Verilog nor like this CLaSH. But, If this kind of HDL can be used along with Verilog, it might be helpful to build verification IPs.
- zhemao 12y agoWait, so what are you using to describe the circuit on the logic or RTL level? Do you have VLSI engineers using Cadence or something? From my understanding, using Verilog in ASIC design (and not just verification) is pretty widespread in industry.
- platinum1 12y agoI think what he's saying is the architectural decisions outweigh the implementation language. When I was taught Verilog for IP implementation, one thing I noticed is that people get caught in the trap of trying to abstract away the hardware or approach it from a higher level. Haskell/Verilog 2001/SystemVerilog all give us tools to do this. However, when trying to make real silicon, you need to understand what is actually getting built (i.e. know exactly how many flip flops you're creating and how they fan out) and then use the language to describe it. If you use a 'for' loop to try to do computation, as you might in a programming language, you could end up with something entirely unexpected or unsynthesizable. Traditionally you first design your module conceptually on a whiteboard (or Excel, Viso, etc.), then implement it in an HDL. Because of the influx of software engineers trying to get into hardware (via FPGAs, etc.), there has been a trend in trying to obfuscate away the details of the implementation, and this can cause a lot of confusion. That said, I've heard of projects that already translate native Haskell to HDL with some success. I'm not a programmer so I don't claim to understand if it's a good idea, but I still think understanding exactly what's being output is important to knowing if it can perform in a reasonable way, especially if you're doing something of any complexity.
- 12y ago
- smackay 12y agoIn a former life (a long time ago), I used ELLA for designing processors. It was a pretty decent functional language. Great at abstracting components or subsystems and infinitely better than modelling stuff with C. IIRC European Silicon Structures used to offer it as a part of their toolset when VLSI design was young and hot. https://en.wikipedia.org/wiki/ELLA_%28programming_language%29 https://en.wikipedia.org/wiki/ELLA_%28programming_language%2...