Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

runtime: unknown variable size while test with msan #50460

Closed
mengzhuo opened this issue Jan 6, 2022 · 3 comments
Closed

runtime: unknown variable size while test with msan #50460

mengzhuo opened this issue Jan 6, 2022 · 3 comments

Comments

@mengzhuo
Copy link
Contributor

@mengzhuo mengzhuo commented Jan 6, 2022

What version of Go are you using (go version)?

$ go version
go version devel go1.18-b5bfaf410a Thu Jan 6 00:26:47 2022 +0000 linux/amd64

Does this issue reproduce with the latest release?

What operating system and processor architecture are you using (go env)?

go env Output
$ go env
GO111MODULE=""
GOARCH="amd64"
GOBIN=""
GOCACHE="/root/.cache/go-build"
GOENV="/root/.config/go/env"
GOEXE=""
GOEXPERIMENT=""
GOFLAGS=""
GOHOSTARCH="amd64"
GOHOSTOS="linux"
GOINSECURE=""
GOMODCACHE="/root/go/pkg/mod"
GONOPROXY=""
GONOSUMDB=""
GOOS="linux"
GOPATH="/root/go"
GOPRIVATE=""
GOPROXY="https://proxy.golang.org,direct"
GOROOT="/root/godev"
GOSUMDB="sum.golang.org"
GOTMPDIR=""
GOTOOLDIR="/root/godev/pkg/tool/linux_amd64"
GOVCS=""
GOVERSION="devel go1.18-b5bfaf410a Thu Jan 6 00:26:47 2022 +0000"
GCCGO="gccgo"
GOAMD64="v1"
AR="ar"
CC="clang"
CXX="g++"
CGO_ENABLED="1"
GOMOD="/root/godev/src/go.mod"
GOWORK=""
CGO_CFLAGS="-g -O2"
CGO_CPPFLAGS=""
CGO_CXXFLAGS="-g -O2"
CGO_FFLAGS="-g -O2"
CGO_LDFLAGS="-g -O2"
PKG_CONFIG="pkg-config"
GOGCCFLAGS="-fPIC -m64 -pthread -fmessage-length=0 -fdebug-prefix-map=/tmp/go-build2929981647=/tmp/go-build -gno-record-gcc-switches"
GOROOT/bin/go version: go version devel go1.18-b5bfaf410a Thu Jan 6 00:26:47 2022 +0000 linux/amd64
GOROOT/bin/go tool compile -V: compile version devel go1.18-b5bfaf410a Thu Jan 6 00:26:47 2022 +0000
uname -sr: Linux 5.10.0-9-amd64
Distributor ID:	Debian
Description:	Debian GNU/Linux 11 (bullseye)
Release:	11
Codename:	bullseye
/lib/x86_64-linux-gnu/libc.so.6: GNU C Library (Debian GLIBC 2.31-13+deb11u2) stable release version 2.31.
gdb --version: GNU gdb (Debian 10.1-1.7) 10.1.90.20210103-git

What did you do?

cd runtime && CC=clang ~/godev/bin/go test -msan

What did you expect to see?

PASSED

What did you see instead?

./msan_amd64.s:31:1: [amd64] domsanread: unknown variable size; offset 8 is sz+8(FP)
./msan_amd64.s:40:1: [amd64] msanwrite: unknown variable size; offset 8 is sz+8(FP)
./msan_amd64.s:48:1: [amd64] msanmalloc: unknown variable size; offset 8 is sz+8(FP)
./msan_amd64.s:56:1: [amd64] msanfree: unknown variable size; offset 8 is sz+8(FP)
./msan_amd64.s:65:1: [amd64] msanmove: unknown variable size; offset 16 is sz+16(FP)
# runtime_test [runtime.test]
./norace_linux_test.go:28:67: internal compiler error: missed typecheck: 
.   CONVNOP uintptr # norace_linux_test.go:28:67
.   .   ADDR PTR-*uintptr # norace_linux_test.go:28:67
.   .   .   LINKSYMOFFSET Offset:0 uintptr
goroutine 1 [running]:
runtime/debug.Stack()
	/root/godev/src/runtime/debug/stack.go:24 +0x65
cmd/compile/internal/base.FatalfAt({0xe92d10?, 0x0?}, {0xd2874b, 0x15}, {0xc004a8ede8, 0x1, 0x1})
	/root/godev/src/cmd/compile/internal/base/print.go:227 +0x1ca
cmd/compile/internal/base.Fatalf(...)
	/root/godev/src/cmd/compile/internal/base/print.go:196
cmd/compile/internal/walk.walkExpr({0xe92d10, 0xc0006bed20}, 0xc004a8fa70)
	/root/godev/src/cmd/compile/internal/walk/expr.go:48 +0x34b
cmd/compile/internal/walk.walkConv(0xc003112b90, 0xc003112b90?)
	/root/godev/src/cmd/compile/internal/walk/convert.go:23 +0x3b
