14 ms·
Random question, why would someone use gccgo over the standard go compiler?
by jshen 13y ago
Random question, why would someone use gccgo over the standard go compiler?
- cespare 13y agoOne reason is that gccgo supports many architectures that gc does not (SPARC, MIPS, PowerPC, Alpha). It also was the only way to get Go on Solaris until the more recent port of gc to that platform. gccgo is also supposed to produce better code for certain computationally heavy workloads.
- 4ad 13y ago> gccgo is also supposed to produce better code for certain computationally heavy workloads. Unfortunately, this is very seldom true. Gccgo could potentially generate faster floating point code, but its lack of escape analysis grinds it to a halt.
- whyrusleeping 13y agowith gccgo you get to take advantage of a lot of gcc's optimizations (-O3) and it can generate faster code because of it.
- 4ad 13y agoThere is extremely little code in the world that is faster with gccgo. Yes, gccgo can do better with floating point, but the lack of escape analysis slows it down tremendously in every real world situation out there. http://dave.cheney.net/2013/11/19/benchmarking-go-1-2rc5-vs-gccgo http://dave.cheney.net/2013/11/19/benchmarking-go-1-2rc5-vs-...
- supersillyus 13y agoThere is a GSOC to add escape analysis (https://www.google-melange.com/gsoc/project/details/google/gsoc2014/coko156/5733935958982656 https://www.google-melange.com/gsoc/project/details/google/g...). It'll be interesting to see how that affects things.
- whyrusleeping 13y agoWow. I guess the last time i look at the differences was around 1.1 Thanks for the correction