Commit graph

14143 commits

Author SHA1 Message Date
Andreas Gampe
3149e9b4b7 Merge "Build: Move preopt classpath to private variable"
am: 57048cd455

Change-Id: I4db3b8594e32761b10e9b9f489c48caa6e73a270
2017-10-20 00:24:11 +00:00
Treehugger Robot
57048cd455 Merge "Build: Move preopt classpath to private variable" 2017-10-20 00:01:20 +00:00
Jeff Gaston
32668a2252 Merge "Slightly easier debugging of missing inputs to copy-file-to-target"
am: 1cba05bb39

Change-Id: I57ba43f79d5fc3e9baf73e119bb9881d3ccd0f68
2017-10-19 22:56:30 +00:00
Treehugger Robot
1cba05bb39 Merge "Slightly easier debugging of missing inputs to copy-file-to-target" 2017-10-19 22:52:20 +00:00
Tom Cherry
8b182afa9b Merge "Don't truncate ${USER} when generating ro.build.fingerprint"
am: 8543feae1d

Change-Id: Id5afb5ee4a11034ab8ae03f1d386c7f7c68c5bb0
2017-10-18 23:24:19 +00:00
Tom Cherry
8543feae1d Merge "Don't truncate ${USER} when generating ro.build.fingerprint" 2017-10-18 23:15:38 +00:00
Tom Cherry
a4af66e8cb Don't truncate ${USER} when generating ro.build.fingerprint
We have removed the 92 character limit on ro.build.fingerprint, so
there is no longer a reason to truncate ${USER} when generating
fingerprints.

Bug: 34954705
Test: boot bullhead and observe non-truncated username
Change-Id: If79bf1d5372f709c9c1725f860bc61b99e830751
2017-10-18 14:17:47 -07:00
Mathieu Chartier
d5e2cc0081 Merge "Add product property for preopting extracted APKs"
am: 4856596dc6

Change-Id: I60ab3d2cae7fbdcbd70cc90a8adc46af260b3e9b
2017-10-18 18:09:03 +00:00
TreeHugger Robot
3bb60f4c6e Merge "master is now P" into stage-aosp-master 2017-10-18 02:03:43 +00:00
Mathieu Chartier
55eabd5511 Add product property for preopting extracted APKs
The property is PRODUCT_ALWAYS_PREOPT_EXTRACTED_APK. If specified,
this preopts the APK with the default compile filter (quicken).

This will be used to quicken preopt of gmscore dynamite modules when
preopting is disabled. This fixes a possible RAM regression caused
by running out of the APK.

Bug: 65601274
Test: make and flash

(cherry picked from commit 0fbb836cf6)

Merged-In: Ibf0fa73ee7fafd9735e587baf19c4950a7da817a
Change-Id: Ibf0fa73ee7fafd9735e587baf19c4950a7da817a
2017-10-17 15:57:45 -07:00
Colin Cross
7c381d8015 Merge "Use system modules generated by soong when using javac -target 1.9"
am: 58cd98dc47

Change-Id: I1525b7088afee77baee014fd346cf19cf6a9641e
2017-10-17 18:43:21 +00:00
Colin Cross
58cd98dc47 Merge "Use system modules generated by soong when using javac -target 1.9" 2017-10-17 18:37:35 +00:00
Ian Pedowitz
43a4731d8e master is now P
Fixes: 64141010
Test: source build/envsetup.sh && lunch marlin-userdebug
============================================
PLATFORM_VERSION_CODENAME=P
PLATFORM_VERSION=P
TARGET_PRODUCT=marlin
TARGET_BUILD_VARIANT=userdebug
TARGET_BUILD_TYPE=release
TARGET_PLATFORM_VERSION=PPR1
TARGET_BUILD_APPS=
TARGET_ARCH=arm64
TARGET_ARCH_VARIANT=armv8-a
TARGET_CPU_VARIANT=kryo
TARGET_2ND_ARCH=arm
TARGET_2ND_ARCH_VARIANT=armv7-a-neon
TARGET_2ND_CPU_VARIANT=kryo
HOST_ARCH=x86_64
HOST_2ND_ARCH=x86
HOST_OS=linux
HOST_OS_EXTRA=Linux-4.4.0-79-generic-x86_64-Ubuntu-14.04.5-LTS
HOST_CROSS_OS=windows
HOST_CROSS_ARCH=x86
HOST_CROSS_2ND_ARCH=x86_64
HOST_BUILD_TYPE=release
BUILD_ID=MASTER
OUT_DIR=out
AUX_OS_VARIANT_LIST=
============================================

