Skip to content

feat: add UBSAN and ASAN to cassert build - #14

Merged
steve-chavez merged 2 commits into
supabase:masterfrom
AndrewJackson2020:asan_ubsan_build
Nov 3, 2026
Merged

steve-chavez merged 2 commits into
supabase:masterfrom
AndrewJackson2020:asan_ubsan_build

Conversation

@AndrewJackson2020

@AndrewJackson2020 AndrewJackson2020 commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor

This PR adds the UBSAN sanitizer to the cassert build. It also adds and tests an example that will pass the non cassert build testing but will fail during the cassert build testing.

https://clang.llvm.org/docs/UndefinedBehaviorSanitizer.html

@AndrewJackson2020 AndrewJackson2020 changed the title Asan ubsan build Add UBSAN to cassert build Oct 26, 2026
@AndrewJackson2020 AndrewJackson2020 changed the title Add UBSAN to cassert build feat: add UBSAN to cassert build Oct 26, 2026
Comment thread examples/ubsan/README.md Resolved

@steve-chavez steve-chavez left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Overall looks pretty good 👍

Only some errors on CI need to be cleared.

@AndrewJackson2020

AndrewJackson2020 commented Oct 26, 2026 •

Copy link
Copy Markdown
Contributor Author

Overall looks pretty good 👍

Only some errors on CI need to be cleared.

Works on macos/clang, not sure why Linux/gcc is not working.

Edit. Seems like its just do to a different warning/error message. Interestingly gcc raises a runtime error with divide by zero while clang just moves past it.

@AndrewJackson2020
AndrewJackson2020 force-pushed the asan_ubsan_build branch 5 times, most recently from 0aa1c40 to f42c32a Compare October 27, 2026 23:03
@AndrewJackson2020
AndrewJackson2020 force-pushed the asan_ubsan_build branch 4 times, most recently from a530df1 to a4755ed Compare November 2, 2026 22:36
@AndrewJackson2020

AndrewJackson2020 commented Nov 2, 2026 •

Copy link
Copy Markdown
Contributor Author

I think this PR is in somewhat better shape. Took an embarrassingly long time to get it there, lots of issues along the way: long build/CI times (fixed mostly now), some non hermetic system leakages that prevent me from debugging locally that we still need to fix, one of the sanitizers straight up just doesn't work on macOS and causes hello world binaries to freeze at 100% CPU, etc.

That said I think this PR is mostly good at this point.

Comment thread nix/xpg.nix Resolved
Comment thread .github/workflows/ci.yml Resolved
Comment thread examples/hello/test/init.conf Resolved
@AndrewJackson2020 AndrewJackson2020 changed the title feat: add UBSAN to cassert build feat: add UBSAN and ASAN to cassert build Nov 3, 2026
@steve-chavez
steve-chavez merged commit 27aedcb into supabase:master Nov 3, 2026
12 checks passed
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