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

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

Issue 6532020: ARM: Implement DoPower in the lithium code generator. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge/src
Patch Set: Disable crankshaft on non ARM EABI platforms. Created 9 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/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 1399 matching lines...) Expand 10 before | Expand all | Expand 10 after
1410 } else if (instr->representation().IsDouble()) { 1410 } else if (instr->representation().IsDouble()) {
1411 return DoArithmeticD(Token::ADD, instr); 1411 return DoArithmeticD(Token::ADD, instr);
1412 } else { 1412 } else {
1413 ASSERT(instr->representation().IsTagged()); 1413 ASSERT(instr->representation().IsTagged());
1414 return DoArithmeticT(Token::ADD, instr); 1414 return DoArithmeticT(Token::ADD, instr);
1415 } 1415 }
1416 } 1416 }
1417 1417
1418 1418
1419 LInstruction* LChunkBuilder::DoPower(HPower* instr) { 1419 LInstruction* LChunkBuilder::DoPower(HPower* instr) {
1420 Abort("LPower instruction not implemented on ARM"); 1420 ASSERT(instr->representation().IsDouble());
1421 return NULL; 1421 // We call a C function for double power. It can't trigger a GC.
1422 // We need to use fixed result register for the call.
1423 Representation exponent_type = instr->right()->representation();
1424 ASSERT(instr->left()->representation().IsDouble());
1425 LOperand* left = UseFixedDouble(instr->left(), d1);
1426 LOperand* right = exponent_type.IsDouble() ?
1427 UseFixedDouble(instr->right(), d2) :
1428 UseFixed(instr->right(), r0);
1429 LPower* result = new LPower(left, right);
1430 return MarkAsCall(DefineFixedDouble(result, d3),
1431 instr,
1432 CAN_DEOPTIMIZE_EAGERLY);
1422 } 1433 }
1423 1434
1424 1435
1425 LInstruction* LChunkBuilder::DoCompare(HCompare* instr) { 1436 LInstruction* LChunkBuilder::DoCompare(HCompare* instr) {
1426 Token::Value op = instr->token(); 1437 Token::Value op = instr->token();
1427 Representation r = instr->GetInputRepresentation(); 1438 Representation r = instr->GetInputRepresentation();
1428 if (r.IsInteger32()) { 1439 if (r.IsInteger32()) {
1429 ASSERT(instr->left()->representation().IsInteger32()); 1440 ASSERT(instr->left()->representation().IsInteger32());
1430 ASSERT(instr->right()->representation().IsInteger32()); 1441 ASSERT(instr->right()->representation().IsInteger32());
1431 LOperand* left = UseRegisterAtStart(instr->left()); 1442 LOperand* left = UseRegisterAtStart(instr->left());
(...skipping 570 matching lines...) Expand 10 before | Expand all | Expand 10 after
2002 2013
2003 2014
2004 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { 2015 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) {
2005 HEnvironment* outer = current_block_->last_environment()->outer(); 2016 HEnvironment* outer = current_block_->last_environment()->outer();
2006 current_block_->UpdateEnvironment(outer); 2017 current_block_->UpdateEnvironment(outer);
2007 return NULL; 2018 return NULL;
2008 } 2019 }
2009 2020
2010 2021
2011 } } // namespace v8::internal 2022 } } // 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