New issue
Advanced search Search tips

Issue 640640 link

Starred by 1 user

Issue metadata

Status: Assigned
Owner:
Cc:
EstimatedDays: ----
NextAction: ----
OS: Android
Pri: 3
Type: Bug



Sign in to add a comment

Remove ForTesting functions from official builds

Project Member Reported by agrieve@chromium.org, Aug 24 2016

Issue description

OS: Android

What steps will reproduce the problem?
(1) Build libchrome.so with is_official_build=true
(2) Dump symbols with nm
(3) Observe there are some that end with ForTesting


We shouldn't be shipping ForTesting code. The code is being kept because of the JNI boundary. Here's the list of them:
https://cs.chromium.org/search/?q=Java_.*Testing+file:cc&sq=package:chromium&type=cs
https://cs.chromium.org/search/?q=file:java+native.*ForTesting&sq=package:chromium&type=cs

Proposed solution:
1. Teach jni generator to guard symbols that end with "ForTesting" behind #ifdef OFFICIAL_BUILD
2. Add a new flag to resource_sizes.py: --assert-no-test-symbols
 
Labels: apk-size
Labels: Performance-Browser
Labels: -apk-size binary-size
Labels: -binary-size Performance-Size

Sign in to add a comment