mirror of https://github.com/golang/go.git
runtime/pprof: fix TestCPUProfileWithFork on Windows/ARM
Use smaller heap on Windows/ARM, which generally does not have page file enabled and therefore has limited virtual address space. Updates #26148 Signed-off-by: Jordan Rhee <jordanrh@microsoft.com> Change-Id: I4030be24a10fab7b9b659e3736b7e83f10710bfa Reviewed-on: https://go-review.googlesource.com/c/153719 Run-TryBot: Hyang-Ah Hana Kim <hyangah@gmail.com> Reviewed-by: Ian Lance Taylor <iant@golang.org>
This commit is contained in:
parent
6764d7aeac
commit
da6294a35a
|
|
@ -321,6 +321,10 @@ func TestCPUProfileWithFork(t *testing.T) {
|
|||
// Use smaller size for Android to avoid crash.
|
||||
heap = 100 << 20
|
||||
}
|
||||
if runtime.GOOS == "windows" && runtime.GOARCH == "arm" {
|
||||
// Use smaller heap for Windows/ARM to avoid crash.
|
||||
heap = 100 << 20
|
||||
}
|
||||
if testing.Short() {
|
||||
heap = 100 << 20
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue