[PATCH] D27454: Extract LaneBitmask into a separate type
Krzysztof Parzyszek via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Dec 15 06:46:00 PST 2016
kparzysz marked 2 inline comments as done.
kparzysz added inline comments.
================
Comment at: include/llvm/MC/MCRegisterInfo.h:63-64
+ constexpr bool operator< (LaneBitmask M) const { return Mask < M.Mask; }
+ constexpr bool none() const { return Mask == 0; }
+ constexpr bool all() const { return ~Mask == 0; }
+
----------------
MatzeB wrote:
> Looking at the users `!X.none()` seems to be common enough that it warrants a `bool any() const { return Mask != 0; }` maybe even a `operator bool() const { return Mask != 0; }`.
I will add it in a subsequent patch.
Repository:
rL LLVM
https://reviews.llvm.org/D27454
More information about the llvm-commits
mailing list