OSDN Git Service

Use .KATI_RESTAT to reduce unnecessary rebuilds of binaries
authorShinichiro Hamaji <hamaji@google.com>
Fri, 9 Oct 2015 05:36:04 +0000 (14:36 +0900)
committerShinichiro Hamaji <hamaji@google.com>
Wed, 4 Nov 2015 06:23:59 +0000 (15:23 +0900)
commit0e7587a9ea58b69c9daa43cd682a4657d23b9b23
tree5c1c14adfc39ece149dcf11ed734d41cb8671604
parent5dd68067a6a5e48b29882ca065606ab85b20d3d7
Use .KATI_RESTAT to reduce unnecessary rebuilds of binaries

When a shared object is rebuilt, all dependent libraries and
executables are rebuilt. Such rebuild is unnecessary when there
is no interface change. With this patch, .toc files will be
generated for all .so files. The rule which generates .toc files
has ninja's restat=1 and .toc files are not changed ninja won't
rebuild dependent targets.

Performance:

$ m && touch bionic/libc/stdio/stdio.c && time m
Before: 1m03s (2563 targets)
After: 21s (90 targets)

Bug: 24597504
Change-Id: Ia5dd950273d143f4e99eee8bef7478f1a94cd138
15 files changed:
core/base_rules.mk
core/binary.mk
core/combo/HOST_CROSS_windows-x86.mk
core/combo/HOST_darwin-x86.mk
core/combo/HOST_darwin-x86_64.mk
core/combo/HOST_linux-x86.mk
core/combo/HOST_linux-x86_64.mk
core/combo/TARGET_linux-arm.mk
core/combo/TARGET_linux-arm64.mk
core/combo/TARGET_linux-mips.mk
core/combo/TARGET_linux-mips64.mk
core/combo/TARGET_linux-x86.mk
core/combo/TARGET_linux-x86_64.mk
core/config.mk
core/definitions.mk