
Fix for Golang runtime memory corruption bug - rargulati
https://go-review.googlesource.com/#/c/34835/
======
morecoffee
One thing I like about rsc (and Austin) is that they have these well explained
commit logs that let's people follow along at home. The changes seem like they
are well justified and made for posterity. This change in particular is a
story more than it is a 3 LOC fix.

~~~
masklinn
I like going through Postgres's commit logs once in a while for exactly that
reason, non-trivial commits (logic wise, they may be a 1LOC commit) get short-
story-scale messages, often with references to ML thread(s) where the issue or
change was discussed. It's a nice change of pace from $dayjob where a commit
changing half the codebase in ways unspecified gets logged as "improvements".

~~~
koolba
> It's a nice change of pace from $dayjob where a commit changing half the
> codebase in ways unspecified gets logged as "improvements".

The best (worst?) one is where you'll see a series of major changes with the
following commit messages:

\- Add feature X ( _no explanation of what it does_ )

\- Fix feature X

\- Really fix feature X

\- Fix feature X for real

\- Finally fixed X

\- Fix test environment

~~~
masklinn
I know you don't work at $dayjob because the last commit would be "fix X test
which is dumb", which removes the test entirely.

------
rargulati
An alternative view:
[https://github.com/golang/go/commit/b902a63ade47cf69218c9b38...](https://github.com/golang/go/commit/b902a63ade47cf69218c9b38c9a783fc8cfc3041)

------
0x0
Does this mean every single application binary compiled with go in the wild up
until today has a memory corruption bug?

If so, it's going to take some effort for this bug to be weeded out in every
single deployment around the world...

~~~
Thaxll
I don't understand this comment, are you implying that it's the first time you
see a runtime with a bug?

~~~
0x0
Well usually you can just update whatever library has the bug and restart your
applications, but as I understand this bug will be statically linked in all
application binaries so they will all have to be recompiled and redeployed?

~~~
Manishearth
Yes, that's what the grandparent is saying, this is a bug in the runtime,
which you can't fix by updating libraries, you have to update the
compiler/interpreter (depending on the language).

This is not a unique occurrence.

~~~
wonko1
I think the original question was querying if the runtime is statically or
dynamically linked.

It's also possibly a subtle dig at go, because unlike other languages go does
not use dynamic linking, meaning bugs in libraries require recompilation (has
positive effects too).

~~~
pjmlp
Yes it does, since Go 1.6.

It just isn't the default compilation mode, you have to explicitly enable it.

------
loppers92
Some of the points are just ridiculous. Because you can't compare java and go
or whatever. If you want complain about a language you should first checking
the history of java or whatever. Maybe this language has runtime bugs in old
versions as well.

------
millstone
I'm surprised there was no test added to ensure this doesn't regress. Any
reason why not?

~~~
more_original
Looks like it's a concurrency bug that is only triggered non-deterministically
under certain circumstances. It is probably hard to reproduce reliably in a
test, if this is possible at all.

------
akavel
I wonder if it'll get backported to at least Go 1.7?

~~~
pkroll
Not sure, but I'd expect it to get fixed in 1.4, since that's the version
needed to generate later versions if you're bootstrapping.

------
johansch
Somewhat OT: Just having recently gotten into Go: How about changing the
official name from Go to Golang? It's not ideal, but so wasn't the naming in
the first place :/ Go isn't particularly search friendly. Quite ironic for a
language coming out of the world's largest search company.

Just try searching for go in the otherwise excellent Algolia HN search engine:

Without quotes:

[http://i.imgur.com/8ztH48u.png](http://i.imgur.com/8ztH48u.png)

With quotes:

[http://i.imgur.com/5a229fC.png](http://i.imgur.com/5a229fC.png)

