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

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

Issue 1114563003: Optimize the typeof operator. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Ports. Created 5 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
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <sstream> 5 #include <sstream>
6 6
7 #include "src/v8.h" 7 #include "src/v8.h"
8 8
9 #if V8_TARGET_ARCH_IA32 9 #if V8_TARGET_ARCH_IA32
10 10
(...skipping 2583 matching lines...) Expand 10 before | Expand all | Expand 10 after
2594 2594
2595 LInstruction* LChunkBuilder::DoToFastProperties(HToFastProperties* instr) { 2595 LInstruction* LChunkBuilder::DoToFastProperties(HToFastProperties* instr) {
2596 LOperand* object = UseFixed(instr->value(), eax); 2596 LOperand* object = UseFixed(instr->value(), eax);
2597 LToFastProperties* result = new(zone()) LToFastProperties(object); 2597 LToFastProperties* result = new(zone()) LToFastProperties(object);
2598 return MarkAsCall(DefineFixed(result, eax), instr); 2598 return MarkAsCall(DefineFixed(result, eax), instr);
2599 } 2599 }
2600 2600
2601 2601
2602 LInstruction* LChunkBuilder::DoTypeof(HTypeof* instr) { 2602 LInstruction* LChunkBuilder::DoTypeof(HTypeof* instr) {
2603 LOperand* context = UseFixed(instr->context(), esi); 2603 LOperand* context = UseFixed(instr->context(), esi);
2604 LOperand* value = UseAtStart(instr->value()); 2604 LOperand* value = UseFixed(instr->value(), ebx);
2605 LTypeof* result = new(zone()) LTypeof(context, value); 2605 LTypeof* result = new(zone()) LTypeof(context, value);
2606 return MarkAsCall(DefineFixed(result, eax), instr); 2606 return MarkAsCall(DefineFixed(result, eax), instr);
2607 } 2607 }
2608 2608
2609 2609
2610 LInstruction* LChunkBuilder::DoTypeofIsAndBranch(HTypeofIsAndBranch* instr) { 2610 LInstruction* LChunkBuilder::DoTypeofIsAndBranch(HTypeofIsAndBranch* instr) {
2611 return new(zone()) LTypeofIsAndBranch(UseTempRegister(instr->value())); 2611 return new(zone()) LTypeofIsAndBranch(UseTempRegister(instr->value()));
2612 } 2612 }
2613 2613
2614 2614
(...skipping 105 matching lines...) Expand 10 before | Expand all | Expand 10 after
2720 LOperand* function = UseRegisterAtStart(instr->function()); 2720 LOperand* function = UseRegisterAtStart(instr->function());
2721 LAllocateBlockContext* result = 2721 LAllocateBlockContext* result =
2722 new(zone()) LAllocateBlockContext(context, function); 2722 new(zone()) LAllocateBlockContext(context, function);
2723 return MarkAsCall(DefineFixed(result, esi), instr); 2723 return MarkAsCall(DefineFixed(result, esi), instr);
2724 } 2724 }
2725 2725
2726 2726
2727 } } // namespace v8::internal 2727 } } // namespace v8::internal
2728 2728
2729 #endif // V8_TARGET_ARCH_IA32 2729 #endif // V8_TARGET_ARCH_IA32
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698