freebsd-dev/scripts
Damian Szuberski 63652e1546
Add --enable-asan and --enable-ubsan switches
`configure` now accepts `--enable-asan` and `--enable-ubsan` switches
which results in passing `-fsanitize=address`
and `-fsanitize=undefined`, respectively, to the compiler. Those
flags are enabled in GitHub workflows for ZTS and zloop. Errors
reported by both instrumentations are corrected, except for:

- Memory leak reporting is (temporarily) suppressed. The cost of
  fixing them is relatively high compared to the gains.

- Checksum computing functions in `module/zcommon/zfs_fletcher*`
  have UBSan errors suppressed. It is completely impractical
  to enforce 64-byte payload alignment there due to performance
  impact.

- There's no ASan heap poisoning in `module/zstd/lib/zstd.c`. A custom
  memory allocator is used there rendering that measure
  unfeasible.

- Memory leaks detection has to be suppressed for `cmd/zvol_id`.
  `zvol_id` is run by udev with the help of `ptrace(2)`. Tracing is
  incompatible with memory leaks detection.

Reviewed-by: Ahelenia Ziemiańska <nabijaczleweli@nabijaczleweli.xyz>
Reviewed-by: George Melikov <mail@gmelikov.ru>
Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: szubersk <szuberskidamian@gmail.com>
Closes #12928
2022-02-03 14:35:38 -08:00
..
zfs-images@3331601f6d Add zimport.sh compatibility test script 2014-02-21 12:10:31 -08:00
.gitignore Remove autotools products 2012-08-27 11:47:44 -07:00
commitcheck.sh Add ShellCheck's --enable=all inside scripts/ 2022-01-13 11:09:19 -07:00
common.sh.in zpool_influxdb: move to libexec dir 2020-11-28 11:15:57 -08:00
cstyle.pl cstyle.pl: echo commands for github workflow 2020-08-13 14:58:53 -07:00
dkms.mkconf Remove REMAKE_INITRD 2021-11-30 11:09:15 -08:00
dkms.postbuild Turn shellcheck into a normal make target. Fix new files it caught 2021-06-01 11:38:49 -07:00
enum-extract.pl Fix free memory calculation on v3.14+ 2018-02-23 08:50:06 -08:00
kmodtool Add ShellCheck's --enable=all inside scripts/ 2022-01-13 11:09:19 -07:00
make_gitrev.sh Add ShellCheck's --enable=all inside scripts/ 2022-01-13 11:09:19 -07:00
Makefile.am Add ShellCheck's --enable=all inside scripts/ 2022-01-13 11:09:19 -07:00
man-dates.sh Fix minor shellcheck 0.7.2 warnings 2021-06-09 12:21:24 -07:00
mancheck.sh Pass --enable=all to shellcheck within contrib/ 2021-11-30 10:23:10 -08:00
paxcheck.sh Add ShellCheck's --enable=all inside scripts/ 2022-01-13 11:09:19 -07:00
zfs2zol-patch.sed Add libtpool (thread pools) 2017-08-09 15:31:08 -07:00
zfs-helpers.sh Add ShellCheck's --enable=all inside scripts/ 2022-01-13 11:09:19 -07:00
zfs-tests.sh Add --enable-asan and --enable-ubsan switches 2022-02-03 14:35:38 -08:00
zfs.sh Add ShellCheck's --enable=all inside scripts/ 2022-01-13 11:09:19 -07:00
zimport.sh Add ShellCheck's --enable=all inside scripts/ 2022-01-13 11:09:19 -07:00
zloop.sh Add --enable-asan and --enable-ubsan switches 2022-02-03 14:35:38 -08:00
zol2zfs-patch.sed Move properties, parameters, events, and concepts around manual sections 2021-06-09 14:35:30 -07:00