mirror of
https://github.com/carbon-language/carbon-lang.git
synced 2026-10-05 22:02:55 +01:00
Remove ASan from the default build mode (#7003)
Also increases the default optimization to `-Og` which is likely to give faster turn-around time which is what we want to optimize for here. This should also _substantially_ shrink binary sizes, etc. ASan is still available via `--config=asan`, and is added to the CI infrastructure. However, my current thought is to only run it after push rather than in PRs and in the merge queue.
This commit is contained in:
@@ -24,6 +24,7 @@ contributions.
|
||||
- [Optional tools](#optional-tools)
|
||||
- [Jujutsu (`jj`)](#jujutsu-jj)
|
||||
- [AI assistants](#ai-assistants)
|
||||
- [Running tests with AddressSanitizer (ASan)](#running-tests-with-addresssanitizer-asan)
|
||||
- [Manually building Clang and LLVM (not recommended)](#manually-building-clang-and-llvm-not-recommended)
|
||||
- [Troubleshooting build issues](#troubleshooting-build-issues)
|
||||
- [`bazel clean`](#bazel-clean)
|
||||
@@ -310,6 +311,20 @@ git show
|
||||
git status
|
||||
```
|
||||
|
||||
### Running tests with AddressSanitizer (ASan)
|
||||
|
||||
By default, the Bazel build mode for the toolchain does not enable
|
||||
AddressSanitizer (ASan). If you wish to enable ASan for local testing, you must
|
||||
pass the `--config=asan` flag explicitly:
|
||||
|
||||
```shell
|
||||
bazelisk test --config=asan //...
|
||||
```
|
||||
|
||||
Note that our Continuous Integration (CI) infrastructure runs a separate
|
||||
configuration for ASan to ensure test coverage without slowing down the default
|
||||
test cycle.
|
||||
|
||||
### Manually building Clang and LLVM (not recommended)
|
||||
|
||||
We primarily test against [apt.llvm.org](https://apt.llvm.org) and Homebrew
|
||||
|
||||
Reference in New Issue
Block a user