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

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

Issue 2398683004: [crankshaft] Remove HLoadNamedGeneric and use HCallWithDescriptor to call LoadIC. (Closed)
Patch Set: Created 4 years, 2 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/crankshaft/arm64/lithium-arm64.cc ('k') | src/crankshaft/hydrogen.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 #include "src/crankshaft/arm64/lithium-codegen-arm64.h" 5 #include "src/crankshaft/arm64/lithium-codegen-arm64.h"
6 6
7 #include "src/arm64/frames-arm64.h" 7 #include "src/arm64/frames-arm64.h"
8 #include "src/base/bits.h" 8 #include "src/base/bits.h"
9 #include "src/code-factory.h" 9 #include "src/code-factory.h"
10 #include "src/code-stubs.h" 10 #include "src/code-stubs.h"
(...skipping 3310 matching lines...) Expand 10 before | Expand all | Expand 10 after
3321 STATIC_ASSERT(static_cast<unsigned>(kSmiValueSize) == kWRegSizeInBits); 3321 STATIC_ASSERT(static_cast<unsigned>(kSmiValueSize) == kWRegSizeInBits);
3322 STATIC_ASSERT(kSmiTag == 0); 3322 STATIC_ASSERT(kSmiTag == 0);
3323 __ Load(result, UntagSmiFieldMemOperand(source, offset), 3323 __ Load(result, UntagSmiFieldMemOperand(source, offset),
3324 Representation::Integer32()); 3324 Representation::Integer32());
3325 } else { 3325 } else {
3326 __ Load(result, FieldMemOperand(source, offset), access.representation()); 3326 __ Load(result, FieldMemOperand(source, offset), access.representation());
3327 } 3327 }
3328 } 3328 }
3329 3329
3330 3330
3331 void LCodeGen::DoLoadNamedGeneric(LLoadNamedGeneric* instr) {
3332 DCHECK(ToRegister(instr->context()).is(cp));
3333 // LoadIC expects name and receiver in registers.
3334 DCHECK(ToRegister(instr->object()).is(LoadDescriptor::ReceiverRegister()));
3335 __ Mov(LoadDescriptor::NameRegister(), Operand(instr->name()));
3336 EmitVectorLoadICRegisters<LLoadNamedGeneric>(instr);
3337 Handle<Code> ic = CodeFactory::LoadICInOptimizedCode(isolate()).code();
3338 CallCode(ic, RelocInfo::CODE_TARGET, instr);
3339
3340 DCHECK(ToRegister(instr->result()).is(x0));
3341 }
3342
3343
3344 void LCodeGen::DoLoadRoot(LLoadRoot* instr) { 3331 void LCodeGen::DoLoadRoot(LLoadRoot* instr) {
3345 Register result = ToRegister(instr->result()); 3332 Register result = ToRegister(instr->result());
3346 __ LoadRoot(result, instr->index()); 3333 __ LoadRoot(result, instr->index());
3347 } 3334 }
3348 3335
3349 3336
3350 void LCodeGen::DoMathAbs(LMathAbs* instr) { 3337 void LCodeGen::DoMathAbs(LMathAbs* instr) {
3351 Representation r = instr->hydrogen()->value()->representation(); 3338 Representation r = instr->hydrogen()->value()->representation();
3352 if (r.IsDouble()) { 3339 if (r.IsDouble()) {
3353 DoubleRegister input = ToDoubleRegister(instr->value()); 3340 DoubleRegister input = ToDoubleRegister(instr->value());
(...skipping 2293 matching lines...) Expand 10 before | Expand all | Expand 10 after
5647 // Index is equal to negated out of object property index plus 1. 5634 // Index is equal to negated out of object property index plus 1.
5648 __ Sub(result, result, Operand::UntagSmiAndScale(index, kPointerSizeLog2)); 5635 __ Sub(result, result, Operand::UntagSmiAndScale(index, kPointerSizeLog2));
5649 __ Ldr(result, FieldMemOperand(result, 5636 __ Ldr(result, FieldMemOperand(result,
5650 FixedArray::kHeaderSize - kPointerSize)); 5637 FixedArray::kHeaderSize - kPointerSize));
5651 __ Bind(deferred->exit()); 5638 __ Bind(deferred->exit());
5652 __ Bind(&done); 5639 __ Bind(&done);
5653 } 5640 }
5654 5641
5655 } // namespace internal 5642 } // namespace internal
5656 } // namespace v8 5643 } // namespace v8
OLDNEW
« no previous file with comments | « src/crankshaft/arm64/lithium-arm64.cc ('k') | src/crankshaft/hydrogen.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698