Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Test with ASan and UBSan #534

Closed
wants to merge 2 commits into from
Closed

Conversation

nwellnhof
Copy link
Contributor

This adds a CI job that tests with clang, ASan and UBSan. Only the static build is supported for now, meaning that we miss a few tests.

I happened to run into a very recent and probably short-lived issue with Github runners: actions/runner-images#9491. The work-around can probably be removed soon.

We could also consider removing the valgrind test now.

This adds a CI job that tests with clang, ASan and UBSan. Only the
static build is supported for now.
Since we run our tests through Python, this requires

- to link with -shared-libasan
- to LD_PRELOAD the ASan runtime
- to disable LeakSanitizer beacuse of false positives from Python
@nwellnhof
Copy link
Contributor Author

Maybe we should discuss this before merging.

Here's a more invasive change that enables sanitizers on all OSs and compilers: https://github.com/nwellnhof/cmark/blob/asan2/.github/workflows/ci.yml

@jgm
Copy link
Member

jgm commented Mar 18, 2024

So, is the question here whether we want the minimal change or the one that tests with sanitizers on all OSs/compilers? What is the drawback to the latter option?

@nwellnhof
Copy link
Contributor Author

The new proposal now updated with a full os/compiler/build_type/sanitizer matrix: https://github.com/nwellnhof/cmark/blob/asan2/.github/workflows/ci.yml

Test results: https://github.com/nwellnhof/cmark/actions/runs/8321495139

@nwellnhof
Copy link
Contributor Author

I'll post a new PR.

@nwellnhof nwellnhof closed this Mar 18, 2024
@jgm
Copy link
Member

jgm commented Mar 18, 2024

Are there any drawbacks to using this full matrix? I wasn't sure what you had in mind when you suggested discussion.

@nwellnhof
Copy link
Contributor Author

Are there any drawbacks to using this full matrix?

Not really. The full matrix runs a few more jobs than before.

@nwellnhof nwellnhof deleted the asan branch March 25, 2024 16:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants