This is an archive of the discontinued LLVM Phabricator instance.

[AddressSanitizer] Add fallback DebugLocation for instrumented calls
ClosedPublic

Authored by jkl on Jul 15 2023, 10:51 AM.

Details

Summary

When building the kernel with LTO, KASAN & debug information enabled,
multiple inlinable AddressSanitizer functions require debug information
present.

In such cases we repurpose the InstrumentationIRBuilder that ensures
the necessary debug information is added if necessary.

This has been done analogous to the work for the ThreadSanitizer
in D124937. (I added reviewers based on that, feel free to ignore or add more if not relevant).

This has already been discussed a bit here: https://github.com/ClangBuiltLinux/linux/issues/1721

Diff Detail

Event Timeline

jkl created this revision.Jul 15 2023, 10:51 AM
Herald added a project: Restricted Project. · View Herald TranscriptJul 15 2023, 10:51 AM
jkl requested review of this revision.Jul 15 2023, 10:51 AM
Herald added a project: Restricted Project. · View Herald TranscriptJul 15 2023, 10:51 AM
melver accepted this revision.Jul 17 2023, 12:38 AM
This revision is now accepted and ready to land.Jul 17 2023, 12:38 AM
This revision was landed with ongoing or failed builds.Jul 17 2023, 8:52 AM
This revision was automatically updated to reflect the committed changes.