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

Side by Side Diff: src/x87/lithium-codegen-x87.cc

Issue 964783002: X87: Move Maps' back pointers from "transitions" to "constructor" field. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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/x87/full-codegen-x87.cc ('k') | src/x87/macro-assembler-x87.h » ('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 #include "src/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_X87 7 #if V8_TARGET_ARCH_X87
8 8
9 #include "src/base/bits.h" 9 #include "src/base/bits.h"
10 #include "src/code-factory.h" 10 #include "src/code-factory.h"
(...skipping 2837 matching lines...) Expand 10 before | Expand all | Expand 10 after
2848 __ mov(temp, FieldOperand(input, HeapObject::kMapOffset)); 2848 __ mov(temp, FieldOperand(input, HeapObject::kMapOffset));
2849 __ movzx_b(temp2, FieldOperand(temp, Map::kInstanceTypeOffset)); 2849 __ movzx_b(temp2, FieldOperand(temp, Map::kInstanceTypeOffset));
2850 __ sub(Operand(temp2), Immediate(FIRST_NONCALLABLE_SPEC_OBJECT_TYPE)); 2850 __ sub(Operand(temp2), Immediate(FIRST_NONCALLABLE_SPEC_OBJECT_TYPE));
2851 __ cmp(Operand(temp2), Immediate(LAST_NONCALLABLE_SPEC_OBJECT_TYPE - 2851 __ cmp(Operand(temp2), Immediate(LAST_NONCALLABLE_SPEC_OBJECT_TYPE -
2852 FIRST_NONCALLABLE_SPEC_OBJECT_TYPE)); 2852 FIRST_NONCALLABLE_SPEC_OBJECT_TYPE));
2853 __ j(above, is_false); 2853 __ j(above, is_false);
2854 } 2854 }
2855 2855
2856 // Now we are in the FIRST-LAST_NONCALLABLE_SPEC_OBJECT_TYPE range. 2856 // Now we are in the FIRST-LAST_NONCALLABLE_SPEC_OBJECT_TYPE range.
2857 // Check if the constructor in the map is a function. 2857 // Check if the constructor in the map is a function.
2858 __ mov(temp, FieldOperand(temp, Map::kConstructorOffset)); 2858 __ GetMapConstructor(temp, temp, temp2);
2859 // Objects with a non-function constructor have class 'Object'. 2859 // Objects with a non-function constructor have class 'Object'.
2860 __ CmpObjectType(temp, JS_FUNCTION_TYPE, temp2); 2860 __ CmpInstanceType(temp2, JS_FUNCTION_TYPE);
2861 if (String::Equals(class_name, isolate()->factory()->Object_string())) { 2861 if (String::Equals(class_name, isolate()->factory()->Object_string())) {
2862 __ j(not_equal, is_true); 2862 __ j(not_equal, is_true);
2863 } else { 2863 } else {
2864 __ j(not_equal, is_false); 2864 __ j(not_equal, is_false);
2865 } 2865 }
2866 2866
2867 // temp now contains the constructor function. Grab the 2867 // temp now contains the constructor function. Grab the
2868 // instance class name from there. 2868 // instance class name from there.
2869 __ mov(temp, FieldOperand(temp, JSFunction::kSharedFunctionInfoOffset)); 2869 __ mov(temp, FieldOperand(temp, JSFunction::kSharedFunctionInfoOffset));
2870 __ mov(temp, FieldOperand(temp, 2870 __ mov(temp, FieldOperand(temp,
(...skipping 3516 matching lines...) Expand 10 before | Expand all | Expand 10 after
6387 CallRuntime(Runtime::kPushBlockContext, 2, instr); 6387 CallRuntime(Runtime::kPushBlockContext, 2, instr);
6388 RecordSafepoint(Safepoint::kNoLazyDeopt); 6388 RecordSafepoint(Safepoint::kNoLazyDeopt);
6389 } 6389 }
6390 6390
6391 6391
6392 #undef __ 6392 #undef __
6393 6393
6394 } } // namespace v8::internal 6394 } } // namespace v8::internal
6395 6395
6396 #endif // V8_TARGET_ARCH_X87 6396 #endif // V8_TARGET_ARCH_X87
OLDNEW
« no previous file with comments | « src/x87/full-codegen-x87.cc ('k') | src/x87/macro-assembler-x87.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698