diff options
author | Ian Lance Taylor <ian@gcc.gnu.org> | 2019-02-27 15:51:49 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@gcc.gnu.org> | 2019-02-27 15:51:49 +0000 |
commit | b91dfdcc68b96c399c3815f7700f1803eea34972 (patch) | |
tree | 5460b1f7bea48862229388495dfaae68bf6e8b51 /libgo | |
parent | 86863dad359e4cffb45dac103bc7c37142c7349d (diff) | |
download | gcc-b91dfdcc68b96c399c3815f7700f1803eea34972.zip gcc-b91dfdcc68b96c399c3815f7700f1803eea34972.tar.gz gcc-b91dfdcc68b96c399c3815f7700f1803eea34972.tar.bz2 |
runtime: align first persistentalloc chunk as requested
Backport of upstream https://golang.org/cl/163859.
This fixes various failures on 32-bit SPARC.
Patch from Eric Boctazou.
Reviewed-on: https://go-review.googlesource.com/c/163860
From-SVN: r269258
Diffstat (limited to 'libgo')
-rw-r--r-- | libgo/go/runtime/malloc.go | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libgo/go/runtime/malloc.go b/libgo/go/runtime/malloc.go index d2d86995..b6a7ee1 100644 --- a/libgo/go/runtime/malloc.go +++ b/libgo/go/runtime/malloc.go @@ -1269,7 +1269,7 @@ func persistentalloc1(size, align uintptr, sysStat *uint64) *notInHeap { break } } - persistent.off = sys.PtrSize + persistent.off = round(sys.PtrSize, align) } p := persistent.base.add(persistent.off) persistent.off += size |