This is an archive of the discontinued LLVM Phabricator instance.

[docs] Improve UndefinedBehaviorSanitizer.rst
ClosedPublic

Authored by MaskRay on Jun 11 2023, 9:46 AM.

Details

Reviewers
vitalybuka
Group Reviewers
Restricted Project
Commits
rGee0367ef13f8: [docs] Improve UndefinedBehaviorSanitizer.rst
Summary
  • Mention that -fsanitize= and -fno-sanitize= apply to check groups.
  • Mention "all" can be used as a check group.
  • Mention that -fsanitize-trap= and -fsanitize-recover= lead to no unused command line option warning.
  • Mention that trap mode typically causes the program to terminate due to a SIGILL or SIGTRAP signal.

Diff Detail

Event Timeline

MaskRay created this revision.Jun 11 2023, 9:46 AM
Herald added a project: Restricted Project. · View Herald TranscriptJun 11 2023, 9:46 AM
MaskRay requested review of this revision.Jun 11 2023, 9:46 AM
Herald added a project: Restricted Project. · View Herald TranscriptJun 11 2023, 9:46 AM
Herald added a subscriber: cfe-commits. · View Herald Transcript
vitalybuka accepted this revision.Jun 12 2023, 12:53 PM
vitalybuka added inline comments.
clang/docs/UndefinedBehaviorSanitizer.rst
62

I guess this is the good example of alignment

This revision is now accepted and ready to land.Jun 12 2023, 12:53 PM
MaskRay added inline comments.Jun 12 2023, 12:55 PM
clang/docs/UndefinedBehaviorSanitizer.rst
62

Thanks. This is a deliberate example to show that one can specify multiple -fsanitize= -fno-sanitize= and the driver will do some computation. I'll elaborate the comment.

MaskRay updated this revision to Diff 530645.Jun 12 2023, 1:02 PM
MaskRay marked an inline comment as done.
MaskRay edited the summary of this revision. (Show Details)

better -fsanitize=... -fno-sanitize example
Add "If the signal is not caught, the program will typically terminate due to a `SIGILL or SIGTRAP` signal."

This revision was landed with ongoing or failed builds.Jun 12 2023, 1:04 PM
This revision was automatically updated to reflect the committed changes.