我之前已经推荐过《The Art of the Metaobject Protocol》了,不过今天脑子里又浮现出两本以语言实现为核心的书:1. Ronald Mak 的《Writing Compilers and Interpreters》 2. Bob Morgan 的《Building an Optimizing Compiler》。Morgan 的那本书非常抢手,而且已经绝版了。它是该领域为数不多的实体书价格一直在疯涨的图书之一。
I already answered about "The Art of the Metaobject Protocol" but then two more language-implementation-centric books came to mind today. 1. "Writing Compilers and Interpreters" by Ronald Mak 2. "Building an Optimizing Compiler" by Bob Morgan Morgan's book is well sought after and out of print. It's one of the few books in the field for which the print edition prices keep climbing.
这本书不是那种大包大揽的百科全书式写法,而是直奔主题、绝不浪费你的时间:https://www.amazon.com/gp/aw/d/155558179X/ [更新:是 Bob Morgan 写的《Building an Optimizing Compiler》。] 前提是你不想浪费时间去读语法解析、类型检查或者把 AST 序列化成某种汇编代码,编译器这部分东西其实没那么……
This book is not completionist but instead it's to the point and avoids wasting your time: https://www.amazon.com/gp/aw/d/155558179X/ [Edit: it's Building an Optimizing Compiler by Bob Morgan.] That's assuming you don't want to waste your time reading about parsing, type checking, or serializing an AST into some form of assembly, the parts of a compiler which just aren't that…
Bob Morgan 写的《Building an Optimizing Compiler》完全专注于现代编译器优化(它出版于1997年)。书中详细讲解了构建控制流图(CFG)、基于它能做的各种优化、别名分析、静态单……
Bob Morgan's book Building an Optimizing Compiler is entirely focused on modern compiler optimizations (and it was published in 1997). It goes over building a control flow graph, various optimizations you can do with that, alias analysis, static single…
……讨论编译器的前端,其实真正狂拽酷炫有意思的货全在后端。新版龙书在这方面比老版强多了,不过我还想推荐另外两本书:1) Morgan 的《Building an Optimizing Compiler》——有人很吃这种写作风格,也有人很讨厌,但干货绝对扎实。2) Muchnick 的《Advanced Compiler Design and Implementation》——神作,要是你真想把优化搞透,必读。
…talking about the front-end of the compiler the crazy interesting stuff is in the backend. The new Dragon book greatly improves here over the old one, but I'd also recommend two other texts: 1) Morgan, Building an Optimizing Compiler -- some people love the writing style. Others hate it, but the material is solid. 2) Muchnick, Advanced Compiler Design and Implementation -- Great book. Must read if you're serious about optimizations.
龙书(Dragon Book)其实是本挺烂的编译器教材。别光因为它名字拉风就瞎推荐。Grune 的《Parsing Techniques》和 Morgan 的《Building an Optimizing Compiler》都还行。
The Dragon Book is a bad compiler book. Don’t recommend it just because it has a cool name. Grune’s Parsing Techniques and Morgan’s Building an Optimizing Compiler are okay.
Morgan 在《Building an Optimizing Compiler》里推荐用“探针(spike)”方法:http://www.amazon.com/Building-Optimizing-Compiler-Bob-Morga.... 其核心思想是,从前端到后端,每个阶段都先写出刚好够用的代码,来打通……
Morgan's "Building an Optimizing Compiler" recommends doing a "spike" method: http://www.amazon.com/Building-Optimizing-Compiler-Bob-Morga.... The idea is that you should write enough of each stage, from the front-end to the back-end, to get…
我之前已经推荐过《The Art of the Metaobject Protocol》了,不过今天脑子里又浮现出两本以语言实现为核心的书:1. Ronald Mak 的《Writing Compilers and Interpreters》 2. Bob Morgan 的《Building an Optimizing Compiler》。Morgan 的那本书非常抢手,而且已经绝版了。它是该领域为数不多的实体书价格一直在疯涨的图书之一。
I already answered about "The Art of the Metaobject Protocol" but then two more language-implementation-centric books came to mind today. 1. "Writing Compilers and Interpreters" by Ronald Mak 2. "Building an Optimizing Compiler" by Bob Morgan Morgan's book is well sought after and out of print. It's one of the few books in the field for which the print edition prices keep climbing.
这本书不是那种大包大揽的百科全书式写法,而是直奔主题、绝不浪费你的时间:https://www.amazon.com/gp/aw/d/155558179X/ [更新:是 Bob Morgan 写的《Building an Optimizing Compiler》。] 前提是你不想浪费时间去读语法解析、类型检查或者把 AST 序列化成某种汇编代码,编译器这部分东西其实没那么……
This book is not completionist but instead it's to the point and avoids wasting your time: https://www.amazon.com/gp/aw/d/155558179X/ [Edit: it's Building an Optimizing Compiler by Bob Morgan.] That's assuming you don't want to waste your time reading about parsing, type checking, or serializing an AST into some form of assembly, the parts of a compiler which just aren't that…
Bob Morgan 写的《Building an Optimizing Compiler》完全专注于现代编译器优化(它出版于1997年)。书中详细讲解了构建控制流图(CFG)、基于它能做的各种优化、别名分析、静态单……
Bob Morgan's book Building an Optimizing Compiler is entirely focused on modern compiler optimizations (and it was published in 1997). It goes over building a control flow graph, various optimizations you can do with that, alias analysis, static single…
……讨论编译器的前端,其实真正狂拽酷炫有意思的货全在后端。新版龙书在这方面比老版强多了,不过我还想推荐另外两本书:1) Morgan 的《Building an Optimizing Compiler》——有人很吃这种写作风格,也有人很讨厌,但干货绝对扎实。2) Muchnick 的《Advanced Compiler Design and Implementation》——神作,要是你真想把优化搞透,必读。
…talking about the front-end of the compiler the crazy interesting stuff is in the backend. The new Dragon book greatly improves here over the old one, but I'd also recommend two other texts: 1) Morgan, Building an Optimizing Compiler -- some people love the writing style. Others hate it, but the material is solid. 2) Muchnick, Advanced Compiler Design and Implementation -- Great book. Must read if you're serious about optimizations.
龙书(Dragon Book)其实是本挺烂的编译器教材。别光因为它名字拉风就瞎推荐。Grune 的《Parsing Techniques》和 Morgan 的《Building an Optimizing Compiler》都还行。
The Dragon Book is a bad compiler book. Don’t recommend it just because it has a cool name. Grune’s Parsing Techniques and Morgan’s Building an Optimizing Compiler are okay.
Morgan 在《Building an Optimizing Compiler》里推荐用“探针(spike)”方法:http://www.amazon.com/Building-Optimizing-Compiler-Bob-Morga.... 其核心思想是,从前端到后端,每个阶段都先写出刚好够用的代码,来打通……
Morgan's "Building an Optimizing Compiler" recommends doing a "spike" method: http://www.amazon.com/Building-Optimizing-Compiler-Bob-Morga.... The idea is that you should write enough of each stage, from the front-end to the back-end, to get…