Change-Id: I2d9019af8c4e24e34c743be85d4e0ff224de9d17
Merged-In: I2d9019af8c4e24e34c743be85d4e0ff224de9d17
Merged-In: Ida774a3bc6fa7884e328eb70abb6b2cca7c32028
(cherry picked from commit b56fcf400f)
2017-10-17 18:00:23 +00:00
Yoshisato Yanagisawa
5de0a22292 Merge "Make SOONG_JAVAC_WRAPPER use JAVAC_WRAPPER to call javac."
am: 51e7a0cca4

Change-Id: I2c311aa5442b26c046173be66ade18a73913673d
2017-10-17 05:15:13 +00:00
Treehugger Robot
51e7a0cca4 Merge "Make SOONG_JAVAC_WRAPPER use JAVAC_WRAPPER to call javac." 2017-10-17 05:08:10 +00:00
Colin Cross
f960257c14 Use system modules generated by soong when using javac -target 1.9
Soong has support for building system modules.  Use the directories
produced by Soong with --system to replace -bootclasspath arguments
when using javac -target 1.9.

Since soong can't generate current SDK stubs yet, and no existing
SDK stubs need -target, only use -target 1.9 for modules that are
not compiling against the SDK.  That means in practice the only
system modules that will be used for now is the default one,
core-system-modules.

Bug: 63986449
Test: m -j EXPERIMENTAL_USE_OPENJDK9=true makes some progress
Change-Id: I350ef50aedf36fdd72458c23d4fe8a2edf1a9a02
2017-10-16 17:55:24 -07:00
Dan Willemsen
9ecc0da241 Merge "Switch to $(file) instead of a rule to create soong.variables"
am: a0d0ea3b5c

Change-Id: Id474095fd94d3aef369cbcfdd810c6a1eb309439
2017-10-15 02:51:59 +00:00
Dan Albert
4adab14288 Merge "Re-apply ndk-docs rule."
am: cf2da22a2a

Change-Id: I48bed194348d6cf2c76bdc9db787c58fcdd6cc6e
2017-10-15 02:50:45 +00:00
Bowgo Tsai
86c4f8ed54 Merge "Adding Android verified boot 1.0 metadata into ENG builds"
am: 5f958ccad5

Change-Id: I54405288a18db3940b0721d5638127e66b7cac3e
2017-10-15 02:48:17 +00:00
Mathieu Chartier
dc640ca34a Merge "Re-add missing log filter"
am: 9e89b22ae7

Change-Id: I1235cf6bf0d947217af7f6da6dc8192e76368860
2017-10-15 02:47:23 +00:00
Dan Willemsen
a0d0ea3b5c Merge "Switch to $(file) instead of a rule to create soong.variables" 2017-10-13 23:22:01 +00:00
Treehugger Robot
cf2da22a2a Merge "Re-apply ndk-docs rule." 2017-10-13 21:04:26 +00:00
Dan Albert
303e603fd2 Re-apply ndk-docs rule.
This time wrapped with a check for the docs directory for unbundled
branches.

Test: make checkbuild
Bug: None
Change-Id: If80f0a03850d6cad3eab6d759af02ff2a7870974
2017-10-13 11:56:17 -07:00
Dan Willemsen
8e7153bf98 Merge "Use CALLED_FROM_SETUP instead of KATI"
am: bd4239a1e1

Change-Id: I2495d57b7038bca63aa148b3a3f02c3ae9d88a87
2017-10-13 07:32:03 +00:00
Dan Willemsen
7ad03056dd Switch to $(file) instead of a rule to create soong.variables
Kati seems to have some problems updating this file, and the echo
syntax gets a bit messy. So define some macros and write out the file at
eval time using $(file).

Test: multiproduct_kati -only-config, check soong.variables (on AOSP and internal)
Change-Id: I74279b962918ca1f70fb1d0d25cbb30bd5675041
2017-10-12 21:10:39 -07:00
Treehugger Robot
5f958ccad5 Merge "Adding Android verified boot 1.0 metadata into ENG builds" 2017-10-13 03:39:21 +00:00
Mathieu Chartier
9e89b22ae7 Merge "Re-add missing log filter" 2017-10-13 02:25:08 +00:00
Treehugger Robot
bd4239a1e1 Merge "Use CALLED_FROM_SETUP instead of KATI" 2017-10-13 01:46:11 +00:00
Nan Zhang
72165e0c29 Merge "Support java compilation sharding for target side."
am: 60e1f8ee27

Change-Id: Ia81f7f7c3f98fee3896714129fe053741e457824
2017-10-13 00:51:11 +00:00
Treehugger Robot
60e1f8ee27 Merge "Support java compilation sharding for target side." 2017-10-13 00:40:37 +00:00
Mathieu Chartier
6c1aa4584a Merge "Allow system server jars for WITH_DEXPREOPT_BOOT_IMG_AND_SYSTEM_SERVER_ONLY"
am: dcb1f24e9b

Change-Id: I4cc653c7d4218d2e4b983f4ec1b6f8df77b2d1f4
2017-10-12 22:37:24 +00:00
Dan Willemsen
20f99a60ea Use CALLED_FROM_SETUP instead of KATI
So that we can use kati instead of make for the initial config loading.

Test: m clean; m nothing
Test: USE_GOMA=true m nothing
Test: m PRODUCT-aosp_x86-sdk
Test: m APP-Calculator
Test: multiproduct_kati -only-config  (on AOSP and internal master)
Change-Id: I5d3af847607fa48868c2045401977eca37dc6ae1
2017-10-12 15:35:42 -07:00
Mathieu Chartier
f834eccd52 Allow system server jars for WITH_DEXPREOPT_BOOT_IMG_AND_SYSTEM_SERVER_ONLY
Renamed WITH_DEXPREOPT_BOOT_IMG_ONLY to
WITH_DEXPREOPT_BOOT_IMG_AND_SYSTEM_SERVER_ONLY and changed the
behavior accordingly.

Preopt system server jars since selinux prevents system server from
loading anything from /data. If we don't do this they will need to
be extracted which is not favorable for RAM usage or performance.

Test: make and flash and look at system server maps
Bug: 65122284
Bug: 62356545

(cherry picked from commit 418258cee9)

Merged-In: I2e70c80a86327b455450b95144f21020e7bf0c6f
Change-Id: I316e79c7c6d45e2ccbfff4065137cc3ef9d2738e
2017-10-12 20:40:41 +00:00
Nan Zhang
ad818dcbea Support java compilation sharding for target side.
Add "LOCAL_JAVAC_SHARD_SIZE" to represent the number of java
source path entries in each shard.

Sharding is not allowed when "LOCAL_JAVAC_SHARD_SIZE" and
"LOCAL_JAR_PROCESSORS" are both enabled.

Limitation:
1. 0 <= LOCAL_JAVAC_SHARD_SIZE <= 8192
1. 0 < NUM(java_sources) <= 8192
2. 0 <= NUM(shards) <= 100

Performance Compare:
<Unsharded Build------------------------------------------------>
1. Build from clean state
rm -r -f out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/
&& time m
out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/classes-full-debug.jar

real	1m2.720s user	5m26.604s sys	0m39.552s

2. Incremental build
m out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/classes-full-debug.jar &&
touch frameworks/base/core/java/android/net/http/HttpResponseCache.java && time m
out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/classes-full-debug.jar

real	0m37.586s user	5m47.804s sys	0m50.388s

<Sharded Build-------------------------------------------------->
1. Build from clean state
rm -r -f out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/
&& time m
out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/classes-full-debug.jar

