aboutsummaryrefslogtreecommitdiff
path: root/src/cmd/compile/internal/mips
diff options
context:
space:
mode:
authorJosh Bleecher Snyder <josharian@gmail.com>2017-03-17 08:55:40 -0700
committerJosh Bleecher Snyder <josharian@gmail.com>2017-03-17 23:56:22 +0000
commit174b858f7855077839335a7e54ff7b18d7a59a8c (patch)
treee7b0e503d740fef487839d9e39221e50d6817fc1 /src/cmd/compile/internal/mips
parentd83af90a894cc6edaed97cea0edac62dfe8ba69a (diff)
downloadgo-174b858f7855077839335a7e54ff7b18d7a59a8c.tar.gz
go-174b858f7855077839335a7e54ff7b18d7a59a8c.zip
cmd/compile: pass frame size to defframe
Preparation for de-globalizing Stksize and MaxArg. Passes toolstash -cmp. No compiler performance impact. Updates #15756 Change-Id: I312f0bbd15587a6aebf472cd66c8e62b89e55c8a Reviewed-on: https://go-review.googlesource.com/38328 Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com> Reviewed-by: Matthew Dempsky <mdempsky@google.com>
Diffstat (limited to 'src/cmd/compile/internal/mips')
-rw-r--r--src/cmd/compile/internal/mips/ggen.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cmd/compile/internal/mips/ggen.go b/src/cmd/compile/internal/mips/ggen.go
index 73a28d5f31..5d818a6706 100644
--- a/src/cmd/compile/internal/mips/ggen.go
+++ b/src/cmd/compile/internal/mips/ggen.go
@@ -10,12 +10,12 @@ import (
"cmd/internal/obj/mips"
)
-func defframe(ptxt *obj.Prog, fn *gc.Node) {
+func defframe(ptxt *obj.Prog, fn *gc.Node, sz int64) {
// fill in argument size, stack size
ptxt.To.Type = obj.TYPE_TEXTSIZE
ptxt.To.Val = int32(gc.Rnd(fn.Type.ArgWidth(), int64(gc.Widthptr)))
- frame := uint32(gc.Rnd(gc.Stksize+gc.Maxarg, int64(gc.Widthreg)))
+ frame := uint32(gc.Rnd(sz, int64(gc.Widthreg)))
ptxt.To.Offset = int64(frame)
// insert code to zero ambiguously live variables