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

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

Issue 1708313002: [stubs] Introduce a dedicated FastNewObjectStub. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Remove TODO. Created 4 years, 10 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
« src/bailout-reason.h ('K') | « src/x64/macro-assembler-x64.h ('k') | no next file » | 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 #if V8_TARGET_ARCH_X64 5 #if V8_TARGET_ARCH_X64
6 6
7 #include "src/base/bits.h" 7 #include "src/base/bits.h"
8 #include "src/base/division-by-constant.h" 8 #include "src/base/division-by-constant.h"
9 #include "src/bootstrapper.h" 9 #include "src/bootstrapper.h"
10 #include "src/codegen.h" 10 #include "src/codegen.h"
(...skipping 3934 matching lines...) Expand 10 before | Expand all | Expand 10 after
3945 testb(object, Immediate(kSmiTagMask)); 3945 testb(object, Immediate(kSmiTagMask));
3946 Check(not_equal, kOperandIsASmiAndNotABoundFunction); 3946 Check(not_equal, kOperandIsASmiAndNotABoundFunction);
3947 Push(object); 3947 Push(object);
3948 CmpObjectType(object, JS_BOUND_FUNCTION_TYPE, object); 3948 CmpObjectType(object, JS_BOUND_FUNCTION_TYPE, object);
3949 Pop(object); 3949 Pop(object);
3950 Check(equal, kOperandIsNotABoundFunction); 3950 Check(equal, kOperandIsNotABoundFunction);
3951 } 3951 }
3952 } 3952 }
3953 3953
3954 3954
3955 void MacroAssembler::AssertReceiver(Register object) {
3956 if (emit_debug_code()) {
3957 testb(object, Immediate(kSmiTagMask));
3958 Check(not_equal, kOperandIsASmiAndNotAReceiver);
3959 Push(object);
3960 STATIC_ASSERT(LAST_TYPE == LAST_JS_RECEIVER_TYPE);
3961 CmpObjectType(object, FIRST_JS_RECEIVER_TYPE, object);
3962 Pop(object);
3963 Check(above_equal, kOperandIsNotAReceiver);
3964 }
3965 }
3966
3967
3955 void MacroAssembler::AssertUndefinedOrAllocationSite(Register object) { 3968 void MacroAssembler::AssertUndefinedOrAllocationSite(Register object) {
3956 if (emit_debug_code()) { 3969 if (emit_debug_code()) {
3957 Label done_checking; 3970 Label done_checking;
3958 AssertNotSmi(object); 3971 AssertNotSmi(object);
3959 Cmp(object, isolate()->factory()->undefined_value()); 3972 Cmp(object, isolate()->factory()->undefined_value());
3960 j(equal, &done_checking); 3973 j(equal, &done_checking);
3961 Cmp(FieldOperand(object, 0), isolate()->factory()->allocation_site_map()); 3974 Cmp(FieldOperand(object, 0), isolate()->factory()->allocation_site_map());
3962 Assert(equal, kExpectedUndefinedOrCell); 3975 Assert(equal, kExpectedUndefinedOrCell);
3963 bind(&done_checking); 3976 bind(&done_checking);
3964 } 3977 }
(...skipping 1601 matching lines...) Expand 10 before | Expand all | Expand 10 after
5566 movl(rax, dividend); 5579 movl(rax, dividend);
5567 shrl(rax, Immediate(31)); 5580 shrl(rax, Immediate(31));
5568 addl(rdx, rax); 5581 addl(rdx, rax);
5569 } 5582 }
5570 5583
5571 5584
5572 } // namespace internal 5585 } // namespace internal
5573 } // namespace v8 5586 } // namespace v8
5574 5587
5575 #endif // V8_TARGET_ARCH_X64 5588 #endif // V8_TARGET_ARCH_X64
OLDNEW
« src/bailout-reason.h ('K') | « src/x64/macro-assembler-x64.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698