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

Side by Side Diff: src/arm/lithium-arm.cc

Issue 7000021: Support symbol comparison in crankshaft. (Closed)
Patch Set: Review fixes Created 9 years, 7 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 unified diff | Download patch
« no previous file with comments | « src/arm/lithium-arm.h ('k') | src/arm/lithium-codegen-arm.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 the V8 project authors. All rights reserved. 1 // Copyright 2011 the V8 project authors. All rights reserved.
2 // Redistribution and use in source and binary forms, with or without 2 // Redistribution and use in source and binary forms, with or without
3 // modification, are permitted provided that the following conditions are 3 // modification, are permitted provided that the following conditions are
4 // met: 4 // met:
5 // 5 //
6 // * Redistributions of source code must retain the above copyright 6 // * Redistributions of source code must retain the above copyright
7 // notice, this list of conditions and the following disclaimer. 7 // notice, this list of conditions and the following disclaimer.
8 // * Redistributions in binary form must reproduce the above 8 // * Redistributions in binary form must reproduce the above
9 // copyright notice, this list of conditions and the following 9 // copyright notice, this list of conditions and the following
10 // disclaimer in the documentation and/or other materials provided 10 // disclaimer in the documentation and/or other materials provided
(...skipping 1089 matching lines...) Expand 10 before | Expand all | Expand 10 after
1100 } else if (v->IsIsObject()) { 1100 } else if (v->IsIsObject()) {
1101 HIsObject* compare = HIsObject::cast(v); 1101 HIsObject* compare = HIsObject::cast(v);
1102 ASSERT(compare->value()->representation().IsTagged()); 1102 ASSERT(compare->value()->representation().IsTagged());
1103 1103
1104 LOperand* temp = TempRegister(); 1104 LOperand* temp = TempRegister();
1105 return new LIsObjectAndBranch(UseRegisterAtStart(compare->value()), temp); 1105 return new LIsObjectAndBranch(UseRegisterAtStart(compare->value()), temp);
1106 } else if (v->IsCompareJSObjectEq()) { 1106 } else if (v->IsCompareJSObjectEq()) {
1107 HCompareJSObjectEq* compare = HCompareJSObjectEq::cast(v); 1107 HCompareJSObjectEq* compare = HCompareJSObjectEq::cast(v);
1108 return new LCmpJSObjectEqAndBranch(UseRegisterAtStart(compare->left()), 1108 return new LCmpJSObjectEqAndBranch(UseRegisterAtStart(compare->left()),
1109 UseRegisterAtStart(compare->right())); 1109 UseRegisterAtStart(compare->right()));
1110 } else if (v->IsCompareSymbolEq()) {
1111 HCompareSymbolEq* compare = HCompareSymbolEq::cast(v);
1112 return new LCmpSymbolEqAndBranch(UseRegisterAtStart(compare->left()),
1113 UseRegisterAtStart(compare->right()));
1110 } else if (v->IsInstanceOf()) { 1114 } else if (v->IsInstanceOf()) {
1111 HInstanceOf* instance_of = HInstanceOf::cast(v); 1115 HInstanceOf* instance_of = HInstanceOf::cast(v);
1112 LInstruction* result = 1116 LInstruction* result =
1113 new LInstanceOfAndBranch(UseFixed(instance_of->left(), r0), 1117 new LInstanceOfAndBranch(UseFixed(instance_of->left(), r0),
1114 UseFixed(instance_of->right(), r1)); 1118 UseFixed(instance_of->right(), r1));
1115 return MarkAsCall(result, instr); 1119 return MarkAsCall(result, instr);
1116 } else if (v->IsTypeofIs()) { 1120 } else if (v->IsTypeofIs()) {
1117 HTypeofIs* typeof_is = HTypeofIs::cast(v); 1121 HTypeofIs* typeof_is = HTypeofIs::cast(v);
1118 return new LTypeofIsAndBranch(UseTempRegister(typeof_is->value())); 1122 return new LTypeofIsAndBranch(UseTempRegister(typeof_is->value()));
1119 } else if (v->IsIsConstructCall()) { 1123 } else if (v->IsIsConstructCall()) {
(...skipping 380 matching lines...) Expand 10 before | Expand all | Expand 10 after
1500 1504
1501 LInstruction* LChunkBuilder::DoCompareJSObjectEq( 1505 LInstruction* LChunkBuilder::DoCompareJSObjectEq(
1502 HCompareJSObjectEq* instr) { 1506 HCompareJSObjectEq* instr) {
1503 LOperand* left = UseRegisterAtStart(instr->left()); 1507 LOperand* left = UseRegisterAtStart(instr->left());
1504 LOperand* right = UseRegisterAtStart(instr->right()); 1508 LOperand* right = UseRegisterAtStart(instr->right());
1505 LCmpJSObjectEq* result = new LCmpJSObjectEq(left, right); 1509 LCmpJSObjectEq* result = new LCmpJSObjectEq(left, right);
1506 return DefineAsRegister(result); 1510 return DefineAsRegister(result);
1507 } 1511 }
1508 1512
1509 1513
1514 LInstruction* LChunkBuilder::DoCompareSymbolEq(
1515 HCompareSymbolEq* instr) {
1516 LOperand* left = UseRegisterAtStart(instr->left());
1517 LOperand* right = UseRegisterAtStart(instr->right());
1518 LCmpSymbolEq* result = new LCmpSymbolEq(left, right);
1519 return DefineAsRegister(result);
1520 }
1521
1522
1510 LInstruction* LChunkBuilder::DoIsNull(HIsNull* instr) { 1523 LInstruction* LChunkBuilder::DoIsNull(HIsNull* instr) {
1511 ASSERT(instr->value()->representation().IsTagged()); 1524 ASSERT(instr->value()->representation().IsTagged());
1512 LOperand* value = UseRegisterAtStart(instr->value()); 1525 LOperand* value = UseRegisterAtStart(instr->value());
1513 1526
1514 return DefineAsRegister(new LIsNull(value)); 1527 return DefineAsRegister(new LIsNull(value));
1515 } 1528 }
1516 1529
1517 1530
1518 LInstruction* LChunkBuilder::DoIsObject(HIsObject* instr) { 1531 LInstruction* LChunkBuilder::DoIsObject(HIsObject* instr) {
1519 ASSERT(instr->value()->representation().IsTagged()); 1532 ASSERT(instr->value()->representation().IsTagged());
(...skipping 626 matching lines...) Expand 10 before | Expand all | Expand 10 after
2146 2159
2147 LInstruction* LChunkBuilder::DoIn(HIn* instr) { 2160 LInstruction* LChunkBuilder::DoIn(HIn* instr) {
2148 LOperand* key = UseRegisterAtStart(instr->key()); 2161 LOperand* key = UseRegisterAtStart(instr->key());
2149 LOperand* object = UseRegisterAtStart(instr->object()); 2162 LOperand* object = UseRegisterAtStart(instr->object());
2150 LIn* result = new LIn(key, object); 2163 LIn* result = new LIn(key, object);
2151 return MarkAsCall(DefineFixed(result, r0), instr); 2164 return MarkAsCall(DefineFixed(result, r0), instr);
2152 } 2165 }
2153 2166
2154 2167
2155 } } // namespace v8::internal 2168 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm/lithium-arm.h ('k') | src/arm/lithium-codegen-arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698