From d2552037426fe5a190c74172562d897d921fe311 Mon Sep 17 00:00:00 2001 From: Jorropo Date: Wed, 13 Apr 2022 00:32:15 +0000 Subject: [PATCH] cmd/compile: remove unused offset calculation in ssagen#rtcall This offR accumulation isn't used and some really similar code is done later in the Load results block. Change-Id: I2f77a7bfd568e7e5eb9fc519e7c552401b3af9b8 GitHub-Last-Rev: 2c91e5c8987d21203c494f278ff1e05aa3941211 GitHub-Pull-Request: golang/go#52316 Reviewed-on: https://go-review.googlesource.com/c/go/+/400094 Run-TryBot: Keith Randall Auto-Submit: Keith Randall Reviewed-by: Keith Randall Reviewed-by: Keith Randall TryBot-Result: Gopher Robot Reviewed-by: Ian Lance Taylor Reviewed-by: Matthew Dempsky --- src/cmd/compile/internal/ssagen/ssa.go | 7 ------- 1 file changed, 7 deletions(-) diff --git a/src/cmd/compile/internal/ssagen/ssa.go b/src/cmd/compile/internal/ssagen/ssa.go index bd0b9250196..7da145e08db 100644 --- a/src/cmd/compile/internal/ssagen/ssa.go +++ b/src/cmd/compile/internal/ssagen/ssa.go @@ -5535,13 +5535,6 @@ func (s *state) rtcall(fn *obj.LSym, returns bool, results []*types.Type, args . } off = types.Rnd(off, int64(types.RegSize)) - // Accumulate results types and offsets - offR := off - for _, t := range results { - offR = types.Rnd(offR, t.Alignment()) - offR += t.Size() - } - // Issue call var call *ssa.Value aux := ssa.StaticAuxCall(fn, s.f.ABIDefault.ABIAnalyzeTypes(nil, callArgTypes, results))