cmd/compile/internal/walk.walkExpr1({0xe92d10, 0xc003112b90}, 0xc003112b90?)
	/root/godev/src/cmd/compile/internal/walk/expr.go:219 +0x5fb
cmd/compile/internal/walk.walkExpr({0xe92d10, 0xc003112b90}, 0xc004a8fa70)
	/root/godev/src/cmd/compile/internal/walk/expr.go:55 +0x428
cmd/compile/internal/walk.walkAssign(0xc004a8fa70, {0xe923b0, 0xc0006bedc0?})
	/root/godev/src/cmd/compile/internal/walk/assign.go:72 +0x9dc
cmd/compile/internal/walk.walkExpr1({0xe923b0, 0xc0006bedc0}, 0xc0006bedc0?)
	/root/godev/src/cmd/compile/internal/walk/expr.go:179 +0x43f
cmd/compile/internal/walk.walkExpr({0xe923b0, 0xc0006bedc0}, 0xc004a8fa70)
	/root/godev/src/cmd/compile/internal/walk/expr.go:55 +0x428
cmd/compile/internal/walk.appendWalkStmt(0xc004a8fa70, {0xe923b0, 0xc0006bedc0})
	/root/godev/src/cmd/compile/internal/walk/walk.go:256 +0x65
cmd/compile/internal/walk.copyExpr({0xe92d10?, 0xc003112b90}, 0xc004a8fa70?, 0xc004a8f410?)
	/root/godev/src/cmd/compile/internal/walk/expr.go:438 +0xf5
cmd/compile/internal/walk.cheapExpr({0xe92d10, 0xc003112b90}, 0xc004a8f4b8?)
	/root/godev/src/cmd/compile/internal/walk/expr.go:361 +0x76
cmd/compile/internal/walk.walkCheckPtrArithmetic(0xc003112b90, 0xc004a8fa70)
	/root/godev/src/cmd/compile/internal/walk/convert.go:464 +0x237
cmd/compile/internal/walk.walkConv(0xc003112b90, 0xc001308680?)
	/root/godev/src/cmd/compile/internal/walk/convert.go:29 +0xf6
cmd/compile/internal/walk.walkExpr1({0xe92d10, 0xc003112b90}, 0xc003112b90?)
	/root/godev/src/cmd/compile/internal/walk/expr.go:219 +0x5fb
cmd/compile/internal/walk.walkExpr({0xe92d10, 0xc003112b90}, 0xc004a8fa70)
	/root/godev/src/cmd/compile/internal/walk/expr.go:55 +0x428
cmd/compile/internal/walk.walkAssign(0xc004a8fa70, {0xe923b0, 0xc0006be780?})
	/root/godev/src/cmd/compile/internal/walk/assign.go:72 +0x9dc
cmd/compile/internal/walk.walkExpr1({0xe923b0, 0xc0006be780}, 0xc0006be780?)
	/root/godev/src/cmd/compile/internal/walk/expr.go:179 +0x43f
cmd/compile/internal/walk.walkExpr({0xe923b0, 0xc0006be780}, 0xc004a8fa70)
	/root/godev/src/cmd/compile/internal/walk/expr.go:55 +0x428
cmd/compile/internal/walk.walkStmt({0xe923b0, 0xc0006be780?})
	/root/godev/src/cmd/compile/internal/walk/stmt.go:57 +0x7da
cmd/compile/internal/walk.walkStmtList(...)
	/root/godev/src/cmd/compile/internal/walk/stmt.go:175
cmd/compile/internal/walk.Walk(0xc001737340)
	/root/godev/src/cmd/compile/internal/walk/walk.go:43 +0x151
cmd/compile/internal/gc.prepareFunc(0xc001737340)
	/root/godev/src/cmd/compile/internal/gc/compile.go:92 +0x6d
cmd/compile/internal/gc.enqueueFunc(0xc001737340)
	/root/godev/src/cmd/compile/internal/gc/compile.go:66 +0x2fd
cmd/compile/internal/gc.Main(0xd4bd08)
	/root/godev/src/cmd/compile/internal/gc/main.go:309 +0xf97
main.main()
	/root/godev/src/cmd/compile/main.go:55 +0xdd

FAIL runtime [build failed]

@ianlancetaylor
Copy link
Contributor

@ianlancetaylor ianlancetaylor commented Jan 6, 2022

What exactly did you do to get that result? I don't know how to recreate the problem. Thanks.

@mengzhuo
Copy link
Contributor Author

@mengzhuo mengzhuo commented Jan 6, 2022

What exactly did you do to get that result? I don't know how to recreate the problem. Thanks.

Sorry, I forgot to put command line in report.
cd runtime && CC=clang ~/godev/bin/go test -msan

@ianlancetaylor
Copy link
Contributor

@ianlancetaylor ianlancetaylor commented Jan 6, 2022

Ah. That is not expected to work. The runtime package is special, and you can't test it with the sanitizers.

Closing because this is not expected to work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants