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

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

Issue 6069010: First part of lithium ARM port. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Adress comments and a small bug fix Created 9 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 unified diff | Download patch | Annotate | Revision Log
« 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 2010 the V8 project authors. All rights reserved. 1 // Copyright 2010 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 1277 matching lines...) Expand 10 before | Expand all | Expand 10 after
1288 } 1288 }
1289 } 1289 }
1290 return new LBranch(UseRegisterAtStart(v), first_id, second_id); 1290 return new LBranch(UseRegisterAtStart(v), first_id, second_id);
1291 } 1291 }
1292 1292
1293 1293
1294 LInstruction* LChunkBuilder::DoCompareMapAndBranch( 1294 LInstruction* LChunkBuilder::DoCompareMapAndBranch(
1295 HCompareMapAndBranch* instr) { 1295 HCompareMapAndBranch* instr) {
1296 ASSERT(instr->value()->representation().IsTagged()); 1296 ASSERT(instr->value()->representation().IsTagged());
1297 LOperand* value = UseRegisterAtStart(instr->value()); 1297 LOperand* value = UseRegisterAtStart(instr->value());
1298 HBasicBlock* first = instr->FirstSuccessor(); 1298 LOperand* temp = TempRegister();
1299 HBasicBlock* second = instr->SecondSuccessor(); 1299 return new LCmpMapAndBranch(value, temp);
1300 return new LCmpMapAndBranch(value,
1301 instr->map(),
1302 first->block_id(),
1303 second->block_id());
1304 } 1300 }
1305 1301
1306 1302
1307 LInstruction* LChunkBuilder::DoArgumentsLength(HArgumentsLength* length) { 1303 LInstruction* LChunkBuilder::DoArgumentsLength(HArgumentsLength* length) {
1308 return DefineAsRegister(new LArgumentsLength(Use(length->value()))); 1304 return DefineAsRegister(new LArgumentsLength(Use(length->value())));
1309 } 1305 }
1310 1306
1311 1307
1312 LInstruction* LChunkBuilder::DoArgumentsElements(HArgumentsElements* elems) { 1308 LInstruction* LChunkBuilder::DoArgumentsElements(HArgumentsElements* elems) {
1313 return DefineAsRegister(new LArgumentsElements); 1309 return DefineAsRegister(new LArgumentsElements);
(...skipping 49 matching lines...) Expand 10 before | Expand all | Expand 10 after
1363 BuiltinFunctionId op = instr->op(); 1359 BuiltinFunctionId op = instr->op();
1364 LOperand* input = UseRegisterAtStart(instr->value()); 1360 LOperand* input = UseRegisterAtStart(instr->value());
1365 LInstruction* result = new LUnaryMathOperation(input); 1361 LInstruction* result = new LUnaryMathOperation(input);
1366 switch (op) { 1362 switch (op) {
1367 case kMathAbs: 1363 case kMathAbs:
1368 return AssignEnvironment(AssignPointerMap(DefineSameAsFirst(result))); 1364 return AssignEnvironment(AssignPointerMap(DefineSameAsFirst(result)));
1369 case kMathFloor: 1365 case kMathFloor:
1370 return AssignEnvironment(DefineAsRegister(result)); 1366 return AssignEnvironment(DefineAsRegister(result));
1371 case kMathSqrt: 1367 case kMathSqrt:
1372 return DefineSameAsFirst(result); 1368 return DefineSameAsFirst(result);
1369 case kMathRound:
1370 Abort("MathRound LUnaryMathOperation not implemented");
1371 return NULL;
1373 case kMathPowHalf: 1372 case kMathPowHalf:
1374 Abort("MathPowHalf LUnaryMathOperation not implemented"); 1373 Abort("MathPowHalf LUnaryMathOperation not implemented");
1375 return NULL; 1374 return NULL;
1376 case kMathLog: 1375 case kMathLog:
1377 Abort("MathLog LUnaryMathOperation not implemented"); 1376 Abort("MathLog LUnaryMathOperation not implemented");
1378 return NULL; 1377 return NULL;
1379 case kMathCos: 1378 case kMathCos:
1380 Abort("MathCos LUnaryMathOperation not implemented"); 1379 Abort("MathCos LUnaryMathOperation not implemented");
1381 return NULL; 1380 return NULL;
1382 case kMathSin: 1381 case kMathSin:
(...skipping 384 matching lines...) Expand 10 before | Expand all | Expand 10 after
1767 1766
1768 LInstruction* LChunkBuilder::DoCheckInstanceType(HCheckInstanceType* instr) { 1767 LInstruction* LChunkBuilder::DoCheckInstanceType(HCheckInstanceType* instr) {
1769 LOperand* value = UseRegisterAtStart(instr->value()); 1768 LOperand* value = UseRegisterAtStart(instr->value());
1770 LOperand* temp = TempRegister(); 1769 LOperand* temp = TempRegister();
1771 LInstruction* result = new LCheckInstanceType(value, temp); 1770 LInstruction* result = new LCheckInstanceType(value, temp);
1772 return AssignEnvironment(result); 1771 return AssignEnvironment(result);
1773 } 1772 }
1774 1773
1775 1774
1776 LInstruction* LChunkBuilder::DoCheckPrototypeMaps(HCheckPrototypeMaps* instr) { 1775 LInstruction* LChunkBuilder::DoCheckPrototypeMaps(HCheckPrototypeMaps* instr) {
1777 LOperand* temp = TempRegister(); 1776 LOperand* temp1 = TempRegister();
1777 LOperand* temp2 = TempRegister();
1778 LInstruction* result = 1778 LInstruction* result =
1779 new LCheckPrototypeMaps(temp, 1779 new LCheckPrototypeMaps(temp1,
1780 temp2,
1780 instr->holder(), 1781 instr->holder(),
1781 instr->receiver_map()); 1782 instr->receiver_map());
1782 return AssignEnvironment(result); 1783 return AssignEnvironment(result);
1783 } 1784 }
1784 1785
1785 1786
1786 LInstruction* LChunkBuilder::DoCheckSmi(HCheckSmi* instr) { 1787 LInstruction* LChunkBuilder::DoCheckSmi(HCheckSmi* instr) {
1787 LOperand* value = UseRegisterAtStart(instr->value()); 1788 LOperand* value = UseRegisterAtStart(instr->value());
1788 return AssignEnvironment(new LCheckSmi(value, ne)); 1789 return AssignEnvironment(new LCheckSmi(value, ne));
1789 } 1790 }
(...skipping 327 matching lines...) Expand 10 before | Expand all | Expand 10 after
2117 void LPointerMap::PrintTo(StringStream* stream) const { 2118 void LPointerMap::PrintTo(StringStream* stream) const {
2118 stream->Add("{"); 2119 stream->Add("{");
2119 for (int i = 0; i < pointer_operands_.length(); ++i) { 2120 for (int i = 0; i < pointer_operands_.length(); ++i) {
2120 if (i != 0) stream->Add(";"); 2121 if (i != 0) stream->Add(";");
2121 pointer_operands_[i]->PrintTo(stream); 2122 pointer_operands_[i]->PrintTo(stream);
2122 } 2123 }
2123 stream->Add("} @%d", position()); 2124 stream->Add("} @%d", position());
2124 } 2125 }
2125 2126
2126 } } // namespace v8::internal 2127 } } // 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