4 ms·
Why was the Go compiler not based on SSA form originally? Isn't that kind of an embarrassment? All industrial compilers I'm aware of completed their transition
by sievebrain 11y ago
Why was the Go compiler not based on SSA form originally? Isn't that kind of an embarrassment? All industrial compilers I'm aware of completed their transition to SSA ~15 years ago ... it seems bizarre that a compiler for a language started in 2009 wouldn't have been that way from the start.
- steveklabnik 11y agoAlternative viewpoint: go has also accomplished a lot of its goals for years without needing this. It could reasonably be viewed as a premature optimization.
- sievebrain 11y agoIt's a pretty big architectural change to any compiler, and when all other major compilers have paid that refactoring cost, it's very strange to want to go through the transition pain instead of just doing SSA up front like LLVM did.
- kjksf 11y agoOriginal Go compiler was based on plan 9 C compiler (http://plan9.bell-labs.com/sys/doc/compiler.html http://plan9.bell-labs.com/sys/doc/compiler.html) because Ken Thompson and Rob Pike (co)designed and (co)implemented those compilers and they were 2 out of 3 original Go designers/implementers. Those compilers are at least 16 years old so Pike and Thompson aren't as incompetent as you think them to be.
- sievebrain 11y agoThat just changes the question to why did they base their compiler on an obscure 16 year old codebase? I can guess that the answer is familiarity, but, that doesn't change the negative impact of a low tech compiler on the user base.