|
|
DescriptionDisable g++ inlining of eager-tracing mark() method.
Versions of g++ (with -Os) are over-eager about inlining the mark()
method that's used for all non-mixin Oilpan objects, resulting in
a code size increase that's unwanted (for Android official builds.)
Other compilers and g++ (with -O2/-O3) are more discriminate about
inlining the method, with no comparable code size increase delta.
Tuning the compiler's optimization option set to avoid the problem
hasn't proven successful, so bluntly address the problem by disabling
inlining for the method.
R=haraken
BUG=681991
Review-Url: https://codereview.chromium.org/2643403003
Cr-Commit-Position: refs/heads/master@{#445288}
Committed: https://chromium.googlesource.com/chromium/src/+/9fa52ef0da5a0a6e03a15c4c72d8021567070127
Patch Set 1 #
Messages
Total messages: 17 (9 generated)
The CQ bit was checked by sigbjornf@opera.com 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...
sigbjornf@opera.com changed reviewers: + agrieve@chromium.org, oilpan-reviews@chromium.org
please take a look. I observe a 360k reduction in size for libcontent_shell_content_view.so with this change for a target_os=android official build.
The CQ bit was unchecked by commit-bot@chromium.org
Dry run: This issue passed the CQ dry run.
LGTM. Just to confirm: Is this a specific problem in g++ builds (i.e., not a problem in clang builds)?
On 2017/01/21 13:15:36, haraken wrote: > LGTM. > > Just to confirm: Is this a specific problem in g++ builds (i.e., not a problem > in clang builds)? That's right, arm & g++ specific. Confirmed not to reproduce with clang. For x86, no problem with either toolchain. Given that android uses the problematic toolchain for official builds, I think we should try this, but marking slowdown is the risk.
Description was changed from ========== Disable g++ inlining of eager-tracing mark() method. Versions of g++ (with -Os) are over-eager about inlining the mark() method that's used for all non-mixin Oilpan objects, resulting in a code size increase that's unwanted (for Android official builds.) Other compilers and g++ (with -O2/-O3) are more discriminate about inlining the method, with no comparable code size increase delta. Tuning the compiler's optimization option set to avoid the problem hasn't proven successful, so bluntly address the problem by disabling inlining for the method. R= BUG=681991 ========== to ========== Disable g++ inlining of eager-tracing mark() method. Versions of g++ (with -Os) are over-eager about inlining the mark() method that's used for all non-mixin Oilpan objects, resulting in a code size increase that's unwanted (for Android official builds.) Other compilers and g++ (with -O2/-O3) are more discriminate about inlining the method, with no comparable code size increase delta. Tuning the compiler's optimization option set to avoid the problem hasn't proven successful, so bluntly address the problem by disabling inlining for the method. R=haraken BUG=681991 ==========
The CQ bit was checked by sigbjornf@opera.com
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/v2/patch-status/codereview.chromium.or...
CQ is committing da patch. Bot data: {"patchset_id": 1, "attempt_start_ts": 1485008309612200, "parent_rev": "858ceafc7cf4f11a6549b8c1ace839a45d943d68", "commit_rev": "9fa52ef0da5a0a6e03a15c4c72d8021567070127"}
Message was sent while issue was closed.
Description was changed from ========== Disable g++ inlining of eager-tracing mark() method. Versions of g++ (with -Os) are over-eager about inlining the mark() method that's used for all non-mixin Oilpan objects, resulting in a code size increase that's unwanted (for Android official builds.) Other compilers and g++ (with -O2/-O3) are more discriminate about inlining the method, with no comparable code size increase delta. Tuning the compiler's optimization option set to avoid the problem hasn't proven successful, so bluntly address the problem by disabling inlining for the method. R=haraken BUG=681991 ========== to ========== Disable g++ inlining of eager-tracing mark() method. Versions of g++ (with -Os) are over-eager about inlining the mark() method that's used for all non-mixin Oilpan objects, resulting in a code size increase that's unwanted (for Android official builds.) Other compilers and g++ (with -O2/-O3) are more discriminate about inlining the method, with no comparable code size increase delta. Tuning the compiler's optimization option set to avoid the problem hasn't proven successful, so bluntly address the problem by disabling inlining for the method. R=haraken BUG=681991 Review-Url: https://codereview.chromium.org/2643403003 Cr-Commit-Position: refs/heads/master@{#445288} Committed: https://chromium.googlesource.com/chromium/src/+/9fa52ef0da5a0a6e03a15c4c72d8... ==========
Message was sent while issue was closed.
Committed patchset #1 (id:1) as https://chromium.googlesource.com/chromium/src/+/9fa52ef0da5a0a6e03a15c4c72d8...
Message was sent while issue was closed.
On 2017/01/21 08:48:14, sof wrote: > please take a look. > > I observe a 360k reduction in size for libcontent_shell_content_view.so with > this change for a target_os=android official build. Re: 360k, this was with dcheck_always_on=true.
Message was sent while issue was closed.
On 2017/01/23 13:24:17, sof wrote: > On 2017/01/21 08:48:14, sof wrote: > > please take a look. > > > > I observe a 360k reduction in size for libcontent_shell_content_view.so with > > this change for a target_os=android official build. > > Re: 360k, this was with dcheck_always_on=true. The bots report 140kb saved by this: https://chromeperf.appspot.com/report?sid=cfc29eed1238fd38fb5e6cf83bdba6c619b... Could be the difference is from dcheck_always_on. Still, great work!
Message was sent while issue was closed.
On 2017/01/23 16:00:32, agrieve wrote: > On 2017/01/23 13:24:17, sof wrote: > > On 2017/01/21 08:48:14, sof wrote: > > > please take a look. > > > > > > I observe a 360k reduction in size for libcontent_shell_content_view.so with > > > this change for a target_os=android official build. > > > > Re: 360k, this was with dcheck_always_on=true. > > The bots report 140kb saved by this: > https://chromeperf.appspot.com/report?sid=cfc29eed1238fd38fb5e6cf83bdba6c619b... > > Could be the difference is from dcheck_always_on. Still, great work! Thanks, I suspect it is - there's a pair of DCHECK()s in that method, which were inlined also. That "g++ -Os" still wanted to inline, is even more unusual. |