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

Unified Diff: src/x64/macro-assembler-x64.cc

Issue 171107: X64: Implement debugger hooks. (Closed)
Patch Set: Created 11 years, 4 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
Index: src/x64/macro-assembler-x64.cc
diff --git a/src/x64/macro-assembler-x64.cc b/src/x64/macro-assembler-x64.cc
index 2219a5a0ee81821c9431103f7d67b4e6b6ffb62d..fa81c4ef9ca16f8a8261de12a67cbb732321c519 100644
--- a/src/x64/macro-assembler-x64.cc
+++ b/src/x64/macro-assembler-x64.cc
@@ -262,8 +262,7 @@ void MacroAssembler::Abort(const char* msg) {
void MacroAssembler::CallStub(CodeStub* stub) {
ASSERT(allow_stub_calls()); // calls are not allowed in some stubs
- movq(kScratchRegister, stub->GetCode(), RelocInfo::CODE_TARGET);
- call(kScratchRegister);
+ Call(stub->GetCode(), RelocInfo::CODE_TARGET);
}
@@ -495,7 +494,6 @@ void MacroAssembler::Jump(Address destination, RelocInfo::Mode rmode) {
void MacroAssembler::Jump(Handle<Code> code_object, RelocInfo::Mode rmode) {
- WriteRecordedPositions();
William Hesse 2009/08/19 08:44:00 How can it be correct to remove this?
Lasse Reichstein 2009/08/19 10:12:32 It's correct in the sense that it matches what we
ASSERT(RelocInfo::IsCodeTarget(rmode));
movq(kScratchRegister, code_object, rmode);
#ifdef DEBUG
@@ -523,8 +521,8 @@ void MacroAssembler::Call(Address destination, RelocInfo::Mode rmode) {
void MacroAssembler::Call(Handle<Code> code_object, RelocInfo::Mode rmode) {
- WriteRecordedPositions();
ASSERT(RelocInfo::IsCodeTarget(rmode));
+ WriteRecordedPositions();
movq(kScratchRegister, code_object, rmode);
#ifdef DEBUG
// Patch target is kPointer size bytes *before* target label.
@@ -859,12 +857,11 @@ void MacroAssembler::InvokePrologue(const ParameterCount& expected,
movq(rdx, code_register);
}
- movq(kScratchRegister, adaptor, RelocInfo::CODE_TARGET);
if (flag == CALL_FUNCTION) {
- call(kScratchRegister);
+ Call(adaptor, RelocInfo::CODE_TARGET);
jmp(done);
} else {
- jmp(kScratchRegister);
+ Jump(adaptor, RelocInfo::CODE_TARGET);
}
bind(&invoke);
}

Powered by Google App Engine
This is Rietveld 408576698