|
|
DescriptionRemove ref_counted.cc
This CL moves all RefCountedThreadSafeBase methods in //base/ref_counted.cc
to the header as inline functions for smaller binary.
RefCountedThreadSafe methods in ref_counted.cc are too small to have
non-inlined function. Inlining them to the caller reduces the stripped
binary size of Chromium on Linux by 84kB, since the binary size the
function body are even smaller than the binary size of the function
call itself.
Committed: https://crrev.com/2c5c70912ccd80e712b18b4bf39f6da3d41e8847
Cr-Commit-Position: refs/heads/master@{#419973}
Patch Set 1 #Patch Set 2 : -BASE_EXPORT #Patch Set 3 : +NON_EXPORTED_BASE #Patch Set 4 : revert _EXPORT part #
Messages
Total messages: 30 (20 generated)
The CQ bit was checked by tzik@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Description was changed from ========== Remove ref_counted.cc BUG= ========== to ========== Remove ref_counted.cc This CL moves all RefCountedThreadSafeBase methods in //base/ref_counted.cc to the header as inline functions for smaller binary. RefCountedThreadSafe methods in ref_counted.cc are too small to have non-inlined function. Inlining them to the caller reduces the stripped binary size of Chromium on Linux by 84kB, since the binary size the function body are even smaller than the binary size of the function call itself. ==========
tzik@chromium.org changed reviewers: + dcheng@chromium.org
PTAL
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: win_chromium_compile_dbg_ng on master.tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_comp...)
LGTM! Btw, do you have a process by which you're finding these? I wonder if we can write a binary analysis tool to help find these more easily...
On 2016/09/16 19:23:37, dcheng wrote: > LGTM! > > Btw, do you have a process by which you're finding these? I wonder if we can > write a binary analysis tool to help find these more easily... That's just a result of a chance. I made a WIP CL to use scoped_refptr in CallbackBase, but that gains the binary size significantly, over 500kB. While dealing with it, I found scoped_refptr takes large part of the size gain. Assuming a function worth considering to inline is smaller than 20 bytes and is called more than 10k times, I found no function other than RefCountedThreadSafe and Callback related ones.
The CQ bit was checked by tzik@chromium.org
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Try jobs failed on following builders: win_chromium_compile_dbg_ng on master.tryserver.chromium.win (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.win/builders/win_chromium_comp...)
The CQ bit was checked by tzik@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: Try jobs failed on following builders: mac_chromium_rel_ng on master.tryserver.chromium.mac (JOB_FAILED, http://build.chromium.org/p/tryserver.chromium.mac/builders/mac_chromium_rel_...)
The CQ bit was checked by tzik@chromium.org to run a CQ dry run
Dry run: CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
The CQ bit was checked by tzik@chromium.org
The patchset sent to the CQ was uploaded after l-g-t-m from dcheng@chromium.org Link to the patchset: https://codereview.chromium.org/2345013003/#ps60001 (title: "revert _EXPORT part")
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
Message was sent while issue was closed.
Description was changed from ========== Remove ref_counted.cc This CL moves all RefCountedThreadSafeBase methods in //base/ref_counted.cc to the header as inline functions for smaller binary. RefCountedThreadSafe methods in ref_counted.cc are too small to have non-inlined function. Inlining them to the caller reduces the stripped binary size of Chromium on Linux by 84kB, since the binary size the function body are even smaller than the binary size of the function call itself. ========== to ========== Remove ref_counted.cc This CL moves all RefCountedThreadSafeBase methods in //base/ref_counted.cc to the header as inline functions for smaller binary. RefCountedThreadSafe methods in ref_counted.cc are too small to have non-inlined function. Inlining them to the caller reduces the stripped binary size of Chromium on Linux by 84kB, since the binary size the function body are even smaller than the binary size of the function call itself. ==========
Message was sent while issue was closed.
Committed patchset #4 (id:60001)
Message was sent while issue was closed.
Description was changed from ========== Remove ref_counted.cc This CL moves all RefCountedThreadSafeBase methods in //base/ref_counted.cc to the header as inline functions for smaller binary. RefCountedThreadSafe methods in ref_counted.cc are too small to have non-inlined function. Inlining them to the caller reduces the stripped binary size of Chromium on Linux by 84kB, since the binary size the function body are even smaller than the binary size of the function call itself. ========== to ========== Remove ref_counted.cc This CL moves all RefCountedThreadSafeBase methods in //base/ref_counted.cc to the header as inline functions for smaller binary. RefCountedThreadSafe methods in ref_counted.cc are too small to have non-inlined function. Inlining them to the caller reduces the stripped binary size of Chromium on Linux by 84kB, since the binary size the function body are even smaller than the binary size of the function call itself. Committed: https://crrev.com/2c5c70912ccd80e712b18b4bf39f6da3d41e8847 Cr-Commit-Position: refs/heads/master@{#419973} ==========
Message was sent while issue was closed.
Patchset 4 (id:??) landed as https://crrev.com/2c5c70912ccd80e712b18b4bf39f6da3d41e8847 Cr-Commit-Position: refs/heads/master@{#419973}
Message was sent while issue was closed.
On 2016/09/21 04:45:46, commit-bot: I haz the power wrote: > Patchset 4 (id:??) landed as > https://crrev.com/2c5c70912ccd80e712b18b4bf39f6da3d41e8847 > Cr-Commit-Position: refs/heads/master@{#419973} FYI - this commit *grew* libchrome.so on Android by ~50kb. https://chromeperf.appspot.com/report?sid=f8be4459943df7093c2c0cdfa83b9350c74... I'd guess if there was no other motivation than code size, we should revert it.
Message was sent while issue was closed.
A revert of this CL (patchset #4 id:60001) has been created in https://codereview.chromium.org/2366323003/ by agrieve@chromium.org. The reason for reverting is: Increased Android .so by 50kb rather than shrinking it.. |