[Bug 1279620] Re: stack corruption running "go install launchpad.net/juju-core/..."

Michael Hudson-Doyle michael.hudson+lp at canonical.com
Mon Feb 17 01:30:53 UTC 2014


OK, so it's definitely signal handling: for whatever reason, signals are
not being executed on the stack requested via sigaltstack.  Sooner or
later, one gets executed where writing to the stack causes real
problems.

You can make this happen a LOT more frequently by invoking "touch"
instead of whatever program go is running, this sort of thing in
build.go:runOut:

+       ncl := []string{"touch"}
+       for i, c := range cmdline {
+               if c == "-o" || c == "cru" {
+                       f := cmdline[i+1]
+                       if f[0] != '/' { f = dir + "/" + f }
+                       ncl = append(ncl, f)
+               }
+       }
+       cmdline = ncl

So I'm suspecting a kernel bug now.  The go runtime uses
getcontext/makecontext/setcontext a lot and something must be getting
confused.

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to gcc-4.8 in Ubuntu.
https://bugs.launchpad.net/bugs/1279620

Title:
  stack corruption running "go install launchpad.net/juju-core/..."

Status in “gcc-4.8” package in Ubuntu:
  New

Bug description:
  This is the sort of bug I was hoping we were going to escape in this
  porting effort :(

  It's not frequent, but maybe 10% of the time go install launchpad.net
  /juju-core/... will fail with some kind of memory error. It's not
  exactly the same error every time, but it's consistent with something
  scribbling on the stack.  It doesn't seem to happen if you run pass -p
  1 to install, which limits the parallelism inside the install command,
  so it's probably some kind of race.  Yay!

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/gcc-4.8/+bug/1279620/+subscriptions



More information about the foundations-bugs mailing list