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

Side by Side Diff: src/ia32/code-stubs-ia32.cc

Issue 1819813002: [es6] Faster implementation of OrdinaryHasInstance. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Revert flag-flip again. Created 4 years, 9 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
« no previous file with comments | « src/ia32/builtins-ia32.cc ('k') | src/mips/builtins-mips.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 #if V8_TARGET_ARCH_IA32 5 #if V8_TARGET_ARCH_IA32
6 6
7 #include "src/code-stubs.h" 7 #include "src/code-stubs.h"
8 #include "src/api-arguments.h" 8 #include "src/api-arguments.h"
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/bootstrapper.h" 10 #include "src/bootstrapper.h"
(...skipping 2195 matching lines...) Expand 10 before | Expand all | Expand 10 after
2206 __ Move(eax, Immediate(Smi::FromInt(0))); 2206 __ Move(eax, Immediate(Smi::FromInt(0)));
2207 __ StoreRoot(eax, scratch, Heap::kInstanceofCacheFunctionRootIndex); 2207 __ StoreRoot(eax, scratch, Heap::kInstanceofCacheFunctionRootIndex);
2208 __ TailCallRuntime(Runtime::kHasInPrototypeChain); 2208 __ TailCallRuntime(Runtime::kHasInPrototypeChain);
2209 2209
2210 // Slow-case: Call the %InstanceOf runtime function. 2210 // Slow-case: Call the %InstanceOf runtime function.
2211 __ bind(&slow_case); 2211 __ bind(&slow_case);
2212 __ PopReturnAddressTo(scratch); 2212 __ PopReturnAddressTo(scratch);
2213 __ Push(object); 2213 __ Push(object);
2214 __ Push(function); 2214 __ Push(function);
2215 __ PushReturnAddressFrom(scratch); 2215 __ PushReturnAddressFrom(scratch);
2216 __ TailCallRuntime(Runtime::kInstanceOf); 2216 __ TailCallRuntime(is_es6_instanceof() ? Runtime::kOrdinaryHasInstance
2217 : Runtime::kInstanceOf);
2217 } 2218 }
2218 2219
2219 2220
2220 // ------------------------------------------------------------------------- 2221 // -------------------------------------------------------------------------
2221 // StringCharCodeAtGenerator 2222 // StringCharCodeAtGenerator
2222 2223
2223 void StringCharCodeAtGenerator::GenerateFast(MacroAssembler* masm) { 2224 void StringCharCodeAtGenerator::GenerateFast(MacroAssembler* masm) {
2224 // If the receiver is a smi trigger the non-string case. 2225 // If the receiver is a smi trigger the non-string case.
2225 STATIC_ASSERT(kSmiTag == 0); 2226 STATIC_ASSERT(kSmiTag == 0);
2226 if (check_mode_ == RECEIVER_IS_UNKNOWN) { 2227 if (check_mode_ == RECEIVER_IS_UNKNOWN) {
(...skipping 3653 matching lines...) Expand 10 before | Expand all | Expand 10 after
5880 return_value_operand, NULL); 5881 return_value_operand, NULL);
5881 } 5882 }
5882 5883
5883 5884
5884 #undef __ 5885 #undef __
5885 5886
5886 } // namespace internal 5887 } // namespace internal
5887 } // namespace v8 5888 } // namespace v8
5888 5889
5889 #endif // V8_TARGET_ARCH_IA32 5890 #endif // V8_TARGET_ARCH_IA32
OLDNEW
« no previous file with comments | « src/ia32/builtins-ia32.cc ('k') | src/mips/builtins-mips.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698