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

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

Issue 318773009: ARM64: Clean up support for explicit literal load. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 6 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 | Annotate | Revision Log
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/v8.h" 5 #include "src/v8.h"
6 6
7 #if V8_TARGET_ARCH_ARM64 7 #if V8_TARGET_ARCH_ARM64
8 8
9 #include "src/code-stubs.h" 9 #include "src/code-stubs.h"
10 #include "src/codegen.h" 10 #include "src/codegen.h"
(...skipping 441 matching lines...) Expand 10 before | Expand all | Expand 10 after
452 const Register& current_sp = __ StackPointer(); 452 const Register& current_sp = __ StackPointer();
453 // Nothing ensures 16 bytes alignment here. 453 // Nothing ensures 16 bytes alignment here.
454 ASSERT(!current_sp.Is(csp)); 454 ASSERT(!current_sp.Is(csp));
455 __ mov(current_sp, fp); 455 __ mov(current_sp, fp);
456 int no_frame_start = masm_->pc_offset(); 456 int no_frame_start = masm_->pc_offset();
457 __ ldp(fp, lr, MemOperand(current_sp, 2 * kXRegSize, PostIndex)); 457 __ ldp(fp, lr, MemOperand(current_sp, 2 * kXRegSize, PostIndex));
458 // Drop the arguments and receiver and return. 458 // Drop the arguments and receiver and return.
459 // TODO(all): This implementation is overkill as it supports 2**31+1 459 // TODO(all): This implementation is overkill as it supports 2**31+1
460 // arguments, consider how to improve it without creating a security 460 // arguments, consider how to improve it without creating a security
461 // hole. 461 // hole.
462 __ LoadLiteral(ip0, 3 * kInstructionSize); 462 __ ldr_pcrel(ip0, (3 * kInstructionSize) >> kLoadLiteralScaleLog2);
463 __ add(current_sp, current_sp, ip0); 463 __ add(current_sp, current_sp, ip0);
464 __ ret(); 464 __ ret();
465 __ dc64(kXRegSize * (info_->scope()->num_parameters() + 1)); 465 __ dc64(kXRegSize * (info_->scope()->num_parameters() + 1));
466 info_->AddNoFrameRange(no_frame_start, masm_->pc_offset()); 466 info_->AddNoFrameRange(no_frame_start, masm_->pc_offset());
467 } 467 }
468 } 468 }
469 } 469 }
470 470
471 471
472 void FullCodeGenerator::EffectContext::Plug(Variable* var) const { 472 void FullCodeGenerator::EffectContext::Plug(Variable* var) const {
(...skipping 4420 matching lines...) Expand 10 before | Expand all | Expand 10 after
4893 return previous_; 4893 return previous_;
4894 } 4894 }
4895 4895
4896 4896
4897 #undef __ 4897 #undef __
4898 4898
4899 4899
4900 } } // namespace v8::internal 4900 } } // namespace v8::internal
4901 4901
4902 #endif // V8_TARGET_ARCH_ARM64 4902 #endif // V8_TARGET_ARCH_ARM64
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698