Modified: trunk/Source/_javascript_Core/jit/JITArithmetic32_64.cpp (95296 => 95297)
--- trunk/Source/_javascript_Core/jit/JITArithmetic32_64.cpp 2011-09-16 16:26:20 UTC (rev 95296)
+++ trunk/Source/_javascript_Core/jit/JITArithmetic32_64.cpp 2011-09-16 16:36:22 UTC (rev 95297)
@@ -175,7 +175,7 @@
emitLoad(op1, regT1, regT0);
addSlowCase(branch32(NotEqual, regT1, TrustedImm32(JSValue::Int32Tag)));
lshift32(Imm32(getConstantOperand(op2).asInt32()), regT0);
- emitStoreAndMapInt32(dst, regT1, regT0, dst == op1, OPCODE_LENGTH(op_lshift));
+ emitStoreInt32(dst, regT0, dst == op1);
return;
}
@@ -184,7 +184,7 @@
addSlowCase(branch32(NotEqual, regT1, TrustedImm32(JSValue::Int32Tag)));
addSlowCase(branch32(NotEqual, regT3, TrustedImm32(JSValue::Int32Tag)));
lshift32(regT2, regT0);
- emitStoreAndMapInt32(dst, regT1, regT0, dst == op1 || dst == op2, OPCODE_LENGTH(op_lshift));
+ emitStoreInt32(dst, regT0, dst == op1 || dst == op2);
}
void JIT::emitSlow_op_lshift(Instruction* currentInstruction, Vector<SlowCaseEntry>::iterator& iter)
@@ -228,7 +228,7 @@
} else if (shift) { // signed right shift by zero is simply toInt conversion
rshift32(Imm32(shift & 0x1f), regT0);
}
- emitStoreAndMapInt32(dst, regT1, regT0, dst == op1, OPCODE_LENGTH(op_rshift));
+ emitStoreInt32(dst, regT0, dst == op1);
return;
}
@@ -241,7 +241,7 @@
addSlowCase(branch32(LessThan, regT0, TrustedImm32(0)));
} else
rshift32(regT2, regT0);
- emitStoreAndMapInt32(dst, regT1, regT0, dst == op1, OPCODE_LENGTH(op_rshift));
+ emitStoreInt32(dst, regT0, dst == op1 || dst == op2);
}
void JIT::emitRightShiftSlowCase(Instruction* currentInstruction, Vector<SlowCaseEntry>::iterator& iter, bool isUnsigned)
@@ -342,7 +342,7 @@
emitLoad(op, regT1, regT0);
addSlowCase(branch32(NotEqual, regT1, TrustedImm32(JSValue::Int32Tag)));
and32(Imm32(constant), regT0);
- emitStoreAndMapInt32(dst, regT1, regT0, dst == op, OPCODE_LENGTH(op_bitand));
+ emitStoreInt32(dst, regT0, (op == dst));
return;
}
@@ -350,7 +350,7 @@
addSlowCase(branch32(NotEqual, regT1, TrustedImm32(JSValue::Int32Tag)));
addSlowCase(branch32(NotEqual, regT3, TrustedImm32(JSValue::Int32Tag)));
and32(regT2, regT0);
- emitStoreAndMapInt32(dst, regT1, regT0, (op1 == dst || op2 == dst), OPCODE_LENGTH(op_bitand));
+ emitStoreInt32(dst, regT0, (op1 == dst || op2 == dst));
}
void JIT::emitSlow_op_bitand(Instruction* currentInstruction, Vector<SlowCaseEntry>::iterator& iter)
@@ -383,7 +383,7 @@
emitLoad(op, regT1, regT0);
addSlowCase(branch32(NotEqual, regT1, TrustedImm32(JSValue::Int32Tag)));
or32(Imm32(constant), regT0);
- emitStoreAndMapInt32(dst, regT1, regT0, op == dst, OPCODE_LENGTH(op_bitor));
+ emitStoreInt32(dst, regT0, (op == dst));
return;
}
@@ -391,7 +391,7 @@
addSlowCase(branch32(NotEqual, regT1, TrustedImm32(JSValue::Int32Tag)));
addSlowCase(branch32(NotEqual, regT3, TrustedImm32(JSValue::Int32Tag)));
or32(regT2, regT0);
- emitStoreAndMapInt32(dst, regT1, regT0, (op1 == dst || op2 == dst), OPCODE_LENGTH(op_bitor));
+ emitStoreInt32(dst, regT0, (op1 == dst || op2 == dst));
}
void JIT::emitSlow_op_bitor(Instruction* currentInstruction, Vector<SlowCaseEntry>::iterator& iter)
@@ -424,7 +424,7 @@
emitLoad(op, regT1, regT0);
addSlowCase(branch32(NotEqual, regT1, TrustedImm32(JSValue::Int32Tag)));
xor32(Imm32(constant), regT0);
- emitStoreAndMapInt32(dst, regT1, regT0, op == dst, OPCODE_LENGTH(op_bitxor));
+ emitStoreInt32(dst, regT0, (op == dst));
return;
}
@@ -432,7 +432,7 @@
addSlowCase(branch32(NotEqual, regT1, TrustedImm32(JSValue::Int32Tag)));
addSlowCase(branch32(NotEqual, regT3, TrustedImm32(JSValue::Int32Tag)));
xor32(regT2, regT0);
- emitStoreAndMapInt32(dst, regT1, regT0, (op1 == dst || op2 == dst), OPCODE_LENGTH(op_bitxor));
+ emitStoreInt32(dst, regT0, (op1 == dst || op2 == dst));
}
void JIT::emitSlow_op_bitxor(Instruction* currentInstruction, Vector<SlowCaseEntry>::iterator& iter)
@@ -462,7 +462,7 @@
addSlowCase(branch32(NotEqual, regT1, TrustedImm32(JSValue::Int32Tag)));
not32(regT0);
- emitStoreAndMapInt32(dst, regT1, regT0, dst == src, OPCODE_LENGTH(op_bitnot));
+ emitStoreInt32(dst, regT0, (dst == src));
}
void JIT::emitSlow_op_bitnot(Instruction* currentInstruction, Vector<SlowCaseEntry>::iterator& iter)
@@ -489,11 +489,10 @@
if (dst == srcDst) // x = x++ is a noop for ints.
return;
- move(regT0, regT2);
- addSlowCase(branchAdd32(Overflow, TrustedImm32(1), regT2));
- emitStoreInt32(srcDst, regT2, true);
+ emitStoreInt32(dst, regT0);
- emitStoreAndMapInt32(dst, regT1, regT0, false, OPCODE_LENGTH(op_post_inc));
+ addSlowCase(branchAdd32(Overflow, TrustedImm32(1), regT0));
+ emitStoreInt32(srcDst, regT0, true);
}
void JIT::emitSlow_op_post_inc(Instruction* currentInstruction, Vector<SlowCaseEntry>::iterator& iter)
@@ -524,11 +523,10 @@
if (dst == srcDst) // x = x-- is a noop for ints.
return;
- move(regT0, regT2);
- addSlowCase(branchSub32(Overflow, TrustedImm32(1), regT2));
- emitStoreInt32(srcDst, regT2, true);
+ emitStoreInt32(dst, regT0);
- emitStoreAndMapInt32(dst, regT1, regT0, false, OPCODE_LENGTH(op_post_dec));
+ addSlowCase(branchSub32(Overflow, TrustedImm32(1), regT0));
+ emitStoreInt32(srcDst, regT0, true);
}
void JIT::emitSlow_op_post_dec(Instruction* currentInstruction, Vector<SlowCaseEntry>::iterator& iter)
@@ -556,7 +554,7 @@
addSlowCase(branch32(NotEqual, regT1, TrustedImm32(JSValue::Int32Tag)));
addSlowCase(branchAdd32(Overflow, TrustedImm32(1), regT0));
- emitStoreAndMapInt32(srcDst, regT1, regT0, true, OPCODE_LENGTH(op_pre_inc));
+ emitStoreInt32(srcDst, regT0, true);
}
void JIT::emitSlow_op_pre_inc(Instruction* currentInstruction, Vector<SlowCaseEntry>::iterator& iter)
@@ -581,7 +579,7 @@
addSlowCase(branch32(NotEqual, regT1, TrustedImm32(JSValue::Int32Tag)));
addSlowCase(branchSub32(Overflow, TrustedImm32(1), regT0));
- emitStoreAndMapInt32(srcDst, regT1, regT0, true, OPCODE_LENGTH(op_pre_dec));
+ emitStoreInt32(srcDst, regT0, true);
}
void JIT::emitSlow_op_pre_dec(Instruction* currentInstruction, Vector<SlowCaseEntry>::iterator& iter)