From: Than McIntosh Date: Sun, 9 Mar 2025 12:59:45 +0000 (-0400) Subject: cmd/cgo/internal/testsanitizers: bump GCC version for asan location checking X-Git-Tag: go1.25rc1~786 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=fd3997168d24eca57394026428e39afea20f3ae1;p=gostls13.git cmd/cgo/internal/testsanitizers: bump GCC version for asan location checking Require GCC 11 or greater to turn on the location checking portion of the asan tests in this directory; the copy of libasan.so.6 shipped with GCC 10 doesn't seem to properly digest the new DWARF 5 being generated by the Go compiler+linker. Updates #72752. Change-Id: I92718c112df844d9333c4c798cddaae95665feb2 Reviewed-on: https://go-review.googlesource.com/c/go/+/656175 Reviewed-by: Cherry Mui Reviewed-by: Ian Lance Taylor LUCI-TryBot-Result: Go LUCI --- diff --git a/src/cmd/cgo/internal/testsanitizers/cc_test.go b/src/cmd/cgo/internal/testsanitizers/cc_test.go index fa0105b11a..7233b6a775 100644 --- a/src/cmd/cgo/internal/testsanitizers/cc_test.go +++ b/src/cmd/cgo/internal/testsanitizers/cc_test.go @@ -266,7 +266,12 @@ func compilerSupportsLocation() bool { } switch compiler.name { case "gcc": - return compiler.major >= 10 + // TODO(72752): the asan runtime support library + // (libasan.so.6) shipped with GCC 10 has problems digesting + // version 5 DWARF produced by the Go toolchain. Disable + // location checking if gcc is not sufficiently up to date in + // this case. + return compiler.major > 10 case "clang": // TODO(65606): The clang toolchain on the LUCI builders is not built against // zlib, the ASAN runtime can't actually symbolize its own stack trace. Once