Post a Comment
From all the attention and famous cases of use, I think we'll see more and more about this one... in fact, even more with mobile computing and desktop computing getting so close these days.
Actually, this reminds me when OpenGL for BeOS was begin implemented and the engineer build a a program to build most of the OpenGL extensions, because there was so many of them, and it ended up usually better than manual coding most of them... Even if some programmers don't want to admit, solutions like this will become more and more common each day.
I wonder if Vala guys could target this compiler system to their language resulting some improvement...
This is probably the first example of the unified HLVM and LLVM. http://www.hlvm.org is designed to be a common runtime for most languages including "typeless" languages like Python.
Stay away from Wikipedia. I mean it.
Dragon Book FTW!
http://www.amazon.com/Compilers-Principles-Techniques-Alfred-Aho/dp...
I modded you up for the general wisdom contained in your retort. However, notice that I'm criticising this horrid trend of nowadays where people believe that reading whatever is written in Wikipedia is enough to grasp a concept, any concept, and base their work on whatever shallow article comes up on WP.
Bottom line is: buy a book. Read a book. If for no other reason than being healthier for your eyes and blood flow. Some WP articles might be very thorough, but they're no substitute to the proper literature on any non-trivial subject.
(You'd never attempt to fix a modern car engine after reading Wikipedia articles on 4-stroke engines, would you?)
Have you ever seen any tutorial that describes every aspect of building a real-life implementation of whatever the tutorial subject is?
Tutorials are simply things that point you to the direction of how things are done under a given environment. It won't give you a step-by-step breakdown on how to write your own operating system, or to build your own your own Gothic cathedral.
The sole purpose of tutorials is to present concepts you're familiar with on ways that match the environment you're working with at the moment. If you need to go beyond that, then you need a "For Dummies" book, then there's a natural progression to books named after the subject, then books named after the subject with an "Advanced Topics" subtitle, then "Subject: the reference manual", then after half a decade or so "Subject: becoming more productive", "Subject: a modern approach", and finally you manage your way around a simple cheat sheet.
See, tutorials are polar opposites of "cheat sheets".
(and yes, it gives me the creeps when I see newbie Python programmers using cheat sheets and coming up with sloppiest solution ever for a given problem, coated with the shiniest syntactic sugar...)
Edit: I'm past the edit time for my previous message, but I just found the link to Dragon Book, 2nd ed. on Amazon, and I think it's worth sharing:
http://www.amazon.com/Compilers-Principles-Techniques-Tools-2nd/dp/...
Edited 2007-11-07 18:16
No, I have seen tutorials that are small scale but what they show have real value.
If his purpose was only to show LLVM, he would have skipped lexing and parsing and AST and he would have gone straight to how LLVM is used to produce code.
His tutorial can be summarized into the following simple phrases:
step 1: LLVM has a library which contains classes which can be used to represent a program; LLVM knows how to interpret the instances of these classes to assembly code.
step 2: In order to provide optimizations, you tell the compiler engine which optimizations you require and then you call the engine to optimize the objects produced in step 1.







