r-hub / rhub

R-hub API client

Home Page:https://r-hub.github.io/rhub/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Possible ASAN false positve, need for more tuning parameters?

eddelbuettel opened this issue · comments

As a test, I ran the clang-asan container against a package that is clean at CRAN. It didn't get very far on either examples or tests:

SUMMARY: AddressSanitizer: alloc-dealloc-mismatch (/opt/R/devel-asan/lib/R/bin/exec/R+0xc6306) \
      (BuildId: 272af7e16eb36c1b611bd4560b5c047b99d9c469) in free
==4698==HINT: if you don't care about these errors you may set ASAN_OPTIONS=alloc_dealloc_mismatch=0

Googling the message leads to e.g. this GH issue suggesting we want to set the env var. Could a new config argument for env vars be added?

Thanks, yes, definitely need to be able to pass env vars, let's keep this issue open for that.

But for this case specifically it seems like something that we always want to set on libc++ + asan containers.

I have the same issue with a package of mine containing compiled code and testing with clang + ASAN/UBSAN.

Package RcppParallel also causes an ODR false positive (this is even noted in the official memtest README).
ASAN_OPTIONS needs to be extended by detect_odr_violation=0 to fix this particular problem.

setenv ASAN_OPTIONS 'detect_leaks=0'
[RcppParallel is run adding detect_odr_violation=0]