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

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

Issue 14159015: MIPS: Improvements in lithium code generation. Recognizing if some operands are constants, we can o… (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years, 8 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/mips/lithium-codegen-mips.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 2322 matching lines...) Expand 10 before | Expand all | Expand 10 after
2333 // arguments.length and element access are supported directly on 2333 // arguments.length and element access are supported directly on
2334 // stack arguments, and any real arguments object use causes a bailout. 2334 // stack arguments, and any real arguments object use causes a bailout.
2335 // So this value is never used. 2335 // So this value is never used.
2336 return NULL; 2336 return NULL;
2337 } 2337 }
2338 2338
2339 2339
2340 LInstruction* LChunkBuilder::DoAccessArgumentsAt(HAccessArgumentsAt* instr) { 2340 LInstruction* LChunkBuilder::DoAccessArgumentsAt(HAccessArgumentsAt* instr) {
2341 info()->MarkAsRequiresFrame(); 2341 info()->MarkAsRequiresFrame();
2342 LOperand* args = UseRegister(instr->arguments()); 2342 LOperand* args = UseRegister(instr->arguments());
2343 LOperand* length = UseTempRegister(instr->length()); 2343 LOperand* length;
2344 LOperand* index = UseRegister(instr->index()); 2344 LOperand* index;
2345 if (instr->length()->IsConstant() && instr->index()->IsConstant()) {
2346 length = UseRegisterOrConstant(instr->length());
2347 index = UseOrConstant(instr->index());
2348 } else {
2349 length = UseTempRegister(instr->length());
2350 index = Use(instr->index());
2351 }
2345 return DefineAsRegister(new(zone()) LAccessArgumentsAt(args, length, index)); 2352 return DefineAsRegister(new(zone()) LAccessArgumentsAt(args, length, index));
2346 } 2353 }
2347 2354
2348 2355
2349 LInstruction* LChunkBuilder::DoToFastProperties(HToFastProperties* instr) { 2356 LInstruction* LChunkBuilder::DoToFastProperties(HToFastProperties* instr) {
2350 LOperand* object = UseFixed(instr->value(), a0); 2357 LOperand* object = UseFixed(instr->value(), a0);
2351 LToFastProperties* result = new(zone()) LToFastProperties(object); 2358 LToFastProperties* result = new(zone()) LToFastProperties(object);
2352 return MarkAsCall(DefineFixed(result, v0), instr); 2359 return MarkAsCall(DefineFixed(result, v0), instr);
2353 } 2360 }
2354 2361
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
2481 2488
2482 2489
2483 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { 2490 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
2484 LOperand* object = UseRegister(instr->object()); 2491 LOperand* object = UseRegister(instr->object());
2485 LOperand* index = UseRegister(instr->index()); 2492 LOperand* index = UseRegister(instr->index());
2486 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); 2493 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index));
2487 } 2494 }
2488 2495
2489 2496
2490 } } // namespace v8::internal 2497 } } // namespace v8::internal
OLDNEW
« no previous file with comments | « src/mips/lithium-codegen-mips.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698