aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/malloc.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/runtime/malloc.go')
-rw-r--r--src/runtime/malloc.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/runtime/malloc.go b/src/runtime/malloc.go
index ffaf92debc..ccdebb26fb 100644
--- a/src/runtime/malloc.go
+++ b/src/runtime/malloc.go
@@ -630,7 +630,7 @@ func mallocinit() {
}
// Initialize the memory limit here because the allocator is going to look at it
// but we haven't called gcinit yet and we're definitely going to allocate memory before then.
- gcController.memoryLimit.Store(maxInt64)
+ gcController.memoryLimit.Store(math.MaxInt64)
}
// sysAlloc allocates heap arena space for at least n bytes. The
@@ -1816,7 +1816,7 @@ func profilealloc(mp *m, x unsafe.Pointer, size uintptr) {
func nextSample() int64 {
if MemProfileRate == 0 {
// Basically never sample.
- return maxInt64
+ return math.MaxInt64
}
if MemProfileRate == 1 {
// Sample immediately.