[PATCH] D143191: DAG: Handle inversion of fcSubnormal | fcZero

Serge Pavlov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Wed Feb 22 08:55:59 PST 2023


sepavloff added inline comments.


================
Comment at: llvm/test/CodeGen/X86/is_fpclass.ll:894-901
+; CHECK-32-NEXT:    flds {{[0-9]+}}(%esp)
+; CHECK-32-NEXT:    fldz
+; CHECK-32-NEXT:    fucompp
+; CHECK-32-NEXT:    fnstsw %ax
+; CHECK-32-NEXT:    # kill: def $ah killed $ah killed $ax
+; CHECK-32-NEXT:    sahf
+; CHECK-32-NEXT:    setp %cl
----------------
arsenm wrote:
> sepavloff wrote:
> > This code looks incorrect. The argument is compared against 0.0 and the result is true if the comparison is unordered or not equal.
> Looks like I broke the inverted case and ended up fixing it in one of my later patches
Not sure if x87 has DAZ mode. Corresponding flag is in MXCSR only and it is not clear if MXCSR affects operations in x87. @jcranmer-intel, could you please clarify this point?


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D143191/new/

https://reviews.llvm.org/D143191



More information about the llvm-commits mailing list