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

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

Issue 8373029: [hydrogen] optimize switch with string clauses (Closed) Base URL: gh:v8/v8@master
Patch Set: merged with master Created 9 years, 1 month 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
« src/x64/lithium-codegen-x64.cc ('K') | « src/x64/lithium-x64.h ('k') | no next file » | 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 1432 matching lines...) Expand 10 before | Expand all | Expand 10 after
1443 return new LIsNilAndBranch(UseRegisterAtStart(instr->value()), temp); 1443 return new LIsNilAndBranch(UseRegisterAtStart(instr->value()), temp);
1444 } 1444 }
1445 1445
1446 1446
1447 LInstruction* LChunkBuilder::DoIsObjectAndBranch(HIsObjectAndBranch* instr) { 1447 LInstruction* LChunkBuilder::DoIsObjectAndBranch(HIsObjectAndBranch* instr) {
1448 ASSERT(instr->value()->representation().IsTagged()); 1448 ASSERT(instr->value()->representation().IsTagged());
1449 return new LIsObjectAndBranch(UseRegisterAtStart(instr->value())); 1449 return new LIsObjectAndBranch(UseRegisterAtStart(instr->value()));
1450 } 1450 }
1451 1451
1452 1452
1453 LInstruction* LChunkBuilder::DoIsStringAndBranch(HIsStringAndBranch* instr) {
1454 ASSERT(instr->value()->representation().IsTagged());
1455 LOperand* temp = TempRegister();
1456 return new LIsStringAndBranch(UseRegisterAtStart(instr->value()), temp);
1457 }
1458
1459
1453 LInstruction* LChunkBuilder::DoIsSmiAndBranch(HIsSmiAndBranch* instr) { 1460 LInstruction* LChunkBuilder::DoIsSmiAndBranch(HIsSmiAndBranch* instr) {
1454 ASSERT(instr->value()->representation().IsTagged()); 1461 ASSERT(instr->value()->representation().IsTagged());
1455 return new LIsSmiAndBranch(Use(instr->value())); 1462 return new LIsSmiAndBranch(Use(instr->value()));
1456 } 1463 }
1457 1464
1458 1465
1459 LInstruction* LChunkBuilder::DoIsUndetectableAndBranch( 1466 LInstruction* LChunkBuilder::DoIsUndetectableAndBranch(
1460 HIsUndetectableAndBranch* instr) { 1467 HIsUndetectableAndBranch* instr) {
1461 ASSERT(instr->value()->representation().IsTagged()); 1468 ASSERT(instr->value()->representation().IsTagged());
1462 return new LIsUndetectableAndBranch(UseRegisterAtStart(instr->value()), 1469 return new LIsUndetectableAndBranch(UseRegisterAtStart(instr->value()),
(...skipping 731 matching lines...) Expand 10 before | Expand all | Expand 10 after
2194 LOperand* key = UseOrConstantAtStart(instr->key()); 2201 LOperand* key = UseOrConstantAtStart(instr->key());
2195 LOperand* object = UseOrConstantAtStart(instr->object()); 2202 LOperand* object = UseOrConstantAtStart(instr->object());
2196 LIn* result = new LIn(key, object); 2203 LIn* result = new LIn(key, object);
2197 return MarkAsCall(DefineFixed(result, rax), instr); 2204 return MarkAsCall(DefineFixed(result, rax), instr);
2198 } 2205 }
2199 2206
2200 2207
2201 } } // namespace v8::internal 2208 } } // namespace v8::internal
2202 2209
2203 #endif // V8_TARGET_ARCH_X64 2210 #endif // V8_TARGET_ARCH_X64
OLDNEW
« src/x64/lithium-codegen-x64.cc ('K') | « src/x64/lithium-x64.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698