[PATCH] D57914: [Driver] Allow enum SanitizerOrdinal to represent more than 64 different sanitizer checks, NFC.
Bruno Ricci via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Mon Feb 18 10:03:34 PST 2019
riccibruno added inline comments.
================
Comment at: include/clang/Basic/Sanitizers.h:43
+ // Low bits of mask value.
+ uint64_t maskLo;
+ // High bits of mask value.
----------------
Why not use a fixed size array of `uint64_t`s, and then compute the index without any branch with `ArrayIndex = BitPosition / 64` (with an assertion that `ArrayIndex < MaxArrayIndex` ? This has the advantage that in the future all that is needed to do is bump up the size of the array.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D57914/new/
https://reviews.llvm.org/D57914
More information about the cfe-commits
mailing list