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: Test Scavenge/PreserveHugePageBottom failed on linux/mips64le #35449

Closed
mengzhuo opened this issue Nov 8, 2019 · 5 comments
Closed

runtime: Test Scavenge/PreserveHugePageBottom failed on linux/mips64le #35449

mengzhuo opened this issue Nov 8, 2019 · 5 comments
Assignees
Milestone

Comments

@mengzhuo
Copy link
Contributor

@mengzhuo mengzhuo commented Nov 8, 2019

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

$ go version
go version devel +45b4ed7 Fri Nov 8 04:44:53 2019 +0000 linux/mips64le

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

linux/mips64le

What did you do?

https://build.golang.org/log/c487a3da5c5d67c6d9619e3ed77a8a5c96d06a11
The dashboard shows it failed since https://go-review.googlesource.com/c/go/+/195697

fatal error: index out of range

goroutine 22778 [running]:
runtime.throw(0x1202b0d6c, 0x12)
	/tmp/workdir-host-linux-mipsle-mengzhuo/go/src/runtime/panic.go:1106 +0x6c fp=0xc00011fe28 sp=0xc00011fe00 pc=0x12003fd2c
runtime.panicCheck1(0x120034c50, 0x1202b0d6c, 0x12)
	/tmp/workdir-host-linux-mipsle-mengzhuo/go/src/runtime/panic.go:34 +0x110 fp=0xc00011fe50 sp=0xc00011fe28 pc=0x12003ccd0
runtime.goPanicIndexU(0x3f, 0x8)
	/tmp/workdir-host-linux-mipsle-mengzhuo/go/src/runtime/panic.go:91 +0x54 fp=0xc00011fe90 sp=0xc00011fe50 pc=0x12003ce74
runtime.(*pageBits).setRange(0xc0000ae000, 0x0, 0xff6)
	/tmp/workdir-host-linux-mipsle-mengzhuo/go/src/runtime/mpallocbits.go:38 +0x190 fp=0xc00011fea8 sp=0xc00011fe90 pc=0x120034c50
runtime.(*pallocBits).allocRange(...)
	/tmp/workdir-host-linux-mipsle-mengzhuo/go/src/runtime/mpallocbits.go:319
runtime.(*pallocData).allocRange(0xc0000ae000, 0x0, 0xff6)
	/tmp/workdir-host-linux-mipsle-mengzhuo/go/src/runtime/mpallocbits.go:369 +0x50 fp=0xc00011fec8 sp=0xc00011fea8 pc=0x120035c58
runtime.(*PallocData).AllocRange(...)
	/tmp/workdir-host-linux-mipsle-mengzhuo/go/src/runtime/export_test.go:673
runtime_test.makePallocData(0xc00049a600, 0x2, 0x2, 0x0, 0x0, 0x0, 0x88fa6230e6330)
	/tmp/workdir-host-linux-mipsle-mengzhuo/go/src/runtime/mgcscavenge_test.go:24 +0x134 fp=0xc00011ff08 sp=0xc00011fec8 pc=0x1201dbed4
runtime_test.TestPallocDataFindScavengeCandidate.func1(0xc0003c0240)
	/tmp/workdir-host-linux-mipsle-mengzhuo/go/src/runtime/mgcscavenge_test.go:251 +0x68 fp=0xc00011ff80 sp=0xc00011ff08 pc=0x120219d20
testing.tRunner(0xc0003c0240, 0xc0000740c0)
	/tmp/workdir-host-linux-mipsle-mengzhuo/go/src/testing/testing.go:954 +0xf8 fp=0xc00011ffc8 sp=0xc00011ff80 pc=0x120106f00
runtime.goexit()
	/tmp/workdir-host-linux-mipsle-mengzhuo/go/src/runtime/asm_mips64x.s:646 +0x4 fp=0xc00011ffc8 sp=0xc00011ffc8 pc=0x120080e74
created by testing.(*T).Run
	/tmp/workdir-host-linux-mipsle-mengzhuo/go/src/testing/testing.go:1005 +0x378

@mengzhuo

This comment has been minimized.

Copy link
Contributor Author

@mengzhuo mengzhuo commented Nov 8, 2019

Main reason: huge page is way more huge then 2M

cat /sys/kernel/mm/transparent_hugepage/hpage_pmd_size
33554432

and the test try to alloc no more than huge page limit .

PallocChunkPages - (uint(PhysHugePageSize / uintptr(PageSize) + 2)

however, when hpage is more than 2M, it will cause uint subtraction overflow.

@gopherbot

This comment has been minimized.

Copy link

@gopherbot gopherbot commented Nov 8, 2019

Change https://golang.org/cl/206097 mentions this issue: runtime: skip PallocDataFindScavengeCandidate if hugepage is too large

@bcmills bcmills added this to the Go1.14 milestone Nov 8, 2019
@bcmills bcmills added the Soon label Nov 8, 2019
@mknyszek

This comment has been minimized.

Copy link
Contributor

@mknyszek mknyszek commented Nov 8, 2019

I uploaded fix for this yesterday and filed an issue about it.

https://go-review.googlesource.com/c/go/+/205937

#35431

The only reason it hasn't landed was because I was unable to validate myself, either via the SlowBots or a gomote.

@mknyszek

This comment has been minimized.

Copy link
Contributor

@mknyszek mknyszek commented Nov 8, 2019

Duplicate of #35431.

@mengzhuo

This comment has been minimized.

Copy link
Contributor Author

@mengzhuo mengzhuo commented Nov 8, 2019

Close
Duplicate of #35431.

@mengzhuo mengzhuo closed this Nov 8, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants
You can’t perform that action at this time.