Skip to content

Conversation

@akifcorduk
Copy link
Contributor

This PR adds sanitizer build option.
To use sanitizer with cuda runtime, one must follow a few steps:

  1. Find libasan.so with "gcc -print-file-name=libasan.so"
  2. Run the binary with env var set: LD_PRELOAD=$PATH_TO_LIBASAN ASAN_OPTIONS='protect_shadow_gap=0:replace_intrin=0'
  3. (Optional) To run with a debugger (gdb or cuda-gdb) use the additional ASAN option alloc_dealloc_mismatch=0

@akifcorduk akifcorduk added this to the 25.10 milestone Sep 10, 2025
@akifcorduk akifcorduk requested review from a team as code owners September 10, 2025 12:51
@akifcorduk akifcorduk added improvement Improves an existing functionality non-breaking Introduces a non-breaking change labels Sep 10, 2025
Copy link
Contributor

@tmckayus tmckayus left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, defer on the option naming discussion

@akifcorduk
Copy link
Contributor Author

/merge

@rapids-bot rapids-bot bot merged commit 6e2e622 into NVIDIA:branch-25.10 Sep 17, 2025
102 checks passed
copy-pr-bot bot pushed a commit that referenced this pull request Sep 22, 2025
This PR adds sanitizer build option.
To use sanitizer with cuda runtime, one must follow a few steps:
1. Find libasan.so with "gcc -print-file-name=libasan.so"
2. Run the binary with env var set: LD_PRELOAD=$PATH_TO_LIBASAN ASAN_OPTIONS='protect_shadow_gap=0:replace_intrin=0'
3. (Optional) To run with a debugger (gdb or cuda-gdb) use the additional ASAN option alloc_dealloc_mismatch=0

Authors:
  - Akif ÇÖRDÜK (https://github.com/akifcorduk)

Approvers:
  - Hugo Linsenmaier (https://github.com/hlinsen)
  - Trevor McKay (https://github.com/tmckayus)

URL: #385
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

improvement Improves an existing functionality non-breaking Introduces a non-breaking change

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants