]> Cypherpunks repositories - gostls13.git/commit
cmd/compile/internal/abi: fix ComputePadding
authorDerek Parker <parkerderek86@gmail.com>
Wed, 19 Mar 2025 01:54:41 +0000 (01:54 +0000)
committerKeith Randall <khr@golang.org>
Thu, 20 Mar 2025 22:45:30 +0000 (15:45 -0700)
commita20d583bb99cb2715dd412738c3c5f56e8700158
treef79f1ded1af62f1f3532915baa7f310ce54071d4
parent2ffda87f2dce71024f72ccff32cbfe29ee676bf8
cmd/compile/internal/abi: fix ComputePadding

Fixes the ComputePadding calculation to take into account
the padding added for the current offset. This fixes an issue
where padding can be added incorrectly for certain structs.

Related: https://github.com/go-delve/delve/issues/3923

Fixes #72053

Change-Id: I277629799168c6b44bc9ed03df4345e0318064ce
GitHub-Last-Rev: 9478b29a137e20421ad348bb93a54406b1977008
GitHub-Pull-Request: golang/go#72805
Reviewed-on: https://go-review.googlesource.com/c/go/+/656736
LUCI-TryBot-Result: Go LUCI <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Cherry Mui <cherryyz@google.com>
Reviewed-by: Keith Randall <khr@google.com>
src/cmd/compile/internal/abi/abiutils.go
src/cmd/compile/internal/ssa/debug.go
src/cmd/compile/internal/test/abiutils_test.go
src/cmd/link/internal/ld/dwarf_test.go