[PATCH] D143195: ValueTracking: Add start of computeKnownFPClass API
Nikita Popov via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Thu Mar 9 05:37:36 PST 2023
nikic added inline comments.
================
Comment at: llvm/include/llvm/Analysis/ValueTracking.h:234
+ else if (SignBit)
+ *SignBit &= *RHS.SignBit;
+
----------------
I don't understand your logic here. If `&` is supposed to be (doc comments?) an intersection, then if one side knows the sign bit and the other doesn't, shouldn't we be using the known sign bit?
It doesn't look like `operator&=` or `commonBits()` is actually used though. It may be worthwhile to split out this class into a separate header (like KnownBits) and unit test it.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D143195/new/
https://reviews.llvm.org/D143195
More information about the llvm-commits
mailing list