attempt to reconcile usan and benchHash

This commit is contained in:
Yann Collet 2019-11-04 17:25:42 -08:00
parent a642aba0f5
commit d3a76b3a28
2 changed files with 4 additions and 1 deletions

View File

@ -229,11 +229,13 @@ c90test: xxhash.c
$(CC) $(FLAGS) $^ $(LDFLAGS) -c
$(RM) xxhash.o
.PHONY: usan
usan: CC=clang
usan: CXX=clang++
usan: ## check CLI runtime for undefined behavior, using clang's sanitizer
@echo ---- check undefined behavior - sanitize ----
$(MAKE) clean
$(MAKE) test CC=$(CC) MOREFLAGS="-g -fsanitize=undefined -fno-sanitize-recover=all"
$(MAKE) test CC=$(CC) CXX=$(CXX) MOREFLAGS="-g -fsanitize=undefined -fno-sanitize-recover=all"
.PHONY: staticAnalyze
SCANBUILD ?= scan-build

View File

@ -31,6 +31,7 @@ CFLAGS ?= -O3
CFLAGS += -std=c99 -Wall -Wextra -Wstrict-aliasing=1
CFLAGS += $(MOREFLAGS) # custom way to add flags
CXXFLAGS ?= -O3
LDFLAGS += $(MOREFLAGS)
OBJ_LIST = main.o bhDisplay.o benchHash.o benchfn.o timefn.o