aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorbfredl <bjorn.linse@gmail.com>2023-01-18 15:42:30 +0100
committerbfredl <bjorn.linse@gmail.com>2023-02-10 22:14:45 +0100
commit87d08095451d8d34030ddc62df093394f247740f (patch)
tree5a127ec3112d57a511c956c5502a5339c6bdc207
parentb8ad1bfe8bc23ed5ffbfe43df5fda3501f1d2802 (diff)
downloadrneovim-87d08095451d8d34030ddc62df093394f247740f.tar.gz
rneovim-87d08095451d8d34030ddc62df093394f247740f.tar.bz2
rneovim-87d08095451d8d34030ddc62df093394f247740f.zip
build(ci): let ASAN print tracebacks for more errors (SIGABORT, SIGILL)
-rwxr-xr-x.github/workflows/env.sh2
-rw-r--r--CONTRIBUTING.md2
-rw-r--r--src/nvim/README.md4
3 files changed, 4 insertions, 4 deletions
diff --git a/.github/workflows/env.sh b/.github/workflows/env.sh
index 7be26e1a72..b4cdb3a8d9 100755
--- a/.github/workflows/env.sh
+++ b/.github/workflows/env.sh
@@ -23,7 +23,7 @@ TSAN_OPTIONS=
case "$FLAVOR" in
asan)
CLANG_SANITIZER=ASAN_UBSAN
- ASAN_OPTIONS="detect_leaks=1:check_initialization_order=1:log_path=$LOG_DIR/asan:intercept_tls_get_addr=0"
+ ASAN_OPTIONS="detect_leaks=1:check_initialization_order=1:handle_abort=1:handle_sigill=1:log_path=$LOG_DIR/asan:intercept_tls_get_addr=0"
UBSAN_OPTIONS="print_stacktrace=1 log_path=$LOG_DIR/ubsan"
;;
tsan)
diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md
index 98c823ea9c..fe2cdb8a36 100644
--- a/CONTRIBUTING.md
+++ b/CONTRIBUTING.md
@@ -187,7 +187,7 @@ master build. To view the defects, just request access; you will be approved.
```
- When running Neovim, use
```
- UBSAN_OPTIONS=print_stacktrace=1 ASAN_OPTIONS=log_path=/tmp/nvim_asan nvim args...
+ UBSAN_OPTIONS=print_stacktrace=1 ASAN_OPTIONS=log_path=/tmp/nvim_asan,handle_abort=1,handle_sigill=1 nvim args...
```
- If Neovim exits unexpectedly, check `/tmp/nvim_asan.{PID}` (or your preferred `log_path`) for log files with error messages.
diff --git a/src/nvim/README.md b/src/nvim/README.md
index 6876227e48..712fda87ba 100644
--- a/src/nvim/README.md
+++ b/src/nvim/README.md
@@ -70,8 +70,8 @@ Create a directory to store logs:
Configure the sanitizer(s) via these environment variables:
- # Change to detect_leaks=1 to detect memory leaks (slower).
- export ASAN_OPTIONS="detect_leaks=0:log_path=$HOME/logs/asan"
+ # Change to detect_leaks=1 to detect memory leaks (slower, noisier).
+ export ASAN_OPTIONS="detect_leaks=0:log_path=$HOME/logs/asan,handle_abort=1,handle_sigill=1"
# Show backtraces in the logs.
export UBSAN_OPTIONS=print_stacktrace=1
export MSAN_OPTIONS="log_path=${HOME}/logs/msan"