[llvm] 559e813 - ValueTracking: log may never return -0 (#173380)

via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 29 02:08:12 PST 2025


Author: Matt Arsenault
Date: 2025-12-29T11:08:08+01:00
New Revision: 559e8131ec6a3637937fdea3ba3188c3eb24dbd7

URL: https://github.com/llvm/llvm-project/commit/559e8131ec6a3637937fdea3ba3188c3eb24dbd7
DIFF: https://github.com/llvm/llvm-project/commit/559e8131ec6a3637937fdea3ba3188c3eb24dbd7.diff

LOG: ValueTracking: log may never return -0 (#173380)

Added: 
    

Modified: 
    llvm/lib/Analysis/ValueTracking.cpp
    llvm/test/Transforms/Attributor/AMDGPU/nofpclass-amdgcn-log.ll
    llvm/test/Transforms/Attributor/nofpclass-log.ll

Removed: 
    


################################################################################
diff  --git a/llvm/lib/Analysis/ValueTracking.cpp b/llvm/lib/Analysis/ValueTracking.cpp
index be51194a74d5a..fe4463da44477 100644
--- a/llvm/lib/Analysis/ValueTracking.cpp
+++ b/llvm/lib/Analysis/ValueTracking.cpp
@@ -5421,6 +5421,8 @@ void computeKnownFPClass(const Value *V, const APInt &DemandedElts,
       if (IID == Intrinsic::amdgcn_log && EltTy->isFloatTy())
         Known.knownNot(fcSubnormal);
 
+      Known.knownNot(fcNegZero);
+
       // log(+inf) -> +inf
       // log([+-]0.0) -> -inf
       // log(-inf) -> nan

diff  --git a/llvm/test/Transforms/Attributor/AMDGPU/nofpclass-amdgcn-log.ll b/llvm/test/Transforms/Attributor/AMDGPU/nofpclass-amdgcn-log.ll
index 0e4e9b6d7acdb..f447315787fa7 100644
--- a/llvm/test/Transforms/Attributor/AMDGPU/nofpclass-amdgcn-log.ll
+++ b/llvm/test/Transforms/Attributor/AMDGPU/nofpclass-amdgcn-log.ll
@@ -2,9 +2,9 @@
 ; RUN: opt -S -passes=attributor -attributor-manifest-internal < %s | FileCheck %s
 
 define half @ret_log_f16(half %arg) #1 {
-; CHECK-LABEL: define half @ret_log_f16(
+; CHECK-LABEL: define nofpclass(nzero) half @ret_log_f16(
 ; CHECK-SAME: half [[ARG:%.*]]) #[[ATTR0:[0-9]+]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call half @llvm.amdgcn.log.f16(half [[ARG]]) #[[ATTR7:[0-9]+]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nzero) half @llvm.amdgcn.log.f16(half [[ARG]]) #[[ATTR7:[0-9]+]]
 ; CHECK-NEXT:    ret half [[CALL]]
 ;
   %call = call half @llvm.amdgcn.log.f16(half %arg)
@@ -12,9 +12,9 @@ define half @ret_log_f16(half %arg) #1 {
 }
 
 define float @ret_log_f32(float %arg) #1 {
-; CHECK-LABEL: define nofpclass(sub) float @ret_log_f32(
+; CHECK-LABEL: define nofpclass(nzero sub) float @ret_log_f32(
 ; CHECK-SAME: float [[ARG:%.*]]) #[[ATTR0]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(sub) float @llvm.amdgcn.log.f32(float [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nzero sub) float @llvm.amdgcn.log.f32(float [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -22,9 +22,9 @@ define float @ret_log_f32(float %arg) #1 {
 }
 
 define float @ret_log_noinf(float nofpclass(inf) %arg) #1 {
-; CHECK-LABEL: define nofpclass(pinf sub) float @ret_log_noinf(
+; CHECK-LABEL: define nofpclass(pinf nzero sub) float @ret_log_noinf(
 ; CHECK-SAME: float nofpclass(inf) [[ARG:%.*]]) #[[ATTR0]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(inf) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(inf) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -32,9 +32,9 @@ define float @ret_log_noinf(float nofpclass(inf) %arg) #1 {
 }
 
 define float @ret_log_noneg(float nofpclass(ninf nsub nnorm) %arg) #1 {
-; CHECK-LABEL: define nofpclass(sub) float @ret_log_noneg(
+; CHECK-LABEL: define nofpclass(nzero sub) float @ret_log_noneg(
 ; CHECK-SAME: float nofpclass(ninf nsub nnorm) [[ARG:%.*]]) #[[ATTR0]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(sub) float @llvm.amdgcn.log.f32(float nofpclass(ninf nsub nnorm) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(ninf nsub nnorm) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -42,9 +42,9 @@ define float @ret_log_noneg(float nofpclass(ninf nsub nnorm) %arg) #1 {
 }
 
 define float @ret_log_noneg_nonan(float nofpclass(nan ninf nsub nnorm) %arg) #1 {
-; CHECK-LABEL: define nofpclass(nan sub) float @ret_log_noneg_nonan(
+; CHECK-LABEL: define nofpclass(nan nzero sub) float @ret_log_noneg_nonan(
 ; CHECK-SAME: float nofpclass(nan ninf nsub nnorm) [[ARG:%.*]]) #[[ATTR0]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan sub) float @llvm.amdgcn.log.f32(float nofpclass(nan ninf nsub nnorm) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(nan ninf nsub nnorm) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -52,9 +52,9 @@ define float @ret_log_noneg_nonan(float nofpclass(nan ninf nsub nnorm) %arg) #1
 }
 
 define float @ret_log_noinf_noneg(float nofpclass(inf nsub nnorm) %arg) #1 {
-; CHECK-LABEL: define nofpclass(pinf sub) float @ret_log_noinf_noneg(
+; CHECK-LABEL: define nofpclass(pinf nzero sub) float @ret_log_noinf_noneg(
 ; CHECK-SAME: float nofpclass(inf nsub nnorm) [[ARG:%.*]]) #[[ATTR0]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nsub nnorm) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nsub nnorm) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -62,9 +62,9 @@ define float @ret_log_noinf_noneg(float nofpclass(inf nsub nnorm) %arg) #1 {
 }
 
 define float @ret_log_noinf_noneg_nonan(float nofpclass(nan inf nsub nnorm) %arg) #1 {
-; CHECK-LABEL: define nofpclass(nan pinf sub) float @ret_log_noinf_noneg_nonan(
+; CHECK-LABEL: define nofpclass(nan pinf nzero sub) float @ret_log_noinf_noneg_nonan(
 ; CHECK-SAME: float nofpclass(nan inf nsub nnorm) [[ARG:%.*]]) #[[ATTR0]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(nan inf nsub nnorm) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(nan inf nsub nnorm) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -72,9 +72,9 @@ define float @ret_log_noinf_noneg_nonan(float nofpclass(nan inf nsub nnorm) %arg
 }
 
 define float @ret_log_nopinf(float nofpclass(pinf) %arg) #1 {
-; CHECK-LABEL: define nofpclass(pinf sub) float @ret_log_nopinf(
+; CHECK-LABEL: define nofpclass(pinf nzero sub) float @ret_log_nopinf(
 ; CHECK-SAME: float nofpclass(pinf) [[ARG:%.*]]) #[[ATTR0]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(pinf) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(pinf) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -82,9 +82,9 @@ define float @ret_log_nopinf(float nofpclass(pinf) %arg) #1 {
 }
 
 define float @ret_log_noninf(float nofpclass(ninf) %arg) #1 {
-; CHECK-LABEL: define nofpclass(sub) float @ret_log_noninf(
+; CHECK-LABEL: define nofpclass(nzero sub) float @ret_log_noninf(
 ; CHECK-SAME: float nofpclass(ninf) [[ARG:%.*]]) #[[ATTR0]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(sub) float @llvm.amdgcn.log.f32(float nofpclass(ninf) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(ninf) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -92,9 +92,9 @@ define float @ret_log_noninf(float nofpclass(ninf) %arg) #1 {
 }
 
 define float @ret_log_nonan(float nofpclass(nan) %arg) #1 {
-; CHECK-LABEL: define nofpclass(sub) float @ret_log_nonan(
+; CHECK-LABEL: define nofpclass(nzero sub) float @ret_log_nonan(
 ; CHECK-SAME: float nofpclass(nan) [[ARG:%.*]]) #[[ATTR0]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(sub) float @llvm.amdgcn.log.f32(float nofpclass(nan) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(nan) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -102,9 +102,9 @@ define float @ret_log_nonan(float nofpclass(nan) %arg) #1 {
 }
 
 define float @ret_log_nonan_noinf(float nofpclass(nan inf) %arg) #1 {
-; CHECK-LABEL: define nofpclass(pinf sub) float @ret_log_nonan_noinf(
+; CHECK-LABEL: define nofpclass(pinf nzero sub) float @ret_log_nonan_noinf(
 ; CHECK-SAME: float nofpclass(nan inf) [[ARG:%.*]]) #[[ATTR0]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(nan inf) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(nan inf) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -112,9 +112,9 @@ define float @ret_log_nonan_noinf(float nofpclass(nan inf) %arg) #1 {
 }
 
 define float @ret_log_nonan_noinf_nozero(float nofpclass(nan inf zero) %arg) #1 {
-; CHECK-LABEL: define nofpclass(inf sub) float @ret_log_nonan_noinf_nozero(
+; CHECK-LABEL: define nofpclass(inf nzero sub) float @ret_log_nonan_noinf_nozero(
 ; CHECK-SAME: float nofpclass(nan inf zero) [[ARG:%.*]]) #[[ATTR0]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(inf sub) float @llvm.amdgcn.log.f32(float nofpclass(nan inf zero) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(inf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(nan inf zero) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -122,9 +122,9 @@ define float @ret_log_nonan_noinf_nozero(float nofpclass(nan inf zero) %arg) #1
 }
 
 define float @ret_log_noinf_nozero(float nofpclass(inf zero) %arg) #1 {
-; CHECK-LABEL: define nofpclass(inf sub) float @ret_log_noinf_nozero(
+; CHECK-LABEL: define nofpclass(inf nzero sub) float @ret_log_noinf_nozero(
 ; CHECK-SAME: float nofpclass(inf zero) [[ARG:%.*]]) #[[ATTR0]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(inf sub) float @llvm.amdgcn.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(inf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -132,9 +132,9 @@ define float @ret_log_noinf_nozero(float nofpclass(inf zero) %arg) #1 {
 }
 
 define float @ret_log_noinf_nonegzero(float nofpclass(inf nzero) %arg) #1 {
-; CHECK-LABEL: define nofpclass(pinf sub) float @ret_log_noinf_nonegzero(
+; CHECK-LABEL: define nofpclass(pinf nzero sub) float @ret_log_noinf_nonegzero(
 ; CHECK-SAME: float nofpclass(inf nzero) [[ARG:%.*]]) #[[ATTR0]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -142,10 +142,10 @@ define float @ret_log_noinf_nonegzero(float nofpclass(inf nzero) %arg) #1 {
 }
 
 define float @ret_log_positive_source(i32 %arg) #1 {
-; CHECK-LABEL: define nofpclass(nan pinf sub) float @ret_log_positive_source(
+; CHECK-LABEL: define nofpclass(nan pinf nzero sub) float @ret_log_positive_source(
 ; CHECK-SAME: i32 [[ARG:%.*]]) #[[ATTR0]] {
 ; CHECK-NEXT:    [[UITOFP:%.*]] = uitofp i32 [[ARG]] to float
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan pinf sub) float @llvm.amdgcn.log.f32(float [[UITOFP]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan pinf nzero sub) float @llvm.amdgcn.log.f32(float [[UITOFP]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %uitofp = uitofp i32 %arg to float
@@ -154,10 +154,10 @@ define float @ret_log_positive_source(i32 %arg) #1 {
 }
 
 define float @ret_log_unknown_sign(float nofpclass(nan) %arg, float nofpclass(nan) %arg1) #1 {
-; CHECK-LABEL: define nofpclass(sub) float @ret_log_unknown_sign(
+; CHECK-LABEL: define nofpclass(nzero sub) float @ret_log_unknown_sign(
 ; CHECK-SAME: float nofpclass(nan) [[ARG:%.*]], float nofpclass(nan) [[ARG1:%.*]]) #[[ATTR0]] {
 ; CHECK-NEXT:    [[UNKNOWN_SIGN_NOT_NAN:%.*]] = fmul nnan float [[ARG]], [[ARG1]]
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(sub) float @llvm.amdgcn.log.f32(float [[UNKNOWN_SIGN_NOT_NAN]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nzero sub) float @llvm.amdgcn.log.f32(float [[UNKNOWN_SIGN_NOT_NAN]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %unknown.sign.not.nan = fmul nnan float %arg, %arg1
@@ -166,9 +166,9 @@ define float @ret_log_unknown_sign(float nofpclass(nan) %arg, float nofpclass(na
 }
 
 define float @ret_log_daz_noinf_nozero(float nofpclass(inf zero) %arg) #2 {
-; CHECK-LABEL: define nofpclass(pinf sub) float @ret_log_daz_noinf_nozero(
+; CHECK-LABEL: define nofpclass(pinf nzero sub) float @ret_log_daz_noinf_nozero(
 ; CHECK-SAME: float nofpclass(inf zero) [[ARG:%.*]]) #[[ATTR1:[0-9]+]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -176,9 +176,9 @@ define float @ret_log_daz_noinf_nozero(float nofpclass(inf zero) %arg) #2 {
 }
 
 define <2 x float> @ret_log_daz_noinf_nozero_v2f32(<2 x float> nofpclass(inf zero) %arg) #2 {
-; CHECK-LABEL: define nofpclass(pinf) <2 x float> @ret_log_daz_noinf_nozero_v2f32(
+; CHECK-LABEL: define nofpclass(pinf nzero) <2 x float> @ret_log_daz_noinf_nozero_v2f32(
 ; CHECK-SAME: <2 x float> nofpclass(inf zero) [[ARG:%.*]]) #[[ATTR1]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) <2 x float> @llvm.log.v2f32(<2 x float> nofpclass(inf zero) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) <2 x float> @llvm.log.v2f32(<2 x float> nofpclass(inf zero) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret <2 x float> [[CALL]]
 ;
   %call = call <2 x float> @llvm.log.v2f32(<2 x float> %arg)
@@ -186,9 +186,9 @@ define <2 x float> @ret_log_daz_noinf_nozero_v2f32(<2 x float> nofpclass(inf zer
 }
 
 define float @ret_log_daz_noinf_nonegzero(float nofpclass(inf nzero) %arg) #2 {
-; CHECK-LABEL: define nofpclass(pinf sub) float @ret_log_daz_noinf_nonegzero(
+; CHECK-LABEL: define nofpclass(pinf nzero sub) float @ret_log_daz_noinf_nonegzero(
 ; CHECK-SAME: float nofpclass(inf nzero) [[ARG:%.*]]) #[[ATTR1]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -196,9 +196,9 @@ define float @ret_log_daz_noinf_nonegzero(float nofpclass(inf nzero) %arg) #2 {
 }
 
 define float @ret_log_dynamic_noinf_nozero(float nofpclass(inf zero) %arg) #3 {
-; CHECK-LABEL: define nofpclass(pinf sub) float @ret_log_dynamic_noinf_nozero(
+; CHECK-LABEL: define nofpclass(pinf nzero sub) float @ret_log_dynamic_noinf_nozero(
 ; CHECK-SAME: float nofpclass(inf zero) [[ARG:%.*]]) #[[ATTR2:[0-9]+]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -206,9 +206,9 @@ define float @ret_log_dynamic_noinf_nozero(float nofpclass(inf zero) %arg) #3 {
 }
 
 define float @ret_log_dynamic_noinf_nonegzero(float nofpclass(inf nzero) %arg) #3 {
-; CHECK-LABEL: define nofpclass(pinf sub) float @ret_log_dynamic_noinf_nonegzero(
+; CHECK-LABEL: define nofpclass(pinf nzero sub) float @ret_log_dynamic_noinf_nonegzero(
 ; CHECK-SAME: float nofpclass(inf nzero) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -216,9 +216,9 @@ define float @ret_log_dynamic_noinf_nonegzero(float nofpclass(inf nzero) %arg) #
 }
 
 define float @ret_log_ftz_noinf_nonegzero(float nofpclass(inf nzero) %arg) #4 {
-; CHECK-LABEL: define nofpclass(pinf sub) float @ret_log_ftz_noinf_nonegzero(
+; CHECK-LABEL: define nofpclass(pinf nzero sub) float @ret_log_ftz_noinf_nonegzero(
 ; CHECK-SAME: float nofpclass(inf nzero) [[ARG:%.*]]) #[[ATTR3:[0-9]+]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -226,9 +226,9 @@ define float @ret_log_ftz_noinf_nonegzero(float nofpclass(inf nzero) %arg) #4 {
 }
 
 define float @ret_log_ftz_dynamic_noinf_nonegzero(float nofpclass(inf nzero) %arg) #5 {
-; CHECK-LABEL: define nofpclass(pinf sub) float @ret_log_ftz_dynamic_noinf_nonegzero(
+; CHECK-LABEL: define nofpclass(pinf nzero sub) float @ret_log_ftz_dynamic_noinf_nonegzero(
 ; CHECK-SAME: float nofpclass(inf nzero) [[ARG:%.*]]) #[[ATTR4:[0-9]+]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -236,9 +236,9 @@ define float @ret_log_ftz_dynamic_noinf_nonegzero(float nofpclass(inf nzero) %ar
 }
 
 define float @ret_log_dynamic_noinf_nozero_nosub(float nofpclass(inf zero sub) %arg) #3 {
-; CHECK-LABEL: define nofpclass(inf sub) float @ret_log_dynamic_noinf_nozero_nosub(
+; CHECK-LABEL: define nofpclass(inf nzero sub) float @ret_log_dynamic_noinf_nozero_nosub(
 ; CHECK-SAME: float nofpclass(inf zero sub) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(inf sub) float @llvm.amdgcn.log.f32(float nofpclass(inf zero sub) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(inf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(inf zero sub) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -246,9 +246,9 @@ define float @ret_log_dynamic_noinf_nozero_nosub(float nofpclass(inf zero sub) %
 }
 
 define float @ret_log_dynamic_noinf_nopzero_nopsub(float nofpclass(inf pzero psub) %arg) #3 {
-; CHECK-LABEL: define nofpclass(pinf sub) float @ret_log_dynamic_noinf_nopzero_nopsub(
+; CHECK-LABEL: define nofpclass(pinf nzero sub) float @ret_log_dynamic_noinf_nopzero_nopsub(
 ; CHECK-SAME: float nofpclass(inf pzero psub) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(inf pzero psub) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(inf pzero psub) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)
@@ -256,9 +256,9 @@ define float @ret_log_dynamic_noinf_nopzero_nopsub(float nofpclass(inf pzero psu
 }
 
 define float @ret_log_dynamic_noinf_nonzero_nonsub(float nofpclass(inf nzero nsub) %arg) #3 {
-; CHECK-LABEL: define nofpclass(pinf sub) float @ret_log_dynamic_noinf_nonzero_nonsub(
+; CHECK-LABEL: define nofpclass(pinf nzero sub) float @ret_log_dynamic_noinf_nonzero_nonsub(
 ; CHECK-SAME: float nofpclass(inf nzero nsub) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nzero nsub) [[ARG]]) #[[ATTR7]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero sub) float @llvm.amdgcn.log.f32(float nofpclass(inf nzero nsub) [[ARG]]) #[[ATTR7]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.amdgcn.log.f32(float %arg)

diff  --git a/llvm/test/Transforms/Attributor/nofpclass-log.ll b/llvm/test/Transforms/Attributor/nofpclass-log.ll
index e5ee709f40f21..a0b969d557eb6 100644
--- a/llvm/test/Transforms/Attributor/nofpclass-log.ll
+++ b/llvm/test/Transforms/Attributor/nofpclass-log.ll
@@ -11,9 +11,9 @@ declare float @llvm.experimental.constrained.log2.f32(float, metadata, metadata)
 declare float @llvm.experimental.constrained.log10.f32(float, metadata, metadata)
 
 define float @ret_log(float %arg) #0 {
-; CHECK-LABEL: define float @ret_log
+; CHECK-LABEL: define nofpclass(nzero) float @ret_log
 ; CHECK-SAME: (float [[ARG:%.*]]) #[[ATTR2:[0-9]+]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call float @llvm.log.f32(float [[ARG]]) #[[ATTR10:[0-9]+]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nzero) float @llvm.log.f32(float [[ARG]]) #[[ATTR10:[0-9]+]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -21,9 +21,9 @@ define float @ret_log(float %arg) #0 {
 }
 
 define float @ret_log_noinf(float nofpclass(inf) %arg) #0 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_noinf
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_noinf
 ; CHECK-SAME: (float nofpclass(inf) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(inf) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(inf) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -31,9 +31,9 @@ define float @ret_log_noinf(float nofpclass(inf) %arg) #0 {
 }
 
 define float @ret_log_noneg(float nofpclass(ninf nsub nnorm) %arg) #0 {
-; CHECK-LABEL: define float @ret_log_noneg
+; CHECK-LABEL: define nofpclass(nzero) float @ret_log_noneg
 ; CHECK-SAME: (float nofpclass(ninf nsub nnorm) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call float @llvm.log.f32(float nofpclass(ninf nsub nnorm) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nzero) float @llvm.log.f32(float nofpclass(ninf nsub nnorm) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -41,9 +41,9 @@ define float @ret_log_noneg(float nofpclass(ninf nsub nnorm) %arg) #0 {
 }
 
 define float @ret_log_noneg_nonan(float nofpclass(ninf nsub nnorm nan) %arg) #0 {
-; CHECK-LABEL: define nofpclass(nan) float @ret_log_noneg_nonan
+; CHECK-LABEL: define nofpclass(nan nzero) float @ret_log_noneg_nonan
 ; CHECK-SAME: (float nofpclass(nan ninf nsub nnorm) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan) float @llvm.log.f32(float nofpclass(nan ninf nsub nnorm) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan nzero) float @llvm.log.f32(float nofpclass(nan ninf nsub nnorm) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -51,9 +51,9 @@ define float @ret_log_noneg_nonan(float nofpclass(ninf nsub nnorm nan) %arg) #0
 }
 
 define float @ret_log_noinf_noneg(float nofpclass(inf nsub nnorm) %arg) #0 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_noinf_noneg
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_noinf_noneg
 ; CHECK-SAME: (float nofpclass(inf nsub nnorm) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(inf nsub nnorm) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(inf nsub nnorm) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -61,9 +61,9 @@ define float @ret_log_noinf_noneg(float nofpclass(inf nsub nnorm) %arg) #0 {
 }
 
 define float @ret_log_noinf_noneg_nonan(float nofpclass(inf nsub nnorm nan) %arg) #0 {
-; CHECK-LABEL: define nofpclass(nan pinf) float @ret_log_noinf_noneg_nonan
+; CHECK-LABEL: define nofpclass(nan pinf nzero) float @ret_log_noinf_noneg_nonan
 ; CHECK-SAME: (float nofpclass(nan inf nsub nnorm) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan pinf) float @llvm.log.f32(float nofpclass(nan inf nsub nnorm) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan pinf nzero) float @llvm.log.f32(float nofpclass(nan inf nsub nnorm) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -71,9 +71,9 @@ define float @ret_log_noinf_noneg_nonan(float nofpclass(inf nsub nnorm nan) %arg
 }
 
 define float @ret_log_nopinf(float nofpclass(pinf) %arg) #0 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_nopinf
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_nopinf
 ; CHECK-SAME: (float nofpclass(pinf) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(pinf) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(pinf) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -81,9 +81,9 @@ define float @ret_log_nopinf(float nofpclass(pinf) %arg) #0 {
 }
 
 define float @ret_log_noninf(float nofpclass(ninf) %arg) #0 {
-; CHECK-LABEL: define float @ret_log_noninf
+; CHECK-LABEL: define nofpclass(nzero) float @ret_log_noninf
 ; CHECK-SAME: (float nofpclass(ninf) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call float @llvm.log.f32(float nofpclass(ninf) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nzero) float @llvm.log.f32(float nofpclass(ninf) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -91,9 +91,9 @@ define float @ret_log_noninf(float nofpclass(ninf) %arg) #0 {
 }
 
 define float @ret_log_nonan(float nofpclass(nan) %arg) #0 {
-; CHECK-LABEL: define float @ret_log_nonan
+; CHECK-LABEL: define nofpclass(nzero) float @ret_log_nonan
 ; CHECK-SAME: (float nofpclass(nan) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call float @llvm.log.f32(float nofpclass(nan) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nzero) float @llvm.log.f32(float nofpclass(nan) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -101,9 +101,9 @@ define float @ret_log_nonan(float nofpclass(nan) %arg) #0 {
 }
 
 define float @ret_log_nonan_noinf(float nofpclass(nan inf) %arg) #0 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_nonan_noinf
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_nonan_noinf
 ; CHECK-SAME: (float nofpclass(nan inf) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(nan inf) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(nan inf) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -111,9 +111,9 @@ define float @ret_log_nonan_noinf(float nofpclass(nan inf) %arg) #0 {
 }
 
 define float @ret_log_nonan_noinf_nozero(float nofpclass(nan inf zero) %arg) #0 {
-; CHECK-LABEL: define nofpclass(inf) float @ret_log_nonan_noinf_nozero
+; CHECK-LABEL: define nofpclass(inf nzero) float @ret_log_nonan_noinf_nozero
 ; CHECK-SAME: (float nofpclass(nan inf zero) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(inf) float @llvm.log.f32(float nofpclass(nan inf zero) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(inf nzero) float @llvm.log.f32(float nofpclass(nan inf zero) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -121,9 +121,9 @@ define float @ret_log_nonan_noinf_nozero(float nofpclass(nan inf zero) %arg) #0
 }
 
 define float @ret_log_noinf_nozero(float nofpclass(inf zero) %arg) #0 {
-; CHECK-LABEL: define nofpclass(inf) float @ret_log_noinf_nozero
+; CHECK-LABEL: define nofpclass(inf nzero) float @ret_log_noinf_nozero
 ; CHECK-SAME: (float nofpclass(inf zero) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(inf) float @llvm.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(inf nzero) float @llvm.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -131,9 +131,9 @@ define float @ret_log_noinf_nozero(float nofpclass(inf zero) %arg) #0 {
 }
 
 define float @ret_log_noinf_nonegzero(float nofpclass(inf nzero) %arg) #0 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_noinf_nonegzero
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_noinf_nonegzero
 ; CHECK-SAME: (float nofpclass(inf nzero) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -141,10 +141,10 @@ define float @ret_log_noinf_nonegzero(float nofpclass(inf nzero) %arg) #0 {
 }
 
 define float @ret_log_positive_source(i32 %arg) #0 {
-; CHECK-LABEL: define nofpclass(nan pinf) float @ret_log_positive_source
+; CHECK-LABEL: define nofpclass(nan pinf nzero) float @ret_log_positive_source
 ; CHECK-SAME: (i32 [[ARG:%.*]]) #[[ATTR2]] {
 ; CHECK-NEXT:    [[UITOFP:%.*]] = uitofp i32 [[ARG]] to float
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan pinf) float @llvm.log.f32(float [[UITOFP]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan pinf nzero) float @llvm.log.f32(float [[UITOFP]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %uitofp = uitofp i32 %arg to float
@@ -154,10 +154,10 @@ define float @ret_log_positive_source(i32 %arg) #0 {
 
 ; Could produce a nan because we don't know if the multiply is negative.
 define float @ret_log_unknown_sign(float nofpclass(nan) %arg, float nofpclass(nan) %arg1) #0 {
-; CHECK-LABEL: define float @ret_log_unknown_sign
+; CHECK-LABEL: define nofpclass(nzero) float @ret_log_unknown_sign
 ; CHECK-SAME: (float nofpclass(nan) [[ARG:%.*]], float nofpclass(nan) [[ARG1:%.*]]) #[[ATTR2]] {
 ; CHECK-NEXT:    [[UNKNOWN_SIGN_NOT_NAN:%.*]] = fmul nnan float [[ARG]], [[ARG1]]
-; CHECK-NEXT:    [[CALL:%.*]] = call float @llvm.log.f32(float [[UNKNOWN_SIGN_NOT_NAN]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nzero) float @llvm.log.f32(float [[UNKNOWN_SIGN_NOT_NAN]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %unknown.sign.not.nan = fmul nnan float %arg, %arg1
@@ -166,9 +166,9 @@ define float @ret_log_unknown_sign(float nofpclass(nan) %arg, float nofpclass(na
 }
 
 define float @ret_log_daz_noinf_nozero(float nofpclass(inf zero) %arg) #1 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_daz_noinf_nozero
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_daz_noinf_nozero
 ; CHECK-SAME: (float nofpclass(inf zero) [[ARG:%.*]]) #[[ATTR3:[0-9]+]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -176,9 +176,9 @@ define float @ret_log_daz_noinf_nozero(float nofpclass(inf zero) %arg) #1 {
 }
 
 define <2 x float> @ret_log_daz_noinf_nozero_v2f32(<2 x float> nofpclass(inf zero) %arg) #1 {
-; CHECK-LABEL: define nofpclass(pinf) <2 x float> @ret_log_daz_noinf_nozero_v2f32
+; CHECK-LABEL: define nofpclass(pinf nzero) <2 x float> @ret_log_daz_noinf_nozero_v2f32
 ; CHECK-SAME: (<2 x float> nofpclass(inf zero) [[ARG:%.*]]) #[[ATTR3]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) <2 x float> @llvm.log.v2f32(<2 x float> nofpclass(inf zero) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) <2 x float> @llvm.log.v2f32(<2 x float> nofpclass(inf zero) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret <2 x float> [[CALL]]
 ;
   %call = call <2 x float> @llvm.log.v2f32(<2 x float> %arg)
@@ -186,9 +186,9 @@ define <2 x float> @ret_log_daz_noinf_nozero_v2f32(<2 x float> nofpclass(inf zer
 }
 
 define float @ret_log_daz_noinf_nonegzero(float nofpclass(inf nzero) %arg) #1 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_daz_noinf_nonegzero
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_daz_noinf_nonegzero
 ; CHECK-SAME: (float nofpclass(inf nzero) [[ARG:%.*]]) #[[ATTR3]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -196,9 +196,9 @@ define float @ret_log_daz_noinf_nonegzero(float nofpclass(inf nzero) %arg) #1 {
 }
 
 define float @ret_log_dapz_noinf_nozero(float nofpclass(inf zero) %arg) #2 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_dapz_noinf_nozero
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_dapz_noinf_nozero
 ; CHECK-SAME: (float nofpclass(inf zero) [[ARG:%.*]]) #[[ATTR4:[0-9]+]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -206,9 +206,9 @@ define float @ret_log_dapz_noinf_nozero(float nofpclass(inf zero) %arg) #2 {
 }
 
 define float @ret_log_dapz_noinf_nonegzero(float nofpclass(inf nzero) %arg) #2 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_dapz_noinf_nonegzero
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_dapz_noinf_nonegzero
 ; CHECK-SAME: (float nofpclass(inf nzero) [[ARG:%.*]]) #[[ATTR4]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -216,9 +216,9 @@ define float @ret_log_dapz_noinf_nonegzero(float nofpclass(inf nzero) %arg) #2 {
 }
 
 define float @ret_log_dynamic_noinf_nozero(float nofpclass(inf zero) %arg) #3 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_dynamic_noinf_nozero
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_dynamic_noinf_nozero
 ; CHECK-SAME: (float nofpclass(inf zero) [[ARG:%.*]]) #[[ATTR5:[0-9]+]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(inf zero) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -226,9 +226,9 @@ define float @ret_log_dynamic_noinf_nozero(float nofpclass(inf zero) %arg) #3 {
 }
 
 define float @ret_log_dynamic_noinf_nonegzero(float nofpclass(inf nzero) %arg) #3 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_dynamic_noinf_nonegzero
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_dynamic_noinf_nonegzero
 ; CHECK-SAME: (float nofpclass(inf nzero) [[ARG:%.*]]) #[[ATTR5]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -236,9 +236,9 @@ define float @ret_log_dynamic_noinf_nonegzero(float nofpclass(inf nzero) %arg) #
 }
 
 define float @ret_log_ftz_noinf_nonegzero(float nofpclass(inf nzero) %arg) #4 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_ftz_noinf_nonegzero
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_ftz_noinf_nonegzero
 ; CHECK-SAME: (float nofpclass(inf nzero) [[ARG:%.*]]) #[[ATTR6:[0-9]+]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -246,9 +246,9 @@ define float @ret_log_ftz_noinf_nonegzero(float nofpclass(inf nzero) %arg) #4 {
 }
 
 define float @ret_log_ftpz_noinf_nonegzero(float nofpclass(inf nzero) %arg) #5 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_ftpz_noinf_nonegzero
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_ftpz_noinf_nonegzero
 ; CHECK-SAME: (float nofpclass(inf nzero) [[ARG:%.*]]) #[[ATTR7:[0-9]+]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -256,9 +256,9 @@ define float @ret_log_ftpz_noinf_nonegzero(float nofpclass(inf nzero) %arg) #5 {
 }
 
 define float @ret_log_ftz_dynamic_noinf_nonegzero(float nofpclass(inf nzero) %arg) #6 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log_ftz_dynamic_noinf_nonegzero
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log_ftz_dynamic_noinf_nonegzero
 ; CHECK-SAME: (float nofpclass(inf nzero) [[ARG:%.*]]) #[[ATTR8:[0-9]+]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log.f32(float nofpclass(inf nzero) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log.f32(float %arg)
@@ -266,9 +266,9 @@ define float @ret_log_ftz_dynamic_noinf_nonegzero(float nofpclass(inf nzero) %ar
 }
 
 define float @constrained_log(float %arg) strictfp {
-; CHECK-LABEL: define float @constrained_log
+; CHECK-LABEL: define nofpclass(nzero) float @constrained_log
 ; CHECK-SAME: (float [[ARG:%.*]]) #[[ATTR9:[0-9]+]] {
-; CHECK-NEXT:    [[VAL:%.*]] = call float @llvm.experimental.constrained.log.f32(float [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11:[0-9]+]]
+; CHECK-NEXT:    [[VAL:%.*]] = call nofpclass(nzero) float @llvm.experimental.constrained.log.f32(float [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11:[0-9]+]]
 ; CHECK-NEXT:    ret float [[VAL]]
 ;
   %val = call float @llvm.experimental.constrained.log.f32(float %arg, metadata !"round.dynamic", metadata !"fpexcept.strict")
@@ -276,9 +276,9 @@ define float @constrained_log(float %arg) strictfp {
 }
 
 define float @constrained_log_nonan(float nofpclass(nan) %arg) strictfp {
-; CHECK-LABEL: define float @constrained_log_nonan
+; CHECK-LABEL: define nofpclass(nzero) float @constrained_log_nonan
 ; CHECK-SAME: (float nofpclass(nan) [[ARG:%.*]]) #[[ATTR9]] {
-; CHECK-NEXT:    [[VAL:%.*]] = call float @llvm.experimental.constrained.log.f32(float nofpclass(nan) [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11]]
+; CHECK-NEXT:    [[VAL:%.*]] = call nofpclass(nzero) float @llvm.experimental.constrained.log.f32(float nofpclass(nan) [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11]]
 ; CHECK-NEXT:    ret float [[VAL]]
 ;
   %val = call float @llvm.experimental.constrained.log.f32(float %arg, metadata !"round.dynamic", metadata !"fpexcept.strict")
@@ -286,9 +286,9 @@ define float @constrained_log_nonan(float nofpclass(nan) %arg) strictfp {
 }
 
 define float @constrained_log_nopinf(float nofpclass(pinf) %arg) strictfp {
-; CHECK-LABEL: define nofpclass(pinf) float @constrained_log_nopinf
+; CHECK-LABEL: define nofpclass(pinf nzero) float @constrained_log_nopinf
 ; CHECK-SAME: (float nofpclass(pinf) [[ARG:%.*]]) #[[ATTR9]] {
-; CHECK-NEXT:    [[VAL:%.*]] = call nofpclass(pinf) float @llvm.experimental.constrained.log.f32(float nofpclass(pinf) [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11]]
+; CHECK-NEXT:    [[VAL:%.*]] = call nofpclass(pinf nzero) float @llvm.experimental.constrained.log.f32(float nofpclass(pinf) [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11]]
 ; CHECK-NEXT:    ret float [[VAL]]
 ;
   %val = call float @llvm.experimental.constrained.log.f32(float %arg, metadata !"round.dynamic", metadata !"fpexcept.strict")
@@ -296,9 +296,9 @@ define float @constrained_log_nopinf(float nofpclass(pinf) %arg) strictfp {
 }
 
 define float @constrained_log_nonegzero(float nofpclass(nzero) %arg) strictfp {
-; CHECK-LABEL: define float @constrained_log_nonegzero
+; CHECK-LABEL: define nofpclass(nzero) float @constrained_log_nonegzero
 ; CHECK-SAME: (float nofpclass(nzero) [[ARG:%.*]]) #[[ATTR9]] {
-; CHECK-NEXT:    [[VAL:%.*]] = call float @llvm.experimental.constrained.log.f32(float nofpclass(nzero) [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11]]
+; CHECK-NEXT:    [[VAL:%.*]] = call nofpclass(nzero) float @llvm.experimental.constrained.log.f32(float nofpclass(nzero) [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11]]
 ; CHECK-NEXT:    ret float [[VAL]]
 ;
   %val = call float @llvm.experimental.constrained.log.f32(float %arg, metadata !"round.dynamic", metadata !"fpexcept.strict")
@@ -306,9 +306,9 @@ define float @constrained_log_nonegzero(float nofpclass(nzero) %arg) strictfp {
 }
 
 define float @constrained_log_nozero(float nofpclass(zero) %arg) strictfp {
-; CHECK-LABEL: define nofpclass(ninf) float @constrained_log_nozero
+; CHECK-LABEL: define nofpclass(ninf nzero) float @constrained_log_nozero
 ; CHECK-SAME: (float nofpclass(zero) [[ARG:%.*]]) #[[ATTR9]] {
-; CHECK-NEXT:    [[VAL:%.*]] = call nofpclass(ninf) float @llvm.experimental.constrained.log.f32(float nofpclass(zero) [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11]]
+; CHECK-NEXT:    [[VAL:%.*]] = call nofpclass(ninf nzero) float @llvm.experimental.constrained.log.f32(float nofpclass(zero) [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11]]
 ; CHECK-NEXT:    ret float [[VAL]]
 ;
   %val = call float @llvm.experimental.constrained.log.f32(float %arg, metadata !"round.dynamic", metadata !"fpexcept.strict")
@@ -316,9 +316,9 @@ define float @constrained_log_nozero(float nofpclass(zero) %arg) strictfp {
 }
 
 define float @ret_log2_noinf_noneg(float nofpclass(inf nsub nnorm) %arg) #0 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log2_noinf_noneg
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log2_noinf_noneg
 ; CHECK-SAME: (float nofpclass(inf nsub nnorm) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log2.f32(float nofpclass(inf nsub nnorm) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log2.f32(float nofpclass(inf nsub nnorm) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log2.f32(float %arg)
@@ -326,9 +326,9 @@ define float @ret_log2_noinf_noneg(float nofpclass(inf nsub nnorm) %arg) #0 {
 }
 
 define float @ret_log2_noinf_noneg_nonan(float nofpclass(inf nsub nnorm nan) %arg) #0 {
-; CHECK-LABEL: define nofpclass(nan pinf) float @ret_log2_noinf_noneg_nonan
+; CHECK-LABEL: define nofpclass(nan pinf nzero) float @ret_log2_noinf_noneg_nonan
 ; CHECK-SAME: (float nofpclass(nan inf nsub nnorm) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan pinf) float @llvm.log2.f32(float nofpclass(nan inf nsub nnorm) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(nan pinf nzero) float @llvm.log2.f32(float nofpclass(nan inf nsub nnorm) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log2.f32(float %arg)
@@ -336,9 +336,9 @@ define float @ret_log2_noinf_noneg_nonan(float nofpclass(inf nsub nnorm nan) %ar
 }
 
 define float @ret_log2_noinf_noneg_noqnan(float nofpclass(inf nsub nnorm qnan) %arg) #0 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log2_noinf_noneg_noqnan
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log2_noinf_noneg_noqnan
 ; CHECK-SAME: (float nofpclass(qnan inf nsub nnorm) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log2.f32(float nofpclass(qnan inf nsub nnorm) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log2.f32(float nofpclass(qnan inf nsub nnorm) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log2.f32(float %arg)
@@ -346,9 +346,9 @@ define float @ret_log2_noinf_noneg_noqnan(float nofpclass(inf nsub nnorm qnan) %
 }
 
 define float @ret_log2_noinf_noneg_nosnan(float nofpclass(inf nsub nnorm snan) %arg) #0 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log2_noinf_noneg_nosnan
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log2_noinf_noneg_nosnan
 ; CHECK-SAME: (float nofpclass(snan inf nsub nnorm) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log2.f32(float nofpclass(snan inf nsub nnorm) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log2.f32(float nofpclass(snan inf nsub nnorm) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log2.f32(float %arg)
@@ -356,9 +356,9 @@ define float @ret_log2_noinf_noneg_nosnan(float nofpclass(inf nsub nnorm snan) %
 }
 
 define float @ret_log10_noinf_noneg(float nofpclass(inf nsub nnorm) %arg) #0 {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_log10_noinf_noneg
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_log10_noinf_noneg
 ; CHECK-SAME: (float nofpclass(inf nsub nnorm) [[ARG:%.*]]) #[[ATTR2]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.log10.f32(float nofpclass(inf nsub nnorm) [[ARG]]) #[[ATTR10]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.log10.f32(float nofpclass(inf nsub nnorm) [[ARG]]) #[[ATTR10]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.log10.f32(float %arg)
@@ -366,9 +366,9 @@ define float @ret_log10_noinf_noneg(float nofpclass(inf nsub nnorm) %arg) #0 {
 }
 
 define float @ret_constrained_log2_noinf_noneg(float nofpclass(inf nsub nnorm) %arg) strictfp {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_constrained_log2_noinf_noneg
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_constrained_log2_noinf_noneg
 ; CHECK-SAME: (float nofpclass(inf nsub nnorm) [[ARG:%.*]]) #[[ATTR9]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.experimental.constrained.log2.f32(float nofpclass(inf nsub nnorm) [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.experimental.constrained.log2.f32(float nofpclass(inf nsub nnorm) [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.experimental.constrained.log2.f32(float %arg, metadata !"round.dynamic", metadata !"fpexcept.strict")
@@ -376,9 +376,9 @@ define float @ret_constrained_log2_noinf_noneg(float nofpclass(inf nsub nnorm) %
 }
 
 define float @ret_constrained_log10_noinf_noneg(float nofpclass(inf nsub nnorm) %arg) strictfp {
-; CHECK-LABEL: define nofpclass(pinf) float @ret_constrained_log10_noinf_noneg
+; CHECK-LABEL: define nofpclass(pinf nzero) float @ret_constrained_log10_noinf_noneg
 ; CHECK-SAME: (float nofpclass(inf nsub nnorm) [[ARG:%.*]]) #[[ATTR9]] {
-; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf) float @llvm.experimental.constrained.log10.f32(float nofpclass(inf nsub nnorm) [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11]]
+; CHECK-NEXT:    [[CALL:%.*]] = call nofpclass(pinf nzero) float @llvm.experimental.constrained.log10.f32(float nofpclass(inf nsub nnorm) [[ARG]], metadata !"round.dynamic", metadata !"fpexcept.strict") #[[ATTR11]]
 ; CHECK-NEXT:    ret float [[CALL]]
 ;
   %call = call float @llvm.experimental.constrained.log10.f32(float %arg, metadata !"round.dynamic", metadata !"fpexcept.strict")


        


More information about the llvm-commits mailing list