Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(197)

Unified Diff: src/crankshaft/mips/lithium-codegen-mips.cc

Issue 2542403002: MIPS: Use JIC/JIALC offset when possible (Closed)
Patch Set: Fix deserialization problem, rebase to master Created 3 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: src/crankshaft/mips/lithium-codegen-mips.cc
diff --git a/src/crankshaft/mips/lithium-codegen-mips.cc b/src/crankshaft/mips/lithium-codegen-mips.cc
index 7fb6f38fcf5ed0c3da7dcdcd174d4ee91dbbda71..38a7b625dc83e1c1ce2f480a8f87e5d65f21684f 100644
--- a/src/crankshaft/mips/lithium-codegen-mips.cc
+++ b/src/crankshaft/mips/lithium-codegen-mips.cc
@@ -375,9 +375,7 @@ bool LCodeGen::GenerateJumpTable() {
}
// Add the base address to the offset previously loaded in entry_offset.
- __ Addu(entry_offset, entry_offset,
- Operand(ExternalReference::ForDeoptEntry(base)));
- __ Jump(entry_offset);
+ __ Jump(entry_offset, Operand(ExternalReference::ForDeoptEntry(base)));
}
__ RecordComment("]");
@@ -3538,8 +3536,7 @@ void LCodeGen::DoCallWithDescriptor(LCallWithDescriptor* instr) {
} else {
DCHECK(instr->target()->IsRegister());
Register target = ToRegister(instr->target());
- __ Addu(target, target, Operand(Code::kHeaderSize - kHeapObjectTag));
- __ Jump(target);
+ __ Jump(target, Code::kHeaderSize - kHeapObjectTag);
}
} else {
LPointerMap* pointers = instr->pointer_map();
@@ -3554,8 +3551,7 @@ void LCodeGen::DoCallWithDescriptor(LCallWithDescriptor* instr) {
DCHECK(instr->target()->IsRegister());
Register target = ToRegister(instr->target());
generator.BeforeCall(__ CallSize(target));
- __ Addu(target, target, Operand(Code::kHeaderSize - kHeapObjectTag));
- __ Call(target);
+ __ Call(target, Code::kHeaderSize - kHeapObjectTag);
}
generator.AfterCall();
}

Powered by Google App Engine
This is Rietveld 408576698