Disable sanitizer in gn instead of passing around an ignorelist

The array-bounds sanitizer should not be applied in
third_party/wuffs as it causes a performance degradation that shows
up in some benchmarks otherwise.

This was achieved by adding third_party/wuffs to a global ignorelist
that is passed around to clang everywhere, not only in wuffs where
needed.

The ignorelist breaks distributed builds using icecc, so the ignorelist
was disabled for icecc builds. So without the ignorelist icecc will work
again, but at the cost of the performance degradation coming back.

We can disable the sanitizer in wuffs by just removing the sanitizer
config in third_party/wuffs/BUILD.gn, which removes the need for a
global ignorelist.

This commit disables the sanitizer by removing the config in wuffs and
it removes the no longer needed ignorelist. We then avoid passing around
a global ignorelist everywhere and icecc will work again.

Bug: 457303640, 454399366
Change-Id: Ie2c42df2ee87c0a980bc8be8b85abc0b5cba6d00
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7172338
Reviewed-by: Gyuyoung Kim <[email protected]>
Commit-Queue: Olle Liljenzin <[email protected]>
Reviewed-by: Nico Weber <[email protected]>
Cr-Commit-Position: refs/heads/main@{#1547966}
NOKEYCHECK=True
GitOrigin-RevId: 0ae8f7148dadd42b98f2a71da000711ec41e8e5b
1 file changed
tree: b387ae1ca763d862057cf5d5ebf08d0cc3299254
  1. angle.gni
  2. build.gni
  3. dawn.gni
  4. glslang.gni
  5. gtest.gni
  6. ipcz.gni
  7. OWNERS
  8. partition_alloc.gni
  9. pdfium.gni
  10. protobuf.gni
  11. README.md
  12. spirv_tools.gni
  13. swiftshader.gni
  14. tint.gni
  15. vulkan_common.gni
  16. vulkan_headers.gni
  17. vulkan_loader.gni
  18. vulkan_tools.gni
  19. vulkan_utility_libraries.gni
  20. vulkan_validation_layers.gni
  21. wayland.gni
README.md

Build overrides in GN

This directory is used to allow different products to customize settings for repos that are DEPS'ed in or shared.

For example: V8 could be built on its own (in a “standalone” configuration), and it could be built as part of Chromium. V8 might define a top-level target, //v8:d8 (a simple executable), that should only be built in the standalone configuration. To figure out whether or not it should be in a standalone configuration, v8 can create a file, build_overrides/v8.gni, that contains a variable, build_standalone_d8 = true. and import it (as import(“//build_overrides/v8.gni”) from its top-level BUILD.gn file.

Chromium, on the other hand, might not need to build d8, and so it would create its own build_overrides/v8.gni file, and in it set build_standalone_d8 = false.

The two files should define the same set of variables, but the values can vary as appropriate to the needs of the two different builds.

The build.gni file provides a way for projects to override defaults for variables used in //build itself (which we want to be shareable between projects).

TODO(crbug.com/41240413): Ideally //build_overrides and, in particular, //build_overrides/build.gni should go away completely in favor of some mechanism that can re-use other required files like //.gn, so that we don't have to keep requiring projects to create a bunch of different files to use GN.