summaryrefslogtreecommitdiff
path: root/src/lj_asm_arm.h
diff options
context:
space:
mode:
authorMike Pall <mike>2012-08-25 14:13:47 +0200
committerMike Pall <mike>2012-08-25 14:13:47 +0200
commit099635c86c98b08bf07fc948fc8638c8e4ad59f2 (patch)
tree3c79fa85766b2a379f52ca6efa206837b3828946 /src/lj_asm_arm.h
parentf2479a96542c639861fb40c721c07f9c53cae20a (diff)
downloadluajit2-099635c86c98b08bf07fc948fc8638c8e4ad59f2.tar.gz
ARM: Fix commit ceaa60c0.
Diffstat (limited to 'src/lj_asm_arm.h')
-rw-r--r--src/lj_asm_arm.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/lj_asm_arm.h b/src/lj_asm_arm.h
index 618bc5b7..e865850d 100644
--- a/src/lj_asm_arm.h
+++ b/src/lj_asm_arm.h
@@ -358,8 +358,6 @@ static void asm_gencall(ASMState *as, const CCallInfo *ci, IRRef *args)
if (irt_isfp(ir->t)) {
RegSet of = as->freeset;
Reg src;
- /* Workaround to protect argument GPRs from being used for remat. */
- as->freeset &= ~RSET_RANGE(REGARG_FIRSTGPR, REGARG_LASTGPR+1);
if (!LJ_ABI_SOFTFP && !(ci->flags & CCI_VARARG)) {
if (irt_isnum(ir->t)) {
if (fpr <= REGARG_LASTFPR) {
@@ -377,10 +375,15 @@ static void asm_gencall(ASMState *as, const CCallInfo *ci, IRRef *args)
fprodd = fpr++;
continue;
}
+ /* Workaround to protect argument GPRs from being used for remat. */
+ as->freeset &= ~RSET_RANGE(REGARG_FIRSTGPR, REGARG_LASTGPR+1);
src = ra_alloc1(as, ref, RSET_FPR); /* May alloc GPR to remat FPR. */
+ as->freeset |= (of & RSET_RANGE(REGARG_FIRSTGPR, REGARG_LASTGPR+1));
fprodd = 0;
goto stackfp;
}
+ /* Workaround to protect argument GPRs from being used for remat. */
+ as->freeset &= ~RSET_RANGE(REGARG_FIRSTGPR, REGARG_LASTGPR+1);
src = ra_alloc1(as, ref, RSET_FPR); /* May alloc GPR to remat FPR. */
as->freeset |= (of & RSET_RANGE(REGARG_FIRSTGPR, REGARG_LASTGPR+1));
if (irt_isnum(ir->t)) gpr = (gpr+1) & ~1u;