OLD | NEW |
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_X64 | 9 #if V8_TARGET_ARCH_X64 |
10 | 10 |
(...skipping 2308 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2319 LOperand* context = UseFixed(instr->context(), rsi); | 2319 LOperand* context = UseFixed(instr->context(), rsi); |
2320 LOperand* object = | 2320 LOperand* object = |
2321 UseFixed(instr->object(), StoreDescriptor::ReceiverRegister()); | 2321 UseFixed(instr->object(), StoreDescriptor::ReceiverRegister()); |
2322 LOperand* key = UseFixed(instr->key(), StoreDescriptor::NameRegister()); | 2322 LOperand* key = UseFixed(instr->key(), StoreDescriptor::NameRegister()); |
2323 LOperand* value = UseFixed(instr->value(), StoreDescriptor::ValueRegister()); | 2323 LOperand* value = UseFixed(instr->value(), StoreDescriptor::ValueRegister()); |
2324 | 2324 |
2325 DCHECK(instr->object()->representation().IsTagged()); | 2325 DCHECK(instr->object()->representation().IsTagged()); |
2326 DCHECK(instr->key()->representation().IsTagged()); | 2326 DCHECK(instr->key()->representation().IsTagged()); |
2327 DCHECK(instr->value()->representation().IsTagged()); | 2327 DCHECK(instr->value()->representation().IsTagged()); |
2328 | 2328 |
2329 LStoreKeyedGeneric* result = | 2329 LOperand* slot = NULL; |
2330 new(zone()) LStoreKeyedGeneric(context, object, key, value); | 2330 LOperand* vector = NULL; |
| 2331 if (instr->HasVectorAndSlot()) { |
| 2332 slot = FixedTemp(VectorStoreICDescriptor::SlotRegister()); |
| 2333 vector = FixedTemp(VectorStoreICDescriptor::VectorRegister()); |
| 2334 } |
| 2335 |
| 2336 LStoreKeyedGeneric* result = new (zone()) |
| 2337 LStoreKeyedGeneric(context, object, key, value, slot, vector); |
2331 return MarkAsCall(result, instr); | 2338 return MarkAsCall(result, instr); |
2332 } | 2339 } |
2333 | 2340 |
2334 | 2341 |
2335 LInstruction* LChunkBuilder::DoTransitionElementsKind( | 2342 LInstruction* LChunkBuilder::DoTransitionElementsKind( |
2336 HTransitionElementsKind* instr) { | 2343 HTransitionElementsKind* instr) { |
2337 if (IsSimpleMapChangeTransition(instr->from_kind(), instr->to_kind())) { | 2344 if (IsSimpleMapChangeTransition(instr->from_kind(), instr->to_kind())) { |
2338 LOperand* object = UseRegister(instr->object()); | 2345 LOperand* object = UseRegister(instr->object()); |
2339 LOperand* new_map_reg = TempRegister(); | 2346 LOperand* new_map_reg = TempRegister(); |
2340 LOperand* temp_reg = TempRegister(); | 2347 LOperand* temp_reg = TempRegister(); |
(...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2424 | 2431 |
2425 return new(zone()) LStoreNamedField(obj, val, temp); | 2432 return new(zone()) LStoreNamedField(obj, val, temp); |
2426 } | 2433 } |
2427 | 2434 |
2428 | 2435 |
2429 LInstruction* LChunkBuilder::DoStoreNamedGeneric(HStoreNamedGeneric* instr) { | 2436 LInstruction* LChunkBuilder::DoStoreNamedGeneric(HStoreNamedGeneric* instr) { |
2430 LOperand* context = UseFixed(instr->context(), rsi); | 2437 LOperand* context = UseFixed(instr->context(), rsi); |
2431 LOperand* object = | 2438 LOperand* object = |
2432 UseFixed(instr->object(), StoreDescriptor::ReceiverRegister()); | 2439 UseFixed(instr->object(), StoreDescriptor::ReceiverRegister()); |
2433 LOperand* value = UseFixed(instr->value(), StoreDescriptor::ValueRegister()); | 2440 LOperand* value = UseFixed(instr->value(), StoreDescriptor::ValueRegister()); |
| 2441 LOperand* slot = NULL; |
| 2442 LOperand* vector = NULL; |
| 2443 if (instr->HasVectorAndSlot()) { |
| 2444 slot = FixedTemp(VectorStoreICDescriptor::SlotRegister()); |
| 2445 vector = FixedTemp(VectorStoreICDescriptor::VectorRegister()); |
| 2446 } |
2434 | 2447 |
2435 LStoreNamedGeneric* result = | 2448 LStoreNamedGeneric* result = |
2436 new(zone()) LStoreNamedGeneric(context, object, value); | 2449 new (zone()) LStoreNamedGeneric(context, object, value, slot, vector); |
2437 return MarkAsCall(result, instr); | 2450 return MarkAsCall(result, instr); |
2438 } | 2451 } |
2439 | 2452 |
2440 | 2453 |
2441 LInstruction* LChunkBuilder::DoStringAdd(HStringAdd* instr) { | 2454 LInstruction* LChunkBuilder::DoStringAdd(HStringAdd* instr) { |
2442 LOperand* context = UseFixed(instr->context(), rsi); | 2455 LOperand* context = UseFixed(instr->context(), rsi); |
2443 LOperand* left = UseFixed(instr->left(), rdx); | 2456 LOperand* left = UseFixed(instr->left(), rdx); |
2444 LOperand* right = UseFixed(instr->right(), rax); | 2457 LOperand* right = UseFixed(instr->right(), rax); |
2445 return MarkAsCall( | 2458 return MarkAsCall( |
2446 DefineFixed(new(zone()) LStringAdd(context, left, right), rax), instr); | 2459 DefineFixed(new(zone()) LStringAdd(context, left, right), rax), instr); |
(...skipping 257 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2704 LAllocateBlockContext* result = | 2717 LAllocateBlockContext* result = |
2705 new(zone()) LAllocateBlockContext(context, function); | 2718 new(zone()) LAllocateBlockContext(context, function); |
2706 return MarkAsCall(DefineFixed(result, rsi), instr); | 2719 return MarkAsCall(DefineFixed(result, rsi), instr); |
2707 } | 2720 } |
2708 | 2721 |
2709 | 2722 |
2710 } // namespace internal | 2723 } // namespace internal |
2711 } // namespace v8 | 2724 } // namespace v8 |
2712 | 2725 |
2713 #endif // V8_TARGET_ARCH_X64 | 2726 #endif // V8_TARGET_ARCH_X64 |
OLD | NEW |