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

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

Issue 6448001: x64: Add MulI and DivI to lithium instructions. (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' 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/ia32/lithium-codegen-ia32.cc ('k') | src/x64/assembler-x64.h » ('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 1302 matching lines...) Expand 10 before | Expand all | Expand 10 after
1313 } 1313 }
1314 1314
1315 1315
1316 LInstruction* LChunkBuilder::DoDiv(HDiv* instr) { 1316 LInstruction* LChunkBuilder::DoDiv(HDiv* instr) {
1317 if (instr->representation().IsDouble()) { 1317 if (instr->representation().IsDouble()) {
1318 return DoArithmeticD(Token::DIV, instr); 1318 return DoArithmeticD(Token::DIV, instr);
1319 } else if (instr->representation().IsInteger32()) { 1319 } else if (instr->representation().IsInteger32()) {
1320 // The temporary operand is necessary to ensure that right is not allocated 1320 // The temporary operand is necessary to ensure that right is not allocated
1321 // into edx. 1321 // into edx.
1322 LOperand* temp = FixedTemp(edx); 1322 LOperand* temp = FixedTemp(edx);
1323 LOperand* value = UseFixed(instr->left(), eax); 1323 LOperand* dividend = UseFixed(instr->left(), eax);
1324 LOperand* divisor = UseRegister(instr->right()); 1324 LOperand* divisor = UseRegister(instr->right());
1325 LDivI* result = new LDivI(value, divisor, temp); 1325 LDivI* result = new LDivI(dividend, divisor, temp);
1326 return AssignEnvironment(DefineFixed(result, eax)); 1326 return AssignEnvironment(DefineFixed(result, eax));
1327 } else { 1327 } else {
1328 ASSERT(instr->representation().IsTagged()); 1328 ASSERT(instr->representation().IsTagged());
1329 return DoArithmeticT(Token::DIV, instr); 1329 return DoArithmeticT(Token::DIV, instr);
1330 } 1330 }
1331 } 1331 }
1332 1332
1333 1333
1334 LInstruction* LChunkBuilder::DoMod(HMod* instr) { 1334 LInstruction* LChunkBuilder::DoMod(HMod* instr) {
1335 if (instr->representation().IsInteger32()) { 1335 if (instr->representation().IsInteger32()) {
(...skipping 643 matching lines...) Expand 10 before | Expand all | Expand 10 after
1979 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) { 1979 LInstruction* LChunkBuilder::DoLeaveInlined(HLeaveInlined* instr) {
1980 HEnvironment* outer = current_block_->last_environment()->outer(); 1980 HEnvironment* outer = current_block_->last_environment()->outer();
1981 current_block_->UpdateEnvironment(outer); 1981 current_block_->UpdateEnvironment(outer);
1982 return NULL; 1982 return NULL;
1983 } 1983 }
1984 1984
1985 1985
1986 } } // namespace v8::internal 1986 } } // namespace v8::internal
1987 1987
1988 #endif // V8_TARGET_ARCH_IA32 1988 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/ia32/lithium-codegen-ia32.cc ('k') | src/x64/assembler-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698