]> Cypherpunks repositories - gostls13.git/commitdiff
runtime: disable stack allocation tests on sanitizers
authorKeith Randall <khr@golang.org>
Thu, 20 Nov 2025 18:37:10 +0000 (10:37 -0800)
committerGopher Robot <gobot@golang.org>
Thu, 20 Nov 2025 22:42:50 +0000 (14:42 -0800)
CL 707755 broke the asan/msan builders.

Change-Id: Ic9738140999a9bcfc94cecfe0964a5f1bc243c56
Reviewed-on: https://go-review.googlesource.com/c/go/+/722480
Auto-Submit: Keith Randall <khr@golang.org>
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: David Chase <drchase@google.com>
Reviewed-by: Keith Randall <khr@google.com>
src/runtime/slice_test.go

index 5463b6c02fbe4b3919a2caa9ce95492727743875..376b4a58f239bb9fc55570a7cfc8ca5f594ab1b5 100644 (file)
@@ -6,6 +6,8 @@ package runtime_test
 
 import (
        "fmt"
+       "internal/asan"
+       "internal/msan"
        "internal/race"
        "internal/testenv"
        "runtime"
@@ -516,6 +518,9 @@ func TestAppendByteInLoop(t *testing.T) {
        if race.Enabled {
                t.Skip("skipping in -race mode")
        }
+       if asan.Enabled || msan.Enabled {
+               t.Skip("skipping in sanitizer mode")
+       }
        for _, test := range [][3]int{
                {0, 0, 0},
                {1, 1, 8},
@@ -562,6 +567,9 @@ func TestAppendPtrInLoop(t *testing.T) {
        if race.Enabled {
                t.Skip("skipping in -race mode")
        }
+       if asan.Enabled || msan.Enabled {
+               t.Skip("skipping in sanitizer mode")
+       }
        var tests [][3]int
        if runtime.PtrSize == 8 {
                tests = [][3]int{
@@ -628,6 +636,9 @@ func TestAppendByteCapInLoop(t *testing.T) {
        if race.Enabled {
                t.Skip("skipping in -race mode")
        }
+       if asan.Enabled || msan.Enabled {
+               t.Skip("skipping in sanitizer mode")
+       }
        for _, test := range [][3]int{
                {0, 0, 0},
                {1, 1, 8},