x64: LAddI must use LEAL, not LEAQ

R=danno@chromium.org

Review URL: https://codereview.chromium.org/17448005

git-svn-id: http://v8.googlecode.com/svn/branches/bleeding_edge@15203 ce2b1a6d-e550-0410-aec6-3dcde31c8c00
parent 1be45275
......@@ -1717,10 +1717,11 @@ void LCodeGen::DoAddI(LAddI* instr) {
if (LAddI::UseLea(instr->hydrogen()) && !left->Equals(instr->result())) {
if (right->IsConstantOperand()) {
int32_t offset = ToInteger32(LConstantOperand::cast(right));
__ lea(ToRegister(instr->result()), MemOperand(ToRegister(left), offset));
__ leal(ToRegister(instr->result()),
MemOperand(ToRegister(left), offset));
} else {
Operand address(ToRegister(left), ToRegister(right), times_1, 0);
__ lea(ToRegister(instr->result()), address);
__ leal(ToRegister(instr->result()), address);
}
} else {
if (right->IsConstantOperand()) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment