4 ms·
Go compiler now committed to gcc mainline (to be gcc 4.6)
- Vidura 16y agoSo why didn't java and python made it to gcc ?
- deleted 16y ago[deleted]
- xtho 16y agoBecause java did make it and python doesn't compile to machine code (with the exception of using a jit compiler maybe)?
- pmjordan 16y agoI'm trying to work out at what level your question makes sense. I'm unaware of a GCC-based Python compiler, so surely there's nothing to merge there? As for Java: http://gcc.gnu.org/java/ http://gcc.gnu.org/java/ (this has been in for years)
- froydnj 16y agoThere was a SoC project for a Python front-end to GCC this past summer. I don't know how far it got.
- jrockway 16y agoWhat's gcj? Oh, the Java compiler in gcc? Hmm. As for why Python isn't in gcc... it's because nobody has sent a patch. There is no conspiracy here; Google wrote Go and sent the gcc folks a patch to add it to gcc. Simple.
- masklinn 16y agoAlso, erm… Python is not compiled to native code, so a gcc plugin doesn't really make any sense.
- bretthoerner 16y agoJava normally isn't, either. You're discussing implementation details, not laws. http://gcc.gnu.org/java/ http://gcc.gnu.org/java/
- pbiggar 16y agoSort of. Scripting languages cross a bit of a line in that their implementation details leak out into the language. It simply isn't possible to statically compile Python (or PHP, Ruby, etc), and still cover the full breadth of the language. You need to handle dynamic code generation (for example eval()) which means you need an interpreter at run-time, which means you're no longer really statically compiling it. In gcj, they added a java interpreter, and statically compile what they can. This works great when you have all the source code. It doesn't work great for things like Eclipse, where there are tons of dynamically loaded plugins which are then slow because they're interpreted.
- jedbrown 16y agoEvidently you are not familiar with how many Lisp compilers work. You don't need an interpreter anywhere, just a compiler. Note that eval(), as much as it makes sense in the C language, can be implemented in C too (inject the text into a stub, compile it into a shared library, dlopen(), dlsym(), call it).
- pieter 16y agoAnyone else has the problem that they need to log in with a Google account before being able to see posts on Google Groups? I even have this on the group I created, which I set to the most public settings.
- percept 16y agoIf you're logged in to GMail in another tab, sign out and reload the Groups page. Also, tack 'topics?gvc=2' onto the end of any Groups URL to get the nice tabular view (you can get there through clicks but this is quicker).
- jrockway 16y agoYes, I have noticed this. Although I am usually logged in to Google, it seems to want me to log in again, which I am much too lazy to do. So I just don't use Google Groups.
- masklinn 16y agoThat seems to be if you're logged in an other Google service in the same browser/session: if I open a browser I only use for development (and not for personal stuff, so it's not logged into any Google service) such as Opera, I get the message. On the other hand if I open the link in my "usual" browser it asks me to log into Google Groups (if I'm not already logged into it)
- andrewf 16y agoMore information here: http://www.airs.com/blog/archives/448 http://www.airs.com/blog/archives/448
- junkbit 16y ago"Release gccgo in gcc is going to introduce a difficulty for Go programmers who use it. The Go language continues to evolve, but gcc 4.6 will not. That means that people using gcc 4.6 will be using a language which will be increasingly out of date. I don’t think there is any way to avoid that problem at this stage. The language will become more stable over time."
- joubert 16y agoWhy bother with GCC when the medium to long term seems to favor the LLVM compiler infrastructure? (and yes, I know you can use GCC together with LLVM, but for example, in Apple's case, XCode 4 now favors LLVM+Clang instead of the LLVM+GCC setup of XCode 3)
- CrLf 16y agoThere's more to compilers than desktop/server targets. Although LLVM now targets a number os architectures, it is nowhere near what GCC supports.
- froydnj 16y agoThe long-term goal of the Go frontend is to be usable with both GCC and LLVM. GCC has excellent medium to long term prospects, too, you know.
- deleted 16y ago[deleted]
- pbiggar 16y agoIn this particular case: - Go is created by google - Ian Lance Taylor, the author of gccgo, works for Google - Taylor has worked on gcc for more than a decade - Google uses gcc for all its infrastructure I doubt they would object to an LLVM front-end, and I'm sure someone will create one in the future. As to why Google doesn't use LLVM, the generated code is simply not as fast as GCC. Google (last I heard) employs about 30 compiler engineers to support gcc internally, so they're not about to switch over to a less mature platform, even though it shows great potential.
- Q6T46nT668w6i3m 16y agoFrom Ars: I was initially a bit surprised that Google chose not to use the Low-Level Virtual Machine (LLVM) compiler framework—it has a lot of LLVM expertise internally and is using it extensively for their awesome Python optimization effort. Pike says that LLVM was considered during the early stages of the Go project, but its compile-time performance was judged to be inadequate. http://arstechnica.com/open-source/news/2009/11/go-new-open-source-programming-language-from-google.ars http://arstechnica.com/open-source/news/2009/11/go-new-open-...