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

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

Issue 25563002: MIPS: Tweak LoadKeyed. (Closed) Base URL: https://github.com/v8/v8.git@gbl
Patch Set: Created 7 years, 2 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
« 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 2101 matching lines...) Expand 10 before | Expand all | Expand 10 after
2112 2112
2113 LInstruction* LChunkBuilder::DoLoadKeyed(HLoadKeyed* instr) { 2113 LInstruction* LChunkBuilder::DoLoadKeyed(HLoadKeyed* instr) {
2114 ASSERT(instr->key()->representation().IsSmiOrInteger32()); 2114 ASSERT(instr->key()->representation().IsSmiOrInteger32());
2115 ElementsKind elements_kind = instr->elements_kind(); 2115 ElementsKind elements_kind = instr->elements_kind();
2116 LOperand* key = UseRegisterOrConstantAtStart(instr->key()); 2116 LOperand* key = UseRegisterOrConstantAtStart(instr->key());
2117 LLoadKeyed* result = NULL; 2117 LLoadKeyed* result = NULL;
2118 2118
2119 if (!instr->is_external()) { 2119 if (!instr->is_external()) {
2120 LOperand* obj = NULL; 2120 LOperand* obj = NULL;
2121 if (instr->representation().IsDouble()) { 2121 if (instr->representation().IsDouble()) {
2122 obj = UseTempRegister(instr->elements()); 2122 obj = UseRegister(instr->elements());
2123 } else { 2123 } else {
2124 ASSERT(instr->representation().IsSmiOrTagged()); 2124 ASSERT(instr->representation().IsSmiOrTagged());
2125 obj = UseRegisterAtStart(instr->elements()); 2125 obj = UseRegisterAtStart(instr->elements());
2126 } 2126 }
2127 result = new(zone()) LLoadKeyed(obj, key); 2127 result = new(zone()) LLoadKeyed(obj, key);
2128 } else { 2128 } else {
2129 ASSERT( 2129 ASSERT(
2130 (instr->representation().IsInteger32() && 2130 (instr->representation().IsInteger32() &&
2131 (elements_kind != EXTERNAL_FLOAT_ELEMENTS) && 2131 (elements_kind != EXTERNAL_FLOAT_ELEMENTS) &&
2132 (elements_kind != EXTERNAL_DOUBLE_ELEMENTS)) || 2132 (elements_kind != EXTERNAL_DOUBLE_ELEMENTS)) ||
(...skipping 398 matching lines...) Expand 10 before | Expand all | Expand 10 after
2531 2531
2532 2532
2533 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) { 2533 LInstruction* LChunkBuilder::DoLoadFieldByIndex(HLoadFieldByIndex* instr) {
2534 LOperand* object = UseRegister(instr->object()); 2534 LOperand* object = UseRegister(instr->object());
2535 LOperand* index = UseRegister(instr->index()); 2535 LOperand* index = UseRegister(instr->index());
2536 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index)); 2536 return DefineAsRegister(new(zone()) LLoadFieldByIndex(object, index));
2537 } 2537 }
2538 2538
2539 2539
2540 } } // namespace v8::internal 2540 } } // 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