diff options
| author | Josh Bleecher Snyder <josharian@gmail.com> | 2017-03-21 12:13:12 -0700 |
|---|---|---|
| committer | Josh Bleecher Snyder <josharian@gmail.com> | 2017-03-21 19:26:19 +0000 |
| commit | 89840e4ac9525ddff2b04a8f17fe5b85e96f9bdc (patch) | |
| tree | 0f6ede2a980abbfd77e016751af9b81e2a0a2ad9 /src | |
| parent | baa0fdd0934cb9dca88ea0effb46cf42089c9ccd (diff) | |
| download | go-89840e4ac9525ddff2b04a8f17fe5b85e96f9bdc.tar.xz | |
cmd/compile: eliminate a Curfn reference in plive
I think this got lost in a rebase somewhere.
Updates #15756
Change-Id: Ia3e7c60d1b9254f2877217073732b46c91059ade
Reviewed-on: https://go-review.googlesource.com/38425
Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com>
Reviewed-by: Matthew Dempsky <mdempsky@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Diffstat (limited to 'src')
| -rw-r--r-- | src/cmd/compile/internal/gc/plive.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/cmd/compile/internal/gc/plive.go b/src/cmd/compile/internal/gc/plive.go index 8b8882ac55..548f1ea6c6 100644 --- a/src/cmd/compile/internal/gc/plive.go +++ b/src/cmd/compile/internal/gc/plive.go @@ -413,8 +413,8 @@ func localswords(lv *Liveness) int32 { } // Returns the number of words of in and out arguments. -func argswords() int32 { - return int32(Curfn.Type.ArgWidth() / int64(Widthptr)) +func argswords(lv *Liveness) int32 { + return int32(lv.fn.Type.ArgWidth() / int64(Widthptr)) } // Generates live pointer value maps for arguments and local variables. The @@ -1082,7 +1082,7 @@ func finishgclocals(sym *Sym) { // length of the bitmaps. All bitmaps are assumed to be of equal length. The // remaining bytes are the raw bitmaps. func livenessemit(lv *Liveness, argssym, livesym *Sym) { - args := bvalloc(argswords()) + args := bvalloc(argswords(lv)) aoff := duint32(argssym, 0, uint32(len(lv.livevars))) // number of bitmaps aoff = duint32(argssym, aoff, uint32(args.n)) // number of bits in each bitmap |
