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

Side by Side Diff: src/crankshaft/arm/lithium-codegen-arm.cc

Issue 2512943002: [crankshaft] The array protector is a PropertyCell, not a Cell. (Closed)
Patch Set: Created 4 years, 1 month 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 | « no previous file | src/crankshaft/arm64/lithium-codegen-arm64.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 #include "src/crankshaft/arm/lithium-codegen-arm.h" 5 #include "src/crankshaft/arm/lithium-codegen-arm.h"
6 6
7 #include "src/base/bits.h" 7 #include "src/base/bits.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/crankshaft/arm/lithium-gap-resolver-arm.h" 10 #include "src/crankshaft/arm/lithium-gap-resolver-arm.h"
(...skipping 2855 matching lines...) Expand 10 before | Expand all | Expand 10 after
2866 DCHECK(instr->hydrogen()->elements_kind() == FAST_HOLEY_ELEMENTS); 2866 DCHECK(instr->hydrogen()->elements_kind() == FAST_HOLEY_ELEMENTS);
2867 Label done; 2867 Label done;
2868 __ LoadRoot(scratch, Heap::kTheHoleValueRootIndex); 2868 __ LoadRoot(scratch, Heap::kTheHoleValueRootIndex);
2869 __ cmp(result, scratch); 2869 __ cmp(result, scratch);
2870 __ b(ne, &done); 2870 __ b(ne, &done);
2871 if (info()->IsStub()) { 2871 if (info()->IsStub()) {
2872 // A stub can safely convert the hole to undefined only if the array 2872 // A stub can safely convert the hole to undefined only if the array
2873 // protector cell contains (Smi) Isolate::kProtectorValid. Otherwise 2873 // protector cell contains (Smi) Isolate::kProtectorValid. Otherwise
2874 // it needs to bail out. 2874 // it needs to bail out.
2875 __ LoadRoot(result, Heap::kArrayProtectorRootIndex); 2875 __ LoadRoot(result, Heap::kArrayProtectorRootIndex);
2876 __ ldr(result, FieldMemOperand(result, Cell::kValueOffset)); 2876 __ ldr(result, FieldMemOperand(result, PropertyCell::kValueOffset));
2877 __ cmp(result, Operand(Smi::FromInt(Isolate::kProtectorValid))); 2877 __ cmp(result, Operand(Smi::FromInt(Isolate::kProtectorValid)));
2878 DeoptimizeIf(ne, instr, DeoptimizeReason::kHole); 2878 DeoptimizeIf(ne, instr, DeoptimizeReason::kHole);
2879 } 2879 }
2880 __ LoadRoot(result, Heap::kUndefinedValueRootIndex); 2880 __ LoadRoot(result, Heap::kUndefinedValueRootIndex);
2881 __ bind(&done); 2881 __ bind(&done);
2882 } 2882 }
2883 } 2883 }
2884 2884
2885 2885
2886 void LCodeGen::DoLoadKeyed(LLoadKeyed* instr) { 2886 void LCodeGen::DoLoadKeyed(LLoadKeyed* instr) {
(...skipping 2495 matching lines...) Expand 10 before | Expand all | Expand 10 after
5382 __ ldr(result, FieldMemOperand(scratch, 5382 __ ldr(result, FieldMemOperand(scratch,
5383 FixedArray::kHeaderSize - kPointerSize)); 5383 FixedArray::kHeaderSize - kPointerSize));
5384 __ bind(deferred->exit()); 5384 __ bind(deferred->exit());
5385 __ bind(&done); 5385 __ bind(&done);
5386 } 5386 }
5387 5387
5388 #undef __ 5388 #undef __
5389 5389
5390 } // namespace internal 5390 } // namespace internal
5391 } // namespace v8 5391 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/crankshaft/arm64/lithium-codegen-arm64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698