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

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

Issue 1124443004: New hydrogen instruction to reduce cost of growing an array on keyed stores. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: REBASE. Created 5 years, 7 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-mips.h ('k') | src/mips64/interface-descriptors-mips64.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 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include <sstream> 5 #include <sstream>
6 6
7 #include "src/v8.h" 7 #include "src/v8.h"
8 8
9 #if V8_TARGET_ARCH_MIPS 9 #if V8_TARGET_ARCH_MIPS
10 10
(...skipping 2298 matching lines...) Expand 10 before | Expand all | Expand 10 after
2309 LInstruction* LChunkBuilder::DoTrapAllocationMemento( 2309 LInstruction* LChunkBuilder::DoTrapAllocationMemento(
2310 HTrapAllocationMemento* instr) { 2310 HTrapAllocationMemento* instr) {
2311 LOperand* object = UseRegister(instr->object()); 2311 LOperand* object = UseRegister(instr->object());
2312 LOperand* temp = TempRegister(); 2312 LOperand* temp = TempRegister();
2313 LTrapAllocationMemento* result = 2313 LTrapAllocationMemento* result =
2314 new(zone()) LTrapAllocationMemento(object, temp); 2314 new(zone()) LTrapAllocationMemento(object, temp);
2315 return AssignEnvironment(result); 2315 return AssignEnvironment(result);
2316 } 2316 }
2317 2317
2318 2318
2319 LInstruction* LChunkBuilder::DoMaybeGrowElements(HMaybeGrowElements* instr) {
2320 info()->MarkAsDeferredCalling();
2321 LOperand* context = UseFixed(instr->context(), cp);
2322 LOperand* object = Use(instr->object());
2323 LOperand* elements = Use(instr->elements());
2324 LOperand* key = UseRegisterOrConstant(instr->key());
2325 LOperand* current_capacity = UseRegisterOrConstant(instr->current_capacity());
2326
2327 LMaybeGrowElements* result = new (zone())
2328 LMaybeGrowElements(context, object, elements, key, current_capacity);
2329 DefineFixed(result, v0);
2330 return AssignPointerMap(AssignEnvironment(result));
2331 }
2332
2333
2319 LInstruction* LChunkBuilder::DoStoreNamedField(HStoreNamedField* instr) { 2334 LInstruction* LChunkBuilder::DoStoreNamedField(HStoreNamedField* instr) {
2320 bool is_in_object = instr->access().IsInobject(); 2335 bool is_in_object = instr->access().IsInobject();
2321 bool needs_write_barrier = instr->NeedsWriteBarrier(); 2336 bool needs_write_barrier = instr->NeedsWriteBarrier();
2322 bool needs_write_barrier_for_map = instr->has_transition() && 2337 bool needs_write_barrier_for_map = instr->has_transition() &&
2323 instr->NeedsWriteBarrierForMap(); 2338 instr->NeedsWriteBarrierForMap();
2324 2339
2325 LOperand* obj; 2340 LOperand* obj;
2326 if (needs_write_barrier) { 2341 if (needs_write_barrier) {
2327 obj = is_in_object 2342 obj = is_in_object
2328 ? UseRegister(instr->object()) 2343 ? UseRegister(instr->object())
(...skipping 286 matching lines...) Expand 10 before | Expand all | Expand 10 after
2615 LOperand* context = UseFixed(instr->context(), cp); 2630 LOperand* context = UseFixed(instr->context(), cp);
2616 LOperand* function = UseRegisterAtStart(instr->function()); 2631 LOperand* function = UseRegisterAtStart(instr->function());
2617 LAllocateBlockContext* result = 2632 LAllocateBlockContext* result =
2618 new(zone()) LAllocateBlockContext(context, function); 2633 new(zone()) LAllocateBlockContext(context, function);
2619 return MarkAsCall(DefineFixed(result, cp), instr); 2634 return MarkAsCall(DefineFixed(result, cp), instr);
2620 } 2635 }
2621 2636
2622 } } // namespace v8::internal 2637 } } // namespace v8::internal
2623 2638
2624 #endif // V8_TARGET_ARCH_MIPS 2639 #endif // V8_TARGET_ARCH_MIPS
OLDNEW
« no previous file with comments | « src/mips/lithium-mips.h ('k') | src/mips64/interface-descriptors-mips64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698