Javac Shard Size: 50----real	1m10.163s user	25m59.008s sys	1m58.460s
Javac Shard Size: 100---real	1m2.115s user	21m3.600s sys	1m15.964s
Javac Shard Size: 150---real	0m59.520s user	18m10.544s sys	1m12.628s
Javac Shard Size: 200---real	0m56.894s user	15m39.244s sys	1m11.608s
Javac Shard Size: 250---real	0m55.991s user	14m38.716s sys	1m2.292s
Javac Shard Size: 300---real	0m55.114s user	13m6.568s sys	1m8.200s
Javac Shard Size: 350---real	0m53.144s user	12m7.740s sys	1m3.836s
Javac Shard Size: 400---real	0m54.929s user	12m9.324s sys	1m4.340s
Javac Shard Size: 450---real	1m30.194s user	25m31.468s sys	1m52.416s
Javac Shard Size: 500---real	0m53.976s user	10m35.500s sys	0m55.160s

2. Incremental build
m out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/classes-full-debug.jar &&
touch frameworks/base/core/java/android/net/http/HttpResponseCache.java && time m
out/target/common/obj/JAVA_LIBRARIES/framework_intermediates/classes-full-debug.jar

Javac Shard Size: 50-----real	0m16.322s user	1m8.648s sys	0m31.700s
Javac Shard Size: 100----real	0m16.163s user	1m22.932s sys	0m29.440s
Javac Shard Size: 150----real	0m16.611s user	1m37.828s sys	0m21.168s
Javac Shard Size: 200----real	0m16.936s user	1m49.248s sys	0m28.636s
Javac Shard Size: 250----real	0m17.509s user	1m54.944s sys	0m32.768s
Javac Shard Size: 300----real	0m18.868s user	1m54.088s sys	0m28.824s
Javac Shard Size: 350----real	0m17.629s user	1m54.108s sys	0m31.056s
Javac Shard Size: 400----real	0m18.658s user	2m7.712s sys	0m30.636s
Javac Shard Size: 450----real	0m18.874s user	2m8.808s sys	0m33.540s
Javac Shard Size: 500----real	0m19.432s user	2m24.400s sys	0m30.368s

time m nothing:
real 0m5.799s user 0m7.236s sys 0m3.068s

Test: m clean && m -j checkbuild
Bug: b/67424047
Change-Id: Id0766d2b7de7c4546d29bbc7f8a0dd0e4b9ad45b
2017-10-12 13:23:06 -07:00
Yoshisato Yanagisawa
42b808b18e Make SOONG_JAVAC_WRAPPER use JAVAC_WRAPPER to call javac.
JAVAC_WRAPPER seems not be used when SOONG_JAVAC_WRAPPER is used.
Since JAVAC_WRAPPER just wraps actual javac call, the result must
be the same.

Bug: 67723445
Change-Id: I944f9534587c00ffd1bc79806c534432467ba4a5
2017-10-12 16:04:20 +09:00
Bowgo Tsai
6ceeb1a8bf Adding Android verified boot 1.0 metadata into ENG builds
Adding verified boot metadata with a "disable magic". The resulting
metadata at the end of each image (e.g., system.img, vendor.img) will
be the same as triggering an "adb disable-verity" on an USERDEBUG image.

This can help simplify the code on fs_mgr, which won't have to check if
current image is an ENG build or not.

Bug: 63056044
Test: boot sailfish eng/userdebug builds
Change-Id: I95d23ac7b76c04d6d4483c9c4dc1de16bf0d9c3a
2017-10-12 10:08:44 +08:00
Mathieu Chartier
a996337658 Re-add missing log filter
Was accidentally deleted in a61acf62c9

Test: make
Change-Id: Ib25b5c5b54bfbfa1ec80dfc4a0ee5134c8be2631
2017-10-11 17:10:25 -07:00
Courtney Goeltzenleuchter
d0047d922e Move include in prep of Android.bp support
Test: make
Merged-In: I1d1a240b2557db3d9d0a0b2227f84eff09f8d4ca
Change-Id: I1d1a240b2557db3d9d0a0b2227f84eff09f8d4ca
(cherry picked from commit dd35495a77)
2017-10-11 03:29:53 +00:00
Jiyong Park
327a511925 Merge "Prevent vendor libs from depending on private VNDK libraries"
am: 492f67c0ac

