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

Side by Side Diff: src/x64/macro-assembler-x64.cc

Issue 334323003: Reland r22082 "Replace HeapNumber as doublebox with an explicit MutableHeapNumber." (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Migrations test fixed Created 6 years, 5 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/x64/macro-assembler-x64.h ('k') | src/x64/stub-cache-x64.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 "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/bootstrapper.h" 9 #include "src/bootstrapper.h"
10 #include "src/codegen.h" 10 #include "src/codegen.h"
(...skipping 4575 matching lines...) Expand 10 before | Expand all | Expand 10 after
4586 #ifdef DEBUG 4586 #ifdef DEBUG
4587 cmpp(object, top_operand); 4587 cmpp(object, top_operand);
4588 Check(below, kUndoAllocationOfNonAllocatedMemory); 4588 Check(below, kUndoAllocationOfNonAllocatedMemory);
4589 #endif 4589 #endif
4590 movp(top_operand, object); 4590 movp(top_operand, object);
4591 } 4591 }
4592 4592
4593 4593
4594 void MacroAssembler::AllocateHeapNumber(Register result, 4594 void MacroAssembler::AllocateHeapNumber(Register result,
4595 Register scratch, 4595 Register scratch,
4596 Label* gc_required) { 4596 Label* gc_required,
4597 MutableMode mode) {
4597 // Allocate heap number in new space. 4598 // Allocate heap number in new space.
4598 Allocate(HeapNumber::kSize, result, scratch, no_reg, gc_required, TAG_OBJECT); 4599 Allocate(HeapNumber::kSize, result, scratch, no_reg, gc_required, TAG_OBJECT);
4599 4600
4601 Heap::RootListIndex map_index = mode == MUTABLE
4602 ? Heap::kMutableHeapNumberMapRootIndex
4603 : Heap::kHeapNumberMapRootIndex;
4604
4600 // Set the map. 4605 // Set the map.
4601 LoadRoot(kScratchRegister, Heap::kHeapNumberMapRootIndex); 4606 LoadRoot(kScratchRegister, map_index);
4602 movp(FieldOperand(result, HeapObject::kMapOffset), kScratchRegister); 4607 movp(FieldOperand(result, HeapObject::kMapOffset), kScratchRegister);
4603 } 4608 }
4604 4609
4605 4610
4606 void MacroAssembler::AllocateTwoByteString(Register result, 4611 void MacroAssembler::AllocateTwoByteString(Register result,
4607 Register length, 4612 Register length,
4608 Register scratch1, 4613 Register scratch1,
4609 Register scratch2, 4614 Register scratch2,
4610 Register scratch3, 4615 Register scratch3,
4611 Label* gc_required) { 4616 Label* gc_required) {
(...skipping 738 matching lines...) Expand 10 before | Expand all | Expand 10 after
5350 if (ms.shift() > 0) sarl(rdx, Immediate(ms.shift())); 5355 if (ms.shift() > 0) sarl(rdx, Immediate(ms.shift()));
5351 movl(rax, dividend); 5356 movl(rax, dividend);
5352 shrl(rax, Immediate(31)); 5357 shrl(rax, Immediate(31));
5353 addl(rdx, rax); 5358 addl(rdx, rax);
5354 } 5359 }
5355 5360
5356 5361
5357 } } // namespace v8::internal 5362 } } // namespace v8::internal
5358 5363
5359 #endif // V8_TARGET_ARCH_X64 5364 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/x64/macro-assembler-x64.h ('k') | src/x64/stub-cache-x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698