diff options
author | Quentin Carbonneaux <quentin.carbonneaux@yale.edu> | 2016-02-04 12:19:55 -0500 |
---|---|---|
committer | Quentin Carbonneaux <quentin.carbonneaux@yale.edu> | 2016-02-04 12:19:55 -0500 |
commit | 059d378b9d4115061647b8efae95b3a7dc54abe2 (patch) | |
tree | c55498abca86a1e8b745b4b98fa33625b485bb79 /lisc/spill.c | |
parent | fb838ce09547bc85da10dd447851536867e6f9a9 (diff) | |
download | roux-059d378b9d4115061647b8efae95b3a7dc54abe2.tar.gz |
fix hinting bug in spiller
We have to first free the output register of an instruction before setting the interference hints for inregs temporaries.
Diffstat (limited to 'lisc/spill.c')
-rw-r--r-- | lisc/spill.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lisc/spill.c b/lisc/spill.c index aaec562..ea89fd9 100644 --- a/lisc/spill.c +++ b/lisc/spill.c @@ -478,9 +478,6 @@ spill(Fn *fn) i->arg[n] = slot(t); } } - r = v.t[0] & (BIT(Tmp0)-1); - if (r) - sethint(&v, r); reloads(&u, &v); if (!req(i->to, R)) { t = i->to.val; @@ -488,6 +485,9 @@ spill(Fn *fn) BCLR(v, t); } emiti(*i); + r = v.t[0] & (BIT(Tmp0)-1); + if (r) + sethint(&v, r); } assert(!r || b==fn->start); |