Skip to main content

You are not logged in. Your edit will be placed in a queue until it is peer reviewed.

We welcome edits that make the post easier to understand and more valuable for readers. Because community members review edits, please try to make the post substantially better than how you found it, for example, by fixing grammar or adding additional resources and hyperlinks.

4
  • 2
    Wow, I had no idea UBSAN is used for Release versions of software. Are you sure that's a good idea? There's quite a performance impact in enabling this sort of stuff. Like, a lot as far as I know. I understood it was only something to be used in development and for debugging. Commented Nov 27 at 1:24
  • 4
    Apparently it’s fast enough, see the issue requesting it to be enabled. (There isn’t much detail there, but Kees knows what he’s doing.) Fedora kernels have UBSAN enabled too. Commented Nov 27 at 7:22
  • 4
    @Zebrafish: I'd guess it's not the full -fsanitize=undefined (which indeed costs quite a lot of extra machine-code size, e.g. checking for arithmetic overflow on every signed integer op but not unsigned because of C rules), but rather only some subset of the sanitizers, like bounds checks. Commented 2 days ago
  • @PeterCordes Ah, so like Rust then. Commented 2 days ago