Change-Id: If73d1034a1c1c5668f2b3367e8b498e758494bf8
2017-10-11 01:51:24 +00:00
Treehugger Robot
492f67c0ac Merge "Prevent vendor libs from depending on private VNDK libraries" 2017-10-11 01:45:36 +00:00
Colin Cross
a0dd1e08f2 Merge "Add hostdex support for soong"
am: 9f588bcd15

Change-Id: I78acacc81e1d159c1f4107aa936d68adf4ce11f9
2017-10-10 22:03:28 +00:00
Colin Cross
9f588bcd15 Merge "Add hostdex support for soong" 2017-10-10 21:52:17 +00:00
Jiyong Park
a3fb1588f4 Prevent vendor libs from depending on private VNDK libraries
For module installed to /vendor partition, direct linking to the libs
marked as `vendor_available: false` is not allowed. The

Bug: 64730695
Test: Add vendor_available: false to libft2 and
libcompiler_rt. Add the two libs into LOCAL_SHARED_LIBRARIES of a vendor
lib (e.g. libdrm). Build fails with the link_type check error message.

Change-Id: Iaf23574ceddb0c087111e1d95997e9ddd60cdf87
2017-10-10 19:38:06 +09:00
Dan Willemsen
589471eb35 Merge changes Id1d8ffb8,I20a6396d
am: f398cc78fe

Change-Id: I1d646eb40f1a15d6ea5b12af92b36f26526e4fe5
2017-10-10 05:41:57 +00:00
Dan Willemsen
2d081b35d4 Fix broken foreach loop
This wasn't initializing the STATS.MODULE_TYPE.* variables, leading to
106kB of stack usage in ckati for sdk_x86_64-eng. With this fixed, the
next highest stack usage is 35kB.

Bug: 36182021
Test: Run $(flavor) over all the variables
Test: Check stack usage with custom ckati patches
Test: build-sdk_x86_64.ninja is identical before/after this change
Change-Id: Id1d8ffb8415ad6613d0093d31be5472d42d300fd
2017-10-10 03:36:42 +00:00
Dan Willemsen
44fd0f6b8e Reduce stack usage in ckati
When limiting ckati to 768kB of stack, it would crash with a segfault
when processing this recursive expanded variable. So always use := to
turn this into a simple variable.

I measured this using 772kB of stack in ckati on sdk_x86_64-eng. With
this change, the next highest stack user is 106kB.

Bug: 36182021
Test: ulimit -s 768; lunch sdk_x86_64-eng; m nothing
Test: build-sdk_x86_64.ninja is identical before/after this change
Change-Id: I20a6396db173decf178107e3aac6cf089e541e36
2017-10-10 03:36:21 +00:00
Colin Cross
abfa40776f Add hostdex support for soong
When LOCAL_IS_HOST_MODULE is set LOCAL_BUILT_MODULE is the same
as common_javalib.jar, and dexpreopting shouldn't be enabled.

Bug: 67600882
Test: m -j checkbuild
Change-Id: I7397fa430ebc18d5cb6ba71b06e343180f09ae08
2017-10-09 17:37:49 -07:00
Alan Leung
81e4d14cc7 Merge "Revert "Enable D8 by default.""
am: bc29d906bc

Change-Id: Ic839c5b69dca0866049ae4b4f48f41a64fa06697
2017-10-09 21:35:16 +00:00
Alan Leung
ba985e6efe Revert "Enable D8 by default."
Breaks EmulatorSmokeTests

Bug: 67569208

This reverts commit 4c1a09823c.

Change-Id: I85b28b9b59226f4ce6fda0ea2445933eade07d89
2017-10-09 21:24:52 +00:00
Alan Leung
d46624b4d8 Merge "Enable D8 by default."
am: a867dfa71c

Change-Id: I0e68a345fb18cb52033480678eca6979bcb94f5e
2017-10-09 20:18:15 +00:00