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

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

Issue 1980463002: Fix %FunctionGetName and %_ClassOf for bound functions. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fix %_ClassOf instead Created 4 years, 7 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/full-codegen/arm/full-codegen-arm.cc ('k') | src/full-codegen/ia32/full-codegen-ia32.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 2013 the V8 project authors. All rights reserved. 1 // Copyright 2013 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_ARM64 5 #if V8_TARGET_ARCH_ARM64
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 2723 matching lines...) Expand 10 before | Expand all | Expand 10 after
2734 2734
2735 // If the object is not a JSReceiver, we return null. 2735 // If the object is not a JSReceiver, we return null.
2736 __ JumpIfSmi(x0, &null); 2736 __ JumpIfSmi(x0, &null);
2737 STATIC_ASSERT(LAST_JS_RECEIVER_TYPE == LAST_TYPE); 2737 STATIC_ASSERT(LAST_JS_RECEIVER_TYPE == LAST_TYPE);
2738 __ CompareObjectType(x0, x10, x11, FIRST_JS_RECEIVER_TYPE); 2738 __ CompareObjectType(x0, x10, x11, FIRST_JS_RECEIVER_TYPE);
2739 // x10: object's map. 2739 // x10: object's map.
2740 // x11: object's type. 2740 // x11: object's type.
2741 __ B(lt, &null); 2741 __ B(lt, &null);
2742 2742
2743 // Return 'Function' for JSFunction objects. 2743 // Return 'Function' for JSFunction objects.
2744 __ Cmp(x11, JS_FUNCTION_TYPE); 2744 __ Cmp(x11, FIRST_FUNCTION_TYPE);
2745 __ B(eq, &function); 2745 STATIC_ASSERT(LAST_FUNCTION_TYPE == LAST_TYPE);
2746 __ B(hs, &function);
2746 2747
2747 // Check if the constructor in the map is a JS function. 2748 // Check if the constructor in the map is a JS function.
2748 Register instance_type = x14; 2749 Register instance_type = x14;
2749 __ GetMapConstructor(x12, x10, x13, instance_type); 2750 __ GetMapConstructor(x12, x10, x13, instance_type);
2750 __ Cmp(instance_type, JS_FUNCTION_TYPE); 2751 __ Cmp(instance_type, JS_FUNCTION_TYPE);
2751 __ B(ne, &non_function_constructor); 2752 __ B(ne, &non_function_constructor);
2752 2753
2753 // x12 now contains the constructor function. Grab the 2754 // x12 now contains the constructor function. Grab the
2754 // instance class name from there. 2755 // instance class name from there.
2755 __ Ldr(x13, FieldMemOperand(x12, JSFunction::kSharedFunctionInfoOffset)); 2756 __ Ldr(x13, FieldMemOperand(x12, JSFunction::kSharedFunctionInfoOffset));
(...skipping 1235 matching lines...) Expand 10 before | Expand all | Expand 10 after
3991 } 3992 }
3992 3993
3993 return INTERRUPT; 3994 return INTERRUPT;
3994 } 3995 }
3995 3996
3996 3997
3997 } // namespace internal 3998 } // namespace internal
3998 } // namespace v8 3999 } // namespace v8
3999 4000
4000 #endif // V8_TARGET_ARCH_ARM64 4001 #endif // V8_TARGET_ARCH_ARM64
OLDNEW
« no previous file with comments | « src/full-codegen/arm/full-codegen-arm.cc ('k') | src/full-codegen/ia32/full-codegen-ia32.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698