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/arm/lithium-arm.cc

Issue 11293061: Emit VMLA for multiply-add on ARM (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Clean up and support other targets Created 8 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 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 1293 matching lines...) Expand 10 before | Expand all | Expand 10 after
1304 1304
1305 } else if (instr->representation().IsDouble()) { 1305 } else if (instr->representation().IsDouble()) {
1306 return DoArithmeticD(Token::MUL, instr); 1306 return DoArithmeticD(Token::MUL, instr);
1307 1307
1308 } else { 1308 } else {
1309 return DoArithmeticT(Token::MUL, instr); 1309 return DoArithmeticT(Token::MUL, instr);
1310 } 1310 }
1311 } 1311 }
1312 1312
1313 1313
1314 LInstruction* LChunkBuilder::DoMultiplyAddD(HMultiplyAddD* instr) {
1315 ASSERT(instr->representation().IsDouble());
1316 ASSERT(instr->a()->representation().IsDouble());
1317 ASSERT(instr->b()->representation().IsDouble());
1318 ASSERT(instr->c()->representation().IsDouble());
1319
1320 LOperand* a = UseRegisterAtStart(instr->a());
1321 LOperand* b = UseRegisterAtStart(instr->b());
1322 LOperand* c = UseRegisterAtStart(instr->c());
1323 LMultiplyAddD* result = new(zone()) LMultiplyAddD(c, a, b);
1324 return DefineSameAsFirst(result);
1325 }
1326
1327
1314 LInstruction* LChunkBuilder::DoSub(HSub* instr) { 1328 LInstruction* LChunkBuilder::DoSub(HSub* instr) {
1315 if (instr->representation().IsInteger32()) { 1329 if (instr->representation().IsInteger32()) {
1316 ASSERT(instr->left()->representation().IsInteger32()); 1330 ASSERT(instr->left()->representation().IsInteger32());
1317 ASSERT(instr->right()->representation().IsInteger32()); 1331 ASSERT(instr->right()->representation().IsInteger32());
1318 LOperand* left = UseRegisterAtStart(instr->left()); 1332 LOperand* left = UseRegisterAtStart(instr->left());
1319 LOperand* right = UseOrConstantAtStart(instr->right()); 1333 LOperand* right = UseOrConstantAtStart(instr->right());
1320 LSubI* sub = new(zone()) LSubI(left, right); 1334 LSubI* sub = new(zone()) LSubI(left, right);
1321 LInstruction* result = DefineAsRegister(sub); 1335 LInstruction* result = DefineAsRegister(sub);
1322 if (instr->CheckFlag(HValue::kCanOverflow)) { 1336 if (instr->CheckFlag(HValue::kCanOverflow)) {
1323 result = AssignEnvironment(result); 1337 result = AssignEnvironment(result);
(...skipping 938 matching lines...) Expand 10 before | Expand all | Expand 10 after
2262 2276
2263 2277
2264 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { 2278 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
2265 LOperand* object = UseRegister(instr->object()); 2279 LOperand* object = UseRegister(instr->object());
2266 LOperand* index = UseRegister(instr->index()); 2280 LOperand* index = UseRegister(instr->index());
2267 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); 2281 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index));
2268 } 2282 }
2269 2283
2270 2284
2271 } } // namespace v8::internal 2285 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/arm/lithium-arm.h ('k') | src/arm/lithium-codegen-arm.cc » ('j') | src/ia32/lithium-ia32.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698