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

Issue 2172033002: Reland of Shrink gn's chrome.dll - now smaller than gyp's (Closed)

Created:
4 years, 5 months ago by brucedawson
Modified:
4 years, 5 months ago
Reviewers:
brettw
CC:
chromium-reviews, posciak+watch_chromium.org, jam, feature-media-reviews_chromium.org, darin-cc_chromium.org, blink-reviews, piman+watch_chromium.org
Base URL:
https://chromium.googlesource.com/chromium/src.git@master
Target Ref:
refs/pending/heads/master
Project:
chromium
Visibility:
Public.

Description

Reland of Shrink gn's chrome.dll - now smaller than gyp's (patchset #1 id:1 of https://codereview.chromium.org/2173453004/ ) Reason for revert (reland): Problem is understood, mostly. Needed to slightly update the patch to fix it. Blink split counts were copied from gyp. Original issue's description (with indents removed): More work to shrink gn's chrome.dll The three largest globals that were present in gn's chrome.dll but not in gyp's chrome.dll were eliminated by using /verbose linker output to track the object files that pulled them in and then conditionally changing source_set targets to static_library targets. Specifically: unigram_table, in compact_enc_det.obj - Referenced by TextResourceDecoder.obj from //third_party/WebKit/Source/core:html - some other source_set targets in this file were also modified gpu::ApplyFramebufferAttachmentCMAAINTELResourceManager::cmaa_frag_s1_ and cmaa_frag_s2_, in gles2_cmd_apply_framebuffer_attachment_cmaa_intel.obj from //gpu/command_buffer/service:service_sources - Referenced by gpu_command_buffer_stub.obj from //gpu/ipc/service:ipc_service_sources - Referenced by gpu_video_decode_accelerator.obj from //media/gpu/ipc/service:service - Referenced by gpu_child_thread.obj from //content/gpu:gpu_sources - Referenced by gpu_video_decode_accelerator_factory.obj from //content/public/gpu:gpu_sources As of R406709 this shrinks gn's 32-bit official chrome.dll file size from 38,907,904 bytes to 37,571,584 bytes - an unexpected 1,336,320 byte savings, mostly from the .text section. There is also ~67,000 bytes of memory-only savings in the zero-init part of the .data section. At the same revision gyp's 32-bit official chrome.dll file size is 37,843,456 bytes - 271,872 bytes *larger* than the gn version. There are still globals that are present in gn's chrome.dll but not gyp's chrome.dll, so the optimization technique can still be applied some more, but the priority is much lower now that gn is winning. This is a follow-on to crrev.com/2163823002. TBR=brettw@chromium.org,achuith@chromium.org BUG=624274 CQ_INCLUDE_TRYBOTS=master.tryserver.chromium.linux:linux_optional_gpu_tests_rel;master.tryserver.chromium.mac:mac_optional_gpu_tests_rel;master.tryserver.chromium.win:win_optional_gpu_tests_rel Committed: https://crrev.com/6e53a2e16dc26dec41494b02da83a1221b72e7c4 Cr-Commit-Position: refs/heads/master@{#407372}

Patch Set 1 #

Patch Set 2 : Tweaked split counts to avoid breakage #

Unified diffs Side-by-side diffs Delta from patch set Stats (+56 lines, -10 lines) Patch
M content/gpu/BUILD.gn View 1 1 chunk +6 lines, -1 line 0 comments Download
M content/public/gpu/BUILD.gn View 1 1 chunk +6 lines, -1 line 0 comments Download
M gpu/command_buffer/service/BUILD.gn View 1 1 chunk +6 lines, -1 line 0 comments Download
M gpu/ipc/service/BUILD.gn View 1 1 chunk +6 lines, -1 line 0 comments Download
M media/gpu/ipc/service/BUILD.gn View 1 chunk +6 lines, -1 line 0 comments Download
M third_party/WebKit/Source/core/BUILD.gn View 1 7 chunks +26 lines, -5 lines 0 comments Download

Messages

Total messages: 33 (27 generated)
brucedawson
Created Reland of Shrink gn's chrome.dll - now smaller than gyp's
4 years, 5 months ago (2016-07-22 00:21:59 UTC) #1
brucedawson
PTAL. The '19' number could certainly be changed, but it is harmless, safe, and matches ...
4 years, 5 months ago (2016-07-22 22:43:54 UTC) #25
brettw
lgtm
4 years, 5 months ago (2016-07-23 00:53:40 UTC) #26
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.org/2172033002/170001
4 years, 5 months ago (2016-07-23 19:31:59 UTC) #28
commit-bot: I haz the power
Committed patchset #2 (id:170001)
4 years, 5 months ago (2016-07-23 19:36:02 UTC) #31
commit-bot: I haz the power
4 years, 5 months ago (2016-07-23 19:37:35 UTC) #33
Message was sent while issue was closed.
Patchset 2 (id:??) landed as
https://crrev.com/6e53a2e16dc26dec41494b02da83a1221b72e7c4
Cr-Commit-Position: refs/heads/master@{#407372}

Powered by Google App Engine
This is Rietveld 408576698