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

Side by Side Diff: src/ia32/assembler-ia32-inl.h

Issue 146021: X64 implementation: Change argument to relocator to take a 64-bit delta. Cha... (Closed) Base URL: http://v8.googlecode.com/svn/branches/bleeding_edge/
Patch Set: '' Created 11 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
« no previous file with comments | « src/ia32/assembler-ia32.h ('k') | src/x64/assembler-x64.h » ('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) 1994-2006 Sun Microsystems Inc. 1 // Copyright (c) 1994-2006 Sun Microsystems Inc.
2 // All Rights Reserved. 2 // All Rights Reserved.
3 // 3 //
4 // Redistribution and use in source and binary forms, with or without 4 // Redistribution and use in source and binary forms, with or without
5 // modification, are permitted provided that the following conditions are 5 // modification, are permitted provided that the following conditions are
6 // met: 6 // met:
7 // 7 //
8 // - Redistributions of source code must retain the above copyright notice, 8 // - Redistributions of source code must retain the above copyright notice,
9 // this list of conditions and the following disclaimer. 9 // this list of conditions and the following disclaimer.
10 // 10 //
(...skipping 30 matching lines...) Expand all
41 41
42 namespace v8 { 42 namespace v8 {
43 namespace internal { 43 namespace internal {
44 44
45 Condition NegateCondition(Condition cc) { 45 Condition NegateCondition(Condition cc) {
46 return static_cast<Condition>(cc ^ 1); 46 return static_cast<Condition>(cc ^ 1);
47 } 47 }
48 48
49 49
50 // The modes possibly affected by apply must be in kApplyMask. 50 // The modes possibly affected by apply must be in kApplyMask.
51 void RelocInfo::apply(int delta) { 51 void RelocInfo::apply(intptr_t delta) {
52 if (rmode_ == RUNTIME_ENTRY || IsCodeTarget(rmode_)) { 52 if (rmode_ == RUNTIME_ENTRY || IsCodeTarget(rmode_)) {
53 int32_t* p = reinterpret_cast<int32_t*>(pc_); 53 int32_t* p = reinterpret_cast<int32_t*>(pc_);
54 *p -= delta; // relocate entry 54 *p -= delta; // relocate entry
55 } else if (rmode_ == JS_RETURN && IsCallInstruction()) { 55 } else if (rmode_ == JS_RETURN && IsCallInstruction()) {
56 // Special handling of js_return when a break point is set (call 56 // Special handling of js_return when a break point is set (call
57 // instruction has been inserted). 57 // instruction has been inserted).
58 int32_t* p = reinterpret_cast<int32_t*>(pc_ + 1); 58 int32_t* p = reinterpret_cast<int32_t*>(pc_ + 1);
59 *p -= delta; // relocate entry 59 *p -= delta; // relocate entry
60 } else if (IsInternalReference(rmode_)) { 60 } else if (IsInternalReference(rmode_)) {
61 // absolute code pointer inside code object moves with the code object. 61 // absolute code pointer inside code object moves with the code object.
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after
310 310
311 Operand::Operand(int32_t disp, RelocInfo::Mode rmode) { 311 Operand::Operand(int32_t disp, RelocInfo::Mode rmode) {
312 // [disp/r] 312 // [disp/r]
313 set_modrm(0, ebp); 313 set_modrm(0, ebp);
314 set_dispr(disp, rmode); 314 set_dispr(disp, rmode);
315 } 315 }
316 316
317 } } // namespace v8::internal 317 } } // namespace v8::internal
318 318
319 #endif // V8_IA32_ASSEMBLER_IA32_INL_H_ 319 #endif // V8_IA32_ASSEMBLER_IA32_INL_H_
OLDNEW
« no previous file with comments | « src/ia32/assembler-ia32.h ('k') | src/x64/assembler-x64.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698