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

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

Issue 2614663009: PPC: fix smi compare in DoBoundsCheck (Closed)
Patch Set: Created 3 years, 11 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/crankshaft/ppc/lithium-codegen-ppc.cc
diff --git a/src/crankshaft/ppc/lithium-codegen-ppc.cc b/src/crankshaft/ppc/lithium-codegen-ppc.cc
index 4162a6006d100df65f382f4cb77da69edef8151b..f546dc22d2546f55b454347332ae415c7c6e5ebd 100644
--- a/src/crankshaft/ppc/lithium-codegen-ppc.cc
+++ b/src/crankshaft/ppc/lithium-codegen-ppc.cc
@@ -4022,7 +4022,7 @@ void LCodeGen::DoBoundsCheck(LBoundsCheck* instr) {
int32_t length = ToInteger32(LConstantOperand::cast(instr->length()));
Register index = ToRegister(instr->index());
if (representation.IsSmi()) {
- __ Cmpli(index, Operand(Smi::FromInt(length)), r0);
+ __ CmplSmiLiteral(index, Smi::FromInt(length), r0);
} else {
__ Cmplwi(index, Operand(length), r0);
}
@@ -4031,7 +4031,7 @@ void LCodeGen::DoBoundsCheck(LBoundsCheck* instr) {
int32_t index = ToInteger32(LConstantOperand::cast(instr->index()));
Register length = ToRegister(instr->length());
if (representation.IsSmi()) {
- __ Cmpli(length, Operand(Smi::FromInt(index)), r0);
+ __ CmplSmiLiteral(length, Smi::FromInt(index), r0);
} else {
__ Cmplwi(length, Operand(index), r0);
}
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698