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

Side by Side Diff: src/full-codegen/arm/full-codegen-arm.cc

Issue 2227763003: [turbofan] Rewrite ToObject as TurboFan stub. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Add comment with ES6 section Created 4 years, 4 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
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_ARM 5 #if V8_TARGET_ARCH_ARM
6 6
7 #include "src/ast/scopes.h" 7 #include "src/ast/scopes.h"
8 #include "src/code-factory.h" 8 #include "src/code-factory.h"
9 #include "src/code-stubs.h" 9 #include "src/code-stubs.h"
10 #include "src/codegen.h" 10 #include "src/codegen.h"
(...skipping 985 matching lines...) Expand 10 before | Expand all | Expand 10 after
996 // it to a JS receiver. See ECMA-262 version 5, section 12.6.4. 996 // it to a JS receiver. See ECMA-262 version 5, section 12.6.4.
997 Label convert, done_convert; 997 Label convert, done_convert;
998 __ JumpIfSmi(r0, &convert); 998 __ JumpIfSmi(r0, &convert);
999 __ CompareObjectType(r0, r1, r1, FIRST_JS_RECEIVER_TYPE); 999 __ CompareObjectType(r0, r1, r1, FIRST_JS_RECEIVER_TYPE);
1000 __ b(ge, &done_convert); 1000 __ b(ge, &done_convert);
1001 __ CompareRoot(r0, Heap::kNullValueRootIndex); 1001 __ CompareRoot(r0, Heap::kNullValueRootIndex);
1002 __ b(eq, &exit); 1002 __ b(eq, &exit);
1003 __ CompareRoot(r0, Heap::kUndefinedValueRootIndex); 1003 __ CompareRoot(r0, Heap::kUndefinedValueRootIndex);
1004 __ b(eq, &exit); 1004 __ b(eq, &exit);
1005 __ bind(&convert); 1005 __ bind(&convert);
1006 __ Push(cp);
1006 ToObjectStub stub(isolate()); 1007 ToObjectStub stub(isolate());
1007 __ CallStub(&stub); 1008 __ CallStub(&stub);
1009 __ Pop(cp);
Michael Starzinger 2016/08/09 10:24:29 Please use FullCodeGenerator::RestoreContext after
Franzi 2016/08/09 11:21:38 Done.
1008 __ bind(&done_convert); 1010 __ bind(&done_convert);
1009 PrepareForBailoutForId(stmt->ToObjectId(), BailoutState::TOS_REGISTER); 1011 PrepareForBailoutForId(stmt->ToObjectId(), BailoutState::TOS_REGISTER);
1010 __ push(r0); 1012 __ push(r0);
1011 1013
1012 // Check cache validity in generated code. If we cannot guarantee cache 1014 // Check cache validity in generated code. If we cannot guarantee cache
1013 // validity, call the runtime system to check cache validity or get the 1015 // validity, call the runtime system to check cache validity or get the
1014 // property names in a fixed array. Note: Proxies never have an enum cache, 1016 // property names in a fixed array. Note: Proxies never have an enum cache,
1015 // so will always take the slow path. 1017 // so will always take the slow path.
1016 Label call_runtime; 1018 Label call_runtime;
1017 __ CheckEnumCache(&call_runtime); 1019 __ CheckEnumCache(&call_runtime);
(...skipping 2820 matching lines...) Expand 10 before | Expand all | Expand 10 after
3838 DCHECK(interrupt_address == 3840 DCHECK(interrupt_address ==
3839 isolate->builtins()->OnStackReplacement()->entry()); 3841 isolate->builtins()->OnStackReplacement()->entry());
3840 return ON_STACK_REPLACEMENT; 3842 return ON_STACK_REPLACEMENT;
3841 } 3843 }
3842 3844
3843 3845
3844 } // namespace internal 3846 } // namespace internal
3845 } // namespace v8 3847 } // namespace v8
3846 3848
3847 #endif // V8_TARGET_ARCH_ARM 3849 #endif // V8_TARGET_ARCH_ARM
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698