Skip to content

UBSan diagnostics should say the name of the sanitizer #117729

Open
@davidben

Description

When enabling UBSan, you get errors that look like:

...: runtime error: reference binding to address ... with insufficient space for an object of type '...'

But this doesn't say which sanitizer option triggered that message. You have to grep for the error message in LLVM source, which can be difficult with line breaks and different chunks being assembled from different places. Reasons you might want to know the precise name of the sanitizer:

  • Temporarily adding a fine-grained suppression without suppressing every sanitizer
  • Look up more information about this particularly check (e.g. how does it know the size? is it compile-time information or runtime information?)

When Clang emits a warning, it says the name of the warning flag. It would be nice for sanitizer warnings to do the same.

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions