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

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

Issue 132373011: A64: Synchronize with r17635. (Closed) Base URL: https://v8.googlecode.com/svn/branches/experimental/a64
Patch Set: Created 6 years, 10 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 | Annotate | Revision Log
« no previous file with comments | « src/a64/lithium-a64.h ('k') | src/a64/lithium-codegen-a64.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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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 673 matching lines...) Expand 10 before | Expand all | Expand 10 after
684 } 684 }
685 685
686 686
687 void LChunkBuilder::VisitInstruction(HInstruction* current) { 687 void LChunkBuilder::VisitInstruction(HInstruction* current) {
688 HInstruction* old_current = current_instruction_; 688 HInstruction* old_current = current_instruction_;
689 current_instruction_ = current; 689 current_instruction_ = current;
690 if (current->has_position()) position_ = current->position(); 690 if (current->has_position()) position_ = current->position();
691 691
692 LInstruction* instr = NULL; 692 LInstruction* instr = NULL;
693 if (current->CanReplaceWithDummyUses()) { 693 if (current->CanReplaceWithDummyUses()) {
694 HValue* first_operand = current->OperandCount() == 0 694 if (current->OperandCount() == 0) {
695 ? graph()->GetConstant1() 695 instr = DefineAsRegister(new(zone()) LDummy());
696 : current->OperandAt(0); 696 } else {
697 instr = DefineAsRegister(new(zone()) LDummyUse(UseAny(first_operand))); 697 instr = DefineAsRegister(new(zone())
698 LDummyUse(UseAny(current->OperandAt(0))));
699 }
698 for (int i = 1; i < current->OperandCount(); ++i) { 700 for (int i = 1; i < current->OperandCount(); ++i) {
699 LInstruction* dummy = 701 LInstruction* dummy =
700 new(zone()) LDummyUse(UseAny(current->OperandAt(i))); 702 new(zone()) LDummyUse(UseAny(current->OperandAt(i)));
701 dummy->set_hydrogen_value(current); 703 dummy->set_hydrogen_value(current);
702 chunk_->AddInstruction(dummy, current_block_); 704 chunk_->AddInstruction(dummy, current_block_);
703 } 705 }
704 } else { 706 } else {
705 instr = current->CompileToLithium(this); 707 instr = current->CompileToLithium(this);
706 } 708 }
707 709
(...skipping 1281 matching lines...) Expand 10 before | Expand all | Expand 10 after
1989 return MarkAsCall(DefineFixed(new(zone()) LRegExpLiteral, x0), instr); 1991 return MarkAsCall(DefineFixed(new(zone()) LRegExpLiteral, x0), instr);
1990 } 1992 }
1991 1993
1992 1994
1993 LInstruction* LChunkBuilder::DoReturn(HReturn* instr) { 1995 LInstruction* LChunkBuilder::DoReturn(HReturn* instr) {
1994 LOperand* parameter_count = UseRegisterOrConstant(instr->parameter_count()); 1996 LOperand* parameter_count = UseRegisterOrConstant(instr->parameter_count());
1995 return new(zone()) LReturn(UseFixed(instr->value(), x0), parameter_count); 1997 return new(zone()) LReturn(UseFixed(instr->value(), x0), parameter_count);
1996 } 1998 }
1997 1999
1998 2000
2001 LInstruction* LChunkBuilder::DoSeqStringGetChar(HSeqStringGetChar* instr) {
2002 Abort(kUnimplemented);
2003 return NULL;
2004 }
2005
2006
1999 LInstruction* LChunkBuilder::DoSeqStringSetChar(HSeqStringSetChar* instr) { 2007 LInstruction* LChunkBuilder::DoSeqStringSetChar(HSeqStringSetChar* instr) {
2000 LOperand* string = UseRegister(instr->string()); 2008 LOperand* string = UseRegister(instr->string());
2001 LOperand* index = UseRegister(instr->index()); 2009 LOperand* index = UseRegister(instr->index());
2002 LOperand* value = UseRegister(instr->value()); 2010 LOperand* value = UseRegister(instr->value());
2003 LOperand* temp = TempRegister(); 2011 LOperand* temp = TempRegister();
2004 LSeqStringSetChar* result = 2012 LSeqStringSetChar* result =
2005 new(zone()) LSeqStringSetChar(instr->encoding(), 2013 new(zone()) LSeqStringSetChar(instr->encoding(),
2006 string, index, value, temp); 2014 string, index, value, temp);
2007 return DefineAsRegister(result); 2015 return DefineAsRegister(result);
2008 } 2016 }
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after
2230 2238
2231 LInstruction* LChunkBuilder::DoStoreNamedGeneric(HStoreNamedGeneric* instr) { 2239 LInstruction* LChunkBuilder::DoStoreNamedGeneric(HStoreNamedGeneric* instr) {
2232 LOperand* object = UseFixed(instr->object(), x1); 2240 LOperand* object = UseFixed(instr->object(), x1);
2233 LOperand* value = UseFixed(instr->value(), x0); 2241 LOperand* value = UseFixed(instr->value(), x0);
2234 LInstruction* result = new(zone()) LStoreNamedGeneric(object, value); 2242 LInstruction* result = new(zone()) LStoreNamedGeneric(object, value);
2235 return MarkAsCall(result, instr); 2243 return MarkAsCall(result, instr);
2236 } 2244 }
2237 2245
2238 2246
2239 LInstruction* LChunkBuilder::DoStringAdd(HStringAdd* instr) { 2247 LInstruction* LChunkBuilder::DoStringAdd(HStringAdd* instr) {
2240 LOperand* left = UseRegisterAtStart(instr->left()); 2248 LOperand* left = FLAG_new_string_add ? UseFixed(instr->left(), x1)
2241 LOperand* right = UseRegisterAtStart(instr->right()); 2249 : UseRegisterAtStart(instr->left());
2250 LOperand* right = FLAG_new_string_add ? UseFixed(instr->right(), x0)
2251 : UseRegisterAtStart(instr->right());
2242 2252
2243 LStringAdd* result = new(zone()) LStringAdd(left, right); 2253 LStringAdd* result = new(zone()) LStringAdd(left, right);
2244 return MarkAsCall(DefineFixed(result, x0), instr); 2254 return MarkAsCall(DefineFixed(result, x0), instr);
2245 } 2255 }
2246 2256
2247 2257
2248 LInstruction* LChunkBuilder::DoStringCharCodeAt(HStringCharCodeAt* instr) { 2258 LInstruction* LChunkBuilder::DoStringCharCodeAt(HStringCharCodeAt* instr) {
2249 LOperand* string = UseRegisterAndClobber(instr->string()); 2259 LOperand* string = UseRegisterAndClobber(instr->string());
2250 LOperand* index = UseRegisterAndClobber(instr->index()); 2260 LOperand* index = UseRegisterAndClobber(instr->index());
2251 LStringCharCodeAt* result = new(zone()) LStringCharCodeAt(string, index); 2261 LStringCharCodeAt* result = new(zone()) LStringCharCodeAt(string, index);
(...skipping 292 matching lines...) Expand 10 before | Expand all | Expand 10 after
2544 LInstruction* LChunkBuilder::DoWrapReceiver(HWrapReceiver* instr) { 2554 LInstruction* LChunkBuilder::DoWrapReceiver(HWrapReceiver* instr) {
2545 LOperand* receiver = UseRegister(instr->receiver()); 2555 LOperand* receiver = UseRegister(instr->receiver());
2546 LOperand* function = UseRegisterAtStart(instr->function()); 2556 LOperand* function = UseRegisterAtStart(instr->function());
2547 LOperand* temp = TempRegister(); 2557 LOperand* temp = TempRegister();
2548 LWrapReceiver* result = new(zone()) LWrapReceiver(receiver, function, temp); 2558 LWrapReceiver* result = new(zone()) LWrapReceiver(receiver, function, temp);
2549 return AssignEnvironment(DefineAsRegister(result)); 2559 return AssignEnvironment(DefineAsRegister(result));
2550 } 2560 }
2551 2561
2552 2562
2553 } } // namespace v8::internal 2563 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/a64/lithium-a64.h ('k') | src/a64/lithium-codegen-a64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698