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

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

Issue 771033003: Revert of Use weak cells in map checks in polymorphic ICs. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 6 years 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/x64/macro-assembler-x64.h ('k') | src/x87/macro-assembler-x87.h » ('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/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/base/division-by-constant.h" 10 #include "src/base/division-by-constant.h"
(...skipping 2834 matching lines...) Expand 10 before | Expand all | Expand 10 after
2845 if (dst.is(rax)) { 2845 if (dst.is(rax)) {
2846 AllowDeferredHandleDereference embedding_raw_address; 2846 AllowDeferredHandleDereference embedding_raw_address;
2847 load_rax(cell.location(), RelocInfo::CELL); 2847 load_rax(cell.location(), RelocInfo::CELL);
2848 } else { 2848 } else {
2849 Move(dst, cell, RelocInfo::CELL); 2849 Move(dst, cell, RelocInfo::CELL);
2850 movp(dst, Operand(dst, 0)); 2850 movp(dst, Operand(dst, 0));
2851 } 2851 }
2852 } 2852 }
2853 2853
2854 2854
2855 void MacroAssembler::CmpWeakValue(Register value, Handle<WeakCell> cell,
2856 Register scratch) {
2857 Move(scratch, cell, RelocInfo::EMBEDDED_OBJECT);
2858 cmpp(value, FieldOperand(scratch, WeakCell::kValueOffset));
2859 }
2860
2861
2862 void MacroAssembler::LoadWeakValue(Register value, Handle<WeakCell> cell,
2863 Label* miss) {
2864 Move(value, cell, RelocInfo::EMBEDDED_OBJECT);
2865 movp(value, FieldOperand(value, WeakCell::kValueOffset));
2866 JumpIfSmi(value, miss);
2867 }
2868
2869
2870 void MacroAssembler::Drop(int stack_elements) { 2855 void MacroAssembler::Drop(int stack_elements) {
2871 if (stack_elements > 0) { 2856 if (stack_elements > 0) {
2872 addp(rsp, Immediate(stack_elements * kPointerSize)); 2857 addp(rsp, Immediate(stack_elements * kPointerSize));
2873 } 2858 }
2874 } 2859 }
2875 2860
2876 2861
2877 void MacroAssembler::DropUnderReturnAddress(int stack_elements, 2862 void MacroAssembler::DropUnderReturnAddress(int stack_elements,
2878 Register scratch) { 2863 Register scratch) {
2879 DCHECK(stack_elements > 0); 2864 DCHECK(stack_elements > 0);
(...skipping 2529 matching lines...) Expand 10 before | Expand all | Expand 10 after
5409 if (mag.shift > 0) sarl(rdx, Immediate(mag.shift)); 5394 if (mag.shift > 0) sarl(rdx, Immediate(mag.shift));
5410 movl(rax, dividend); 5395 movl(rax, dividend);
5411 shrl(rax, Immediate(31)); 5396 shrl(rax, Immediate(31));
5412 addl(rdx, rax); 5397 addl(rdx, rax);
5413 } 5398 }
5414 5399
5415 5400
5416 } } // namespace v8::internal 5401 } } // namespace v8::internal
5417 5402
5418 #endif // V8_TARGET_ARCH_X64 5403 #endif // V8_TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « src/x64/macro-assembler-x64.h ('k') | src/x87/macro-assembler-x87.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698