]> Cypherpunks.ru repositories - gostls13.git/commitdiff
Revert "cmd/cgo/internal/testsanitizers: fix msan test failing with clang >= 16"
authorThan McIntosh <thanm@google.com>
Mon, 18 Dec 2023 21:11:13 +0000 (21:11 +0000)
committerGopher Robot <gobot@golang.org>
Mon, 18 Dec 2023 21:30:58 +0000 (21:30 +0000)
This reverts commit https://go.dev/cl/c/go/+/549297

Reason for revert: breaks clang builder

Change-Id: I2321dec9bc1fc20dfafa8a984303b0b5710f8aac
Reviewed-on: https://go-review.googlesource.com/c/go/+/550779
Auto-Submit: Than McIntosh <thanm@google.com>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Mauri de Souza Meneguzzo <mauri870@gmail.com>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
src/cmd/cgo/internal/testsanitizers/msan_test.go
src/cmd/cgo/internal/testsanitizers/testdata/msan8.go

index c534b72442abb199708aa6297b1ec71f843fab1a..83d66f6660d7bfdfaf55c83c692bad006db8e753 100644 (file)
@@ -71,10 +71,7 @@ func TestMSAN(t *testing.T) {
                        defer dir.RemoveAll(t)
 
                        outPath := dir.Join(name)
-                       buildcmd := config.goCmdWithExperiments("build", []string{"-o", outPath, srcPath(tc.src)}, tc.experiments)
-                       // allow tests to define -f flags in CGO_CFLAGS
-                       replaceEnv(buildcmd, "CGO_CFLAGS_ALLOW", "-f.*")
-                       mustRun(t, buildcmd)
+                       mustRun(t, config.goCmdWithExperiments("build", []string{"-o", outPath, srcPath(tc.src)}, tc.experiments))
 
                        cmd := hangProneCmd(outPath)
                        if tc.wantErr {
index e79d343cc7ae4bd365f900ea652b1aaa0271456a..1cb5c5677fa758711ae44a6d04e3fdcccbe6c00e 100644 (file)
@@ -5,13 +5,6 @@
 package main
 
 /*
-// For clang >= 16, uninitialized memory is more aggressively reported.
-// Restore the old behavior for this particular test as it relies on
-// uninitialized variables. See #64616
-#if __clang_major__ >= 16
-#cgo CFLAGS: -fno-sanitize-memory-param-retval
-#endif
-
 #include <pthread.h>
 #include <signal.h>
 #include <stdint.h>