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

Issue 7920004: Start refactoring to reduce executable type knowledge. (Closed)

Created:
9 years, 3 months ago by dgarrett
Modified:
9 years, 2 months ago
CC:
chromium-reviews
Visibility:
Public.

Description

Start refactoring to reduce executable type knowledge. This creates executable detection functions, a globally shared enum for describing an executable type, and reduces the number of classes and locations with executable specific knowledge. These changes, along with moving architecture specific classes into their own files should make it easier to produce special purpose clients that only contain the code required to apply their own form of patch. DisassemblerWin32EXE, ImagePE, CourgetteWin32X86PatchGenerator, and CourgetteWin32X86Patcher, and ensemble handling are all heavily affected here. This should have no effect on the behavior of the system yet, and is instead all prep-work. BUG=None TEST=Unittests Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=103879

Patch Set 1 #

Total comments: 4

Patch Set 2 : A little more cleanup. #

Patch Set 3 : Rebase to top of tree. #

Patch Set 4 : Fix windows compile warning. #

Unified diffs Side-by-side diffs Delta from patch set Stats (+202 lines, -586 lines) Patch
M courgette/courgette.h View 1 2 chunks +15 lines, -2 lines 0 comments Download
M courgette/courgette.gyp View 1 1 chunk +2 lines, -0 lines 0 comments Download
M courgette/courgette_tool.cc View 3 chunks +14 lines, -13 lines 0 comments Download
M courgette/disassembler.h View 2 chunks +2 lines, -9 lines 0 comments Download
M courgette/disassembler.cc View 3 chunks +16 lines, -392 lines 0 comments Download
A courgette/disassembler_win32_x86.h View 1 chunk +56 lines, -0 lines 0 comments Download
A + courgette/disassembler_win32_x86.cc View 3 chunks +5 lines, -79 lines 0 comments Download
M courgette/encode_decode_unittest.cc View 1 chunk +2 lines, -1 line 0 comments Download
M courgette/encoded_program_fuzz_unittest.cc View 1 chunk +2 lines, -1 line 0 comments Download
M courgette/ensemble.h View 3 chunks +12 lines, -10 lines 0 comments Download
M courgette/ensemble.cc View 2 chunks +42 lines, -55 lines 0 comments Download
M courgette/ensemble_apply.cc View 1 1 chunk +11 lines, -5 lines 0 comments Download
M courgette/ensemble_create.cc View 1 2 3 1 chunk +14 lines, -10 lines 0 comments Download
M courgette/win32_x86_generator.h View 2 chunks +6 lines, -6 lines 0 comments Download
M courgette/win32_x86_patcher.h View 1 chunk +3 lines, -3 lines 0 comments Download

Messages

Total messages: 12 (0 generated)
dgarrett
This CL isn't yet ready, but it'll be big enough that I wanted to show ...
9 years, 3 months ago (2011-09-16 02:49:04 UTC) #1
Paweł Hajdan Jr.
Drive-by with a testing nit. No need to wait for me. http://codereview.chromium.org/7920004/diff/1/courgette/versioning_unittest.cc File courgette/versioning_unittest.cc (right): ...
9 years, 3 months ago (2011-09-16 18:34:34 UTC) #2
dgarrett
http://codereview.chromium.org/7920004/diff/1/courgette/versioning_unittest.cc File courgette/versioning_unittest.cc (right): http://codereview.chromium.org/7920004/diff/1/courgette/versioning_unittest.cc#newcode43 courgette/versioning_unittest.cc:43: EXPECT_TRUE(!"Could not read test data"); On 2011/09/16 18:34:34, Paweł ...
9 years, 3 months ago (2011-09-22 02:20:46 UTC) #3
sra1
LGTM http://codereview.chromium.org/7920004/diff/1/courgette/versioning_unittest.cc File courgette/versioning_unittest.cc (right): http://codereview.chromium.org/7920004/diff/1/courgette/versioning_unittest.cc#newcode43 courgette/versioning_unittest.cc:43: EXPECT_TRUE(!"Could not read test data"); On 2011/09/16 18:34:34, ...
9 years, 3 months ago (2011-09-22 02:58:17 UTC) #4
Paweł Hajdan Jr.
http://codereview.chromium.org/7920004/diff/1/courgette/versioning_unittest.cc File courgette/versioning_unittest.cc (right): http://codereview.chromium.org/7920004/diff/1/courgette/versioning_unittest.cc#newcode43 courgette/versioning_unittest.cc:43: EXPECT_TRUE(!"Could not read test data"); On 2011/09/22 02:58:17, sra1 ...
9 years, 2 months ago (2011-09-26 17:08:21 UTC) #5
dgarrett
9 years, 2 months ago (2011-09-29 18:29:05 UTC) #6
dgarrett
Okay, I think this is ready to go in now. I've removed the backwards compatibility ...
9 years, 2 months ago (2011-09-29 21:02:39 UTC) #7
commit-bot: I haz the power
CQ is trying the patch. Follow status at https://chromium-status.appspot.com/cq/dgarrett@chromium.org/7920004/10001
9 years, 2 months ago (2011-10-03 18:51:56 UTC) #8
commit-bot: I haz the power
Try job failure for 7920004-10001 (retry) on win_rel for step "compile" (clobber build). It's a ...
9 years, 2 months ago (2011-10-03 19:09:50 UTC) #9
commit-bot: I haz the power
CQ is trying the patch. Follow status at https://chromium-status.appspot.com/cq/dgarrett@chromium.org/7920004/10003
9 years, 2 months ago (2011-10-03 21:15:28 UTC) #10
dgarrett
LGTM - The only change was a tweak to fix a windows compiler warning.
9 years, 2 months ago (2011-10-03 23:38:00 UTC) #11
commit-bot: I haz the power
9 years, 2 months ago (2011-10-04 13:43:27 UTC) #12
Change committed as 103879

Powered by Google App Engine
This is Rietveld 408576698