Repository navigation
Closed
Labels
FrozenDueToAgeNeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Milestone
Description
For example:
https://build.golang.org/log/e0e92d72d0a3ca60d2b158135c420739dc0b7308
https://build.golang.org/log/956610b6addc3783bca4ef6f9b4a784581a9693e
https://build.golang.org/log/1718e9a596ccee492fc8e5c7f7814122bd147024
The error is usually along the lines of:
--- FAIL: TestGdbBacktrace (2.26s)
runtime-gdb_test.go:59: gdb version 7.9
runtime-gdb_test.go:345: could not find '#0.*main\.eee' in backtrace
runtime-gdb_test.go:346: gdb output:
warning: File "/data/mips/go/src/runtime/runtime-gdb.py" auto-loading has been declined by your `auto-load safe-path' set to "$debugdir:$datadir/auto-load".
To enable execution of this file add
add-auto-load-safe-path /data/mips/go/src/runtime/runtime-gdb.py
line to your configuration file "/mips/proj/build-compiler/upstream-testing/go-lang/.gdbinit".
To completely disable this security protection add
set auto-load safe-path /
line to your configuration file "/mips/proj/build-compiler/upstream-testing/go-lang/.gdbinit".
For more information about this security protection see the
"Auto-loading safe path" section in the GDB manual. E.g., run from the shell:
info "(gdb)Auto-loading safe path"
Breakpoint 1 at 0x67664: main.eee. (2 locations)
Breakpoint 1, main.ddd (~r0=<optimized out>) at /tmp/go-build199996638/main.go:14
14 func ddd() bool { return f() }
#0 main.ddd (~r0=<optimized out>) at /tmp/go-build199996638/main.go:14
#1 0x0006764c in main.ccc (~r0=<optimized out>) at /tmp/go-build199996638/main.go:11
#2 0x00067600 in main.bbb (~r0=<optimized out>) at /tmp/go-build199996638/main.go:8
#3 0x000675b4 in main.aaa (~r0=<optimized out>) at /tmp/go-build199996638/main.go:5
#4 0x00067700 in main.main () at /tmp/go-build199996638/main.go:22
Breakpoint 1, main.eee (~r0=<optimized out>) at /tmp/go-build199996638/main.go:17
17 func eee() bool { return true }
FAIL
FAIL runtime 146.377s
Note that these builders were already somewhat flakey, as can be seen on the build dashboard. But after that CL, they seem to almost always fail with this error.
Metadata
Metadata
Assignees
Labels
FrozenDueToAgeNeedsInvestigationSomeone must examine and confirm this is a valid issue and not a duplicate of an existing one.Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
Activity
mengzhuo commentedon Apr 5, 2018
same as arm64
dr2chase commentedon Apr 5, 2018
I will look at this, I am happy to see a failure on arm64 since I actually have easy access to one of those.
laboger commentedon Apr 5, 2018
Not sure if this helps, but I tried this on a ppc64le system and here is what I see when I try to use gdb on the test program:
Setting the breakpoint at main.eee also seems to be setting it at main.ddd in the latest.
I tried the same thing with a toolchain that's a bit older and it only set 1 breakpoint and the gdb traceback output looks right.
gopherbot commentedon Apr 5, 2018
Change https://golang.org/cl/104955 mentions this issue:
cmd/compile: ensure first instruction of function is stmtdr2chase commentedon Apr 5, 2018
@laboger That helps -- it's the exact same failure as arm64. First instruction isn't marked as a statement, so gdb "isn't sure" if the 0x5b4a0 is in eee or the function containing the previous statement, which is ddd, so it sets breakpoints in both places.
laboger commentedon Apr 5, 2018
That fixes it.
mvdan commentedon Apr 6, 2018
The PPC64 builders are already happy :) Thanks @dr2chase!
mengzhuo commentedon Apr 8, 2018
arm64 is happy too
Thanks @dr2chase