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

Side by Side Diff: runtime/vm/assembler_x64.cc

Issue 1433243003: Background compilation work: (Closed) Base URL: https://github.com/dart-lang/sdk.git@master
Patch Set: d Created 5 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 | « runtime/vm/assembler_mips.cc ('k') | runtime/vm/code_generator.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 (c) 2013, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #include "vm/globals.h" // NOLINT 5 #include "vm/globals.h" // NOLINT
6 #if defined(TARGET_ARCH_X64) 6 #if defined(TARGET_ARCH_X64)
7 7
8 #include "vm/assembler.h" 8 #include "vm/assembler.h"
9 #include "vm/cpu.h" 9 #include "vm/cpu.h"
10 #include "vm/heap.h" 10 #include "vm/heap.h"
(...skipping 3313 matching lines...) Expand 10 before | Expand all | Expand 10 after
3324 offset += kFpuRegisterSize; 3324 offset += kFpuRegisterSize;
3325 } 3325 }
3326 } 3326 }
3327 ASSERT(offset == (xmm_regs_count * kFpuRegisterSize)); 3327 ASSERT(offset == (xmm_regs_count * kFpuRegisterSize));
3328 AddImmediate(RSP, Immediate(offset)); 3328 AddImmediate(RSP, Immediate(offset));
3329 } 3329 }
3330 } 3330 }
3331 3331
3332 3332
3333 void Assembler::EnterCallRuntimeFrame(intptr_t frame_space) { 3333 void Assembler::EnterCallRuntimeFrame(intptr_t frame_space) {
3334 Comment("EnterCallRuntimeFrame");
3334 EnterStubFrame(); 3335 EnterStubFrame();
3335 3336
3336 // TODO(vegorov): avoid saving FpuTMP, it is used only as scratch. 3337 // TODO(vegorov): avoid saving FpuTMP, it is used only as scratch.
3337 PushRegisters(CallingConventions::kVolatileCpuRegisters, 3338 PushRegisters(CallingConventions::kVolatileCpuRegisters,
3338 CallingConventions::kVolatileXmmRegisters); 3339 CallingConventions::kVolatileXmmRegisters);
3339 3340
3340 ReserveAlignedFrameSpace(frame_space); 3341 ReserveAlignedFrameSpace(frame_space);
3341 } 3342 }
3342 3343
3343 3344
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
3413 if (restore_pp == kRestoreCallerPP) { 3414 if (restore_pp == kRestoreCallerPP) {
3414 movq(PP, Address(RBP, (kSavedCallerPpSlotFromFp * kWordSize))); 3415 movq(PP, Address(RBP, (kSavedCallerPpSlotFromFp * kWordSize)));
3415 set_constant_pool_allowed(false); 3416 set_constant_pool_allowed(false);
3416 } 3417 }
3417 LeaveFrame(); 3418 LeaveFrame();
3418 } 3419 }
3419 3420
3420 3421
3421 void Assembler::CheckCodePointer() { 3422 void Assembler::CheckCodePointer() {
3422 #ifdef DEBUG 3423 #ifdef DEBUG
3424 Comment("CheckCodePointer");
3423 Label cid_ok, instructions_ok; 3425 Label cid_ok, instructions_ok;
3424 pushq(RAX); 3426 pushq(RAX);
3425 LoadClassId(RAX, CODE_REG); 3427 LoadClassId(RAX, CODE_REG);
3426 cmpq(RAX, Immediate(kCodeCid)); 3428 cmpq(RAX, Immediate(kCodeCid));
3427 j(EQUAL, &cid_ok); 3429 j(EQUAL, &cid_ok);
3428 int3(); 3430 int3();
3429 Bind(&cid_ok); 3431 Bind(&cid_ok);
3430 { 3432 {
3431 const intptr_t kRIPRelativeLeaqSize = 7; 3433 const intptr_t kRIPRelativeLeaqSize = 7;
3432 const intptr_t header_to_entry_offset = 3434 const intptr_t header_to_entry_offset =
(...skipping 535 matching lines...) Expand 10 before | Expand all | Expand 10 after
3968 3970
3969 3971
3970 const char* Assembler::FpuRegisterName(FpuRegister reg) { 3972 const char* Assembler::FpuRegisterName(FpuRegister reg) {
3971 ASSERT((0 <= reg) && (reg < kNumberOfXmmRegisters)); 3973 ASSERT((0 <= reg) && (reg < kNumberOfXmmRegisters));
3972 return xmm_reg_names[reg]; 3974 return xmm_reg_names[reg];
3973 } 3975 }
3974 3976
3975 } // namespace dart 3977 } // namespace dart
3976 3978
3977 #endif // defined TARGET_ARCH_X64 3979 #endif // defined TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « runtime/vm/assembler_mips.cc ('k') | runtime/vm/code_generator.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698