
Go from C to Go [video] - cespare
http://confreaks.com/videos/3432-gophercon2014-go-from-c-to-go
======
madhusudancs
People who have posted the original video, if you are reading this, please fix
the speaker's name in the youtube video title. His name is Russ Cox, not Rob
Cox. It pains me to see wrong names, it almost feels to me like miscrediting
:P

~~~
randquistcp
Name fixed, thank you for pointing it out.

~~~
madhusudancs
Thank you very much for fixing this!

------
casca
Youtube link for anyone else who likes to download for sped-up viewing:
[http://www.youtube.com/watch?v=QIE5nV5fDwA](http://www.youtube.com/watch?v=QIE5nV5fDwA)

------
vanderZwan
So who else is _extremely_ curious about the "difficult to explain" goto
statement? (about 17 minutes in)

~~~
jakestl
I think he just meant it was hard to capture what it was doing in a brief
statement like the others were.

~~~
vanderZwan
Yes, but he made it sound like it was a legit use of the goto statement, which
makes it more intriguing what it can be if it doesn't fall under any of the
other descriptions.

------
pjmlp
Nice to see this going on.

I think compilers should be bootstraped, after the basic language is in place.

------
zura
I'm more interested to hear `from C++ to Go` stories :)

~~~
4ad
This presentation is about using an automated program to convert the existing
Plan 9-based Go compiler suite from C to Go, it's not a "rewriting
infrastructure in Go" story.

~~~
logicchains
Part of me dreams that they'd be able to convert the whole Plan 9 OS into Go
one day, but that's probably hoping for too much.

~~~
coldtea
Seems like a rather pointless dream. What would be the benefit? A slower OS
with GC pauses?

~~~
jesstaa
Plan9 was already largely rewritten in a precursor to Go called Limbo. It's
garbage collected and runs on a virtual machine.
[http://en.wikipedia.org/wiki/Inferno_(operating_system)](http://en.wikipedia.org/wiki/Inferno_\(operating_system\))

~~~
4ad
Plan 9 and Inferno are very related, but I wouldn't say Inferno is "Plan 9
rewritten in Limbo", nor is Limbo equivalent enough to Go for the comparison
to make sense.

First, the Inferno kernel is written in C, not Limbo, and is somewhat similar
to the Plan 9 kernel to the point that is moderately feasible to port drivers
from Plan 9 to Inferno.

Second, you could say acme was rewritten from alef (not C) to Limbo, and maybe
you can say cat, tail, mk and yacc were "rewritten in Limbo", but soon after
the list ends. Most utilities are genuinely new utilities that make use of the
different abstractions provided by the operating system. Of course there are
lots of high-level similarities, but they are quite different programs.

This brings me to my next point, the abstractions provided by Plan 9 and
Inferno are very different. Different enough that a new set of tools makes
sense. For comparison, rewriting C code to Go uses the same underlying
abstractions, so it doesn't make as much sense.

Another point I want to make is that compiled Limbo programs are extremely
small, and Limbo is dynamically loaded, unlike Go.

Yet another point is that Limbo programs use reference counting plus a real-
time garbage collector for cycles, which is made easier by Limbo and Inferno
constraints. Go uses neither and the language is different enough to prevent a
real time garbage collector.

