5 ms·
On a related note: What's a good introduction to compiler design ? Has the dragon book been superseded by something yet? Ideally you'd be able to write a decent
by cedex12 7y ago
On a related note: What's a good introduction to compiler design ? Has the dragon book been superseded by something yet? Ideally you'd be able to write a decent compiler for your own language after going through it.
- thechao 7y agoWhat's wrong with the Dragon Book? Obviously, the older versions won't cover SSA. However, in general, for a hobby project, single-static assignment and abstract interpretation (the modern bits) are only going to help with a very tiny part of the compiler (the optimizer). By the time you need a "lot" of SSA (LICM, SCEV, PEO-register assignment, etc.), you're looking at an easy 10-years of effort, so there'd be no need for an "intro" book at that point...
- pizlonator 7y agoFor a lot of us, the optimizer is not the tiny part. It's the biggest and most important part. It does not take 10 years to implement an SSA compiler with LICM, SCEV, and good register allocation. (No idea why you'd want Professional Employer Organizations as part of your RA, but that's just me.) For example, WebKit's B3 compiler took 4 months to write. It's not hard to write it if you know what to write. Hence the need for a good book. Maybe the reason why you think it takes ten years and Professional Employer Organizations is that you never read a good book on the subject!
- brosenlof 7y agoCould you recommend a good book/reference?
- pizlonator 7y agoI can’t! :-( I learned by interning on a team that knew how to do it right and learning from them and then learning more by word of mouth - asking folks who architected compilers how/why they did things.
- CalChris 7y agoThe 2nd edition of the Dragon Book is quite good. I don't think it's been surpassed. For myself, I prefer it with respect to compilers much more than I prefer Computer Architecture A Quantitative Approach with respect to computer architecture.