The register allocator doesn't like OpArg coming in between other
OpIntArg operations, as it doesn't put the spills in the right place
in that situation.
This is just a bug in the new scheduler, I didn't copy over the
proper score from the old scheduler correctly.
Change-Id: I3b4ee1754982fb360e99c5864b19e7408d60b5bc
Reviewed-on: https://go-review.googlesource.com/c/go/+/462858
Run-TryBot: Keith Randall <khr@golang.org>
Reviewed-by: Cherry Mui <cherryyz@google.com>
Reviewed-by: Keith Randall <khr@google.com>
Auto-Submit: Keith Randall <khr@golang.org>
TryBot-Result: Gopher Robot <gobot@golang.org>
if b != f.Entry {
f.Fatalf("%s appeared outside of entry block, b=%s", v.Op, b.String())
}
- score[v.ID] = ScoreArg
+ score[v.ID] = ScorePhi
case v.Op == OpArg:
// We want all the args as early as possible, for better debugging.
score[v.ID] = ScoreArg