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

Unified Diff: src/arm64/lithium-codegen-arm64.cc

Issue 950283002: Move Maps' back pointers from "transitions" to "constructor" field (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: fix stupidity on arm64 Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/arm64/full-codegen-arm64.cc ('k') | src/arm64/macro-assembler-arm64.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/arm64/lithium-codegen-arm64.cc
diff --git a/src/arm64/lithium-codegen-arm64.cc b/src/arm64/lithium-codegen-arm64.cc
index a95ae9ef116fa1ca3de44bbfb7f201efb7782bdf..2f9169812a8e0c63059f41b0f46b61e47fbb4411 100644
--- a/src/arm64/lithium-codegen-arm64.cc
+++ b/src/arm64/lithium-codegen-arm64.cc
@@ -2438,15 +2438,17 @@ void LCodeGen::DoClassOfTestAndBranch(LClassOfTestAndBranch* instr) {
// Now we are in the FIRST-LAST_NONCALLABLE_SPEC_OBJECT_TYPE range.
// Check if the constructor in the map is a function.
- __ Ldr(scratch1, FieldMemOperand(map, Map::kConstructorOffset));
-
+ {
+ UseScratchRegisterScope temps(masm());
+ Register instance_type = temps.AcquireX();
+ __ GetMapConstructor(scratch1, map, scratch2, instance_type);
+ __ Cmp(instance_type, JS_FUNCTION_TYPE);
+ }
// Objects with a non-function constructor have class 'Object'.
if (String::Equals(class_name, isolate()->factory()->Object_string())) {
- __ JumpIfNotObjectType(
- scratch1, scratch2, scratch2, JS_FUNCTION_TYPE, true_label);
+ __ B(ne, true_label);
} else {
- __ JumpIfNotObjectType(
- scratch1, scratch2, scratch2, JS_FUNCTION_TYPE, false_label);
+ __ B(ne, false_label);
}
// The constructor function is in scratch1. Get its instance class name.
« no previous file with comments | « src/arm64/full-codegen-arm64.cc ('k') | src/arm64/macro-assembler-arm64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698