]> Cypherpunks repositories - gostls13.git/commitdiff
runtime: use smaller max align for arm32
authorKeith Randall <khr@golang.org>
Wed, 28 Jan 2026 23:39:46 +0000 (15:39 -0800)
committerGopher Robot <gobot@golang.org>
Thu, 29 Jan 2026 21:04:30 +0000 (13:04 -0800)
Maybe fixes a dashboard build failure for linux/arm32 casued
by CL 724261.

This value comes from cmd/link/internal/arm/l.go (and in general,
maxAlign in cmd/link/internal/$ARCH/<something>.go).

Change-Id: I4d02cd41072da1b6ad6c7405044bd7788626b013
Reviewed-on: https://go-review.googlesource.com/c/go/+/740101
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Keith Randall <khr@google.com>
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Auto-Submit: Keith Randall <khr@google.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
src/runtime/type.go

index c5262ccd0fef80ca832a3d73a49195c863e90f23..78018fd9a88e45b7759d0bfcb6451d01a258f1e2 100644 (file)
@@ -526,7 +526,11 @@ func moduleTypelinks(md *moduledata) []*_type {
        for td < etypedesc {
                // TODO: The fact that type descriptors are aligned to
                // 0x20 does not make sense.
-               td = alignUp(td, 0x20)
+               if GOARCH == "arm" {
+                       td = alignUp(td, 0x8)
+               } else {
+                       td = alignUp(td, 0x20)
+               }
 
                // This code must match the data structures built by
                // cmd/compile/internal/reflectdata/reflect.go:writeType.