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

Unified Diff: courgette/rel32_finder_win32_x86.cc

Issue 1935203002: [Courgette] Using LabelManager to reduce Courgette-apply peak RAM by 25%. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Sync. Created 4 years, 7 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 | « courgette/program_detector.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: courgette/rel32_finder_win32_x86.cc
diff --git a/courgette/rel32_finder_win32_x86.cc b/courgette/rel32_finder_win32_x86.cc
index 0ed492f2e5f4844909ae357477ca9ca164f465a7..61ff9696d5ac19174d514c8930111e64c326342e 100644
--- a/courgette/rel32_finder_win32_x86.cc
+++ b/courgette/rel32_finder_win32_x86.cc
@@ -87,12 +87,13 @@ void Rel32FinderWin32X86_Basic::Find(const uint8_t* start_pointer,
if (abs32_pos != abs32_locations.end()) {
if (*abs32_pos < rel32_rva + 4) {
// Beginning of abs32 reloc is before end of rel32 reloc so they
- // overlap. Skip four bytes past the abs32 reloc.
+ // overlap. Skip four bytes past the abs32 reloc.
p += (*abs32_pos + 4) - current_rva;
continue;
}
}
+ // + 4 since offset is relative to start of next instruction.
RVA target_rva = rel32_rva + 4 + Read32LittleEndian(rel32);
// Valid, rel32 target must be within image, and within this section.
// Subsumes |target_rva| != |kUnassignedRVA|.
« no previous file with comments | « courgette/program_detector.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698