Chromium Code Reviews| 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 "src/v8.h" | 5 #include "src/v8.h" |
| 6 | 6 |
| 7 #if V8_TARGET_ARCH_X64 | 7 #if V8_TARGET_ARCH_X64 |
| 8 | 8 |
| 9 #include "src/lithium-allocator-inl.h" | 9 #include "src/lithium-allocator-inl.h" |
| 10 #include "src/x64/lithium-x64.h" | 10 #include "src/x64/lithium-x64.h" |
| (...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 324 | 324 |
| 325 stream->Add(" length "); | 325 stream->Add(" length "); |
| 326 length()->PrintTo(stream); | 326 length()->PrintTo(stream); |
| 327 | 327 |
| 328 stream->Add(" index "); | 328 stream->Add(" index "); |
| 329 index()->PrintTo(stream); | 329 index()->PrintTo(stream); |
| 330 } | 330 } |
| 331 | 331 |
| 332 | 332 |
| 333 int LPlatformChunk::GetNextSpillIndex(RegisterKind kind) { | 333 int LPlatformChunk::GetNextSpillIndex(RegisterKind kind) { |
| 334 if (kind == DOUBLE_REGISTERS && kDoubleSize == 2 * kPointerSize) { | |
| 335 // Skip a slot if for a double-width slot for x32 port. | |
| 336 // TODO(haitao): make sure spilled doubles are aligned for x32 port. | |
| 337 spill_slot_count_++; | |
| 338 spill_slot_count_ |= 1; | |
|
Toon Verwaest
2014/06/12 09:12:13
Can you comment what this is supposed to do?
haitao.feng
2014/06/13 05:15:24
Done.
| |
| 339 } | |
| 334 return spill_slot_count_++; | 340 return spill_slot_count_++; |
| 335 } | 341 } |
| 336 | 342 |
| 337 | 343 |
| 338 LOperand* LPlatformChunk::GetNextSpillSlot(RegisterKind kind) { | 344 LOperand* LPlatformChunk::GetNextSpillSlot(RegisterKind kind) { |
| 339 // All stack slots are Double stack slots on x64. | 345 // All stack slots are Double stack slots on x64. |
| 340 // Alternatively, at some point, start using half-size | 346 // Alternatively, at some point, start using half-size |
| 341 // stack slots for int32 values. | 347 // stack slots for int32 values. |
| 342 int index = GetNextSpillIndex(kind); | 348 int index = GetNextSpillIndex(kind); |
| 343 if (kind == DOUBLE_REGISTERS) { | 349 if (kind == DOUBLE_REGISTERS) { |
| (...skipping 2253 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 2597 LOperand* function = UseRegisterAtStart(instr->function()); | 2603 LOperand* function = UseRegisterAtStart(instr->function()); |
| 2598 LAllocateBlockContext* result = | 2604 LAllocateBlockContext* result = |
| 2599 new(zone()) LAllocateBlockContext(context, function); | 2605 new(zone()) LAllocateBlockContext(context, function); |
| 2600 return MarkAsCall(DefineFixed(result, rsi), instr); | 2606 return MarkAsCall(DefineFixed(result, rsi), instr); |
| 2601 } | 2607 } |
| 2602 | 2608 |
| 2603 | 2609 |
| 2604 } } // namespace v8::internal | 2610 } } // namespace v8::internal |
| 2605 | 2611 |
| 2606 #endif // V8_TARGET_ARCH_X64 | 2612 #endif // V8_TARGET_ARCH_X64 |
| OLD | NEW |