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

Unified Diff: runtime/vm/assembler_x64.h

Issue 1343373003: Revert "VM: New calling convention for generated code." (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/assembler_mips_test.cc ('k') | runtime/vm/assembler_x64.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/assembler_x64.h
diff --git a/runtime/vm/assembler_x64.h b/runtime/vm/assembler_x64.h
index 6650fd94a7ac57749f942e9dfc534e4b629684f6..a6d64db0dc3f2c5be230533751d6b06868353567 100644
--- a/runtime/vm/assembler_x64.h
+++ b/runtime/vm/assembler_x64.h
@@ -366,7 +366,7 @@ class Assembler : public ValueObject {
void call(Label* label);
void call(const ExternalLabel* label);
- static const intptr_t kCallExternalLabelSize = 15;
+ static const intptr_t kCallExternalLabelSize = 7;
void pushq(Register reg);
void pushq(const Address& address);
@@ -770,7 +770,7 @@ class Assembler : public ValueObject {
const Function& function,
Register new_pp);
void JmpPatchable(const StubEntry& stub_entry, Register pp);
- void Jmp(const StubEntry& stub_entry, Register pp = PP);
+ void Jmp(const StubEntry& stub_entry, Register pp);
void J(Condition condition, const StubEntry& stub_entry, Register pp);
void CallPatchable(const StubEntry& stub_entry);
void Call(const StubEntry& stub_entry);
@@ -832,8 +832,6 @@ class Assembler : public ValueObject {
void PushRegisters(intptr_t cpu_register_set, intptr_t xmm_register_set);
void PopRegisters(intptr_t cpu_register_set, intptr_t xmm_register_set);
- void CheckCodePointer();
-
void EnterFrame(intptr_t frame_space);
void LeaveFrame();
void ReserveAlignedFrameSpace(intptr_t frame_space);
@@ -924,7 +922,6 @@ class Assembler : public ValueObject {
buffer_.FinalizeInstructions(region);
}
- void RestoreCodePointer();
void LoadPoolPointer(Register pp = PP);
// Set up a Dart frame on entry with a frame pointer and PC information to
@@ -946,13 +943,16 @@ class Assembler : public ValueObject {
// ...
// pushq r15
// .....
- void EnterDartFrame(intptr_t frame_size, Register new_pp);
- void LeaveDartFrame(RestorePP restore_pp = kRestoreCallerPP);
+ void EnterDartFrame(intptr_t frame_size,
+ Register new_pp,
+ Register pc_marker_override);
+ void LeaveDartFrame();
// Set up a Dart frame for a function compiled for on-stack replacement.
// The frame layout is a normal Dart frame, but the frame is partially set
// up on entry (it is the frame of the unoptimized code).
- void EnterOsrFrame(intptr_t extra_size);
+ void EnterOsrFrame(intptr_t extra_size,
+ Register new_pp, Register pc_marker_override);
// Set up a stub frame so that the stack traversal code can easily identify
// a stub frame.
@@ -970,6 +970,19 @@ class Assembler : public ValueObject {
void EnterStubFrame();
void LeaveStubFrame();
+ // Instruction pattern from entrypoint is used in dart frame prologues
+ // to set up the frame and save a PC which can be used to figure out the
+ // RawInstruction object corresponding to the code running in the frame.
+ // entrypoint:
+ // pushq rbp (size is 1 byte)
+ // movq rbp, rsp (size is 3 bytes)
+ // call L (size is 5 bytes)
+ // L:
+ static const intptr_t kEntryPointToPcMarkerOffset = 0;
+ static intptr_t EntryPointToPcMarkerOffset() {
+ return kEntryPointToPcMarkerOffset;
+ }
+
void UpdateAllocationStats(intptr_t cid,
Heap::Space space,
bool inline_isolate = true);
« no previous file with comments | « runtime/vm/assembler_mips_test.cc ('k') | runtime/vm/assembler_x64.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698