Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.forth > #22405
| Newsgroups | comp.lang.forth |
|---|---|
| Date | 2013-05-07 14:25 -0700 |
| References | (3 earlier) <72351a29-1334-4832-86ff-92186fdf0ef4@tz3g2000pbb.googlegroups.com> <km158i$3lv$1@speranza.aioe.org> <S-6dncHYyamWohnMnZ2dnUVZ_smdnZ2d@supernews.com> <km4oal$ro0$1@speranza.aioe.org> <NMmdncFxIf4evxvMnZ2dnUVZ_oKdnZ2d@supernews.com> |
| Message-ID | <cb26c45e-8fc5-4f8d-b2d8-7ff00d006ef6@googlegroups.com> (permalink) |
| Subject | Re: are forthers still unimpressed with go lang? |
| From | the_gavino_himself <visphatesjava@gmail.com> |
On Sunday, May 5, 2013 2:12:35 AM UTC-7, Andrew Haley wrote: > Rod Pemberton <do_not_have@notemailnotq.cpm> wrote: > > > "Andrew Haley" <andrew29@littlepinkcloud.invalid> wrote in message > > > news:S-6dncHYyamWohnMnZ2dnUVZ_smdnZ2d@supernews.com... > > >> Rod Pemberton <do_not_have@notemailnotq.cpm> wrote: > > >> > "Hugh Aguilar" <hughaguilar96@yahoo.com> wrote in message > > > news:72351a29-1334-4832-86ff-92186fdf0ef4@tz3g2000pbb.googlegroups.com... > > >> >> On May 1, 8:02 am, Andrew Haley > > >> > <andre...@littlepinkcloud.invalid> > > >> >> wrote: > > >> >> > Rod Pemberton <do_not_h...@notemailnotq.cpm> wrote: > > > ... > > > > > >> >> > > Go is one just more example of a language that is > > >> >> > > compiled to C, > > >> >> > > > >> >> > No it's not. There's a real GCC front end for it. It > > >> >> > doesn't get compiled into C. > > >> > > > >> > It does. > > >> > > >> No, it doesn't. > > > > > > Does too. > > > > > >> > It was done once but manually for all the syntax of a > > >> > language. One can't create a GCC front-end without doing so. > > >> > > >> One certainly can. What does "It was done once but manually for > > >> all the syntax of a language" mean? > > > > > > Each piece of unique language syntax for Go is manually, i.e., by > > > a person, converted to C. > > > > That makes no more sense than the sentence it's supposed to clarify. > > The front end converts Go trees to GCC trees, and it was written by a > > person. Does this mean that Go gets compiled into C? No. > > > > >>> Do you have any idea what a compiler front end does? > > > > > Absolutely, I've written a half-dozen or so from scratch, so they > > > don't follow standard techniques... I've also written a Forth > > > interpreter in C from scratch using the historical methods. Oddly, > > > that uses many of the standard Computer Science techniques, but > > > simplified, and given weird non-Computer Science terminology... > > > I've also used flex and bison for full ISO C front end. But, you > > > should've known that from my description below involving ASTs, etc. > > > > Not really. Your postings are sometimes so incoherent it's hard to > > tell. > > > > >> > It really doesn't matter whether you look at the high-level > > >> > overview, i.e., compiles into C, or you switch topics to the > > >> > actual low-level implementation specific details. The result > > >> > and process is the same or nearly so. The code is parsed and > > >> > represented as either C or a representation of C. To do that, > > >> > at some point it was converted to C, even if that was only > > >> > once. > > >> > > > >> > In the high-level perspective, the Go code goes through this > > >> > process (basically): > > >> > > > >> > Go -> emitted as C > > >> > > >> No. There is a GCC front end for go. It does not get converted > > >> into C. > > > > > > Either way, the code is or was converted to C or a internal > > > representation of C. > > > > It is converted into GCC generic trees. C is a programming langauge. > > Go is not converted into C. The C compiler is not involved. > > > > >> > With -O1, -O2, and -O3 optimization, the code is roughly 90%, > > >> > 95%, 99% the same. The only real difference is whether there > > >> > is a file of actual emitted C code or not. > > >> > > >> Indeed, that is the difference. > > > > > > Indeed, that is one difference. > > > > > > Either way, the code is or was converted to C or a internal > > > representation of C. > > > > You are now back-pedalling on your original claim which was: > > > > >> > In both cases, the Go code is still converted to C, and is > > >> > still represented as C. > > > > This now stands revealed as nonsense. > > > > >> > Why? Because, the AST for GCC was designed to represent C code. > > >> > I.e., to write a Go front end for C one converts the Go code into > > >> > equivalent C code for all the syntactic elements of Go. Next, > > >> > the equivalent C code for Go is parsed by GCC's C front end. > > >> > > >> No, that's not right. > > > > > > Yes, it is. Well, that's the 2nd easiest way. > > > > The question isn't what the easiest way is, but how it actually works. > > The C front end is only involved when parsing C source code. When > > compiling Go, the C front end is not called. > > > > > The 1st easiest way is to emit C code directly. > > > > Which the Go compiler doesn't do. > > > > >> The C front end does not get called; it is not involved in any way. > > > > > > You're correct. > > > > Excellent. That's all I wanted. > > > > > However, I didn't say that here for this case. I said that for the > > > other case. So, please, re-read. > > > > Did you, or did you not, claim that: "the equivalent C code for Go is > > parsed by GCC's C front end." ? > > > > >> The go code is parsed and compiled straight into GCC trees. > > > > > > Well, that's what was said here. Please, read more carefully. > > > > Did you, or did you not, claim that: "the equivalent C code for Go is > > parsed by GCC's C front end." ? > > > > >> > This is where they tell you GCC only handles an AST for C, but > > >> > that it can be used for similar languages, i.e., those > > >> > compileable to C... > > >> > http://gcc.gnu.org/onlinedocs/gccint/Languages.html#Languages > > >> > > >> Which doesn't say what you think it says. > > > > > > Read the first sentence. > > > > > > If it doesn't say that, what does it say? > > > > It says that the interface to front ends for languages in GCC, and in > > particular the tree structure (see GENERIC), was initially designed > > for C, and many aspects of it are still somewhat biased towards C and > > C-like languages. It is, however, reasonably well suited to other > > procedural languages, and front ends for many such languages have been > > written for GCC. > > > > >> > AIR, I provide proof to you (and others here) that nearly all > > >> > languages are or have been compiled to C, and all major > > >> > languages of use today are C derivatives (currently, over > > >> > 61%). > > >> > > >> That may be what you recall; it's not what anyone else recalls. > > > > > > Well, I did so. > > > > Not really, no, especially not if that claim is based on your > > misunderstanding that > > > > >> >> > > Go is one just more example of a language that is > > >> >> > > compiled to C, > > > > Andrew. hold him down and fuck him until he admits his error
Back to comp.lang.forth | Previous | Next — Previous in thread | Next in thread | Find similar
are forthers still unimpressed with go lang? the_gavino_himself <visphatesjava@gmail.com> - 2013-04-30 15:12 -0700
Re: are forthers still unimpressed with go lang? Hugh Aguilar <hughaguilar96@yahoo.com> - 2013-04-30 20:52 -0700
Re: are forthers still unimpressed with go lang? the_gavino_himself <visphatesjava@gmail.com> - 2013-05-03 15:59 -0700
Re: are forthers still unimpressed with go lang? "Rod Pemberton" <do_not_have@notemailnotq.cpm> - 2013-05-01 08:02 -0400
Re: are forthers still unimpressed with go lang? Mark Wills <forthfreak@gmail.com> - 2013-05-01 05:33 -0700
Re: are forthers still unimpressed with go lang? Andrew Haley <andrew29@littlepinkcloud.invalid> - 2013-05-01 10:02 -0500
Re: are forthers still unimpressed with go lang? Hugh Aguilar <hughaguilar96@yahoo.com> - 2013-05-01 15:28 -0700
Re: are forthers still unimpressed with go lang? "Rod Pemberton" <do_not_have@notemailnotq.cpm> - 2013-05-03 16:07 -0400
Re: are forthers still unimpressed with go lang? Andrew Haley <andrew29@littlepinkcloud.invalid> - 2013-05-03 17:49 -0500
Re: are forthers still unimpressed with go lang? "Rod Pemberton" <do_not_have@notemailnotq.cpm> - 2013-05-05 00:51 -0400
Re: are forthers still unimpressed with go lang? Andrew Haley <andrew29@littlepinkcloud.invalid> - 2013-05-05 04:12 -0500
Re: are forthers still unimpressed with go lang? hughaguilar96@yahoo.com - 2013-05-06 23:17 -0700
Re: are forthers still unimpressed with go lang? AKE <assadebrahim2000@gmail.com> - 2013-05-07 10:36 -0700
Re: are forthers still unimpressed with go lang? "Rod Pemberton" <do_not_have@notemailnotq.cpm> - 2013-05-07 18:57 -0400
Re: are forthers still unimpressed with go lang? Andrew Haley <andrew29@littlepinkcloud.invalid> - 2013-05-08 02:54 -0500
Re: are forthers still unimpressed with go lang? Paul Rubin <no.email@nospam.invalid> - 2013-05-08 02:03 -0700
Re: are forthers still unimpressed with go lang? Andrew Haley <andrew29@littlepinkcloud.invalid> - 2013-05-08 12:18 -0500
Re: are forthers still unimpressed with go lang? hughaguilar96@yahoo.com - 2013-05-08 20:53 -0700
Re: are forthers still unimpressed with go lang? the_gavino_himself <visphatesjava@gmail.com> - 2013-05-07 14:25 -0700
Re: are forthers still unimpressed with go lang? the_gavino_himself <visphatesjava@gmail.com> - 2013-05-03 16:00 -0700
csiph-web