aboutsummaryrefslogtreecommitdiff
path: root/src/cmd
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@golang.org>2025-12-04 13:49:21 -0800
committerGopher Robot <gobot@golang.org>2026-02-10 21:27:59 -0800
commita430bc1bd73ab9a7d4a0c740add9760914588396 (patch)
tree592d32b39ac9e812cb50ff4cab2046d080043ab2 /src/cmd
parent67d449c0a608ab6c9891bb9b16cc14016bde8848 (diff)
downloadgo-a430bc1bd73ab9a7d4a0c740add9760914588396.tar.xz
cmd/compile, runtime: set alignment of type descriptors
This trivial change reduces the size of cmd/go by 88K. For #6853 For #36313 Change-Id: I5e74acf118bd1c63cbdd256879d8aa8d72a50505 Reviewed-on: https://go-review.googlesource.com/c/go/+/727021 Reviewed-by: Cherry Mui <cherryyz@google.com> LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com> Reviewed-by: Keith Randall <khr@golang.org> Reviewed-by: Carlos Amedee <carlos@golang.org> Reviewed-by: Keith Randall <khr@google.com> Auto-Submit: Ian Lance Taylor <iant@golang.org>
Diffstat (limited to 'src/cmd')
-rw-r--r--src/cmd/compile/internal/reflectdata/reflect.go1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/cmd/compile/internal/reflectdata/reflect.go b/src/cmd/compile/internal/reflectdata/reflect.go
index c3f041ec57..ea3d0b5b94 100644
--- a/src/cmd/compile/internal/reflectdata/reflect.go
+++ b/src/cmd/compile/internal/reflectdata/reflect.go
@@ -963,6 +963,7 @@ func writeType(t *types.Type) *obj.LSym {
keep = false
}
lsym.Set(obj.AttrMakeTypelink, keep)
+ lsym.Align = int16(types.PtrSize)
return lsym
}