This is an archive of the discontinued LLVM Phabricator instance.

[Bitfield] Disable -ffine-grained-bitfield-accesses only when thread sanitizer is enabled
Needs ReviewPublic

Authored by wmi on Aug 25 2019, 10:34 PM.

Details

Summary

Currently -ffine-grained-bitfield-accesses is disabled when any type of sanitizer is enabled (https://reviews.llvm.org/D36562). That seems unnecessary because the flag only affect Tsan's ability to find race conditions between accesses to consecutive bitfields. The patch disable -ffine-grained-bitfield-accesses only when thread sanitizer is enabled.

Diff Detail

Repository
rL LLVM

Event Timeline

wmi created this revision.Aug 25 2019, 10:34 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 25 2019, 10:34 PM
wmi edited subscribers, added: cfe-commits; removed: llvm-commits.Aug 25 2019, 10:35 PM

I suppose this is fine for ubsan/lsan/asan, but does msan track things on smaller-than-byte level?