Граф коммитов

7 Коммитов

Автор SHA1 Сообщение Дата
Max Moroz 6254389a64 [Code Coverage] Add support for component build + update documentation.
Bug: 831939
Change-Id: I2804796894045dc69aa8309aa3ab34e6c80b38d7
Reviewed-on: https://chromium-review.googlesource.com/1010464
Commit-Queue: Max Moroz <mmoroz@chromium.org>
Reviewed-by: Yuke Liao <liaoyuke@chromium.org>
Reviewed-by: Abhishek Arya <inferno@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#553211}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: d73e45fdf4ab585227bdda1f3fd7e3105ae798ee
2018-04-24 18:32:47 +00:00
Yuke Liao b73ec3eda4 [Coverage] Fix documentation and build error message
Fix documentation and build error message regarding
is_component_build flag.

Change-Id: I393ce3b376e30f4fbbabfea332b77728b5344d5a
Reviewed-on: https://chromium-review.googlesource.com/917223
Reviewed-by: Jonathan Metzman <metzman@chromium.org>
Reviewed-by: Abhishek Arya <inferno@chromium.org>
Commit-Queue: Abhishek Arya <inferno@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#537953}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: ab9c44ebfebc2a832ad119a23a466fa7b82040bf
2018-02-21 00:24:40 +00:00
Jonathan Metzman 043c473dbe Add assertion preventing is_component_build=true from being used with use_clang_coverage.
Bug: 773530
Change-Id: Ib0997ffdead67437f61e279791a7a8887cbe807f
Reviewed-on: https://chromium-review.googlesource.com/714279
Commit-Queue: Jonathan Metzman <metzman@chromium.org>
Reviewed-by: Max Moroz <mmoroz@chromium.org>
Reviewed-by: Dirk Pranke <dpranke@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#509058}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 301ce027adbc5555dec9ac7e449af1732ce3a5f9
2017-10-16 15:43:28 +00:00
Jonathan Metzman b23a360275 Add warnings not to use "is_component_build=true" when using
use_clang_coverage.


Bug: 773530
Change-Id: I7d9002279230b6aa6efaf9cf5ed09117ae4e6ff0
Reviewed-on: https://chromium-review.googlesource.com/711217
Reviewed-by: Max Moroz <mmoroz@chromium.org>
Commit-Queue: Max Moroz <mmoroz@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#507983}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: cc786b3eb32eb1e4c9b844fce74d3e6f5ee1b4b9
2017-10-11 15:07:45 +00:00
Abhishek Arya 58ec82342f Add back clang requirement assert for use_clang_coverage flag.
R=brettw@chromium.org,mmoroz@chromium.org

Bug: 771718, 759794
Change-Id: I77d5f83587777d8ed4b23cf00d8f55ae48015ce0
Reviewed-on: https://chromium-review.googlesource.com/701619
Reviewed-by: Max Moroz <mmoroz@chromium.org>
Reviewed-by: Brett Wilson <brettw@chromium.org>
Commit-Queue: Abhishek Arya <inferno@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#507165}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 433d48700283e612dcafe76ec8b05c837a48a920
2017-10-06 20:35:04 +00:00
Max Moroz 1cf5783309 Remove an assert due to corrupted "is_clang" variable + add a missing import.
TBR=brettw@chromium.org,inferno@chromium.org

Bug: 771718, 759794
Change-Id: I1fc3ab8b054ce6eeee24d0c1c0599be216b2e386
Reviewed-on: https://chromium-review.googlesource.com/700974
Reviewed-by: Max Moroz <mmoroz@chromium.org>
Commit-Queue: Max Moroz <mmoroz@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#506502}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: 74106e986dfbde1caf33410d77cbe1096926db94
2017-10-04 20:36:28 +00:00
Max Moroz e3dda1e762 Optimize clang source-based code coverage build configuration.
I've been testing the changes on net_parse_cookie_line_fuzzer,
which is a fuzz target of average size written in C++.

Improvements step by step:

0) Original configuration, Coverage + ASan:
158 MB  1,000 exec/s

1) Prohibit ASan (and other sanitizers), use only Coverage instrumentation:
132 MB  same speed

The following change hasn't been applied, but let's keep it in the description FTR:
- 2) Disable sanitizer coverage (which is different from clang source-based coverage):
- 90 MB   1,088 exec/s (speed +8-10%)

3) Avoid optimize_for_fuzzing config (i.e. use -O3 instead of -O1 for coverage build):
Same size  1,773 exec/s (speed +60-65% on top of the previous change)

4) Disable coverage for libFuzzer source code:
88 MB  3,988 exec/s (speed +125% on top of previous changes)

5) Disable coverage for libc++ and libc++abi sources
(https://chromium-review.googlesource.com/#/c/chromium/buildtools/+/693570):
86 MB  4,110 exec/s (speed +3% on top of previous changes)

In total, for that particular target:
- build size reduced by ~45%
- execution speed increased by ~310%

I've also tested the changes with zlib_uncompress_fuzzer (a tiny fuzz target for C-library):
- build size reduced by ~83%
- execution speed increased by ~120%

I haven't measured impact on the other fuzz targets, so it may vary a lot,
but the result seems to be quite significant anyway.


Bug: 759794
Change-Id: Icf61c979e38d0f7849ab7281bd9e24cf2b7a7d02
Reviewed-on: https://chromium-review.googlesource.com/693564
Reviewed-by: Brett Wilson <brettw@chromium.org>
Reviewed-by: Oliver Chang <ochang@chromium.org>
Commit-Queue: Abhishek Arya <inferno@chromium.org>
Cr-Original-Commit-Position: refs/heads/master@{#506454}
Cr-Mirrored-From: https://chromium.googlesource.com/chromium/src
Cr-Mirrored-Commit: c8fee977deb6f47aaf602813b00428adfe7baa74
2017-10-04 18:31:46 +00:00