Turn on proguard optimizations for com.google.android.apps.chrome, org.chromium |
|||||
Issue descriptionWe want to turn on Proguard optimizations for the rule -keepnames class com.google.android.apps.chrome.**, org.chromium.**. This doc outlines some options: https://docs.google.com/a/google.com/document/d/1e5mK5TYeExE0vEnfoyDe5GwYaDw4ZF-vqtIYRmu6cpQ/edit?usp=sharing
,
Jul 5 2016
+torne/boliu who would be interested in implications for webview.
,
Jul 5 2016
Err, I realize this particular change affects chrome but there's still monochrome and we'd want to understand whether to apply something similar for them
,
Jul 6 2016
I don't actually know much detail. torne said he ran into too many things being stripped from webview (since webview has entry points from android different from regular apps I guess?). hush looked at this a bit too
,
Jul 8 2016
As long as this will only affect Chrome and not Monochrome or WebView it's fine to go ahead, but we've had lots of problems doing anything different with proguard in webview in the past, and have a *very* different config to chrome at present as a result (including many things that seem like bugs in proguard). We should probably look into this more at some point :/
,
Jul 8 2016
,
Jul 8 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/1a09539d6fb37c06bc73ce348f6f7ea85ddacfa4 commit 1a09539d6fb37c06bc73ce348f6f7ea85ddacfa4 Author: smaier <smaier@chromium.org> Date: Fri Jul 08 20:14:00 2016 Added deobfuscation script for ProGuarded stacktraces BUG= 625704 Review-Url: https://codereview.chromium.org/2126353002 Cr-Commit-Position: refs/heads/master@{#404476} [add] https://crrev.com/1a09539d6fb37c06bc73ce348f6f7ea85ddacfa4/build/android/stacktrace/java_deobfuscate.py
,
Jul 14 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/05c799ee764fef9d63b4e45c4fba22145f96fed3 commit 05c799ee764fef9d63b4e45c4fba22145f96fed3 Author: smaier <smaier@chromium.org> Date: Thu Jul 14 17:09:36 2016 Creating new gn arg: enable_all_proguard_optimizations. If we wish to turn on optimizations for our main code base, we need to first make sure that these optimizations don't break our instrumentation tests when inlining functions. To do this, we make a gn arg which will guard our instrumentation tests and only allow them to run without this flag. This flag will then be the thing that turns on these Proguard optimizations. BUG= 625704 Review-Url: https://codereview.chromium.org/2123753005 Cr-Commit-Position: refs/heads/master@{#405509} [modify] https://crrev.com/05c799ee764fef9d63b4e45c4fba22145f96fed3/BUILD.gn [modify] https://crrev.com/05c799ee764fef9d63b4e45c4fba22145f96fed3/build/config/android/config.gni [modify] https://crrev.com/05c799ee764fef9d63b4e45c4fba22145f96fed3/build/config/android/rules.gni [modify] https://crrev.com/05c799ee764fef9d63b4e45c4fba22145f96fed3/chrome/android/BUILD.gn [modify] https://crrev.com/05c799ee764fef9d63b4e45c4fba22145f96fed3/chrome/android/chrome_public_apk_tmpl.gni [add] https://crrev.com/05c799ee764fef9d63b4e45c4fba22145f96fed3/testing/android/proguard_for_test.flags
,
Jul 15 2016
The following revision refers to this bug: https://chrome-internal.googlesource.com/clank/internal/apps/+/f99130f1439da4deac6552190244d7f37698a99a commit f99130f1439da4deac6552190244d7f37698a99a Author: Sam Maier <smaier@google.com> Date: Wed Jul 13 14:28:00 2016
,
Jul 18 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/e91be6b053a3e7daea66d63cc1d5a46fac86f4ff commit e91be6b053a3e7daea66d63cc1d5a46fac86f4ff Author: smaier <smaier@chromium.org> Date: Mon Jul 18 21:23:06 2016 Turning on optimizations for chromium code This saves us 357kb of .dex size and 44kb of memory per process. BUG= 625704 Review-Url: https://codereview.chromium.org/2127973003 Cr-Commit-Position: refs/heads/master@{#406099} [modify] https://crrev.com/e91be6b053a3e7daea66d63cc1d5a46fac86f4ff/build/android/gyp/proguard.py [modify] https://crrev.com/e91be6b053a3e7daea66d63cc1d5a46fac86f4ff/build/android/gyp/util/proguard_util.py [modify] https://crrev.com/e91be6b053a3e7daea66d63cc1d5a46fac86f4ff/build/config/android/internal_rules.gni [modify] https://crrev.com/e91be6b053a3e7daea66d63cc1d5a46fac86f4ff/chrome/android/java/proguard.flags
,
Jul 29 2016
The following revision refers to this bug: https://chrome-internal.googlesource.com/clank/internal/apps/+/d12c257ee5f278775fd0d30b9316def6aef09ded commit d12c257ee5f278775fd0d30b9316def6aef09ded Author: Sam Maier <smaier@google.com> Date: Fri Jul 29 13:31:07 2016
,
Aug 5 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/d50624e2e5a9d9fe13596d83e73385c9c44069e9 commit d50624e2e5a9d9fe13596d83e73385c9c44069e9 Author: smaier <smaier@chromium.org> Date: Fri Aug 05 14:21:10 2016 Merging under test java into instrumentation test java. This enables us to run all ProGuard uninhibited by tests, since Proguard will now consider both the tests and the tested code while performing its optimizations. This is opposed to running ProGuard on the tested java, keeping stuff around for the tests, which would then use the tested code as a library. This turns on optimizations and removes test code from the shipped apk, saving us ~550kb in .dex size, and ~70kb memory per process. BUG=620323, 625704 , 626710 Review-Url: https://codereview.chromium.org/2182303002 Cr-Commit-Position: refs/heads/master@{#410056} [modify] https://crrev.com/d50624e2e5a9d9fe13596d83e73385c9c44069e9/BUILD.gn [modify] https://crrev.com/d50624e2e5a9d9fe13596d83e73385c9c44069e9/base/android/base_proguard_config.flags [modify] https://crrev.com/d50624e2e5a9d9fe13596d83e73385c9c44069e9/build/android/gyp/util/proguard_util.py [modify] https://crrev.com/d50624e2e5a9d9fe13596d83e73385c9c44069e9/build/android/gyp/write_build_config.py [modify] https://crrev.com/d50624e2e5a9d9fe13596d83e73385c9c44069e9/build/config/android/config.gni [modify] https://crrev.com/d50624e2e5a9d9fe13596d83e73385c9c44069e9/build/config/android/internal_rules.gni [modify] https://crrev.com/d50624e2e5a9d9fe13596d83e73385c9c44069e9/build/config/android/rules.gni [modify] https://crrev.com/d50624e2e5a9d9fe13596d83e73385c9c44069e9/chrome/android/BUILD.gn [modify] https://crrev.com/d50624e2e5a9d9fe13596d83e73385c9c44069e9/chrome/android/chrome_public_apk_tmpl.gni [modify] https://crrev.com/d50624e2e5a9d9fe13596d83e73385c9c44069e9/chrome/android/webapk/libs/runtime_library/javatests/src/org/chromium/webapk/lib/runtime_library/WebApkServiceImplTest.java [modify] https://crrev.com/d50624e2e5a9d9fe13596d83e73385c9c44069e9/testing/android/proguard_for_test.flags
,
Aug 15 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/a3be7ec966cebaa0e2598d86acc95a51845d726e commit a3be7ec966cebaa0e2598d86acc95a51845d726e Author: smaier <smaier@chromium.org> Date: Mon Aug 15 15:17:49 2016 Preparing for ProGuard obfuscation Allowing obfuscation to be a simple uncomment/comment change for anyone. BUG= 625704 Review-Url: https://codereview.chromium.org/2243613002 Cr-Commit-Position: refs/heads/master@{#411966} [modify] https://crrev.com/a3be7ec966cebaa0e2598d86acc95a51845d726e/chrome/android/java/proguard.flags
,
Aug 18 2016
This bug has been sitting open a while, it has been in master for a while. |
|||||
►
Sign in to add a comment |
|||||
Comment 1 by smaier@chromium.org
, Jul 5 2016