[PATCH] D137444: InstCombine: Fold compare with smallest normal if input denormals are flushed
Sanjay Patel via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Nov 6 06:31:38 PST 2022
spatel added inline comments.
================
Comment at: llvm/lib/Transforms/InstCombine/InstCombineCompares.cpp:6799
+ // fcmp olt fabs(x), smallest_normalized_number -> fcmp oeq x, 0.0
+ // https://alive2.llvm.org/ce/z/fib8cf
+ return replaceFCmp(&I, FCmpInst::FCMP_OEQ, X);
----------------
In general, we haven't put Alive2 links in the code (because the top-level URL or the hashed short links might change some day?).
Links are in the test file too, so that's good enough?
================
Comment at: llvm/test/Transforms/InstCombine/fcmp-denormals-are-zero.ll:9
+; CHECK-NEXT: [[CMPF32:%.*]] = fcmp oeq float [[F32:%.*]], 0.000000e+00
+; CHECK-NEXT: store volatile i1 [[CMPF32]], ptr null, align 4294967296
+; CHECK-NEXT: [[CMPF64:%.*]] = fcmp oeq double [[F64:%.*]], 0.000000e+00
----------------
Do the diffs in alignment have meaning?
If not, can we avoid that noise (by writing the minimal test for each pattern as a unique function or don't use a null ptr)?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D137444/new/
https://reviews.llvm.org/D137444
More information about the llvm-commits
mailing list