diff --git a/bench/boost/optimized/area_geo.ll b/bench/boost/optimized/area_geo.ll index dccb9f46f44..c22083bf77d 100644 --- a/bench/boost/optimized/area_geo.ll +++ b/bench/boost/optimized/area_geo.ll @@ -162584,14 +162584,14 @@ _ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123.sink.split: ; p br label %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123 _ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123: ; preds = %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123.sink.split, %173 - %179 = call double @llvm.fabs.f64(double %69) + %179 = call noundef double @llvm.fabs.f64(double %69) %180 = fcmp ogt double %179, 9.000000e+01 %.sroa.speculated222 = select i1 %180, double 9.000000e+01, double %69 %181 = fcmp oeq double %.sroa.speculated222, 0.000000e+00 br i1 %181, label %_ZN5boost8geometry4math11round_angleIdEET_RKS3_.exit, label %182 182: ; preds = %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123 - %183 = select i1 %180, double 9.000000e+01, double %179 + %183 = call noundef double @llvm.fabs.f64(double %.sroa.speculated222) %184 = fcmp olt double %183, 6.250000e-02 %185 = fadd double %183, -6.250000e-02 %186 = fadd double %185, 6.250000e-02 @@ -162603,14 +162603,14 @@ _ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123: ; preds = %_ZN _ZN5boost8geometry4math11round_angleIdEET_RKS3_.exit: ; preds = %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123, %182 %.0.i = phi double [ %190, %182 ], [ 0.000000e+00, %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123 ] - %191 = call double @llvm.fabs.f64(double %71) + %191 = call noundef double @llvm.fabs.f64(double %71) %192 = fcmp ogt double %191, 9.000000e+01 %.sroa.speculated212 = select i1 %192, double 9.000000e+01, double %71 %193 = fcmp oeq double %.sroa.speculated212, 0.000000e+00 br i1 %193, label %_ZN5boost8geometry4math11round_angleIdEET_RKS3_.exit125, label %194 194: ; preds = %_ZN5boost8geometry4math11round_angleIdEET_RKS3_.exit - %195 = select i1 %192, double 9.000000e+01, double %191 + %195 = call noundef double @llvm.fabs.f64(double %.sroa.speculated212) %196 = fcmp olt double %195, 6.250000e-02 %197 = fadd double %195, -6.250000e-02 %198 = fadd double %197, 6.250000e-02 @@ -167026,14 +167026,14 @@ _ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123.sink.split: ; p br label %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123 _ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123: ; preds = %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123.sink.split, %173 - %179 = call double @llvm.fabs.f64(double %69) + %179 = call noundef double @llvm.fabs.f64(double %69) %180 = fcmp ogt double %179, 9.000000e+01 %.sroa.speculated222 = select i1 %180, double 9.000000e+01, double %69 %181 = fcmp oeq double %.sroa.speculated222, 0.000000e+00 br i1 %181, label %_ZN5boost8geometry4math11round_angleIdEET_RKS3_.exit, label %182 182: ; preds = %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123 - %183 = select i1 %180, double 9.000000e+01, double %179 + %183 = call noundef double @llvm.fabs.f64(double %.sroa.speculated222) %184 = fcmp olt double %183, 6.250000e-02 %185 = fadd double %183, -6.250000e-02 %186 = fadd double %185, 6.250000e-02 @@ -167045,14 +167045,14 @@ _ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123: ; preds = %_ZN _ZN5boost8geometry4math11round_angleIdEET_RKS3_.exit: ; preds = %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123, %182 %.0.i = phi double [ %190, %182 ], [ 0.000000e+00, %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123 ] - %191 = call double @llvm.fabs.f64(double %71) + %191 = call noundef double @llvm.fabs.f64(double %71) %192 = fcmp ogt double %191, 9.000000e+01 %.sroa.speculated212 = select i1 %192, double 9.000000e+01, double %71 %193 = fcmp oeq double %.sroa.speculated212, 0.000000e+00 br i1 %193, label %_ZN5boost8geometry4math11round_angleIdEET_RKS3_.exit125, label %194 194: ; preds = %_ZN5boost8geometry4math11round_angleIdEET_RKS3_.exit - %195 = select i1 %192, double 9.000000e+01, double %191 + %195 = call noundef double @llvm.fabs.f64(double %.sroa.speculated212) %196 = fcmp olt double %195, 6.250000e-02 %197 = fadd double %195, -6.250000e-02 %198 = fadd double %197, 6.250000e-02 diff --git a/bench/boost/optimized/buffer_geo_spheroid.ll b/bench/boost/optimized/buffer_geo_spheroid.ll index 82a91a47cfd..27e7b5d261c 100644 --- a/bench/boost/optimized/buffer_geo_spheroid.ll +++ b/bench/boost/optimized/buffer_geo_spheroid.ll @@ -209272,14 +209272,14 @@ _ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123.sink.split: ; p br label %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123 _ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123: ; preds = %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123.sink.split, %173 - %179 = call double @llvm.fabs.f64(double %69) + %179 = call noundef double @llvm.fabs.f64(double %69) %180 = fcmp ogt double %179, 9.000000e+01 %.sroa.speculated222 = select i1 %180, double 9.000000e+01, double %69 %181 = fcmp oeq double %.sroa.speculated222, 0.000000e+00 br i1 %181, label %_ZN5boost8geometry4math11round_angleIdEET_RKS3_.exit, label %182 182: ; preds = %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123 - %183 = select i1 %180, double 9.000000e+01, double %179 + %183 = call noundef double @llvm.fabs.f64(double %.sroa.speculated222) %184 = fcmp olt double %183, 6.250000e-02 %185 = fadd double %183, -6.250000e-02 %186 = fadd double %185, 6.250000e-02 @@ -209291,14 +209291,14 @@ _ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123: ; preds = %_ZN _ZN5boost8geometry4math11round_angleIdEET_RKS3_.exit: ; preds = %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123, %182 %.0.i = phi double [ %190, %182 ], [ 0.000000e+00, %_ZN5boost8geometry4math15sin_cos_degreesIdEEvRKT_RS3_S6_.exit123 ] - %191 = call double @llvm.fabs.f64(double %71) + %191 = call noundef double @llvm.fabs.f64(double %71) %192 = fcmp ogt double %191, 9.000000e+01 %.sroa.speculated212 = select i1 %192, double 9.000000e+01, double %71 %193 = fcmp oeq double %.sroa.speculated212, 0.000000e+00 br i1 %193, label %_ZN5boost8geometry4math11round_angleIdEET_RKS3_.exit125, label %194 194: ; preds = %_ZN5boost8geometry4math11round_angleIdEET_RKS3_.exit - %195 = select i1 %192, double 9.000000e+01, double %191 + %195 = call noundef double @llvm.fabs.f64(double %.sroa.speculated212) %196 = fcmp olt double %195, 6.250000e-02 %197 = fadd double %195, -6.250000e-02 %198 = fadd double %197, 6.250000e-02 diff --git a/bench/bullet3/optimized/btHeightfieldTerrainShape.ll b/bench/bullet3/optimized/btHeightfieldTerrainShape.ll index 6c961748a96..864d81760b4 100644 --- a/bench/bullet3/optimized/btHeightfieldTerrainShape.ll +++ b/bench/bullet3/optimized/btHeightfieldTerrainShape.ll @@ -3356,14 +3356,12 @@ if.end: ; preds = %entry %cond34 = sext i1 %cmp33 to i32 %cond36 = select i1 %cmp30, i32 %cond34, i32 1 %cmp37.not = icmp eq i32 %cond29, 0 - %15 = tail call float @llvm.fabs.f32(float %div) - %16 = fdiv float 1.000000e+00, %15 - %div40 = select i1 %cmp21, float 0x7FF0000000000000, float %16 + %15 = tail call float @llvm.fabs.f32(float %rayDirectionFlatX.0) + %div40 = fdiv float 1.000000e+00, %15 %cond43 = select i1 %cmp37.not, float 0x416312CFE0000000, float %div40 %cmp44.not = icmp eq i32 %cond36, 0 - %17 = tail call float @llvm.fabs.f32(float %div25) - %18 = fdiv float 1.000000e+00, %17 - %div47 = select i1 %cmp21, float 0x7FF0000000000000, float %18 + %16 = tail call float @llvm.fabs.f32(float %rayDirectionFlatZ.0) + %div47 = fdiv float 1.000000e+00, %16 %cond50 = select i1 %cmp44.not, float 0x416312CFE0000000, float %div47 br i1 %cmp37.not, label %if.end79, label %if.then52 @@ -3371,14 +3369,14 @@ if.then52: ; preds = %if.end br i1 %cmp27, label %if.else65, label %if.then54 if.then54: ; preds = %if.then52 - %19 = tail call noundef float @llvm.ceil.f32(float %10) - %sub64 = fsub float %19, %10 + %17 = tail call noundef float @llvm.ceil.f32(float %10) + %sub64 = fsub float %17, %10 %mul = fmul float %div40, %sub64 br label %if.end79 if.else65: ; preds = %if.then52 - %20 = tail call noundef float @llvm.floor.f32(float %10) - %sub75 = fsub float %10, %20 + %18 = tail call noundef float @llvm.floor.f32(float %10) + %sub75 = fsub float %10, %18 %mul76 = fmul float %div40, %sub75 br label %if.end79 @@ -3390,23 +3388,23 @@ if.then81: ; preds = %if.end79 br i1 %cmp30, label %if.else95, label %if.then83 if.then83: ; preds = %if.then81 - %21 = tail call noundef float @llvm.ceil.f32(float %13) - %sub93 = fsub float %21, %13 + %19 = tail call noundef float @llvm.ceil.f32(float %13) + %sub93 = fsub float %19, %13 %mul94 = fmul float %div47, %sub93 br label %if.end109 if.else95: ; preds = %if.then81 - %22 = tail call noundef float @llvm.floor.f32(float %13) - %sub105 = fsub float %13, %22 + %20 = tail call noundef float @llvm.floor.f32(float %13) + %sub105 = fsub float %13, %20 %mul106 = fmul float %div47, %sub105 br label %if.end109 if.end109: ; preds = %if.end79, %if.then83, %if.else95 %paramCrossZ.0 = phi float [ %mul94, %if.then83 ], [ %mul106, %if.else95 ], [ 0x416312CFE0000000, %if.end79 ] - %23 = tail call noundef float @llvm.floor.f32(float %10) - %conv115 = fptosi float %23 to i32 - %24 = tail call noundef float @llvm.floor.f32(float %13) - %conv121 = fptosi float %24 to i32 + %21 = tail call noundef float @llvm.floor.f32(float %10) + %conv115 = fptosi float %21 to i32 + %22 = tail call noundef float @llvm.floor.f32(float %13) + %conv121 = fptosi float %22 to i32 %cmp123 = fcmp oeq float %paramCrossX.0, 0.000000e+00 br i1 %cmp123, label %if.then124, label %if.end130 @@ -3535,14 +3533,12 @@ if.end: ; preds = %entry %cond34 = sext i1 %cmp33 to i32 %cond36 = select i1 %cmp30, i32 %cond34, i32 1 %cmp37.not = icmp eq i32 %cond29, 0 - %15 = tail call float @llvm.fabs.f32(float %div) - %16 = fdiv float 1.000000e+00, %15 - %div40 = select i1 %cmp21, float 0x7FF0000000000000, float %16 + %15 = tail call float @llvm.fabs.f32(float %rayDirectionFlatX.0) + %div40 = fdiv float 1.000000e+00, %15 %cond43 = select i1 %cmp37.not, float 0x416312CFE0000000, float %div40 %cmp44.not = icmp eq i32 %cond36, 0 - %17 = tail call float @llvm.fabs.f32(float %div25) - %18 = fdiv float 1.000000e+00, %17 - %div47 = select i1 %cmp21, float 0x7FF0000000000000, float %18 + %16 = tail call float @llvm.fabs.f32(float %rayDirectionFlatZ.0) + %div47 = fdiv float 1.000000e+00, %16 %cond50 = select i1 %cmp44.not, float 0x416312CFE0000000, float %div47 br i1 %cmp37.not, label %if.end79, label %if.then52 @@ -3550,14 +3546,14 @@ if.then52: ; preds = %if.end br i1 %cmp27, label %if.else65, label %if.then54 if.then54: ; preds = %if.then52 - %19 = tail call noundef float @llvm.ceil.f32(float %10) - %sub64 = fsub float %19, %10 + %17 = tail call noundef float @llvm.ceil.f32(float %10) + %sub64 = fsub float %17, %10 %mul = fmul float %div40, %sub64 br label %if.end79 if.else65: ; preds = %if.then52 - %20 = tail call noundef float @llvm.floor.f32(float %10) - %sub75 = fsub float %10, %20 + %18 = tail call noundef float @llvm.floor.f32(float %10) + %sub75 = fsub float %10, %18 %mul76 = fmul float %div40, %sub75 br label %if.end79 @@ -3569,24 +3565,24 @@ if.then81: ; preds = %if.end79 br i1 %cmp30, label %if.else95, label %if.then83 if.then83: ; preds = %if.then81 - %21 = tail call noundef float @llvm.ceil.f32(float %13) - %sub93 = fsub float %21, %13 + %19 = tail call noundef float @llvm.ceil.f32(float %13) + %sub93 = fsub float %19, %13 %mul94 = fmul float %div47, %sub93 br label %if.end109 if.else95: ; preds = %if.then81 - %22 = tail call noundef float @llvm.floor.f32(float %13) - %sub105 = fsub float %13, %22 + %20 = tail call noundef float @llvm.floor.f32(float %13) + %sub105 = fsub float %13, %20 %mul106 = fmul float %div47, %sub105 br label %if.end109 if.end109: ; preds = %if.end79, %if.then83, %if.else95 %paramCrossZ.0 = phi float [ %mul94, %if.then83 ], [ %mul106, %if.else95 ], [ 0x416312CFE0000000, %if.end79 ] - %23 = tail call noundef float @llvm.floor.f32(float %10) - %conv115 = fptosi float %23 to i32 + %21 = tail call noundef float @llvm.floor.f32(float %10) + %conv115 = fptosi float %21 to i32 store i32 %conv115, ptr %rs, align 4 - %24 = tail call noundef float @llvm.floor.f32(float %13) - %conv121 = fptosi float %24 to i32 + %22 = tail call noundef float @llvm.floor.f32(float %13) + %conv121 = fptosi float %22 to i32 %z = getelementptr inbounds nuw i8, ptr %rs, i64 4 store i32 %conv121, ptr %z, align 4 %cmp123 = fcmp oeq float %paramCrossX.0, 0.000000e+00 @@ -3617,7 +3613,7 @@ if.then136: ; preds = %if.then133 br label %if.end140 if.end140: ; preds = %if.then133, %if.then136, %if.end130 - %25 = phi i32 [ %sub138, %if.then136 ], [ %conv121, %if.then133 ], [ %conv121, %if.end130 ] + %23 = phi i32 [ %sub138, %if.then136 ], [ %conv121, %if.then133 ], [ %conv121, %if.end130 ] %paramCrossZ.1 = phi float [ %add134, %if.then136 ], [ %add134, %if.then133 ], [ %paramCrossZ.0, %if.end130 ] %prev_x = getelementptr inbounds nuw i8, ptr %rs, i64 8 %prev_z = getelementptr inbounds nuw i8, ptr %rs, i64 12 @@ -3627,12 +3623,12 @@ if.end140: ; preds = %if.then133, %if.the while.body: ; preds = %if.else166, %if.end140 %paramCrossZ.265 = phi float [ 0.000000e+00, %if.end140 ], [ %paramCrossZ.2.sink, %if.else166 ] - %26 = phi i32 [ %25, %if.end140 ], [ %27, %if.else166 ] + %24 = phi i32 [ %23, %if.end140 ], [ %25, %if.else166 ] %conv11563 = phi i32 [ %conv11561, %if.end140 ], [ %conv11562, %if.else166 ] %paramCrossX.2 = phi float [ %paramCrossX.1, %if.end140 ], [ %paramCrossX.3, %if.else166 ] %paramCrossZ.2 = phi float [ %paramCrossZ.1, %if.end140 ], [ %paramCrossZ.3, %if.else166 ] store i32 %conv11563, ptr %prev_x, align 4 - store i32 %26, ptr %prev_z, align 4 + store i32 %24, ptr %prev_z, align 4 store float %paramCrossZ.265, ptr %prevParam, align 4 %cmp148 = fcmp olt float %paramCrossX.2, %paramCrossZ.2 br i1 %cmp148, label %if.then149, label %if.else154 @@ -3644,14 +3640,14 @@ if.then149: ; preds = %while.body br label %if.end159 if.else154: ; preds = %while.body - %add156 = add nsw i32 %26, %cond36 + %add156 = add nsw i32 %24, %cond36 store i32 %add156, ptr %z, align 4 %add158 = fadd float %cond50, %paramCrossZ.2 br label %if.end159 if.end159: ; preds = %if.else154, %if.then149 %paramCrossZ.2.sink = phi float [ %paramCrossX.2, %if.then149 ], [ %paramCrossZ.2, %if.else154 ] - %27 = phi i32 [ %26, %if.then149 ], [ %add156, %if.else154 ] + %25 = phi i32 [ %24, %if.then149 ], [ %add156, %if.else154 ] %conv11562 = phi i32 [ %add151, %if.then149 ], [ %conv11563, %if.else154 ] %paramCrossX.3 = phi float [ %add153, %if.then149 ], [ %paramCrossX.2, %if.else154 ] %paramCrossZ.3 = phi float [ %paramCrossZ.2, %if.then149 ], [ %add158, %if.else154 ] @@ -4186,14 +4182,12 @@ if.end: ; preds = %entry %cond34 = sext i1 %cmp33 to i32 %cond36 = select i1 %cmp30, i32 %cond34, i32 1 %cmp37.not = icmp eq i32 %cond29, 0 - %15 = tail call float @llvm.fabs.f32(float %div) - %16 = fdiv float 1.000000e+00, %15 - %div40 = select i1 %cmp21, float 0x7FF0000000000000, float %16 + %15 = tail call float @llvm.fabs.f32(float %rayDirectionFlatX.0) + %div40 = fdiv float 1.000000e+00, %15 %cond43 = select i1 %cmp37.not, float 0x416312CFE0000000, float %div40 %cmp44.not = icmp eq i32 %cond36, 0 - %17 = tail call float @llvm.fabs.f32(float %div25) - %18 = fdiv float 1.000000e+00, %17 - %div47 = select i1 %cmp21, float 0x7FF0000000000000, float %18 + %16 = tail call float @llvm.fabs.f32(float %rayDirectionFlatZ.0) + %div47 = fdiv float 1.000000e+00, %16 %cond50 = select i1 %cmp44.not, float 0x416312CFE0000000, float %div47 br i1 %cmp37.not, label %if.end79, label %if.then52 @@ -4201,14 +4195,14 @@ if.then52: ; preds = %if.end br i1 %cmp27, label %if.else65, label %if.then54 if.then54: ; preds = %if.then52 - %19 = tail call noundef float @llvm.ceil.f32(float %10) - %sub64 = fsub float %19, %10 + %17 = tail call noundef float @llvm.ceil.f32(float %10) + %sub64 = fsub float %17, %10 %mul = fmul float %div40, %sub64 br label %if.end79 if.else65: ; preds = %if.then52 - %20 = tail call noundef float @llvm.floor.f32(float %10) - %sub75 = fsub float %10, %20 + %18 = tail call noundef float @llvm.floor.f32(float %10) + %sub75 = fsub float %10, %18 %mul76 = fmul float %div40, %sub75 br label %if.end79 @@ -4220,23 +4214,23 @@ if.then81: ; preds = %if.end79 br i1 %cmp30, label %if.else95, label %if.then83 if.then83: ; preds = %if.then81 - %21 = tail call noundef float @llvm.ceil.f32(float %13) - %sub93 = fsub float %21, %13 + %19 = tail call noundef float @llvm.ceil.f32(float %13) + %sub93 = fsub float %19, %13 %mul94 = fmul float %div47, %sub93 br label %if.end109 if.else95: ; preds = %if.then81 - %22 = tail call noundef float @llvm.floor.f32(float %13) - %sub105 = fsub float %13, %22 + %20 = tail call noundef float @llvm.floor.f32(float %13) + %sub105 = fsub float %13, %20 %mul106 = fmul float %div47, %sub105 br label %if.end109 if.end109: ; preds = %if.end79, %if.then83, %if.else95 %paramCrossZ.0 = phi float [ %mul94, %if.then83 ], [ %mul106, %if.else95 ], [ 0x416312CFE0000000, %if.end79 ] - %23 = tail call noundef float @llvm.floor.f32(float %10) - %conv115 = fptosi float %23 to i32 - %24 = tail call noundef float @llvm.floor.f32(float %13) - %conv121 = fptosi float %24 to i32 + %21 = tail call noundef float @llvm.floor.f32(float %10) + %conv115 = fptosi float %21 to i32 + %22 = tail call noundef float @llvm.floor.f32(float %13) + %conv121 = fptosi float %22 to i32 %cmp123 = fcmp oeq float %paramCrossX.0, 0.000000e+00 br i1 %cmp123, label %if.then124, label %if.end130 diff --git a/bench/coreutils-rs/optimized/3hxvjlp3c9mnf678.ll b/bench/coreutils-rs/optimized/3hxvjlp3c9mnf678.ll index d3a3659b6d0..710fae6096f 100644 --- a/bench/coreutils-rs/optimized/3hxvjlp3c9mnf678.ll +++ b/bench/coreutils-rs/optimized/3hxvjlp3c9mnf678.ll @@ -1318,55 +1318,54 @@ define hidden void @"_ZN6uu_fmt9linebreak15build_best_path28_$u7b$$u7b$closure$u ; Function Attrs: mustprogress nofree norecurse nosync nounwind nonlazybind willreturn memory(none) uwtable define hidden { i64, float } @_ZN6uu_fmt9linebreak16compute_demerits17hd10ee69a08f3e8ccE(i64 noundef %0, i64 noundef %1, i64 noundef %2, float noundef %3) unnamed_addr #3 { - %5 = icmp ne i64 %0, 0 + %5 = icmp eq i64 %0, 0 %6 = sitofp i64 %0 to float %7 = uitofp i64 %1 to float %8 = fdiv float %6, %7 - %.0 = select i1 %5, float %8, float 0.000000e+00 - %9 = tail call float @llvm.fabs.f32(float %8) + %.0 = select i1 %5, float 0.000000e+00, float %8 + %9 = tail call float @llvm.fabs.f32(float %.0) %10 = fcmp ogt float %9, 1.000000e+00 - %11 = and i1 %5, %10 - br i1 %11, label %18, label %12 - -12: ; preds = %4 - %13 = tail call float @llvm.powi.f32.i32(float %.0, i32 3) - %14 = tail call float @llvm.fabs.f32(float %13) - %15 = fmul float %14, 1.000000e+02 - %16 = tail call i64 @llvm.fptosi.sat.i64.f32(float %15) - %17 = add i64 %16, 1 - br label %18 - -18: ; preds = %4, %12 - %.013 = phi i64 [ %17, %12 ], [ 10000001, %4 ] + br i1 %10, label %17, label %11 + +11: ; preds = %4 + %12 = tail call float @llvm.powi.f32.i32(float %.0, i32 3) + %13 = tail call float @llvm.fabs.f32(float %12) + %14 = fmul float %13, 1.000000e+02 + %15 = tail call i64 @llvm.fptosi.sat.i64.f32(float %14) + %16 = add i64 %15, 1 + br label %17 + +17: ; preds = %4, %11 + %.013 = phi i64 [ %16, %11 ], [ 10000001, %4 ] %.not = icmp ult i64 %2, %1 - br i1 %.not, label %19, label %"_ZN4core3num21_$LT$impl$u20$i64$GT$3pow17h46f3f76ba4990e7aE.llvm.6876384978452292205.exit" - -19: ; preds = %18 - %20 = sub nuw i64 %1, %2 - %21 = uitofp i64 %20 to float - %22 = add i64 %1, -1 - %23 = uitofp i64 %22 to float - %24 = fdiv float %21, %23 - %25 = tail call float @llvm.powi.f32.i32(float %24, i32 3) - %26 = tail call float @llvm.fabs.f32(float %25) - %27 = fmul float %26, 3.000000e+02 - %28 = tail call i64 @llvm.fptosi.sat.i64.f32(float %27) + br i1 %.not, label %18, label %"_ZN4core3num21_$LT$impl$u20$i64$GT$3pow17h46f3f76ba4990e7aE.llvm.6876384978452292205.exit" + +18: ; preds = %17 + %19 = sub nuw i64 %1, %2 + %20 = uitofp i64 %19 to float + %21 = add i64 %1, -1 + %22 = uitofp i64 %21 to float + %23 = fdiv float %20, %22 + %24 = tail call float @llvm.powi.f32.i32(float %23, i32 3) + %25 = tail call float @llvm.fabs.f32(float %24) + %26 = fmul float %25, 3.000000e+02 + %27 = tail call i64 @llvm.fptosi.sat.i64.f32(float %26) br label %"_ZN4core3num21_$LT$impl$u20$i64$GT$3pow17h46f3f76ba4990e7aE.llvm.6876384978452292205.exit" -"_ZN4core3num21_$LT$impl$u20$i64$GT$3pow17h46f3f76ba4990e7aE.llvm.6876384978452292205.exit": ; preds = %18, %19 - %.012 = phi i64 [ %28, %19 ], [ 0, %18 ] - %29 = fsub float %.0, %3 - %30 = fmul float %29, 5.000000e-01 - %31 = tail call float @llvm.powi.f32.i32(float %30, i32 3) - %32 = tail call float @llvm.fabs.f32(float %31) - %33 = fmul float %32, 6.000000e+02 - %34 = tail call i64 @llvm.fptosi.sat.i64.f32(float %33) - %35 = add i64 %.013, %34 - %36 = add i64 %35, %.012 - %37 = mul i64 %36, %36 - %38 = insertvalue { i64, float } poison, i64 %37, 0 - %39 = insertvalue { i64, float } %38, float %.0, 1 - ret { i64, float } %39 +"_ZN4core3num21_$LT$impl$u20$i64$GT$3pow17h46f3f76ba4990e7aE.llvm.6876384978452292205.exit": ; preds = %17, %18 + %.012 = phi i64 [ %27, %18 ], [ 0, %17 ] + %28 = fsub float %.0, %3 + %29 = fmul float %28, 5.000000e-01 + %30 = tail call float @llvm.powi.f32.i32(float %29, i32 3) + %31 = tail call float @llvm.fabs.f32(float %30) + %32 = fmul float %31, 6.000000e+02 + %33 = tail call i64 @llvm.fptosi.sat.i64.f32(float %32) + %34 = add i64 %.013, %33 + %35 = add i64 %34, %.012 + %36 = mul i64 %35, %35 + %37 = insertvalue { i64, float } poison, i64 %36, 0 + %38 = insertvalue { i64, float } %37, float %.0, 1 + ret { i64, float } %38 } ; Function Attrs: nonlazybind uwtable diff --git a/bench/gromacs/optimized/dlasv2.cpp.ll b/bench/gromacs/optimized/dlasv2.cpp.ll index c8fd1cf7aa7..2eda4f8b26b 100644 --- a/bench/gromacs/optimized/dlasv2.cpp.ll +++ b/bench/gromacs/optimized/dlasv2.cpp.ll @@ -29,7 +29,7 @@ define void @dlasv2_(ptr nocapture noundef readonly %0, ptr nocapture noundef re 20: ; preds = %16 store double %.0152, ptr %3, align 8 store double %.0150, ptr %4, align 8 - br label %87 + br label %86 21: ; preds = %16 %22 = fcmp ogt double %18, %.0150 @@ -66,80 +66,79 @@ define void @dlasv2_(ptr nocapture noundef readonly %0, ptr nocapture noundef re %36 = fadd double %.0150, %33 %37 = tail call noundef double @llvm.fabs.f64(double %36) %38 = fmul double %37, 0x3CB0000000000000 - %39 = fcmp uge double %35, %38 + %39 = fcmp olt double %35, %38 %40 = fdiv double %33, %.0150 - %.0136 = select i1 %39, double %40, double 1.000000e+00 + %.0136 = select i1 %39, double 1.000000e+00, double %40 %41 = fdiv double %17, %.0153 %42 = fsub double 2.000000e+00, %.0136 %43 = fmul double %41, %41 %44 = fmul double %42, %42 %45 = fadd double %43, %44 %sqrt = tail call double @llvm.sqrt.f64(double %45) - %46 = tail call double @llvm.fabs.f64(double %40) + %46 = tail call noundef double @llvm.fabs.f64(double %.0136) %47 = fcmp olt double %46, 0x10000000000000 - %48 = and i1 %47, %39 - %49 = tail call double @llvm.fabs.f64(double %41) - %50 = tail call double @llvm.fmuladd.f64(double %.0136, double %.0136, double %43) - %sqrt174 = tail call double @llvm.sqrt.f64(double %50) - %.0137 = select i1 %48, double %49, double %sqrt174 - %51 = fadd double %.0137, %sqrt - %52 = fmul double %51, 5.000000e-01 - %53 = fdiv double %.0152, %52 - store double %53, ptr %3, align 8 - %54 = fmul double %.0150, %52 - store double %54, ptr %4, align 8 - %55 = tail call noundef double @llvm.fabs.f64(double %43) - %56 = fcmp olt double %55, 0x10000000000000 - br i1 %56, label %57, label %70 - -57: ; preds = %32 - %58 = fcmp ogt double %.0153, 0.000000e+00 - br i1 %48, label %59, label %64 - -59: ; preds = %57 - %60 = select i1 %58, double 2.000000e+00, double -2.000000e+00 - %61 = fcmp ogt double %17, 0.000000e+00 - %62 = fneg double %60 - %63 = select i1 %61, double %60, double %62 - br label %78 - -64: ; preds = %57 - %65 = fneg double %33 - %66 = select i1 %58, double %33, double %65 - %67 = fdiv double %17, %66 - %68 = fdiv double %41, %42 - %69 = fadd double %67, %68 - br label %78 - -70: ; preds = %32 - %71 = fadd double %42, %sqrt - %72 = fdiv double %41, %71 - %73 = fadd double %.0136, %.0137 - %74 = fdiv double %41, %73 - %75 = fadd double %74, %72 - %76 = fadd double %52, 1.000000e+00 - %77 = fmul double %75, %76 - br label %78 - -78: ; preds = %59, %64, %70 - %.0149 = phi double [ %63, %59 ], [ %69, %64 ], [ %77, %70 ] - %79 = tail call double @llvm.fmuladd.f64(double %.0149, double %.0149, double 4.000000e+00) - %sqrt175 = tail call double @llvm.sqrt.f64(double %79) - %80 = fdiv double 2.000000e+00, %sqrt175 - %81 = fdiv double %.0149, %sqrt175 - %82 = tail call double @llvm.fmuladd.f64(double %81, double %41, double %80) - %83 = fdiv double %82, %52 - %84 = fdiv double %.0151, %.0153 - %85 = fmul double %84, %81 - %86 = fdiv double %85, %52 - br label %87 - -87: ; preds = %78, %20 - %.0147 = phi double [ 1.000000e+00, %20 ], [ %83, %78 ] - %.0145 = phi double [ 1.000000e+00, %20 ], [ %80, %78 ] - %.0143 = phi double [ 0.000000e+00, %20 ], [ %86, %78 ] - %.0141 = phi double [ 0.000000e+00, %20 ], [ %81, %78 ] - %.1139 = phi i32 [ %.0138, %20 ], [ %.2140.ph, %78 ] + %48 = tail call double @llvm.fabs.f64(double %41) + %49 = tail call double @llvm.fmuladd.f64(double %.0136, double %.0136, double %43) + %sqrt174 = tail call double @llvm.sqrt.f64(double %49) + %.0137 = select i1 %47, double %48, double %sqrt174 + %50 = fadd double %.0137, %sqrt + %51 = fmul double %50, 5.000000e-01 + %52 = fdiv double %.0152, %51 + store double %52, ptr %3, align 8 + %53 = fmul double %.0150, %51 + store double %53, ptr %4, align 8 + %54 = tail call noundef double @llvm.fabs.f64(double %43) + %55 = fcmp olt double %54, 0x10000000000000 + br i1 %55, label %56, label %69 + +56: ; preds = %32 + %57 = fcmp ogt double %.0153, 0.000000e+00 + br i1 %47, label %58, label %63 + +58: ; preds = %56 + %59 = select i1 %57, double 2.000000e+00, double -2.000000e+00 + %60 = fcmp ogt double %17, 0.000000e+00 + %61 = fneg double %59 + %62 = select i1 %60, double %59, double %61 + br label %77 + +63: ; preds = %56 + %64 = fneg double %33 + %65 = select i1 %57, double %33, double %64 + %66 = fdiv double %17, %65 + %67 = fdiv double %41, %42 + %68 = fadd double %66, %67 + br label %77 + +69: ; preds = %32 + %70 = fadd double %42, %sqrt + %71 = fdiv double %41, %70 + %72 = fadd double %.0136, %.0137 + %73 = fdiv double %41, %72 + %74 = fadd double %73, %71 + %75 = fadd double %51, 1.000000e+00 + %76 = fmul double %74, %75 + br label %77 + +77: ; preds = %58, %63, %69 + %.0149 = phi double [ %62, %58 ], [ %68, %63 ], [ %76, %69 ] + %78 = tail call double @llvm.fmuladd.f64(double %.0149, double %.0149, double 4.000000e+00) + %sqrt175 = tail call double @llvm.sqrt.f64(double %78) + %79 = fdiv double 2.000000e+00, %sqrt175 + %80 = fdiv double %.0149, %sqrt175 + %81 = tail call double @llvm.fmuladd.f64(double %80, double %41, double %79) + %82 = fdiv double %81, %51 + %83 = fdiv double %.0151, %.0153 + %84 = fmul double %83, %80 + %85 = fdiv double %84, %51 + br label %86 + +86: ; preds = %77, %20 + %.0147 = phi double [ 1.000000e+00, %20 ], [ %82, %77 ] + %.0145 = phi double [ 1.000000e+00, %20 ], [ %79, %77 ] + %.0143 = phi double [ 0.000000e+00, %20 ], [ %85, %77 ] + %.0141 = phi double [ 0.000000e+00, %20 ], [ %80, %77 ] + %.1139 = phi i32 [ %.0138, %20 ], [ %.2140.ph, %77 ] %.0141..0147 = select i1 %14, double %.0141, double %.0147 %.0145..0143 = select i1 %14, double %.0145, double %.0143 %.0143..0145 = select i1 %14, double %.0143, double %.0145 @@ -148,60 +147,60 @@ define void @dlasv2_(ptr nocapture noundef readonly %0, ptr nocapture noundef re store double %.0145..0143, ptr %7, align 8 store double %.0143..0145, ptr %6, align 8 store double %.0147..0141, ptr %5, align 8 - switch i32 %.1139, label %89 [ + switch i32 %.1139, label %88 [ i32 1, label %.thread169 i32 2, label %.thread172 ] -.thread169: ; preds = %87 - %88 = load double, ptr %6, align 8 +.thread169: ; preds = %86 + %87 = load double, ptr %6, align 8 br label %.thread172 -89: ; preds = %87 +88: ; preds = %86 br label %.thread172 -.thread172: ; preds = %87, %.thread, %.thread169, %89 - %.0147..0141185.sink = phi double [ %88, %.thread169 ], [ %.0147..0141, %89 ], [ 1.000000e+00, %.thread ], [ %.0147..0141, %87 ] - %.sink196 = phi ptr [ %8, %.thread169 ], [ %7, %89 ], [ %8, %.thread ], [ %8, %87 ] - %.sink = phi ptr [ %0, %.thread169 ], [ %2, %89 ], [ %1, %.thread ], [ %1, %87 ] - %90 = fcmp ogt double %.0147..0141185.sink, 0.000000e+00 - %91 = load double, ptr %.sink196, align 8 - %92 = fcmp ogt double %91, 0.000000e+00 - %93 = select i1 %92, double 1.000000e+00, double -1.000000e+00 - %94 = fneg double %93 - %95 = select i1 %90, double %93, double %94 - %96 = load double, ptr %.sink, align 8 - %97 = fcmp ogt double %96, 0.000000e+00 - %98 = fneg double %95 - %99 = select i1 %97, double %95, double %98 - %100 = fcmp olt double %99, 0.000000e+00 - br i1 %100, label %101, label %104 - -101: ; preds = %.thread172 - %102 = load double, ptr %4, align 8 - %103 = fneg double %102 - store double %103, ptr %4, align 8 - br label %104 - -104: ; preds = %101, %.thread172 - %105 = load double, ptr %0, align 8 - %106 = fcmp ogt double %105, 0.000000e+00 - %107 = fneg double %99 - %108 = select i1 %106, double %99, double %107 - %109 = load double, ptr %2, align 8 - %110 = fcmp ogt double %109, 0.000000e+00 - %111 = fneg double %108 - %112 = select i1 %110, double %108, double %111 - %113 = fcmp olt double %112, 0.000000e+00 - br i1 %113, label %114, label %117 - -114: ; preds = %104 - %115 = load double, ptr %3, align 8 - %116 = fneg double %115 - store double %116, ptr %3, align 8 - br label %117 - -117: ; preds = %114, %104 +.thread172: ; preds = %86, %.thread, %.thread169, %88 + %.0147..0141185.sink = phi double [ %87, %.thread169 ], [ %.0147..0141, %88 ], [ 1.000000e+00, %.thread ], [ %.0147..0141, %86 ] + %.sink196 = phi ptr [ %8, %.thread169 ], [ %7, %88 ], [ %8, %.thread ], [ %8, %86 ] + %.sink = phi ptr [ %0, %.thread169 ], [ %2, %88 ], [ %1, %.thread ], [ %1, %86 ] + %89 = fcmp ogt double %.0147..0141185.sink, 0.000000e+00 + %90 = load double, ptr %.sink196, align 8 + %91 = fcmp ogt double %90, 0.000000e+00 + %92 = select i1 %91, double 1.000000e+00, double -1.000000e+00 + %93 = fneg double %92 + %94 = select i1 %89, double %92, double %93 + %95 = load double, ptr %.sink, align 8 + %96 = fcmp ogt double %95, 0.000000e+00 + %97 = fneg double %94 + %98 = select i1 %96, double %94, double %97 + %99 = fcmp olt double %98, 0.000000e+00 + br i1 %99, label %100, label %103 + +100: ; preds = %.thread172 + %101 = load double, ptr %4, align 8 + %102 = fneg double %101 + store double %102, ptr %4, align 8 + br label %103 + +103: ; preds = %100, %.thread172 + %104 = load double, ptr %0, align 8 + %105 = fcmp ogt double %104, 0.000000e+00 + %106 = fneg double %98 + %107 = select i1 %105, double %98, double %106 + %108 = load double, ptr %2, align 8 + %109 = fcmp ogt double %108, 0.000000e+00 + %110 = fneg double %107 + %111 = select i1 %109, double %107, double %110 + %112 = fcmp olt double %111, 0.000000e+00 + br i1 %112, label %113, label %116 + +113: ; preds = %103 + %114 = load double, ptr %3, align 8 + %115 = fneg double %114 + store double %115, ptr %3, align 8 + br label %116 + +116: ; preds = %113, %103 ret void } diff --git a/bench/gromacs/optimized/lmmin.cpp.ll b/bench/gromacs/optimized/lmmin.cpp.ll index 0c7f8fdda20..01a0d91c004 100644 --- a/bench/gromacs/optimized/lmmin.cpp.ll +++ b/bench/gromacs/optimized/lmmin.cpp.ll @@ -106,7 +106,7 @@ define void @_Z6lmmin2iPdS_S_iPKdPKvPFvS1_iS3_S_PiEPK17lm_control_structP16lm_st %31 = load ptr, ptr @stderr, align 8 %32 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %31, ptr noundef nonnull @.str.28, i32 noundef %0) #11 store i32 10, ptr %26, align 4 - br label %1157 + br label %1156 33: ; preds = %10 %34 = icmp slt i32 %4, %0 @@ -116,7 +116,7 @@ define void @_Z6lmmin2iPdS_S_iPKdPKvPFvS1_iS3_S_PiEPK17lm_control_structP16lm_st %36 = load ptr, ptr @stderr, align 8 %37 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %36, ptr noundef nonnull @.str.29, i32 noundef %4, i32 noundef %0) #11 store i32 10, ptr %26, align 4 - br label %1157 + br label %1156 38: ; preds = %33 %39 = load double, ptr %8, align 8 @@ -139,7 +139,7 @@ define void @_Z6lmmin2iPdS_S_iPKdPKvPFvS1_iS3_S_PiEPK17lm_control_structP16lm_st %48 = load double, ptr %47, align 8 %49 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %46, ptr noundef nonnull @.str.30, double noundef %39, double noundef %.pre1155, double noundef %48) #11 store i32 10, ptr %26, align 4 - br label %1157 + br label %1156 50: ; preds = %42 %51 = icmp slt i32 %14, 1 @@ -149,7 +149,7 @@ define void @_Z6lmmin2iPdS_S_iPKdPKvPFvS1_iS3_S_PiEPK17lm_control_structP16lm_st %53 = load ptr, ptr @stderr, align 8 %54 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %53, ptr noundef nonnull @.str.31, i32 noundef %14) #11 store i32 10, ptr %26, align 4 - br label %1157 + br label %1156 55: ; preds = %50 %56 = getelementptr inbounds nuw i8, ptr %8, i64 32 @@ -161,7 +161,7 @@ define void @_Z6lmmin2iPdS_S_iPKdPKvPFvS1_iS3_S_PiEPK17lm_control_structP16lm_st %60 = load ptr, ptr @stderr, align 8 %61 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %60, ptr noundef nonnull @.str.32, double noundef %57) #11 store i32 10, ptr %26, align 4 - br label %1157 + br label %1156 62: ; preds = %55 %63 = getelementptr inbounds nuw i8, ptr %8, i64 44 @@ -173,7 +173,7 @@ define void @_Z6lmmin2iPdS_S_iPKdPKvPFvS1_iS3_S_PiEPK17lm_control_structP16lm_st %66 = load ptr, ptr @stderr, align 8 %67 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %66, ptr noundef nonnull @.str.33, i32 noundef %64) #11 store i32 10, ptr %26, align 4 - br label %1157 + br label %1156 68: ; preds = %62 %69 = shl nuw nsw i32 %4, 1 @@ -192,7 +192,7 @@ define void @_Z6lmmin2iPdS_S_iPKdPKvPFvS1_iS3_S_PiEPK17lm_control_structP16lm_st 81: ; preds = %68 store i32 9, ptr %26, align 4 - br label %1157 + br label %1156 82: ; preds = %68 %83 = zext nneg i32 %4 to i64 @@ -354,12 +354,12 @@ _ZL13lm_print_parsiPKdP8_IO_FILE.exit: ; preds = %.lr.ph.i, %106 %wide.trip.count1125 = zext nneg i32 %21 to i64 br label %.lr.ph861.preheader -.lr.ph861.preheader: ; preds = %1114, %.preheader804 - %.0767 = phi double [ %.2769, %1114 ], [ 0.000000e+00, %.preheader804 ] - %.1622 = phi double [ %.5626, %1114 ], [ 0.000000e+00, %.preheader804 ] - %.0615 = phi double [ %.5620, %1114 ], [ 0.000000e+00, %.preheader804 ] - %.0606 = phi double [ %.2608, %1114 ], [ %132, %.preheader804 ] - %.0591 = phi i32 [ %1115, %1114 ], [ 0, %.preheader804 ] +.lr.ph861.preheader: ; preds = %1113, %.preheader804 + %.0767 = phi double [ %.2769, %1113 ], [ 0.000000e+00, %.preheader804 ] + %.1622 = phi double [ %.5626, %1113 ], [ 0.000000e+00, %.preheader804 ] + %.0615 = phi double [ %.5620, %1113 ], [ 0.000000e+00, %.preheader804 ] + %.0606 = phi double [ %.2608, %1113 ], [ %132, %.preheader804 ] + %.0591 = phi i32 [ %1114, %1113 ], [ 0, %.preheader804 ] br label %.lr.ph861 .lr.ph861: ; preds = %.lr.ph861.preheader, %._crit_edge @@ -682,12 +682,12 @@ _ZL13lm_print_parsiPKdP8_IO_FILE.exit: ; preds = %.lr.ph.i, %106 %264 = fcmp ole double %.1610, 0x3CB0000000000000 br label %265 -265: ; preds = %1112, %.loopexit796 - %.1768 = phi double [ %.0767, %.loopexit796 ], [ %.2769, %1112 ] - %.4625 = phi double [ %.3624, %.loopexit796 ], [ %.5626, %1112 ] - %.3618 = phi double [ %.2617, %.loopexit796 ], [ %.5620, %1112 ] - %.1607 = phi double [ %.0606, %.loopexit796 ], [ %.2608, %1112 ] - %.0 = phi i32 [ 0, %.loopexit796 ], [ %1113, %1112 ] +265: ; preds = %1111, %.loopexit796 + %.1768 = phi double [ %.0767, %.loopexit796 ], [ %.2769, %1111 ] + %.4625 = phi double [ %.3624, %.loopexit796 ], [ %.5626, %1111 ] + %.3618 = phi double [ %.2617, %.loopexit796 ], [ %.5620, %1111 ] + %.1607 = phi double [ %.0606, %.loopexit796 ], [ %.2608, %1111 ] + %.0 = phi i32 [ 0, %.loopexit796 ], [ %1112, %1111 ] br label %276 .preheader371.i: ; preds = %289 @@ -2456,185 +2456,184 @@ _Z8lm_enormiPKd.exit752: ; preds = %975, %985, %991, %. br i1 %1088, label %1089, label %.loopexit792 1089: ; preds = %1087 - %1090 = tail call double @llvm.fabs.f64(double %1024) - %1091 = select i1 %1021, double %1090, double 1.000000e+00 - %1092 = load double, ptr %8, align 8 - %1093 = fcmp ugt double %1091, %1092 - br i1 %1093, label %1098, label %1094 - -1094: ; preds = %1089 - %1095 = fcmp ole double %1004, %1092 - %1096 = fcmp ole double %1027, 2.000000e+00 - %or.cond5 = select i1 %1095, i1 %1096, i1 false - br i1 %or.cond5, label %1097, label %1098 - -1097: ; preds = %1094 + %1090 = tail call double @llvm.fabs.f64(double %.0605) + %1091 = load double, ptr %8, align 8 + %1092 = fcmp ugt double %1090, %1091 + br i1 %1092, label %1097, label %1093 + +1093: ; preds = %1089 + %1094 = fcmp ole double %1004, %1091 + %1095 = fcmp ole double %1027, 2.000000e+00 + %or.cond5 = select i1 %1094, i1 %1095, i1 false + br i1 %or.cond5, label %1096, label %1097 + +1096: ; preds = %1093 store i32 1, ptr %26, align 4 - br label %1098 - -1098: ; preds = %1097, %1094, %1089 - %1099 = phi i1 [ false, %1097 ], [ true, %1094 ], [ true, %1089 ] - %.pr = phi i32 [ 3, %1097 ], [ 2, %1094 ], [ 2, %1089 ] - %1100 = load double, ptr %.phi.trans.insert, align 8 - %1101 = fmul double %.5626, %1100 - %1102 = fcmp ugt double %.5620, %1101 - br i1 %1102, label %thread-pre-split, label %.loopexit792.sink.split - -thread-pre-split: ; preds = %1098 - br i1 %1099, label %1103, label %.loopexit792 - -1103: ; preds = %thread-pre-split - %1104 = load i32, ptr %28, align 8 - %.not681 = icmp slt i32 %1104, %14 - br i1 %.not681, label %1105, label %.loopexit792.sink.split - -1105: ; preds = %1103 - %1106 = fcmp ole double %1091, 0x3CB0000000000000 - %1107 = fcmp ole double %1004, 0x3CB0000000000000 - %or.cond7 = select i1 %1106, i1 %1107, i1 false - %1108 = fcmp ole double %1027, 2.000000e+00 - %or.cond9 = select i1 %or.cond7, i1 %1108, i1 false - br i1 %or.cond9, label %.loopexit792.sink.split, label %1109 - -1109: ; preds = %1105 - %1110 = fmul double %.5626, 0x3CB0000000000000 - %1111 = fcmp ole double %.5620, %1110 - %brmerge = or i1 %1111, %264 - br i1 %brmerge, label %.loopexit792.sink.split.loopexit.split.loop.exit1331, label %1112 - -1112: ; preds = %1109 - %1113 = add nuw nsw i32 %.0, 1 - br i1 %1070, label %265, label %1114, !llvm.loop !57 - -1114: ; preds = %1112 - %1115 = add nuw nsw i32 %.0591, 1 + br label %1097 + +1097: ; preds = %1096, %1093, %1089 + %1098 = phi i1 [ false, %1096 ], [ true, %1093 ], [ true, %1089 ] + %.pr = phi i32 [ 3, %1096 ], [ 2, %1093 ], [ 2, %1089 ] + %1099 = load double, ptr %.phi.trans.insert, align 8 + %1100 = fmul double %.5626, %1099 + %1101 = fcmp ugt double %.5620, %1100 + br i1 %1101, label %thread-pre-split, label %.loopexit792.sink.split + +thread-pre-split: ; preds = %1097 + br i1 %1098, label %1102, label %.loopexit792 + +1102: ; preds = %thread-pre-split + %1103 = load i32, ptr %28, align 8 + %.not681 = icmp slt i32 %1103, %14 + br i1 %.not681, label %1104, label %.loopexit792.sink.split + +1104: ; preds = %1102 + %1105 = fcmp ole double %1090, 0x3CB0000000000000 + %1106 = fcmp ole double %1004, 0x3CB0000000000000 + %or.cond7 = select i1 %1105, i1 %1106, i1 false + %1107 = fcmp ole double %1027, 2.000000e+00 + %or.cond9 = select i1 %or.cond7, i1 %1107, i1 false + br i1 %or.cond9, label %.loopexit792.sink.split, label %1108 + +1108: ; preds = %1104 + %1109 = fmul double %.5626, 0x3CB0000000000000 + %1110 = fcmp ole double %.5620, %1109 + %brmerge = or i1 %1110, %264 + br i1 %brmerge, label %.loopexit792.sink.split.loopexit.split.loop.exit1331, label %1111 + +1111: ; preds = %1108 + %1112 = add nuw nsw i32 %.0, 1 + br i1 %1070, label %265, label %1113, !llvm.loop !57 + +1113: ; preds = %1111 + %1114 = add nuw nsw i32 %.0591, 1 br label %.lr.ph861.preheader, !llvm.loop !58 .loopexit792.sink.split.sink.split: ; preds = %1085, %1002, %872, %247, %140 %.str.50.sink = phi ptr [ @.str.38, %140 ], [ @.str.43, %247 ], [ @.str.46, %872 ], [ @.str.47, %1002 ], [ @.str.50, %1085 ] %.0621.ph.ph = phi double [ 0.000000e+00, %140 ], [ %244, %247 ], [ %.4625, %872 ], [ %.4625, %1002 ], [ %1082, %1085 ] - %1116 = tail call i64 @fwrite(ptr nonnull %.str.50.sink, i64 11, i64 1, ptr %25) + %1115 = tail call i64 @fwrite(ptr nonnull %.str.50.sink, i64 11, i64 1, ptr %25) br label %.loopexit792.sink.split -.loopexit792.sink.split.loopexit.split.loop.exit1331: ; preds = %1109 - %.mux.le = select i1 %1111, i32 7, i32 8 +.loopexit792.sink.split.loopexit.split.loop.exit1331: ; preds = %1108 + %.mux.le = select i1 %1110, i32 7, i32 8 br label %.loopexit792.sink.split -.loopexit792.sink.split: ; preds = %._crit_edge890, %.loopexit792.sink.split.loopexit.split.loop.exit1331, %1098, %1103, %1105, %.loopexit792.sink.split.sink.split, %1085, %1002, %872, %247, %142, %140, %129 - %.pr.lcssa.sink = phi i32 [ 13, %129 ], [ 12, %140 ], [ 0, %142 ], [ 12, %247 ], [ 12, %872 ], [ 12, %1002 ], [ 12, %1085 ], [ 12, %.loopexit792.sink.split.sink.split ], [ %.mux.le, %.loopexit792.sink.split.loopexit.split.loop.exit1331 ], [ %.pr, %1098 ], [ 5, %1103 ], [ 6, %1105 ], [ 4, %._crit_edge890 ] - %.0621.ph = phi double [ 0.000000e+00, %129 ], [ 0.000000e+00, %140 ], [ 0.000000e+00, %142 ], [ %244, %247 ], [ %.4625, %872 ], [ %.4625, %1002 ], [ %1082, %1085 ], [ %.0621.ph.ph, %.loopexit792.sink.split.sink.split ], [ %.5626, %1105 ], [ %.5626, %1103 ], [ %.5626, %1098 ], [ %.5626, %.loopexit792.sink.split.loopexit.split.loop.exit1331 ], [ %.1622, %._crit_edge890 ] +.loopexit792.sink.split: ; preds = %._crit_edge890, %.loopexit792.sink.split.loopexit.split.loop.exit1331, %1097, %1102, %1104, %.loopexit792.sink.split.sink.split, %1085, %1002, %872, %247, %142, %140, %129 + %.pr.lcssa.sink = phi i32 [ 13, %129 ], [ 12, %140 ], [ 0, %142 ], [ 12, %247 ], [ 12, %872 ], [ 12, %1002 ], [ 12, %1085 ], [ 12, %.loopexit792.sink.split.sink.split ], [ %.mux.le, %.loopexit792.sink.split.loopexit.split.loop.exit1331 ], [ %.pr, %1097 ], [ 5, %1102 ], [ 6, %1104 ], [ 4, %._crit_edge890 ] + %.0621.ph = phi double [ 0.000000e+00, %129 ], [ 0.000000e+00, %140 ], [ 0.000000e+00, %142 ], [ %244, %247 ], [ %.4625, %872 ], [ %.4625, %1002 ], [ %1082, %1085 ], [ %.0621.ph.ph, %.loopexit792.sink.split.sink.split ], [ %.5626, %1104 ], [ %.5626, %1102 ], [ %.5626, %1097 ], [ %.5626, %.loopexit792.sink.split.loopexit.split.loop.exit1331 ], [ %.1622, %._crit_edge890 ] store i32 %.pr.lcssa.sink, ptr %26, align 4 br label %.loopexit792 .loopexit792: ; preds = %.lr.ph861, %thread-pre-split, %1087, %._crit_edge914, %.loopexit792.sink.split, %.loopexit806 %.0621 = phi double [ 0.000000e+00, %.loopexit806 ], [ %.0621.ph, %.loopexit792.sink.split ], [ %.5626, %thread-pre-split ], [ %.5626, %1087 ], [ %.4625, %._crit_edge914 ], [ %.1622, %.lr.ph861 ] - %1117 = tail call noundef double @_Z8lm_fnormiPKdS0_(i32 noundef %4, ptr noundef nonnull %79, ptr noundef %5) - store double %1117, ptr %9, align 8 - %1118 = load i32, ptr %27, align 8 - %.not686 = icmp eq i32 %1118, 0 - br i1 %.not686, label %1120, label %1119 + %1116 = tail call noundef double @_Z8lm_fnormiPKdS0_(i32 noundef %4, ptr noundef nonnull %79, ptr noundef %5) + store double %1116, ptr %9, align 8 + %1117 = load i32, ptr %27, align 8 + %.not686 = icmp eq i32 %1117, 0 + br i1 %.not686, label %1119, label %1118 -1119: ; preds = %.loopexit792 +1118: ; preds = %.loopexit792 store i32 11, ptr %26, align 4 - br label %1120 + br label %1119 -1120: ; preds = %1119, %.loopexit792 - %1121 = load i32, ptr %98, align 8 - %1122 = and i32 %1121, 1 - %.not687 = icmp eq i32 %1122, 0 - br i1 %.not687, label %1126, label %1123 +1119: ; preds = %1118, %.loopexit792 + %1120 = load i32, ptr %98, align 8 + %1121 = and i32 %1120, 1 + %.not687 = icmp eq i32 %1121, 0 + br i1 %.not687, label %1125, label %1122 -1123: ; preds = %1120 - %1124 = load i32, ptr %26, align 4 - %1125 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %25, ptr noundef nonnull @.str.51, i32 noundef %1124) #13 +1122: ; preds = %1119 + %1123 = load i32, ptr %26, align 4 + %1124 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %25, ptr noundef nonnull @.str.51, i32 noundef %1123) #13 %.pre1152 = load i32, ptr %98, align 8 - br label %1126 + br label %1125 -1126: ; preds = %1123, %1120 - %1127 = phi i32 [ %.pre1152, %1123 ], [ %1121, %1120 ] - %1128 = and i32 %1127, 2 - %.not688 = icmp eq i32 %1128, 0 - br i1 %.not688, label %1135, label %1129 +1125: ; preds = %1122, %1119 + %1126 = phi i32 [ %.pre1152, %1122 ], [ %1120, %1119 ] + %1127 = and i32 %1126, 2 + %.not688 = icmp eq i32 %1127, 0 + br i1 %.not688, label %1134, label %1128 -1129: ; preds = %1126 - %1130 = tail call i64 @fwrite(ptr nonnull @.str.53, i64 7, i64 1, ptr %25) - %1131 = icmp sgt i32 %21, 0 - br i1 %1131, label %.lr.ph.preheader.i755, label %_ZL13lm_print_parsiPKdP8_IO_FILE.exit761 +1128: ; preds = %1125 + %1129 = tail call i64 @fwrite(ptr nonnull @.str.53, i64 7, i64 1, ptr %25) + %1130 = icmp sgt i32 %21, 0 + br i1 %1130, label %.lr.ph.preheader.i755, label %_ZL13lm_print_parsiPKdP8_IO_FILE.exit761 -.lr.ph.preheader.i755: ; preds = %1129 +.lr.ph.preheader.i755: ; preds = %1128 %wide.trip.count.i756 = zext nneg i32 %21 to i64 br label %.lr.ph.i757 .lr.ph.i757: ; preds = %.lr.ph.i757, %.lr.ph.preheader.i755 %indvars.iv.i758 = phi i64 [ 0, %.lr.ph.preheader.i755 ], [ %indvars.iv.next.i759, %.lr.ph.i757 ] - %1132 = getelementptr inbounds nuw double, ptr %1, i64 %indvars.iv.i758 - %1133 = load double, ptr %1132, align 8 - %1134 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %25, ptr noundef nonnull @.str.54, double noundef %1133) #13 + %1131 = getelementptr inbounds nuw double, ptr %1, i64 %indvars.iv.i758 + %1132 = load double, ptr %1131, align 8 + %1133 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %25, ptr noundef nonnull @.str.54, double noundef %1132) #13 %indvars.iv.next.i759 = add nuw nsw i64 %indvars.iv.i758, 1 %exitcond.not.i760 = icmp eq i64 %indvars.iv.next.i759, %wide.trip.count.i756 br i1 %exitcond.not.i760, label %_ZL13lm_print_parsiPKdP8_IO_FILE.exit761, label %.lr.ph.i757, !llvm.loop !6 -_ZL13lm_print_parsiPKdP8_IO_FILE.exit761: ; preds = %.lr.ph.i757, %1129 +_ZL13lm_print_parsiPKdP8_IO_FILE.exit761: ; preds = %.lr.ph.i757, %1128 %fputc.i754 = tail call i32 @fputc(i32 10, ptr %25) %.pre1153 = load i32, ptr %98, align 8 - br label %1135 + br label %1134 -1135: ; preds = %_ZL13lm_print_parsiPKdP8_IO_FILE.exit761, %1126 - %1136 = phi i32 [ %.pre1153, %_ZL13lm_print_parsiPKdP8_IO_FILE.exit761 ], [ %1127, %1126 ] - %1137 = and i32 %1136, 8 - %.not689 = icmp eq i32 %1137, 0 - br i1 %.not689, label %.loopexit, label %1138 +1134: ; preds = %_ZL13lm_print_parsiPKdP8_IO_FILE.exit761, %1125 + %1135 = phi i32 [ %.pre1153, %_ZL13lm_print_parsiPKdP8_IO_FILE.exit761 ], [ %1126, %1125 ] + %1136 = and i32 %1135, 8 + %.not689 = icmp eq i32 %1136, 0 + br i1 %.not689, label %.loopexit, label %1137 -1138: ; preds = %1135 +1137: ; preds = %1134 %.not690 = icmp eq ptr %5, null - %1139 = icmp sgt i32 %4, 0 + %1138 = icmp sgt i32 %4, 0 br i1 %.not690, label %.preheader, label %.preheader778 -.preheader778: ; preds = %1138 - br i1 %1139, label %.lr.ph932, label %.loopexit +.preheader778: ; preds = %1137 + br i1 %1138, label %.lr.ph932, label %.loopexit -.preheader: ; preds = %1138 - br i1 %1139, label %.lr.ph934, label %.loopexit +.preheader: ; preds = %1137 + br i1 %1138, label %.lr.ph934, label %.loopexit .lr.ph932: ; preds = %.preheader778, %.lr.ph932 %indvars.iv1142 = phi i64 [ %indvars.iv.next1143, %.lr.ph932 ], [ 0, %.preheader778 ] - %1140 = getelementptr inbounds nuw double, ptr %79, i64 %indvars.iv1142 - %1141 = load double, ptr %1140, align 8 - %1142 = getelementptr inbounds nuw double, ptr %5, i64 %indvars.iv1142 - %1143 = load double, ptr %1142, align 8 - %1144 = fsub double %1143, %1141 - %1145 = trunc nuw nsw i64 %indvars.iv1142 to i32 - %1146 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %25, ptr noundef nonnull @.str.35, i32 noundef %1145, double noundef %1141, double noundef %1144) #13 + %1139 = getelementptr inbounds nuw double, ptr %79, i64 %indvars.iv1142 + %1140 = load double, ptr %1139, align 8 + %1141 = getelementptr inbounds nuw double, ptr %5, i64 %indvars.iv1142 + %1142 = load double, ptr %1141, align 8 + %1143 = fsub double %1142, %1140 + %1144 = trunc nuw nsw i64 %indvars.iv1142 to i32 + %1145 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %25, ptr noundef nonnull @.str.35, i32 noundef %1144, double noundef %1140, double noundef %1143) #13 %indvars.iv.next1143 = add nuw nsw i64 %indvars.iv1142, 1 %exitcond1146.not = icmp eq i64 %indvars.iv.next1143, %83 br i1 %exitcond1146.not, label %.loopexit, label %.lr.ph932, !llvm.loop !59 .lr.ph934: ; preds = %.preheader, %.lr.ph934 %indvars.iv1147 = phi i64 [ %indvars.iv.next1148, %.lr.ph934 ], [ 0, %.preheader ] - %1147 = getelementptr inbounds nuw double, ptr %79, i64 %indvars.iv1147 - %1148 = load double, ptr %1147, align 8 - %1149 = trunc nuw nsw i64 %indvars.iv1147 to i32 - %1150 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %25, ptr noundef nonnull @.str.36, i32 noundef %1149, double noundef %1148) #13 + %1146 = getelementptr inbounds nuw double, ptr %79, i64 %indvars.iv1147 + %1147 = load double, ptr %1146, align 8 + %1148 = trunc nuw nsw i64 %indvars.iv1147 to i32 + %1149 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %25, ptr noundef nonnull @.str.36, i32 noundef %1148, double noundef %1147) #13 %indvars.iv.next1148 = add nuw nsw i64 %indvars.iv1147, 1 %exitcond1151.not = icmp eq i64 %indvars.iv.next1148, %83 br i1 %exitcond1151.not, label %.loopexit, label %.lr.ph934, !llvm.loop !60 -.loopexit: ; preds = %.lr.ph932, %.lr.ph934, %.preheader778, %.preheader, %1135 - %1151 = load i32, ptr %98, align 8 - %1152 = and i32 %1151, 2 - %.not691 = icmp eq i32 %1152, 0 - br i1 %.not691, label %1156, label %1153 +.loopexit: ; preds = %.lr.ph932, %.lr.ph934, %.preheader778, %.preheader, %1134 + %1150 = load i32, ptr %98, align 8 + %1151 = and i32 %1150, 2 + %.not691 = icmp eq i32 %1151, 0 + br i1 %.not691, label %1155, label %1152 -1153: ; preds = %.loopexit - %1154 = load double, ptr %9, align 8 - %1155 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %25, ptr noundef nonnull @.str.52, double noundef %1154, double noundef %.0621) #13 - br label %1156 +1152: ; preds = %.loopexit + %1153 = load double, ptr %9, align 8 + %1154 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %25, ptr noundef nonnull @.str.52, double noundef %1153, double noundef %.0621) #13 + br label %1155 -1156: ; preds = %1153, %.loopexit +1155: ; preds = %1152, %.loopexit tail call void @free(ptr noundef %79) #13 - br label %1157 + br label %1156 -1157: ; preds = %1156, %81, %65, %59, %52, %._crit_edge1154, %35, %30 +1156: ; preds = %1155, %81, %65, %59, %52, %._crit_edge1154, %35, %30 ret void } diff --git a/bench/gromacs/optimized/slasv2.cpp.ll b/bench/gromacs/optimized/slasv2.cpp.ll index 6a67cc73ad5..be39b996ab6 100644 --- a/bench/gromacs/optimized/slasv2.cpp.ll +++ b/bench/gromacs/optimized/slasv2.cpp.ll @@ -29,7 +29,7 @@ define void @slasv2_(ptr nocapture noundef readonly %0, ptr nocapture noundef re 20: ; preds = %16 store float %.0152, ptr %3, align 4 store float %.0150, ptr %4, align 4 - br label %94 + br label %93 21: ; preds = %16 %22 = fcmp ogt float %18, %.0150 @@ -66,87 +66,86 @@ define void @slasv2_(ptr nocapture noundef readonly %0, ptr nocapture noundef re %36 = fadd float %.0150, %33 %37 = tail call noundef float @llvm.fabs.f32(float %36) %38 = fmul float %37, 0x3E80000000000000 - %39 = fcmp uge float %35, %38 + %39 = fcmp olt float %35, %38 %40 = fdiv float %33, %.0150 - %.0136 = select i1 %39, float %40, float 1.000000e+00 + %.0136 = select i1 %39, float 1.000000e+00, float %40 %41 = fdiv float %17, %.0153 %42 = fsub float 2.000000e+00, %.0136 %43 = fmul float %41, %41 %44 = fmul float %42, %42 %45 = fadd float %43, %44 %sqrt = tail call float @llvm.sqrt.f32(float %45) - %46 = tail call float @llvm.fabs.f32(float %40) + %46 = tail call noundef float @llvm.fabs.f32(float %.0136) %47 = fcmp olt float %46, 0x3810000000000000 - %48 = and i1 %47, %39 - %49 = tail call float @llvm.fabs.f32(float %41) - %50 = tail call float @llvm.fmuladd.f32(float %.0136, float %.0136, float %43) - %sqrt174 = tail call float @llvm.sqrt.f32(float %50) - %.0137 = select i1 %48, float %49, float %sqrt174 - %51 = fadd float %.0137, %sqrt - %52 = fmul float %51, 5.000000e-01 - %53 = fdiv float %.0152, %52 - store float %53, ptr %3, align 4 - %54 = fmul float %.0150, %52 - store float %54, ptr %4, align 4 - %55 = tail call noundef float @llvm.fabs.f32(float %43) - %56 = fcmp olt float %55, 0x3810000000000000 - br i1 %56, label %57, label %71 - -57: ; preds = %32 - %58 = fcmp ogt float %.0153, 0.000000e+00 - br i1 %48, label %59, label %65 - -59: ; preds = %57 - %60 = select i1 %58, double 2.000000e+00, double -2.000000e+00 - %61 = fcmp ogt float %17, 0.000000e+00 - %62 = fneg double %60 - %63 = select i1 %61, double %60, double %62 - %64 = fptrunc double %63 to float - br label %82 - -65: ; preds = %57 - %66 = fneg float %33 - %67 = select i1 %58, float %33, float %66 - %68 = fdiv float %17, %67 - %69 = fdiv float %41, %42 - %70 = fadd float %68, %69 - br label %82 - -71: ; preds = %32 - %72 = fadd float %42, %sqrt - %73 = fdiv float %41, %72 - %74 = fadd float %.0136, %.0137 - %75 = fdiv float %41, %74 - %76 = fadd float %75, %73 - %77 = fpext float %76 to double - %78 = fpext float %52 to double - %79 = fadd double %78, 1.000000e+00 - %80 = fmul double %79, %77 - %81 = fptrunc double %80 to float - br label %82 - -82: ; preds = %59, %65, %71 - %.0149 = phi float [ %64, %59 ], [ %70, %65 ], [ %81, %71 ] - %83 = fmul float %.0149, %.0149 - %84 = fpext float %83 to double - %85 = fadd double %84, 4.000000e+00 - %sqrt175 = tail call double @llvm.sqrt.f64(double %85) - %86 = fptrunc double %sqrt175 to float - %87 = fdiv float 2.000000e+00, %86 - %88 = fdiv float %.0149, %86 - %89 = tail call float @llvm.fmuladd.f32(float %88, float %41, float %87) - %90 = fdiv float %89, %52 - %91 = fdiv float %.0151, %.0153 - %92 = fmul float %91, %88 - %93 = fdiv float %92, %52 - br label %94 - -94: ; preds = %82, %20 - %.0147 = phi float [ 1.000000e+00, %20 ], [ %90, %82 ] - %.0145 = phi float [ 1.000000e+00, %20 ], [ %87, %82 ] - %.0143 = phi float [ 0.000000e+00, %20 ], [ %93, %82 ] - %.0141 = phi float [ 0.000000e+00, %20 ], [ %88, %82 ] - %.1139 = phi i32 [ %.0138, %20 ], [ %.2140.ph, %82 ] + %48 = tail call float @llvm.fabs.f32(float %41) + %49 = tail call float @llvm.fmuladd.f32(float %.0136, float %.0136, float %43) + %sqrt174 = tail call float @llvm.sqrt.f32(float %49) + %.0137 = select i1 %47, float %48, float %sqrt174 + %50 = fadd float %.0137, %sqrt + %51 = fmul float %50, 5.000000e-01 + %52 = fdiv float %.0152, %51 + store float %52, ptr %3, align 4 + %53 = fmul float %.0150, %51 + store float %53, ptr %4, align 4 + %54 = tail call noundef float @llvm.fabs.f32(float %43) + %55 = fcmp olt float %54, 0x3810000000000000 + br i1 %55, label %56, label %70 + +56: ; preds = %32 + %57 = fcmp ogt float %.0153, 0.000000e+00 + br i1 %47, label %58, label %64 + +58: ; preds = %56 + %59 = select i1 %57, double 2.000000e+00, double -2.000000e+00 + %60 = fcmp ogt float %17, 0.000000e+00 + %61 = fneg double %59 + %62 = select i1 %60, double %59, double %61 + %63 = fptrunc double %62 to float + br label %81 + +64: ; preds = %56 + %65 = fneg float %33 + %66 = select i1 %57, float %33, float %65 + %67 = fdiv float %17, %66 + %68 = fdiv float %41, %42 + %69 = fadd float %67, %68 + br label %81 + +70: ; preds = %32 + %71 = fadd float %42, %sqrt + %72 = fdiv float %41, %71 + %73 = fadd float %.0136, %.0137 + %74 = fdiv float %41, %73 + %75 = fadd float %74, %72 + %76 = fpext float %75 to double + %77 = fpext float %51 to double + %78 = fadd double %77, 1.000000e+00 + %79 = fmul double %78, %76 + %80 = fptrunc double %79 to float + br label %81 + +81: ; preds = %58, %64, %70 + %.0149 = phi float [ %63, %58 ], [ %69, %64 ], [ %80, %70 ] + %82 = fmul float %.0149, %.0149 + %83 = fpext float %82 to double + %84 = fadd double %83, 4.000000e+00 + %sqrt175 = tail call double @llvm.sqrt.f64(double %84) + %85 = fptrunc double %sqrt175 to float + %86 = fdiv float 2.000000e+00, %85 + %87 = fdiv float %.0149, %85 + %88 = tail call float @llvm.fmuladd.f32(float %87, float %41, float %86) + %89 = fdiv float %88, %51 + %90 = fdiv float %.0151, %.0153 + %91 = fmul float %90, %87 + %92 = fdiv float %91, %51 + br label %93 + +93: ; preds = %81, %20 + %.0147 = phi float [ 1.000000e+00, %20 ], [ %89, %81 ] + %.0145 = phi float [ 1.000000e+00, %20 ], [ %86, %81 ] + %.0143 = phi float [ 0.000000e+00, %20 ], [ %92, %81 ] + %.0141 = phi float [ 0.000000e+00, %20 ], [ %87, %81 ] + %.1139 = phi i32 [ %.0138, %20 ], [ %.2140.ph, %81 ] %.0141..0147 = select i1 %14, float %.0141, float %.0147 %.0145..0143 = select i1 %14, float %.0145, float %.0143 %.0143..0145 = select i1 %14, float %.0143, float %.0145 @@ -155,63 +154,63 @@ define void @slasv2_(ptr nocapture noundef readonly %0, ptr nocapture noundef re store float %.0145..0143, ptr %7, align 4 store float %.0143..0145, ptr %6, align 4 store float %.0147..0141, ptr %5, align 4 - switch i32 %.1139, label %96 [ + switch i32 %.1139, label %95 [ i32 1, label %.thread169 i32 2, label %.thread172 ] -.thread169: ; preds = %94 - %95 = load float, ptr %6, align 4 +.thread169: ; preds = %93 + %94 = load float, ptr %6, align 4 br label %.thread172 -96: ; preds = %94 +95: ; preds = %93 br label %.thread172 -.thread172: ; preds = %94, %.thread, %.thread169, %96 - %.0147..0141185.sink = phi float [ %95, %.thread169 ], [ %.0147..0141, %96 ], [ 1.000000e+00, %.thread ], [ %.0147..0141, %94 ] - %.sink196 = phi ptr [ %8, %.thread169 ], [ %7, %96 ], [ %8, %.thread ], [ %8, %94 ] - %.sink = phi ptr [ %0, %.thread169 ], [ %2, %96 ], [ %1, %.thread ], [ %1, %94 ] - %97 = fcmp ogt float %.0147..0141185.sink, 0.000000e+00 - %98 = load float, ptr %.sink196, align 4 - %99 = fcmp ogt float %98, 0.000000e+00 - %100 = select i1 %99, double 1.000000e+00, double -1.000000e+00 - %101 = fneg double %100 - %102 = select i1 %97, double %100, double %101 - %103 = load float, ptr %.sink, align 4 - %104 = fcmp ogt float %103, 0.000000e+00 - %105 = fneg double %102 - %106 = select i1 %104, double %102, double %105 - %.2 = fptrunc double %106 to float - %107 = fcmp olt float %.2, 0.000000e+00 - br i1 %107, label %108, label %111 - -108: ; preds = %.thread172 - %109 = load float, ptr %4, align 4 - %110 = fneg float %109 - store float %110, ptr %4, align 4 - br label %111 - -111: ; preds = %108, %.thread172 - %112 = fpext float %.2 to double - %113 = load float, ptr %0, align 4 - %114 = fcmp ogt float %113, 0.000000e+00 - %115 = fneg double %112 - %116 = select i1 %114, double %112, double %115 - %117 = load float, ptr %2, align 4 - %118 = fcmp ogt float %117, 0.000000e+00 - %119 = fneg double %116 - %120 = select i1 %118, double %116, double %119 - %121 = fptrunc double %120 to float - %122 = fcmp olt float %121, 0.000000e+00 - br i1 %122, label %123, label %126 - -123: ; preds = %111 - %124 = load float, ptr %3, align 4 - %125 = fneg float %124 - store float %125, ptr %3, align 4 - br label %126 - -126: ; preds = %123, %111 +.thread172: ; preds = %93, %.thread, %.thread169, %95 + %.0147..0141185.sink = phi float [ %94, %.thread169 ], [ %.0147..0141, %95 ], [ 1.000000e+00, %.thread ], [ %.0147..0141, %93 ] + %.sink196 = phi ptr [ %8, %.thread169 ], [ %7, %95 ], [ %8, %.thread ], [ %8, %93 ] + %.sink = phi ptr [ %0, %.thread169 ], [ %2, %95 ], [ %1, %.thread ], [ %1, %93 ] + %96 = fcmp ogt float %.0147..0141185.sink, 0.000000e+00 + %97 = load float, ptr %.sink196, align 4 + %98 = fcmp ogt float %97, 0.000000e+00 + %99 = select i1 %98, double 1.000000e+00, double -1.000000e+00 + %100 = fneg double %99 + %101 = select i1 %96, double %99, double %100 + %102 = load float, ptr %.sink, align 4 + %103 = fcmp ogt float %102, 0.000000e+00 + %104 = fneg double %101 + %105 = select i1 %103, double %101, double %104 + %.2 = fptrunc double %105 to float + %106 = fcmp olt float %.2, 0.000000e+00 + br i1 %106, label %107, label %110 + +107: ; preds = %.thread172 + %108 = load float, ptr %4, align 4 + %109 = fneg float %108 + store float %109, ptr %4, align 4 + br label %110 + +110: ; preds = %107, %.thread172 + %111 = fpext float %.2 to double + %112 = load float, ptr %0, align 4 + %113 = fcmp ogt float %112, 0.000000e+00 + %114 = fneg double %111 + %115 = select i1 %113, double %111, double %114 + %116 = load float, ptr %2, align 4 + %117 = fcmp ogt float %116, 0.000000e+00 + %118 = fneg double %115 + %119 = select i1 %117, double %115, double %118 + %120 = fptrunc double %119 to float + %121 = fcmp olt float %120, 0.000000e+00 + br i1 %121, label %122, label %125 + +122: ; preds = %110 + %123 = load float, ptr %3, align 4 + %124 = fneg float %123 + store float %124, ptr %3, align 4 + br label %125 + +125: ; preds = %122, %110 ret void } diff --git a/bench/imgui/optimized/imgui.cpp.ll b/bench/imgui/optimized/imgui.cpp.ll index 20252147f18..975e055b95d 100644 --- a/bench/imgui/optimized/imgui.cpp.ll +++ b/bench/imgui/optimized/imgui.cpp.ll @@ -29000,19 +29000,18 @@ if.end81.i: ; preds = %land.lhs.true.i497, store float %add.i158.i, ptr %WheelingAxisAvg.i, align 4 %y95.i = getelementptr inbounds nuw i8, ptr %957, i64 16464 %1020 = load float, ptr %y95.i, align 4 - %1021 = call float @llvm.fabs.f32(float %cond22.i) + %1021 = call noundef float @llvm.fabs.f32(float %wheel.sroa.13.0.i) %div.i159.i = fdiv float %1020, 3.000000e+01 %sub.i160.i = fsub float %1020, %div.i159.i - %1022 = fdiv float %1021, 3.000000e+01 - %div2.i161.i = select i1 %tobool83.i, float 0.000000e+00, float %1022 + %div2.i161.i = fdiv float %1021, 3.000000e+01 %add.i162.i = fadd float %div2.i161.i, %sub.i160.i store float %add.i162.i, ptr %y95.i, align 4 %WheelingWindowWheelRemainder.i = getelementptr inbounds nuw i8, ptr %957, i64 16452 - %1023 = load float, ptr %WheelingWindowWheelRemainder.i, align 4 - %add.i163.i = fadd float %wheel.sroa.0.0.i, %1023 + %1022 = load float, ptr %WheelingWindowWheelRemainder.i, align 4 + %add.i163.i = fadd float %wheel.sroa.0.0.i, %1022 %y.i164.i = getelementptr inbounds nuw i8, ptr %957, i64 16456 - %1024 = load float, ptr %y.i164.i, align 4 - %add3.i165.i = fadd float %wheel.sroa.13.0.i, %1024 + %1023 = load float, ptr %y.i164.i, align 4 + %add3.i165.i = fadd float %wheel.sroa.13.0.i, %1023 store i32 0, ptr %WheelingWindowWheelRemainder.i, align 4 store i32 0, ptr %y.i164.i, align 4 %cmp105.i = fcmp oeq float %add.i163.i, 0.000000e+00 @@ -29042,29 +29041,29 @@ for.body.i.i486: ; preds = %for.inc20.i.i, %con if.then.i175.i: ; preds = %for.body.i.i486 %window.029.i.i = load ptr, ptr %HoveredWindow.i.i, align 8 %Flags30.i.i = getelementptr inbounds nuw i8, ptr %window.029.i.i, i64 20 - %1025 = load i32, ptr %Flags30.i.i, align 4 - %and31.i.i = and i32 %1025, 16777216 + %1024 = load i32, ptr %Flags30.i.i, align 4 + %and31.i.i = and i32 %1024, 16777216 %tobool.not32.i.i = icmp eq i32 %and31.i.i, 0 br i1 %tobool.not32.i.i, label %for.inc20.loopexit.i.i, label %for.body3.i.i for.body3.i.i: ; preds = %if.then.i175.i, %for.inc.i.i494 - %1026 = phi i32 [ %1030, %for.inc.i.i494 ], [ %1025, %if.then.i175.i ] + %1025 = phi i32 [ %1029, %for.inc.i.i494 ], [ %1024, %if.then.i175.i ] %window.033.i.i = phi ptr [ %window.0.i.i, %for.inc.i.i494 ], [ %window.029.i.i, %if.then.i175.i ] %ScrollMax.i.i = getelementptr inbounds nuw i8, ptr %window.033.i.i, i64 148 %arrayidx.i28.i.i = getelementptr inbounds nuw float, ptr %ScrollMax.i.i, i64 %indvars.iv.i.i487 - %1027 = load float, ptr %arrayidx.i28.i.i, align 4 - %cmp6.i.i = fcmp oeq float %1027, 0.000000e+00 - %1028 = and i32 %1026, 528 - %1029 = icmp eq i32 %1028, 16 - %brmerge.i.i493 = or i1 %1029, %cmp6.i.i + %1026 = load float, ptr %arrayidx.i28.i.i, align 4 + %cmp6.i.i = fcmp oeq float %1026, 0.000000e+00 + %1027 = and i32 %1025, 528 + %1028 = icmp eq i32 %1027, 16 + %brmerge.i.i493 = or i1 %1028, %cmp6.i.i br i1 %brmerge.i.i493, label %for.inc.i.i494, label %for.inc20.loopexit.i.i for.inc.i.i494: ; preds = %for.body3.i.i %ParentWindow.i.i495 = getelementptr inbounds nuw i8, ptr %window.033.i.i, i64 888 %window.0.i.i = load ptr, ptr %ParentWindow.i.i495, align 8 %Flags.i.i496 = getelementptr inbounds nuw i8, ptr %window.0.i.i, i64 20 - %1030 = load i32, ptr %Flags.i.i496, align 4 - %and.i176.i = and i32 %1030, 16777216 + %1029 = load i32, ptr %Flags.i.i496, align 4 + %and.i176.i = and i32 %1029, 16777216 %tobool.not.i177.i = icmp eq i32 %and.i176.i, 0 br i1 %tobool.not.i177.i, label %for.inc20.loopexit.i.i, label %for.body3.i.i, !llvm.loop !83 @@ -29092,19 +29091,19 @@ if.end28.i.i489: ; preds = %for.end21.i.i if.end42.i.i: ; preds = %if.end28.i.i489 %WheelingWindowStartFrame.i170.i = getelementptr inbounds nuw i8, ptr %981, i64 16440 - %1031 = load i32, ptr %WheelingWindowStartFrame.i170.i, align 8 - %cmp43.i.i = icmp eq i32 %1031, -1 + %1030 = load i32, ptr %WheelingWindowStartFrame.i170.i, align 8 + %cmp43.i.i = icmp eq i32 %1030, -1 %FrameCount.i.i492 = getelementptr inbounds nuw i8, ptr %981, i64 16224 - %1032 = load i32, ptr %FrameCount.i.i492, align 8 + %1031 = load i32, ptr %FrameCount.i.i492, align 8 br i1 %cmp43.i.i, label %if.then44.i.i, label %if.end46.i.i if.then44.i.i: ; preds = %if.end42.i.i - store i32 %1032, ptr %WheelingWindowStartFrame.i170.i, align 8 + store i32 %1031, ptr %WheelingWindowStartFrame.i170.i, align 8 br label %if.end46.i.i if.end46.i.i: ; preds = %if.then44.i.i, %if.end42.i.i - %1033 = phi i32 [ %1032, %if.then44.i.i ], [ %1031, %if.end42.i.i ] - %cmp49.i.i = icmp eq i32 %1033, %1032 + %1032 = phi i32 [ %1031, %if.then44.i.i ], [ %1030, %if.end42.i.i ] + %cmp49.i.i = icmp eq i32 %1032, %1031 %cmp51.i.i = fcmp une float %add.i163.i, 0.000000e+00 %or.cond26.i.i = and i1 %cmp51.i.i, %cmp49.i.i %cmp53.i.i = fcmp une float %add3.i165.i, 0.000000e+00 @@ -29113,10 +29112,10 @@ if.end46.i.i: ; preds = %if.then44.i.i, %if. lor.lhs.false54.i.i: ; preds = %if.end46.i.i %WheelingAxisAvg.i172.i = getelementptr inbounds nuw i8, ptr %981, i64 16460 - %1034 = load float, ptr %WheelingAxisAvg.i172.i, align 4 + %1033 = load float, ptr %WheelingAxisAvg.i172.i, align 4 %y57.i.i = getelementptr inbounds nuw i8, ptr %981, i64 16464 - %1035 = load float, ptr %y57.i.i, align 4 - %cmp58.i.i = fcmp oeq float %1034, %1035 + %1034 = load float, ptr %y57.i.i, align 4 + %cmp58.i.i = fcmp oeq float %1033, %1034 br i1 %cmp58.i.i, label %if.then59.i.i, label %cond.end118.thread239.i if.then59.i.i: ; preds = %lor.lhs.false54.i.i, %if.end46.i.i @@ -29127,7 +29126,7 @@ if.then59.i.i: ; preds = %lor.lhs.false54.i.i br label %cond.end118.thread236.i cond.end118.thread239.i: ; preds = %lor.lhs.false54.i.i - %cmp65.i.i = fcmp ogt float %1034, %1035 + %cmp65.i.i = fcmp ogt float %1033, %1034 %cond71.i.i = select i1 %cmp65.i.i, ptr %windows.i.sroa.0.i.0.windows.i.sroa.0.i.0.windows.i.sroa.0.i.0.windows.i.sroa.0.0.windows.i.sroa.0.0.windows.i.sroa.0.0..i, ptr %windows.i.sroa.5.i.0.windows.i.sroa.5.i.0.windows.i.sroa.5.i.0.windows.i.sroa.5.0.windows.i.sroa.5.0.windows.i.sroa.5.8..i call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %windows.i.sroa.0.i) call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %windows.i.sroa.5.i) @@ -29148,9 +29147,9 @@ cond.end118.i: ; preds = %if.end28.i.i489 if.then121.i: ; preds = %cond.end118.i, %cond.end118.thread239.i, %if.end110.i %cond119235.i = phi ptr [ %cond.i174.i, %cond.end118.i ], [ %cond71.i.i, %cond.end118.thread239.i ], [ %980, %if.end110.i ] %Flags.i469 = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 20 - %1036 = load i32, ptr %Flags.i469, align 4 - %1037 = and i32 %1036, 528 - %or.cond69.i = icmp eq i32 %1037, 0 + %1035 = load i32, ptr %Flags.i469, align 4 + %1036 = and i32 %1035, 528 + %or.cond69.i = icmp eq i32 %1036, 0 br i1 %or.cond69.i, label %if.then127.i, label %_ZN5ImGuiL16UpdateMouseWheelEv.exit if.then127.i: ; preds = %if.then121.i @@ -29159,13 +29158,13 @@ if.then127.i: ; preds = %if.then121.i land.rhs130.i: ; preds = %if.then127.i %ScrollMax.i = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 148 - %1038 = load float, ptr %ScrollMax.i, align 4 - %cmp132.i = fcmp une float %1038, 0.000000e+00 - %1039 = zext i1 %cmp132.i to i8 + %1037 = load float, ptr %ScrollMax.i, align 4 + %cmp132.i = fcmp une float %1037, 0.000000e+00 + %1038 = zext i1 %cmp132.i to i8 br label %land.end133.i land.end133.i: ; preds = %land.rhs130.i, %if.then127.i - %frombool.i470 = phi i8 [ 0, %if.then127.i ], [ %1039, %land.rhs130.i ] + %frombool.i470 = phi i8 [ 0, %if.then127.i ], [ %1038, %land.rhs130.i ] store i8 %frombool.i470, ptr %do_scroll.i, align 1 %arrayinit.element.i = getelementptr inbounds nuw i8, ptr %do_scroll.i, i64 1 %cmp135.i471 = fcmp une float %add3.i165.i, 0.000000e+00 @@ -29177,18 +29176,18 @@ land.end140.thread.i: ; preds = %land.end133.i land.end140.i: ; preds = %land.end133.i %y138.i = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 152 - %1040 = load float, ptr %y138.i, align 4 - %cmp139.i = fcmp une float %1040, 0.000000e+00 + %1039 = load float, ptr %y138.i, align 4 + %cmp139.i = fcmp une float %1039, 0.000000e+00 %frombool141.i = zext i1 %cmp139.i to i8 store i8 %frombool141.i, ptr %arrayinit.element.i, align 1 %tobool142.i = trunc nuw i8 %frombool.i470 to i1 - %1041 = select i1 %tobool142.i, i1 %cmp139.i, i1 false - br i1 %1041, label %if.then146.i, label %if.end154.i + %1040 = select i1 %tobool142.i, i1 %cmp139.i, i1 false + br i1 %1040, label %if.then146.i, label %if.end154.i if.then146.i: ; preds = %land.end140.i - %1042 = load float, ptr %WheelingAxisAvg.i, align 4 - %1043 = load float, ptr %y95.i, align 4 - %cmp151.i484 = fcmp ogt float %1042, %1043 + %1041 = load float, ptr %WheelingAxisAvg.i, align 4 + %1042 = load float, ptr %y95.i, align 4 + %cmp151.i484 = fcmp ogt float %1041, %1042 %idxprom.i485 = zext i1 %cmp151.i484 to i64 %arrayidx153.i = getelementptr inbounds nuw [2 x i8], ptr %do_scroll.i, i64 0, i64 %idxprom.i485 store i8 0, ptr %arrayidx153.i, align 1 @@ -29196,33 +29195,33 @@ if.then146.i: ; preds = %land.end140.i br label %if.end154.i if.end154.i: ; preds = %if.then146.i, %land.end140.i, %land.end140.thread.i - %1044 = phi i8 [ %frombool.i470, %land.end140.thread.i ], [ %frombool.i470, %land.end140.i ], [ %.pre248.i, %if.then146.i ] - %tobool156.i = trunc i8 %1044 to i1 + %1043 = phi i8 [ %frombool.i470, %land.end140.thread.i ], [ %frombool.i470, %land.end140.i ], [ %.pre248.i, %if.then146.i ] + %tobool156.i = trunc i8 %1043 to i1 br i1 %tobool156.i, label %if.then157.i, label %if.end168.i if.then157.i: ; preds = %if.end154.i call fastcc void @_ZL18LockWheelingWindowP11ImGuiWindowf(ptr noundef nonnull %cond119235.i, float noundef %add.i163.i) %InnerRect.i = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 520 %Max.i.i473 = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 528 - %1045 = load float, ptr %Max.i.i473, align 4 - %1046 = load float, ptr %InnerRect.i, align 4 - %sub.i178.i = fsub float %1045, %1046 + %1044 = load float, ptr %Max.i.i473, align 4 + %1045 = load float, ptr %InnerRect.i, align 4 + %sub.i178.i = fsub float %1044, %1045 %mul160.i = fmul float %sub.i178.i, 0x3FE570A3E0000000 - %1047 = load ptr, ptr %cond119235.i, align 8 - %FontBaseSize.i.i474 = getelementptr inbounds nuw i8, ptr %1047, i64 15684 - %1048 = load float, ptr %FontBaseSize.i.i474, align 4 + %1046 = load ptr, ptr %cond119235.i, align 8 + %FontBaseSize.i.i474 = getelementptr inbounds nuw i8, ptr %1046, i64 15684 + %1047 = load float, ptr %FontBaseSize.i.i474, align 4 %FontWindowScale.i.i475 = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 672 - %1049 = load float, ptr %FontWindowScale.i.i475, align 8 - %mul.i179.i = fmul float %1048, %1049 + %1048 = load float, ptr %FontWindowScale.i.i475, align 8 + %mul.i179.i = fmul float %1047, %1048 %ParentWindow.i180.i = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 888 - %1050 = load ptr, ptr %ParentWindow.i180.i, align 8 - %tobool.not.i181.i = icmp eq ptr %1050, null + %1049 = load ptr, ptr %ParentWindow.i180.i, align 8 + %tobool.not.i181.i = icmp eq ptr %1049, null br i1 %tobool.not.i181.i, label %_ZNK11ImGuiWindow12CalcFontSizeEv.exit.i478, label %if.then.i182.i if.then.i182.i: ; preds = %if.then157.i - %FontWindowScale3.i.i476 = getelementptr inbounds nuw i8, ptr %1050, i64 672 - %1051 = load float, ptr %FontWindowScale3.i.i476, align 8 - %mul4.i.i477 = fmul float %mul.i179.i, %1051 + %FontWindowScale3.i.i476 = getelementptr inbounds nuw i8, ptr %1049, i64 672 + %1050 = load float, ptr %FontWindowScale3.i.i476, align 8 + %mul4.i.i477 = fmul float %mul.i179.i, %1050 br label %_ZNK11ImGuiWindow12CalcFontSizeEv.exit.i478 _ZNK11ImGuiWindow12CalcFontSizeEv.exit.i478: ; preds = %if.then.i182.i, %if.then157.i @@ -29233,49 +29232,49 @@ _ZNK11ImGuiWindow12CalcFontSizeEv.exit.i478: ; preds = %if.then.i182.i, %if %conv.i186.i = fptosi float %cond.i185.i to i32 %conv1.i187.i = sitofp i32 %conv.i186.i to float %Scroll.i480 = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 140 - %1052 = load float, ptr %Scroll.i480, align 4 + %1051 = load float, ptr %Scroll.i480, align 4 %neg.i = fneg float %add.i163.i - %1053 = call float @llvm.fmuladd.f32(float %neg.i, float %conv1.i187.i, float %1052) + %1052 = call float @llvm.fmuladd.f32(float %neg.i, float %conv1.i187.i, float %1051) %ScrollTarget.i.i481 = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 156 - store float %1053, ptr %ScrollTarget.i.i481, align 4 + store float %1052, ptr %ScrollTarget.i.i481, align 4 %ScrollTargetCenterRatio.i.i482 = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 164 store float 0.000000e+00, ptr %ScrollTargetCenterRatio.i.i482, align 4 %ScrollTargetEdgeSnapDist.i.i483 = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 172 store float 0.000000e+00, ptr %ScrollTargetEdgeSnapDist.i.i483, align 4 %FrameCount.i = getelementptr inbounds nuw i8, ptr %957, i64 16224 - %1054 = load i32, ptr %FrameCount.i, align 8 + %1053 = load i32, ptr %FrameCount.i, align 8 %WheelingWindowScrolledFrame.i = getelementptr inbounds nuw i8, ptr %957, i64 16444 - store i32 %1054, ptr %WheelingWindowScrolledFrame.i, align 4 + store i32 %1053, ptr %WheelingWindowScrolledFrame.i, align 4 br label %if.end168.i if.end168.i: ; preds = %_ZNK11ImGuiWindow12CalcFontSizeEv.exit.i478, %if.end154.i - %1055 = load i8, ptr %arrayinit.element.i, align 1 - %tobool170.i = trunc i8 %1055 to i1 + %1054 = load i8, ptr %arrayinit.element.i, align 1 + %tobool170.i = trunc i8 %1054 to i1 br i1 %tobool170.i, label %if.then171.i, label %_ZN5ImGuiL16UpdateMouseWheelEv.exit if.then171.i: ; preds = %if.end168.i call fastcc void @_ZL18LockWheelingWindowP11ImGuiWindowf(ptr noundef nonnull %cond119235.i, float noundef %add3.i165.i) %y.i188.i = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 532 - %1056 = load float, ptr %y.i188.i, align 4 + %1055 = load float, ptr %y.i188.i, align 4 %y2.i189.i = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 524 - %1057 = load float, ptr %y2.i189.i, align 4 - %sub.i190.i = fsub float %1056, %1057 + %1056 = load float, ptr %y2.i189.i, align 4 + %sub.i190.i = fsub float %1055, %1056 %mul176.i = fmul float %sub.i190.i, 0x3FE570A3E0000000 - %1058 = load ptr, ptr %cond119235.i, align 8 - %FontBaseSize.i191.i = getelementptr inbounds nuw i8, ptr %1058, i64 15684 - %1059 = load float, ptr %FontBaseSize.i191.i, align 4 + %1057 = load ptr, ptr %cond119235.i, align 8 + %FontBaseSize.i191.i = getelementptr inbounds nuw i8, ptr %1057, i64 15684 + %1058 = load float, ptr %FontBaseSize.i191.i, align 4 %FontWindowScale.i192.i = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 672 - %1060 = load float, ptr %FontWindowScale.i192.i, align 8 - %mul.i193.i = fmul float %1059, %1060 + %1059 = load float, ptr %FontWindowScale.i192.i, align 8 + %mul.i193.i = fmul float %1058, %1059 %ParentWindow.i194.i = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 888 - %1061 = load ptr, ptr %ParentWindow.i194.i, align 8 - %tobool.not.i195.i = icmp eq ptr %1061, null + %1060 = load ptr, ptr %ParentWindow.i194.i, align 8 + %tobool.not.i195.i = icmp eq ptr %1060, null br i1 %tobool.not.i195.i, label %_ZNK11ImGuiWindow12CalcFontSizeEv.exit201.i, label %if.then.i196.i if.then.i196.i: ; preds = %if.then171.i - %FontWindowScale3.i197.i = getelementptr inbounds nuw i8, ptr %1061, i64 672 - %1062 = load float, ptr %FontWindowScale3.i197.i, align 8 - %mul4.i198.i = fmul float %mul.i193.i, %1062 + %FontWindowScale3.i197.i = getelementptr inbounds nuw i8, ptr %1060, i64 672 + %1061 = load float, ptr %FontWindowScale3.i197.i, align 8 + %mul4.i198.i = fmul float %mul.i193.i, %1061 br label %_ZNK11ImGuiWindow12CalcFontSizeEv.exit201.i _ZNK11ImGuiWindow12CalcFontSizeEv.exit201.i: ; preds = %if.then.i196.i, %if.then171.i @@ -29286,55 +29285,55 @@ _ZNK11ImGuiWindow12CalcFontSizeEv.exit201.i: ; preds = %if.then.i196.i, %if %conv.i204.i = fptosi float %cond.i203.i to i32 %conv1.i205.i = sitofp i32 %conv.i204.i to float %y183.i = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 144 - %1063 = load float, ptr %y183.i, align 4 + %1062 = load float, ptr %y183.i, align 4 %neg186.i = fneg float %add3.i165.i - %1064 = call float @llvm.fmuladd.f32(float %neg186.i, float %conv1.i205.i, float %1063) + %1063 = call float @llvm.fmuladd.f32(float %neg186.i, float %conv1.i205.i, float %1062) %y.i206.i = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 160 - store float %1064, ptr %y.i206.i, align 4 + store float %1063, ptr %y.i206.i, align 4 %y1.i.i472 = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 168 store float 0.000000e+00, ptr %y1.i.i472, align 4 %y2.i207.i = getelementptr inbounds nuw i8, ptr %cond119235.i, i64 176 store float 0.000000e+00, ptr %y2.i207.i, align 4 %FrameCount187.i = getelementptr inbounds nuw i8, ptr %957, i64 16224 - %1065 = load i32, ptr %FrameCount187.i, align 8 + %1064 = load i32, ptr %FrameCount187.i, align 8 %WheelingWindowScrolledFrame188.i = getelementptr inbounds nuw i8, ptr %957, i64 16444 - store i32 %1065, ptr %WheelingWindowScrolledFrame188.i, align 4 + store i32 %1064, ptr %WheelingWindowScrolledFrame188.i, align 4 br label %_ZN5ImGuiL16UpdateMouseWheelEv.exit _ZN5ImGuiL16UpdateMouseWheelEv.exit: ; preds = %land.lhs.true37.i, %cond.end27.i, %lor.lhs.false.i463, %_ZL18LockWheelingWindowP11ImGuiWindowf.exit121.i, %_ZN5ImGui12SetWindowPosEP11ImGuiWindowRK6ImVec2i.exit, %if.end76.i, %if.end81.i, %cond.end118.thread236.i, %cond.end118.i, %if.then121.i, %if.end168.i, %_ZNK11ImGuiWindow12CalcFontSizeEv.exit201.i call void @llvm.lifetime.end.p0(i64 2, ptr nonnull %do_scroll.i) %GcCompactAll = getelementptr inbounds nuw i8, ptr %0, i64 16239 - %1066 = load i8, ptr %GcCompactAll, align 1 - %tobool270 = trunc i8 %1066 to i1 + %1065 = load i8, ptr %GcCompactAll, align 1 + %tobool270 = trunc i8 %1065 to i1 br i1 %tobool270, label %cond.end281, label %lor.lhs.false271 lor.lhs.false271: ; preds = %_ZN5ImGuiL16UpdateMouseWheelEv.exit %ConfigMemoryCompactTimer = getelementptr inbounds nuw i8, ptr %0, i64 96 - %1067 = load float, ptr %ConfigMemoryCompactTimer, align 8 - %cmp273 = fcmp olt float %1067, 0.000000e+00 + %1066 = load float, ptr %ConfigMemoryCompactTimer, align 8 + %cmp273 = fcmp olt float %1066, 0.000000e+00 br i1 %cmp273, label %cond.end281, label %cond.false275 cond.false275: ; preds = %lor.lhs.false271 - %1068 = load double, ptr %Time, align 8 - %conv277 = fptrunc double %1068 to float - %sub280 = fsub float %conv277, %1067 + %1067 = load double, ptr %Time, align 8 + %conv277 = fptrunc double %1067 to float + %sub280 = fsub float %conv277, %1066 br label %cond.end281 cond.end281: ; preds = %_ZN5ImGuiL16UpdateMouseWheelEv.exit, %lor.lhs.false271, %cond.false275 %cond282 = phi float [ %sub280, %cond.false275 ], [ 0x47EFFFFFE0000000, %lor.lhs.false271 ], [ 0x47EFFFFFE0000000, %_ZN5ImGuiL16UpdateMouseWheelEv.exit ] %Windows = getelementptr inbounds nuw i8, ptr %0, i64 16296 %Data.i521 = getelementptr inbounds nuw i8, ptr %0, i64 16304 - %1069 = load ptr, ptr %Data.i521, align 8 - %1070 = load i32, ptr %Windows, align 8 - %idx.ext.i523 = sext i32 %1070 to i64 - %add.ptr.i524 = getelementptr inbounds ptr, ptr %1069, i64 %idx.ext.i523 - %cmp289.not817 = icmp eq i32 %1070, 0 + %1068 = load ptr, ptr %Data.i521, align 8 + %1069 = load i32, ptr %Windows, align 8 + %idx.ext.i523 = sext i32 %1069 to i64 + %add.ptr.i524 = getelementptr inbounds ptr, ptr %1068, i64 %idx.ext.i523 + %cmp289.not817 = icmp eq i32 %1069, 0 br i1 %cmp289.not817, label %for.cond306.preheader, label %for.body290 for.cond306.preheader: ; preds = %for.inc303, %cond.end281 %TablesLastTimeActive = getelementptr inbounds nuw i8, ptr %0, i64 19984 - %1071 = load i32, ptr %TablesLastTimeActive, align 8 - %cmp308819 = icmp sgt i32 %1071, 0 + %1070 = load i32, ptr %TablesLastTimeActive, align 8 + %cmp308819 = icmp sgt i32 %1070, 0 br i1 %cmp308819, label %for.body309.lr.ph, label %for.end321 for.body309.lr.ph: ; preds = %for.cond306.preheader @@ -29343,38 +29342,38 @@ for.body309.lr.ph: ; preds = %for.cond306.prehead br label %for.body309 for.body290: ; preds = %cond.end281, %for.inc303 - %__begin1284.0818 = phi ptr [ %incdec.ptr304, %for.inc303 ], [ %1069, %cond.end281 ] - %1072 = load ptr, ptr %__begin1284.0818, align 8 - %Active = getelementptr inbounds nuw i8, ptr %1072, i64 190 - %1073 = load i8, ptr %Active, align 2 - %WasActive = getelementptr inbounds nuw i8, ptr %1072, i64 191 - %frombool292 = and i8 %1073, 1 + %__begin1284.0818 = phi ptr [ %incdec.ptr304, %for.inc303 ], [ %1068, %cond.end281 ] + %1071 = load ptr, ptr %__begin1284.0818, align 8 + %Active = getelementptr inbounds nuw i8, ptr %1071, i64 190 + %1072 = load i8, ptr %Active, align 2 + %WasActive = getelementptr inbounds nuw i8, ptr %1071, i64 191 + %frombool292 = and i8 %1072, 1 store i8 %frombool292, ptr %WasActive, align 1 store i8 0, ptr %Active, align 2 - %WriteAccessed = getelementptr inbounds nuw i8, ptr %1072, i64 192 + %WriteAccessed = getelementptr inbounds nuw i8, ptr %1071, i64 192 store i8 0, ptr %WriteAccessed, align 8 - %BeginCount = getelementptr inbounds nuw i8, ptr %1072, i64 204 - %1074 = load i16, ptr %BeginCount, align 4 - %BeginCountPreviousFrame = getelementptr inbounds nuw i8, ptr %1072, i64 206 - store i16 %1074, ptr %BeginCountPreviousFrame, align 2 + %BeginCount = getelementptr inbounds nuw i8, ptr %1071, i64 204 + %1073 = load i16, ptr %BeginCount, align 4 + %BeginCountPreviousFrame = getelementptr inbounds nuw i8, ptr %1071, i64 206 + store i16 %1073, ptr %BeginCountPreviousFrame, align 2 store i16 0, ptr %BeginCount, align 4 - %tobool296 = trunc i8 %1073 to i1 + %tobool296 = trunc i8 %1072 to i1 br i1 %tobool296, label %for.inc303, label %land.lhs.true297 land.lhs.true297: ; preds = %for.body290 - %MemoryCompacted = getelementptr inbounds nuw i8, ptr %1072, i64 1012 - %1075 = load i8, ptr %MemoryCompacted, align 4 - %tobool298 = trunc i8 %1075 to i1 + %MemoryCompacted = getelementptr inbounds nuw i8, ptr %1071, i64 1012 + %1074 = load i8, ptr %MemoryCompacted, align 4 + %tobool298 = trunc i8 %1074 to i1 br i1 %tobool298, label %for.inc303, label %land.lhs.true299 land.lhs.true299: ; preds = %land.lhs.true297 - %LastTimeActive = getelementptr inbounds nuw i8, ptr %1072, i64 628 - %1076 = load float, ptr %LastTimeActive, align 4 - %cmp300 = fcmp olt float %1076, %cond282 + %LastTimeActive = getelementptr inbounds nuw i8, ptr %1071, i64 628 + %1075 = load float, ptr %LastTimeActive, align 4 + %cmp300 = fcmp olt float %1075, %cond282 br i1 %cmp300, label %if.then301, label %for.inc303 if.then301: ; preds = %land.lhs.true299 - call void @_ZN5ImGui31GcCompactTransientWindowBuffersEP11ImGuiWindow(ptr noundef nonnull %1072) + call void @_ZN5ImGui31GcCompactTransientWindowBuffersEP11ImGuiWindow(ptr noundef nonnull %1071) br label %for.inc303 for.inc303: ; preds = %for.body290, %land.lhs.true297, %land.lhs.true299, %if.then301 @@ -29383,46 +29382,46 @@ for.inc303: ; preds = %for.body290, %land. br i1 %cmp289.not, label %for.cond306.preheader, label %for.body290 for.body309: ; preds = %for.body309.lr.ph, %for.inc320 - %1077 = phi i32 [ %1071, %for.body309.lr.ph ], [ %1081, %for.inc320 ] + %1076 = phi i32 [ %1070, %for.body309.lr.ph ], [ %1080, %for.inc320 ] %indvars.iv835 = phi i64 [ 0, %for.body309.lr.ph ], [ %indvars.iv.next836, %for.inc320 ] - %1078 = load ptr, ptr %Data.i525, align 8 - %arrayidx.i527 = getelementptr inbounds nuw float, ptr %1078, i64 %indvars.iv835 - %1079 = load float, ptr %arrayidx.i527, align 4 - %cmp312 = fcmp oge float %1079, 0.000000e+00 - %cmp316 = fcmp olt float %1079, %cond282 + %1077 = load ptr, ptr %Data.i525, align 8 + %arrayidx.i527 = getelementptr inbounds nuw float, ptr %1077, i64 %indvars.iv835 + %1078 = load float, ptr %arrayidx.i527, align 4 + %cmp312 = fcmp oge float %1078, 0.000000e+00 + %cmp316 = fcmp olt float %1078, %cond282 %or.cond797 = select i1 %cmp312, i1 %cmp316, i1 false br i1 %or.cond797, label %if.then317, label %for.inc320 if.then317: ; preds = %for.body309 - %1080 = load ptr, ptr %Data.i.i531, align 8 - %arrayidx.i.i533 = getelementptr inbounds nuw %struct.ImGuiTable, ptr %1080, i64 %indvars.iv835 + %1079 = load ptr, ptr %Data.i.i531, align 8 + %arrayidx.i.i533 = getelementptr inbounds nuw %struct.ImGuiTable, ptr %1079, i64 %indvars.iv835 call void @_ZN5ImGui30TableGcCompactTransientBuffersEP10ImGuiTable(ptr noundef %arrayidx.i.i533) %.pre846 = load i32, ptr %TablesLastTimeActive, align 8 br label %for.inc320 for.inc320: ; preds = %for.body309, %if.then317 - %1081 = phi i32 [ %1077, %for.body309 ], [ %.pre846, %if.then317 ] + %1080 = phi i32 [ %1076, %for.body309 ], [ %.pre846, %if.then317 ] %indvars.iv.next836 = add nuw nsw i64 %indvars.iv835, 1 - %1082 = sext i32 %1081 to i64 - %cmp308 = icmp slt i64 %indvars.iv.next836, %1082 + %1081 = sext i32 %1080 to i64 + %cmp308 = icmp slt i64 %indvars.iv.next836, %1081 br i1 %cmp308, label %for.body309, label %for.end321, !llvm.loop !85 for.end321: ; preds = %for.inc320, %for.cond306.preheader %TablesTempData = getelementptr inbounds nuw i8, ptr %0, i64 19928 %Data.i534 = getelementptr inbounds nuw i8, ptr %0, i64 19936 - %1083 = load ptr, ptr %Data.i534, align 8 - %1084 = load i32, ptr %TablesTempData, align 8 - %idx.ext.i536 = sext i32 %1084 to i64 - %add.ptr.i537 = getelementptr inbounds %struct.ImGuiTableTempData, ptr %1083, i64 %idx.ext.i536 - %cmp328.not821 = icmp eq i32 %1084, 0 + %1082 = load ptr, ptr %Data.i534, align 8 + %1083 = load i32, ptr %TablesTempData, align 8 + %idx.ext.i536 = sext i32 %1083 to i64 + %add.ptr.i537 = getelementptr inbounds %struct.ImGuiTableTempData, ptr %1082, i64 %idx.ext.i536 + %cmp328.not821 = icmp eq i32 %1083, 0 br i1 %cmp328.not821, label %for.end339, label %for.body329 for.body329: ; preds = %for.end321, %for.inc337 - %__begin1323.0822 = phi ptr [ %incdec.ptr338, %for.inc337 ], [ %1083, %for.end321 ] + %__begin1323.0822 = phi ptr [ %incdec.ptr338, %for.inc337 ], [ %1082, %for.end321 ] %LastTimeActive330 = getelementptr inbounds nuw i8, ptr %__begin1323.0822, i64 4 - %1085 = load float, ptr %LastTimeActive330, align 4 - %cmp331 = fcmp oge float %1085, 0.000000e+00 - %cmp334 = fcmp olt float %1085, %cond282 + %1084 = load float, ptr %LastTimeActive330, align 4 + %cmp331 = fcmp oge float %1084, 0.000000e+00 + %cmp334 = fcmp olt float %1084, %cond282 %or.cond = select i1 %cmp331, i1 %cmp334, i1 false br i1 %or.cond, label %if.then335, label %for.inc337 @@ -29436,8 +29435,8 @@ for.inc337: ; preds = %for.body329, %if.th br i1 %cmp328.not, label %for.end339, label %for.body329 for.end339: ; preds = %for.inc337, %for.end321 - %1086 = load i8, ptr %GcCompactAll, align 1 - %tobool341 = trunc i8 %1086 to i1 + %1085 = load i8, ptr %GcCompactAll, align 1 + %tobool341 = trunc i8 %1085 to i1 br i1 %tobool341, label %if.then342, label %if.end343 if.then342: ; preds = %for.end339 @@ -29447,47 +29446,47 @@ if.then342: ; preds = %for.end339 if.end343: ; preds = %if.then342, %for.end339 store i8 0, ptr %GcCompactAll, align 1 %NavWindow = getelementptr inbounds nuw i8, ptr %0, i64 19176 - %1087 = load ptr, ptr %NavWindow, align 8 - %tobool345.not = icmp eq ptr %1087, null + %1086 = load ptr, ptr %NavWindow, align 8 + %tobool345.not = icmp eq ptr %1086, null br i1 %tobool345.not, label %if.end351, label %land.lhs.true346 land.lhs.true346: ; preds = %if.end343 - %WasActive348 = getelementptr inbounds nuw i8, ptr %1087, i64 191 - %1088 = load i8, ptr %WasActive348, align 1 - %tobool349 = trunc i8 %1088 to i1 + %WasActive348 = getelementptr inbounds nuw i8, ptr %1086, i64 191 + %1087 = load i8, ptr %WasActive348, align 1 + %tobool349 = trunc i8 %1087 to i1 br i1 %tobool349, label %if.end351, label %if.then350 if.then350: ; preds = %land.lhs.true346 - %1089 = load ptr, ptr @GImGui, align 8 - %WindowsFocusOrder.i = getelementptr inbounds nuw i8, ptr %1089, i64 16312 - %1090 = load i32, ptr %WindowsFocusOrder.i, align 8 - %cmp116.i = icmp sgt i32 %1090, 0 + %1088 = load ptr, ptr @GImGui, align 8 + %WindowsFocusOrder.i = getelementptr inbounds nuw i8, ptr %1088, i64 16312 + %1089 = load i32, ptr %WindowsFocusOrder.i, align 8 + %cmp116.i = icmp sgt i32 %1089, 0 br i1 %cmp116.i, label %for.body.lr.ph.i540, label %_ZN5ImGui26FocusTopMostWindowUnderOneEP11ImGuiWindowS1_P13ImGuiViewporti.exit for.body.lr.ph.i540: ; preds = %if.then350 - %sub.i538 = add nsw i32 %1090, -1 - %Data.i.i541 = getelementptr inbounds nuw i8, ptr %1089, i64 16320 - %1091 = load ptr, ptr %Data.i.i541, align 8 - %1092 = zext nneg i32 %sub.i538 to i64 + %sub.i538 = add nsw i32 %1089, -1 + %Data.i.i541 = getelementptr inbounds nuw i8, ptr %1088, i64 16320 + %1090 = load ptr, ptr %Data.i.i541, align 8 + %1091 = zext nneg i32 %sub.i538 to i64 br label %for.body.i542 for.body.i542: ; preds = %for.inc.i546, %for.body.lr.ph.i540 - %indvars.iv.i543 = phi i64 [ %1092, %for.body.lr.ph.i540 ], [ %indvars.iv.next.i547, %for.inc.i546 ] - %arrayidx.i.i544 = getelementptr inbounds nuw ptr, ptr %1091, i64 %indvars.iv.i543 - %1093 = load ptr, ptr %arrayidx.i.i544, align 8 - %cmp4.i = icmp eq ptr %1093, null + %indvars.iv.i543 = phi i64 [ %1091, %for.body.lr.ph.i540 ], [ %indvars.iv.next.i547, %for.inc.i546 ] + %arrayidx.i.i544 = getelementptr inbounds nuw ptr, ptr %1090, i64 %indvars.iv.i543 + %1092 = load ptr, ptr %arrayidx.i.i544, align 8 + %cmp4.i = icmp eq ptr %1092, null br i1 %cmp4.i, label %for.inc.i546, label %lor.lhs.false.i545 lor.lhs.false.i545: ; preds = %for.body.i542 - %WasActive.i = getelementptr inbounds nuw i8, ptr %1093, i64 191 - %1094 = load i8, ptr %WasActive.i, align 1 - %tobool5.i = trunc i8 %1094 to i1 + %WasActive.i = getelementptr inbounds nuw i8, ptr %1092, i64 191 + %1093 = load i8, ptr %WasActive.i, align 1 + %tobool5.i = trunc i8 %1093 to i1 br i1 %tobool5.i, label %if.end7.i, label %for.inc.i546 if.end7.i: ; preds = %lor.lhs.false.i545 - %Flags8.i = getelementptr inbounds nuw i8, ptr %1093, i64 20 - %1095 = load i32, ptr %Flags8.i, align 4 - %and9.i = and i32 %1095, 66048 + %Flags8.i = getelementptr inbounds nuw i8, ptr %1092, i64 20 + %1094 = load i32, ptr %Flags8.i, align 4 + %and9.i = and i32 %1094, 66048 %cmp10.not.i = icmp eq i32 %and9.i, 66048 br i1 %cmp10.not.i, label %for.inc.i546, label %_ZN5ImGui26FocusTopMostWindowUnderOneEP11ImGuiWindowS1_P13ImGuiViewporti.exit @@ -29497,15 +29496,15 @@ for.inc.i546: ; preds = %if.end7.i, %lor.lhs br i1 %cmp1.i548, label %for.body.i542, label %_ZN5ImGui26FocusTopMostWindowUnderOneEP11ImGuiWindowS1_P13ImGuiViewporti.exit, !llvm.loop !86 _ZN5ImGui26FocusTopMostWindowUnderOneEP11ImGuiWindowS1_P13ImGuiViewporti.exit: ; preds = %if.end7.i, %for.inc.i546, %if.then350 - %.sink.i = phi ptr [ null, %if.then350 ], [ null, %for.inc.i546 ], [ %1093, %if.end7.i ] + %.sink.i = phi ptr [ null, %if.then350 ], [ null, %for.inc.i546 ], [ %1092, %if.end7.i ] call void @_ZN5ImGui11FocusWindowEP11ImGuiWindowi(ptr noundef %.sink.i, i32 noundef 1) br label %if.end351 if.end351: ; preds = %_ZN5ImGui26FocusTopMostWindowUnderOneEP11ImGuiWindowS1_P13ImGuiViewporti.exit, %land.lhs.true346, %if.end343 %CurrentWindowStack = getelementptr inbounds nuw i8, ptr %0, i64 16344 %Capacity.i549 = getelementptr inbounds nuw i8, ptr %0, i64 16348 - %1096 = load i32, ptr %Capacity.i549, align 4 - %cmp.i550 = icmp slt i32 %1096, 0 + %1095 = load i32, ptr %Capacity.i549, align 4 + %cmp.i550 = icmp slt i32 %1095, 0 br i1 %cmp.i550, label %if.then.i552, label %_ZN8ImVectorI20ImGuiWindowStackDataE6resizeEi.exit if.then.i552: ; preds = %if.end351 @@ -29516,8 +29515,8 @@ _ZN8ImVectorI20ImGuiWindowStackDataE6resizeEi.exit: ; preds = %if.end351, %if.th store i32 0, ptr %CurrentWindowStack, align 8 %BeginPopupStack = getelementptr inbounds nuw i8, ptr %0, i64 19120 %Capacity.i559 = getelementptr inbounds nuw i8, ptr %0, i64 19124 - %1097 = load i32, ptr %Capacity.i559, align 4 - %cmp.i560 = icmp slt i32 %1097, 0 + %1096 = load i32, ptr %Capacity.i559, align 4 + %cmp.i560 = icmp slt i32 %1096, 0 br i1 %cmp.i560, label %if.then.i562, label %_ZN8ImVectorI14ImGuiPopupDataE6resizeEi.exit if.then.i562: ; preds = %_ZN8ImVectorI20ImGuiWindowStackDataE6resizeEi.exit @@ -29528,8 +29527,8 @@ _ZN8ImVectorI14ImGuiPopupDataE6resizeEi.exit: ; preds = %_ZN8ImVectorI20ImGu store i32 0, ptr %BeginPopupStack, align 8 %ItemFlagsStack = getelementptr inbounds nuw i8, ptr %0, i64 19072 %Capacity.i569 = getelementptr inbounds nuw i8, ptr %0, i64 19076 - %1098 = load i32, ptr %Capacity.i569, align 4 - %cmp.i570 = icmp slt i32 %1098, 0 + %1097 = load i32, ptr %Capacity.i569, align 4 + %cmp.i570 = icmp slt i32 %1097, 0 br i1 %cmp.i570, label %if.then.i572, label %_ZN8ImVectorIiE6resizeEi.exit if.then.i572: ; preds = %_ZN8ImVectorI14ImGuiPopupDataE6resizeEi.exit @@ -29538,30 +29537,30 @@ if.then.i572: ; preds = %_ZN8ImVectorI14ImGu br label %_ZN8ImVectorIiE6resizeEi.exit _ZN8ImVectorIiE6resizeEi.exit: ; preds = %_ZN8ImVectorI14ImGuiPopupDataE6resizeEi.exit, %if.then.i572 - %1099 = phi i32 [ %1098, %_ZN8ImVectorI14ImGuiPopupDataE6resizeEi.exit ], [ %.pre847, %if.then.i572 ] + %1098 = phi i32 [ %1097, %_ZN8ImVectorI14ImGuiPopupDataE6resizeEi.exit ], [ %.pre847, %if.then.i572 ] store i32 0, ptr %ItemFlagsStack, align 8 - %cmp.i580 = icmp eq i32 %1099, 0 + %cmp.i580 = icmp eq i32 %1098, 0 br i1 %cmp.i580, label %_ZNK8ImVectorIiE14_grow_capacityEi.exit.i, label %_ZN8ImVectorIiE9push_backERKi.exit _ZNK8ImVectorIiE14_grow_capacityEi.exit.i: ; preds = %_ZN8ImVectorIiE6resizeEi.exit call void @_ZN8ImVectorIiE7reserveEi(ptr noundef nonnull align 8 dereferenceable(16) %ItemFlagsStack, i32 noundef 8) %.pre.i594 = load i32, ptr %ItemFlagsStack, align 8 - %1100 = sext i32 %.pre.i594 to i64 + %1099 = sext i32 %.pre.i594 to i64 br label %_ZN8ImVectorIiE9push_backERKi.exit _ZN8ImVectorIiE9push_backERKi.exit: ; preds = %_ZN8ImVectorIiE6resizeEi.exit, %_ZNK8ImVectorIiE14_grow_capacityEi.exit.i - %idxprom.i583 = phi i64 [ %1100, %_ZNK8ImVectorIiE14_grow_capacityEi.exit.i ], [ 0, %_ZN8ImVectorIiE6resizeEi.exit ] + %idxprom.i583 = phi i64 [ %1099, %_ZNK8ImVectorIiE14_grow_capacityEi.exit.i ], [ 0, %_ZN8ImVectorIiE6resizeEi.exit ] %Data.i582 = getelementptr inbounds nuw i8, ptr %0, i64 19080 - %1101 = load ptr, ptr %Data.i582, align 8 - %arrayidx.i584 = getelementptr inbounds i32, ptr %1101, i64 %idxprom.i583 + %1100 = load ptr, ptr %Data.i582, align 8 + %arrayidx.i584 = getelementptr inbounds i32, ptr %1100, i64 %idxprom.i583 store i32 0, ptr %arrayidx.i584, align 4 - %1102 = load i32, ptr %ItemFlagsStack, align 8 - %inc.i585 = add nsw i32 %1102, 1 + %1101 = load i32, ptr %ItemFlagsStack, align 8 + %inc.i585 = add nsw i32 %1101, 1 store i32 %inc.i585, ptr %ItemFlagsStack, align 8 %GroupStack = getelementptr inbounds nuw i8, ptr %0, i64 19088 %Capacity.i595 = getelementptr inbounds nuw i8, ptr %0, i64 19092 - %1103 = load i32, ptr %Capacity.i595, align 4 - %cmp.i596 = icmp slt i32 %1103, 0 + %1102 = load i32, ptr %Capacity.i595, align 4 + %cmp.i596 = icmp slt i32 %1102, 0 br i1 %cmp.i596, label %if.then.i598, label %_ZN8ImVectorI14ImGuiGroupDataE6resizeEi.exit if.then.i598: ; preds = %_ZN8ImVectorIiE9push_backERKi.exit @@ -29570,77 +29569,77 @@ if.then.i598: ; preds = %_ZN8ImVectorIiE9pus _ZN8ImVectorI14ImGuiGroupDataE6resizeEi.exit: ; preds = %_ZN8ImVectorIiE9push_backERKi.exit, %if.then.i598 store i32 0, ptr %GroupStack, align 8 - %1104 = load ptr, ptr @GImGui, align 8 - %DebugItemPickerBreakId.i = getelementptr inbounds nuw i8, ptr %1104, i64 24608 + %1103 = load ptr, ptr @GImGui, align 8 + %DebugItemPickerBreakId.i = getelementptr inbounds nuw i8, ptr %1103, i64 24608 store i32 0, ptr %DebugItemPickerBreakId.i, align 8 - %DebugItemPickerActive.i = getelementptr inbounds nuw i8, ptr %1104, i64 24603 - %1105 = load i8, ptr %DebugItemPickerActive.i, align 1 - %tobool.i605 = trunc i8 %1105 to i1 + %DebugItemPickerActive.i = getelementptr inbounds nuw i8, ptr %1103, i64 24603 + %1104 = load i8, ptr %DebugItemPickerActive.i, align 1 + %tobool.i605 = trunc i8 %1104 to i1 br i1 %tobool.i605, label %if.end.i606, label %_ZN5ImGuiL25UpdateDebugToolItemPickerEv.exit if.end.i606: ; preds = %_ZN8ImVectorI14ImGuiGroupDataE6resizeEi.exit - %HoveredIdPreviousFrame.i = getelementptr inbounds nuw i8, ptr %1104, i64 16476 - %1106 = load i32, ptr %HoveredIdPreviousFrame.i, align 4 - %MouseCursor.i.i = getelementptr inbounds nuw i8, ptr %1104, i64 20120 + %HoveredIdPreviousFrame.i = getelementptr inbounds nuw i8, ptr %1103, i64 16476 + %1105 = load i32, ptr %HoveredIdPreviousFrame.i, align 4 + %MouseCursor.i.i = getelementptr inbounds nuw i8, ptr %1103, i64 20120 store i32 7, ptr %MouseCursor.i.i, align 8 - %arrayidx10.i.i.i.i607 = getelementptr inbounds nuw i8, ptr %1104, i64 12108 - %1107 = load i8, ptr %arrayidx10.i.i.i.i607, align 4 - %tobool.i.i608 = trunc i8 %1107 to i1 + %arrayidx10.i.i.i.i607 = getelementptr inbounds nuw i8, ptr %1103, i64 12108 + %1106 = load i8, ptr %arrayidx10.i.i.i.i607, align 4 + %tobool.i.i608 = trunc i8 %1106 to i1 br i1 %tobool.i.i608, label %if.end.i.i635, label %if.end3.i if.end.i.i635: ; preds = %if.end.i606 - %DownDuration.i.i636 = getelementptr inbounds nuw i8, ptr %1104, i64 12112 - %1108 = load float, ptr %DownDuration.i.i636, align 4 - %cmp.i.i637 = fcmp olt float %1108, 0.000000e+00 + %DownDuration.i.i636 = getelementptr inbounds nuw i8, ptr %1103, i64 12112 + %1107 = load float, ptr %DownDuration.i.i636, align 4 + %cmp.i.i637 = fcmp olt float %1107, 0.000000e+00 br i1 %cmp.i.i637, label %if.end3.i, label %if.end2.i.i if.end2.i.i: ; preds = %if.end.i.i635 - %cmp3.i.i638 = fcmp oeq float %1108, 0.000000e+00 + %cmp3.i.i638 = fcmp oeq float %1107, 0.000000e+00 br i1 %cmp3.i.i638, label %if.end14.i.i644, label %if.then6.i.i if.then6.i.i: ; preds = %if.end2.i.i - %KeyRepeatDelay12.i.i.i = getelementptr inbounds nuw i8, ptr %1104, i64 112 - %1109 = load float, ptr %KeyRepeatDelay12.i.i.i, align 8 - %KeyRepeatRate15.i.i.i = getelementptr inbounds nuw i8, ptr %1104, i64 116 - %1110 = load float, ptr %KeyRepeatRate15.i.i.i, align 4 - %cmp7.i.i639 = fcmp ogt float %1108, %1109 + %KeyRepeatDelay12.i.i.i = getelementptr inbounds nuw i8, ptr %1103, i64 112 + %1108 = load float, ptr %KeyRepeatDelay12.i.i.i, align 8 + %KeyRepeatRate15.i.i.i = getelementptr inbounds nuw i8, ptr %1103, i64 116 + %1109 = load float, ptr %KeyRepeatRate15.i.i.i, align 4 + %cmp7.i.i639 = fcmp ogt float %1107, %1108 br i1 %cmp7.i.i639, label %if.end.i.i9.i.i, label %if.end3.i if.end.i.i9.i.i: ; preds = %if.then6.i.i - %DeltaTime.i.i.i = getelementptr inbounds nuw i8, ptr %1104, i64 24 - %1111 = load float, ptr %DeltaTime.i.i.i, align 8 - %sub.i.i.i640 = fsub float %1108, %1111 - %cmp1.i.i.i.i = fcmp ult float %sub.i.i.i640, %1108 + %DeltaTime.i.i.i = getelementptr inbounds nuw i8, ptr %1103, i64 24 + %1110 = load float, ptr %DeltaTime.i.i.i, align 8 + %sub.i.i.i640 = fsub float %1107, %1110 + %cmp1.i.i.i.i = fcmp ult float %sub.i.i.i640, %1107 br i1 %cmp1.i.i.i.i, label %if.end3.i.i.i.i641, label %if.end3.i if.end3.i.i.i.i641: ; preds = %if.end.i.i9.i.i - %cmp4.i.i.i.i = fcmp ugt float %1110, 0.000000e+00 - %cmp9.i.i.i.i = fcmp olt float %sub.i.i.i640, %1109 + %cmp4.i.i.i.i = fcmp ugt float %1109, 0.000000e+00 + %cmp9.i.i.i.i = fcmp olt float %sub.i.i.i640, %1108 br i1 %cmp4.i.i.i.i, label %_ZN5ImGui19GetKeyPressedAmountE8ImGuiKeyff.exit.i.i, label %if.then5.i.i.i.i642 if.then5.i.i.i.i642: ; preds = %if.end3.i.i.i.i641 - %cmp7.i.i.i.i643 = fcmp oge float %1108, %1109 - %1112 = and i1 %cmp7.i.i.i.i643, %cmp9.i.i.i.i - br i1 %1112, label %if.end14.i.i644, label %if.end3.i + %cmp7.i.i.i.i643 = fcmp oge float %1107, %1108 + %1111 = and i1 %cmp7.i.i.i.i643, %cmp9.i.i.i.i + br i1 %1111, label %if.end14.i.i644, label %if.end3.i _ZN5ImGui19GetKeyPressedAmountE8ImGuiKeyff.exit.i.i: ; preds = %if.end3.i.i.i.i641 - %sub.i.i.i.i647 = fsub float %sub.i.i.i640, %1109 - %div.i.i.i.i = fdiv float %sub.i.i.i.i647, %1110 + %sub.i.i.i.i647 = fsub float %sub.i.i.i640, %1108 + %div.i.i.i.i = fdiv float %sub.i.i.i.i647, %1109 %conv10.i.i.i.i = fptosi float %div.i.i.i.i to i32 %cond.i.i.i.i648 = select i1 %cmp9.i.i.i.i, i32 -1, i32 %conv10.i.i.i.i - %cmp11.i.i.i.i649 = fcmp olt float %1108, %1109 - %sub14.i.i.i.i = fsub float %1108, %1109 - %div15.i.i.i.i = fdiv float %sub14.i.i.i.i, %1110 + %cmp11.i.i.i.i649 = fcmp olt float %1107, %1108 + %sub14.i.i.i.i = fsub float %1107, %1108 + %div15.i.i.i.i = fdiv float %sub14.i.i.i.i, %1109 %conv16.i.i.i.i = fptosi float %div15.i.i.i.i to i32 %cond18.i.i.i.i = select i1 %cmp11.i.i.i.i649, i32 -1, i32 %conv16.i.i.i.i - %1113 = icmp sgt i32 %cond18.i.i.i.i, %cond.i.i.i.i648 - br i1 %1113, label %if.end14.i.i644, label %if.end3.i + %1112 = icmp sgt i32 %cond18.i.i.i.i, %cond.i.i.i.i648 + br i1 %1112, label %if.end14.i.i644, label %if.end3.i if.end14.i.i644: ; preds = %_ZN5ImGui19GetKeyPressedAmountE8ImGuiKeyff.exit.i.i, %if.then5.i.i.i.i642, %if.end2.i.i - %LockThisFrame.i.i645 = getelementptr inbounds nuw i8, ptr %1104, i64 16736 - %1114 = load i8, ptr %LockThisFrame.i.i645, align 4 - %1115 = and i8 %1114, 1 - %cmp14.i.i646 = icmp eq i8 %1115, 0 + %LockThisFrame.i.i645 = getelementptr inbounds nuw i8, ptr %1103, i64 16736 + %1113 = load i8, ptr %LockThisFrame.i.i645, align 4 + %1114 = and i8 %1113, 1 + %cmp14.i.i646 = icmp eq i8 %1114, 0 br i1 %cmp14.i.i646, label %if.then1.i, label %if.end3.i if.then1.i: ; preds = %if.end14.i.i644 @@ -29648,80 +29647,80 @@ if.then1.i: ; preds = %if.end14.i.i644 br label %if.end3.i if.end3.i: ; preds = %if.then1.i, %if.end14.i.i644, %_ZN5ImGui19GetKeyPressedAmountE8ImGuiKeyff.exit.i.i, %if.then5.i.i.i.i642, %if.end.i.i9.i.i, %if.then6.i.i, %if.end.i.i635, %if.end.i606 - %KeyMods.i609 = getelementptr inbounds nuw i8, ptr %1104, i64 3688 - %1116 = load i32, ptr %KeyMods.i609, align 8 - %cmp.i610 = icmp eq i32 %1116, 12288 + %KeyMods.i609 = getelementptr inbounds nuw i8, ptr %1103, i64 3688 + %1115 = load i32, ptr %KeyMods.i609, align 8 + %cmp.i610 = icmp eq i32 %1115, 12288 br i1 %cmp.i610, label %for.body.us.preheader.i, label %land.lhs.true.i611 land.lhs.true.i611: ; preds = %if.end3.i - %DebugItemPickerMouseButton.i = getelementptr inbounds nuw i8, ptr %1104, i64 24604 - %1117 = load i8, ptr %DebugItemPickerMouseButton.i, align 4 - %MouseDown.i.i.i = getelementptr inbounds nuw i8, ptr %1104, i64 3664 - %idxprom.i.i.i612 = zext i8 %1117 to i64 + %DebugItemPickerMouseButton.i = getelementptr inbounds nuw i8, ptr %1103, i64 24604 + %1116 = load i8, ptr %DebugItemPickerMouseButton.i, align 4 + %MouseDown.i.i.i = getelementptr inbounds nuw i8, ptr %1103, i64 3664 + %idxprom.i.i.i612 = zext i8 %1116 to i64 %arrayidx.i.i.i613 = getelementptr inbounds nuw [5 x i8], ptr %MouseDown.i.i.i, i64 0, i64 %idxprom.i.i.i612 - %1118 = load i8, ptr %arrayidx.i.i.i613, align 1 - %tobool.i.i.i614 = trunc i8 %1118 to i1 + %1117 = load i8, ptr %arrayidx.i.i.i613, align 1 + %tobool.i.i.i614 = trunc i8 %1117 to i1 br i1 %tobool.i.i.i614, label %if.end.i.i.i623, label %for.end.i if.end.i.i.i623: ; preds = %land.lhs.true.i611 - %MouseDownDuration.i.i.i = getelementptr inbounds nuw i8, ptr %1104, i64 14488 + %MouseDownDuration.i.i.i = getelementptr inbounds nuw i8, ptr %1103, i64 14488 %arrayidx3.i.i.i624 = getelementptr inbounds nuw [5 x float], ptr %MouseDownDuration.i.i.i, i64 0, i64 %idxprom.i.i.i612 - %1119 = load float, ptr %arrayidx3.i.i.i624, align 4 - %or.cond69.i625 = fcmp oeq float %1119, 0.000000e+00 + %1118 = load float, ptr %arrayidx3.i.i.i624, align 4 + %or.cond69.i625 = fcmp oeq float %1118, 0.000000e+00 br i1 %or.cond69.i625, label %if.end19.i.i.i, label %for.end.i if.end19.i.i.i: ; preds = %if.end.i.i.i623 - %or.cond.i.i.i.i = icmp ult i8 %1117, 11 + %or.cond.i.i.i.i = icmp ult i8 %1116, 11 br i1 %or.cond.i.i.i.i, label %if.end.i1.i.i, label %_ZN5ImGui14IsMouseClickedEib.exit.i if.end.i1.i.i: ; preds = %if.end19.i.i.i - %narrow.i628 = add nuw nsw i8 %1117, -113 + %narrow.i628 = add nuw nsw i8 %1116, -113 %idxprom.i.i.i.i629 = zext i8 %narrow.i628 to i64 %LockThisFrame.i.idx.i.i = mul nuw nsw i64 %idxprom.i.i.i.i629, 12 - %1120 = getelementptr i8, ptr %1104, i64 16568 - %LockThisFrame.i.i.i630 = getelementptr i8, ptr %1120, i64 %LockThisFrame.i.idx.i.i - %1121 = load i8, ptr %LockThisFrame.i.i.i630, align 4 - %1122 = and i8 %1121, 1 - %cmp14.i.i.i631 = icmp eq i8 %1122, 0 + %1119 = getelementptr i8, ptr %1103, i64 16568 + %LockThisFrame.i.i.i630 = getelementptr i8, ptr %1119, i64 %LockThisFrame.i.idx.i.i + %1120 = load i8, ptr %LockThisFrame.i.i.i630, align 4 + %1121 = and i8 %1120, 1 + %cmp14.i.i.i631 = icmp eq i8 %1121, 0 br label %_ZN5ImGui14IsMouseClickedEib.exit.i _ZN5ImGui14IsMouseClickedEib.exit.i: ; preds = %if.end.i1.i.i, %if.end19.i.i.i %retval.0.i.i.i = phi i1 [ %cmp14.i.i.i631, %if.end.i1.i.i ], [ true, %if.end19.i.i.i ] - %tobool7.i = icmp ne i32 %1106, 0 + %tobool7.i = icmp ne i32 %1105, 0 %or.cond.i626 = select i1 %retval.0.i.i.i, i1 %tobool7.i, i1 false br i1 %or.cond.i626, label %if.then8.i627, label %for.end.i if.then8.i627: ; preds = %_ZN5ImGui14IsMouseClickedEib.exit.i - store i32 %1106, ptr %DebugItemPickerBreakId.i, align 8 + store i32 %1105, ptr %DebugItemPickerBreakId.i, align 8 store i8 0, ptr %DebugItemPickerActive.i, align 1 br label %for.end.i for.body.us.preheader.i: ; preds = %if.end3.i - %MouseDown.i.i18.i = getelementptr inbounds nuw i8, ptr %1104, i64 3664 - %MouseDownDuration.i.i24.i = getelementptr inbounds nuw i8, ptr %1104, i64 14488 - %invariant.gep.i = getelementptr i8, ptr %1104, i64 18284 - %DebugItemPickerMouseButton18.i = getelementptr inbounds nuw i8, ptr %1104, i64 24604 + %MouseDown.i.i18.i = getelementptr inbounds nuw i8, ptr %1103, i64 3664 + %MouseDownDuration.i.i24.i = getelementptr inbounds nuw i8, ptr %1103, i64 14488 + %invariant.gep.i = getelementptr i8, ptr %1103, i64 18284 + %DebugItemPickerMouseButton18.i = getelementptr inbounds nuw i8, ptr %1103, i64 24604 br label %for.body.us.i for.body.us.i: ; preds = %for.inc.us.i, %for.body.us.preheader.i %indvars.iv.i632 = phi i64 [ 0, %for.body.us.preheader.i ], [ %indvars.iv.next.i633, %for.inc.us.i ] %arrayidx.i.i20.us.i = getelementptr inbounds nuw [5 x i8], ptr %MouseDown.i.i18.i, i64 0, i64 %indvars.iv.i632 - %1123 = load i8, ptr %arrayidx.i.i20.us.i, align 1 - %tobool.i.i21.us.i = trunc i8 %1123 to i1 + %1122 = load i8, ptr %arrayidx.i.i20.us.i, align 1 + %tobool.i.i21.us.i = trunc i8 %1122 to i1 br i1 %tobool.i.i21.us.i, label %if.end.i.i23.us.i, label %for.inc.us.i if.end.i.i23.us.i: ; preds = %for.body.us.i %arrayidx3.i.i25.us.i = getelementptr inbounds nuw [5 x float], ptr %MouseDownDuration.i.i24.i, i64 0, i64 %indvars.iv.i632 - %1124 = load float, ptr %arrayidx3.i.i25.us.i, align 4 - %or.cond70.us.i = fcmp oeq float %1124, 0.000000e+00 + %1123 = load float, ptr %arrayidx3.i.i25.us.i, align 4 + %or.cond70.us.i = fcmp oeq float %1123, 0.000000e+00 br i1 %or.cond70.us.i, label %if.end.i1.i34.us.i, label %for.inc.us.i if.end.i1.i34.us.i: ; preds = %if.end.i.i23.us.i - %1125 = mul nuw nsw i64 %indvars.iv.i632, 12 - %gep.us.i = getelementptr i8, ptr %invariant.gep.i, i64 %1125 - %1126 = load i8, ptr %gep.us.i, align 4 - %1127 = and i8 %1126, 1 - %cmp14.i.i48.us.i = icmp eq i8 %1127, 0 + %1124 = mul nuw nsw i64 %indvars.iv.i632, 12 + %gep.us.i = getelementptr i8, ptr %invariant.gep.i, i64 %1124 + %1125 = load i8, ptr %gep.us.i, align 4 + %1126 = and i8 %1125, 1 + %cmp14.i.i48.us.i = icmp eq i8 %1126, 0 br i1 %cmp14.i.i48.us.i, label %if.then16.us.i, label %for.inc.us.i if.then16.us.i: ; preds = %if.end.i1.i34.us.i @@ -29736,14 +29735,14 @@ for.inc.us.i: ; preds = %if.then16.us.i, %if for.end.i: ; preds = %for.inc.us.i, %land.lhs.true.i611, %if.end.i.i.i623, %_ZN5ImGui14IsMouseClickedEib.exit.i, %if.then8.i627 %DebugItemPickerMouseButton1879.i = phi ptr [ %DebugItemPickerMouseButton.i, %if.then8.i627 ], [ %DebugItemPickerMouseButton.i, %_ZN5ImGui14IsMouseClickedEib.exit.i ], [ %DebugItemPickerMouseButton.i, %if.end.i.i.i623 ], [ %DebugItemPickerMouseButton.i, %land.lhs.true.i611 ], [ %DebugItemPickerMouseButton18.i, %for.inc.us.i ] - %NextWindowData.i.i = getelementptr inbounds nuw i8, ptr %1104, i64 18888 - %1128 = load i32, ptr %NextWindowData.i.i, align 8 - %or.i.i615 = or i32 %1128, 64 + %NextWindowData.i.i = getelementptr inbounds nuw i8, ptr %1103, i64 18888 + %1127 = load i32, ptr %NextWindowData.i.i, align 8 + %or.i.i615 = or i32 %1127, 64 store i32 %or.i.i615, ptr %NextWindowData.i.i, align 8 - %BgAlphaVal.i.i = getelementptr inbounds nuw i8, ptr %1104, i64 18984 + %BgAlphaVal.i.i = getelementptr inbounds nuw i8, ptr %1103, i64 18984 store float 0x3FE6666660000000, ptr %BgAlphaVal.i.i, align 8 %call.i54.i = call noundef zeroext i1 @_ZN5ImGui14BeginTooltipExEii(i32 noundef 0, i32 noundef 0) - call void (ptr, ...) @_ZN5ImGui4TextEPKcz(ptr noundef nonnull @.str.620, i32 noundef %1106) + call void (ptr, ...) @_ZN5ImGui4TextEPKcz(ptr noundef nonnull @.str.620, i32 noundef %1105) call void (ptr, ...) @_ZN5ImGui4TextEPKcz(ptr noundef nonnull @.str.621) br i1 %cmp.i610, label %if.then24.i622, label %if.else.i616 @@ -29752,16 +29751,16 @@ if.then24.i622: ; preds = %for.end.i br label %if.end28.i621 if.else.i616: ; preds = %for.end.i - %tobool25.not.i = icmp eq i32 %1106, 0 - %1129 = load ptr, ptr @GImGui, align 8 - %Colors.i.i = getelementptr inbounds nuw i8, ptr %1129, i64 14804 + %tobool25.not.i = icmp eq i32 %1105, 0 + %1128 = load ptr, ptr @GImGui, align 8 + %Colors.i.i = getelementptr inbounds nuw i8, ptr %1128, i64 14804 %idxprom.i.i617 = zext i1 %tobool25.not.i to i64 %arrayidx.i.i618 = getelementptr inbounds nuw [53 x %struct.ImVec4], ptr %Colors.i.i, i64 0, i64 %idxprom.i.i617 - %1130 = load i8, ptr %DebugItemPickerMouseButton1879.i, align 4 - %idxprom.i619 = zext i8 %1130 to i64 + %1129 = load i8, ptr %DebugItemPickerMouseButton1879.i, align 4 + %idxprom.i619 = zext i8 %1129 to i64 %arrayidx.i620 = getelementptr inbounds nuw [3 x ptr], ptr @__const._ZN5ImGuiL25UpdateDebugToolItemPickerEv.mouse_button_names, i64 0, i64 %idxprom.i619 - %1131 = load ptr, ptr %arrayidx.i620, align 8 - call void (ptr, ptr, ...) @_ZN5ImGui11TextColoredERK6ImVec4PKcz(ptr noundef nonnull align 4 dereferenceable(16) %arrayidx.i.i618, ptr noundef nonnull @.str.626, ptr noundef %1131) + %1130 = load ptr, ptr %arrayidx.i620, align 8 + call void (ptr, ptr, ...) @_ZN5ImGui11TextColoredERK6ImVec4PKcz(ptr noundef nonnull align 4 dereferenceable(16) %arrayidx.i.i618, ptr noundef nonnull @.str.626, ptr noundef %1130) br label %if.end28.i621 if.end28.i621: ; preds = %if.else.i616, %if.then24.i622 @@ -29770,43 +29769,43 @@ if.end28.i621: ; preds = %if.else.i616, %if.t br label %_ZN5ImGuiL25UpdateDebugToolItemPickerEv.exit _ZN5ImGuiL25UpdateDebugToolItemPickerEv.exit: ; preds = %_ZN8ImVectorI14ImGuiGroupDataE6resizeEi.exit, %if.end28.i621 - %1132 = phi ptr [ %1104, %_ZN8ImVectorI14ImGuiGroupDataE6resizeEi.exit ], [ %.pre848, %if.end28.i621 ] - %DebugIDStackTool.i = getelementptr inbounds nuw i8, ptr %1132, i64 24648 - %DebugHookIdInfo.i = getelementptr inbounds nuw i8, ptr %1132, i64 16468 + %1131 = phi ptr [ %1103, %_ZN8ImVectorI14ImGuiGroupDataE6resizeEi.exit ], [ %.pre848, %if.end28.i621 ] + %DebugIDStackTool.i = getelementptr inbounds nuw i8, ptr %1131, i64 24648 + %DebugHookIdInfo.i = getelementptr inbounds nuw i8, ptr %1131, i64 16468 store i32 0, ptr %DebugHookIdInfo.i, align 4 - %FrameCount.i650 = getelementptr inbounds nuw i8, ptr %1132, i64 16224 - %1133 = load i32, ptr %FrameCount.i650, align 8 - %1134 = load i32, ptr %DebugIDStackTool.i, align 8 - %add.i651 = add nsw i32 %1134, 1 - %cmp.not.i652 = icmp eq i32 %1133, %add.i651 + %FrameCount.i650 = getelementptr inbounds nuw i8, ptr %1131, i64 16224 + %1132 = load i32, ptr %FrameCount.i650, align 8 + %1133 = load i32, ptr %DebugIDStackTool.i, align 8 + %add.i651 = add nsw i32 %1133, 1 + %cmp.not.i652 = icmp eq i32 %1132, %add.i651 br i1 %cmp.not.i652, label %if.end.i653, label %_ZN5ImGuiL27UpdateDebugToolStackQueriesEv.exit if.end.i653: ; preds = %_ZN5ImGuiL25UpdateDebugToolItemPickerEv.exit - %HoveredIdPreviousFrame.i654 = getelementptr inbounds nuw i8, ptr %1132, i64 16476 - %1135 = load i32, ptr %HoveredIdPreviousFrame.i654, align 4 - %tobool.not.i655 = icmp eq i32 %1135, 0 + %HoveredIdPreviousFrame.i654 = getelementptr inbounds nuw i8, ptr %1131, i64 16476 + %1134 = load i32, ptr %HoveredIdPreviousFrame.i654, align 4 + %tobool.not.i655 = icmp eq i32 %1134, 0 br i1 %tobool.not.i655, label %cond.false.i672, label %cond.end.i656 cond.false.i672: ; preds = %if.end.i653 - %ActiveId.i673 = getelementptr inbounds nuw i8, ptr %1132, i64 16492 - %1136 = load i32, ptr %ActiveId.i673, align 4 + %ActiveId.i673 = getelementptr inbounds nuw i8, ptr %1131, i64 16492 + %1135 = load i32, ptr %ActiveId.i673, align 4 br label %cond.end.i656 cond.end.i656: ; preds = %cond.false.i672, %if.end.i653 - %cond.i657 = phi i32 [ %1136, %cond.false.i672 ], [ %1135, %if.end.i653 ] - %QueryId.i = getelementptr inbounds nuw i8, ptr %1132, i64 24656 - %1137 = load i32, ptr %QueryId.i, align 8 - %cmp2.not.i658 = icmp eq i32 %1137, %cond.i657 + %cond.i657 = phi i32 [ %1135, %cond.false.i672 ], [ %1134, %if.end.i653 ] + %QueryId.i = getelementptr inbounds nuw i8, ptr %1131, i64 24656 + %1136 = load i32, ptr %QueryId.i, align 8 + %cmp2.not.i658 = icmp eq i32 %1136, %cond.i657 br i1 %cmp2.not.i658, label %if.end5.i, label %if.then3.i if.then3.i: ; preds = %cond.end.i656 store i32 %cond.i657, ptr %QueryId.i, align 8 - %StackLevel.i = getelementptr inbounds nuw i8, ptr %1132, i64 24652 + %StackLevel.i = getelementptr inbounds nuw i8, ptr %1131, i64 24652 store i32 -1, ptr %StackLevel.i, align 4 - %Results.i = getelementptr inbounds nuw i8, ptr %1132, i64 24664 - %Capacity.i.i = getelementptr inbounds nuw i8, ptr %1132, i64 24668 - %1138 = load i32, ptr %Capacity.i.i, align 4 - %cmp.i.i659 = icmp slt i32 %1138, 0 + %Results.i = getelementptr inbounds nuw i8, ptr %1131, i64 24664 + %Capacity.i.i = getelementptr inbounds nuw i8, ptr %1131, i64 24668 + %1137 = load i32, ptr %Capacity.i.i, align 4 + %cmp.i.i659 = icmp slt i32 %1137, 0 br i1 %cmp.i.i659, label %if.then.i.i671, label %_ZN8ImVectorI19ImGuiStackLevelInfoE6resizeEi.exit.i if.then.i.i671: ; preds = %if.then3.i @@ -29822,40 +29821,40 @@ if.end5.i: ; preds = %_ZN8ImVectorI19ImGu br i1 %cmp6.i, label %_ZN5ImGuiL27UpdateDebugToolStackQueriesEv.exit, label %if.end8.i if.end8.i: ; preds = %if.end5.i - %StackLevel9.i = getelementptr inbounds nuw i8, ptr %1132, i64 24652 - %1139 = load i32, ptr %StackLevel9.i, align 4 - %cmp10.i = icmp sgt i32 %1139, -1 + %StackLevel9.i = getelementptr inbounds nuw i8, ptr %1131, i64 24652 + %1138 = load i32, ptr %StackLevel9.i, align 4 + %cmp10.i = icmp sgt i32 %1138, -1 br i1 %cmp10.i, label %land.lhs.true.i661, label %if.end22.i land.lhs.true.i661: ; preds = %if.end8.i - %Results11.i = getelementptr inbounds nuw i8, ptr %1132, i64 24664 - %1140 = load i32, ptr %Results11.i, align 8 - %cmp12.i = icmp slt i32 %1139, %1140 + %Results11.i = getelementptr inbounds nuw i8, ptr %1131, i64 24664 + %1139 = load i32, ptr %Results11.i, align 8 + %cmp12.i = icmp slt i32 %1138, %1139 br i1 %cmp12.i, label %if.then13.i, label %land.lhs.true29.i if.then13.i: ; preds = %land.lhs.true.i661 - %Data.i.i665 = getelementptr inbounds nuw i8, ptr %1132, i64 24672 - %1141 = load ptr, ptr %Data.i.i665, align 8 - %idxprom.i.i666 = zext nneg i32 %1139 to i64 - %arrayidx.i.i667 = getelementptr inbounds nuw %struct.ImGuiStackLevelInfo, ptr %1141, i64 %idxprom.i.i666 + %Data.i.i665 = getelementptr inbounds nuw i8, ptr %1131, i64 24672 + %1140 = load ptr, ptr %Data.i.i665, align 8 + %idxprom.i.i666 = zext nneg i32 %1138 to i64 + %arrayidx.i.i667 = getelementptr inbounds nuw %struct.ImGuiStackLevelInfo, ptr %1140, i64 %idxprom.i.i666 %QuerySuccess.i = getelementptr inbounds nuw i8, ptr %arrayidx.i.i667, i64 5 - %1142 = load i8, ptr %QuerySuccess.i, align 1 - %tobool15.i = trunc i8 %1142 to i1 + %1141 = load i8, ptr %QuerySuccess.i, align 1 + %tobool15.i = trunc i8 %1141 to i1 br i1 %tobool15.i, label %if.end27.thread.i, label %lor.lhs.false.i668 lor.lhs.false.i668: ; preds = %if.then13.i %QueryFrameCount.i = getelementptr inbounds nuw i8, ptr %arrayidx.i.i667, i64 4 - %1143 = load i8, ptr %QueryFrameCount.i, align 4 - %cmp18.i669 = icmp sgt i8 %1143, 2 + %1142 = load i8, ptr %QueryFrameCount.i, align 4 + %cmp18.i669 = icmp sgt i8 %1142, 2 br i1 %cmp18.i669, label %if.end27.thread.i, label %land.lhs.true29.i if.end27.thread.i: ; preds = %lor.lhs.false.i668, %if.then13.i - %inc.i670 = add nuw nsw i32 %1139, 1 + %inc.i670 = add nuw nsw i32 %1138, 1 store i32 %inc.i670, ptr %StackLevel9.i, align 4 br label %land.lhs.true29.i if.end22.i: ; preds = %if.end8.i - %cmp24.i660 = icmp eq i32 %1139, -1 + %cmp24.i660 = icmp eq i32 %1138, -1 br i1 %cmp24.i660, label %if.end27.thread45.i, label %_ZN5ImGuiL27UpdateDebugToolStackQueriesEv.exit if.end27.thread45.i: ; preds = %if.end22.i @@ -29863,51 +29862,51 @@ if.end27.thread45.i: ; preds = %if.end22.i br label %_ZN5ImGuiL27UpdateDebugToolStackQueriesEv.exit land.lhs.true29.i: ; preds = %land.lhs.true.i661, %lor.lhs.false.i668, %if.end27.thread.i - %1144 = phi i32 [ %inc.i670, %if.end27.thread.i ], [ %1139, %lor.lhs.false.i668 ], [ %1139, %land.lhs.true.i661 ] - %cmp32.i663 = icmp slt i32 %1144, %1140 + %1143 = phi i32 [ %inc.i670, %if.end27.thread.i ], [ %1138, %lor.lhs.false.i668 ], [ %1138, %land.lhs.true.i661 ] + %cmp32.i663 = icmp slt i32 %1143, %1139 br i1 %cmp32.i663, label %if.then33.i664, label %_ZN5ImGuiL27UpdateDebugToolStackQueriesEv.exit if.then33.i664: ; preds = %land.lhs.true29.i - %Data.i37.i = getelementptr inbounds nuw i8, ptr %1132, i64 24672 - %1145 = load ptr, ptr %Data.i37.i, align 8 - %idxprom.i38.i = zext nneg i32 %1144 to i64 - %arrayidx.i39.i = getelementptr inbounds nuw %struct.ImGuiStackLevelInfo, ptr %1145, i64 %idxprom.i38.i - %1146 = load i32, ptr %arrayidx.i39.i, align 4 - store i32 %1146, ptr %DebugHookIdInfo.i, align 4 + %Data.i37.i = getelementptr inbounds nuw i8, ptr %1131, i64 24672 + %1144 = load ptr, ptr %Data.i37.i, align 8 + %idxprom.i38.i = zext nneg i32 %1143 to i64 + %arrayidx.i39.i = getelementptr inbounds nuw %struct.ImGuiStackLevelInfo, ptr %1144, i64 %idxprom.i38.i + %1145 = load i32, ptr %arrayidx.i39.i, align 4 + store i32 %1145, ptr %DebugHookIdInfo.i, align 4 %QueryFrameCount39.i = getelementptr inbounds nuw i8, ptr %arrayidx.i39.i, i64 4 - %1147 = load i8, ptr %QueryFrameCount39.i, align 4 - %inc40.i = add i8 %1147, 1 + %1146 = load i8, ptr %QueryFrameCount39.i, align 4 + %inc40.i = add i8 %1146, 1 store i8 %inc40.i, ptr %QueryFrameCount39.i, align 4 br label %_ZN5ImGuiL27UpdateDebugToolStackQueriesEv.exit _ZN5ImGuiL27UpdateDebugToolStackQueriesEv.exit: ; preds = %_ZN5ImGuiL25UpdateDebugToolItemPickerEv.exit, %if.end5.i, %if.end22.i, %if.end27.thread45.i, %land.lhs.true29.i, %if.then33.i664 - %1148 = load ptr, ptr @GImGui, align 8 - %DebugFlashStyleColorTime.i = getelementptr inbounds nuw i8, ptr %1148, i64 24612 - %1149 = load float, ptr %DebugFlashStyleColorTime.i, align 4 - %cmp.i674 = fcmp ugt float %1149, 0.000000e+00 + %1147 = load ptr, ptr @GImGui, align 8 + %DebugFlashStyleColorTime.i = getelementptr inbounds nuw i8, ptr %1147, i64 24612 + %1148 = load float, ptr %DebugFlashStyleColorTime.i, align 4 + %cmp.i674 = fcmp ugt float %1148, 0.000000e+00 br i1 %cmp.i674, label %if.end.i675, label %_ZN5ImGuiL30UpdateDebugToolFlashStyleColorEv.exit if.end.i675: ; preds = %_ZN5ImGuiL27UpdateDebugToolStackQueriesEv.exit - %mul.i676 = fmul float %1149, 6.000000e+00 + %mul.i676 = fmul float %1148, 6.000000e+00 %call.i677 = call float @cosf(float noundef %mul.i676) #39 - %1150 = call float @llvm.fmuladd.f32(float %call.i677, float 5.000000e-01, float 5.000000e-01) - %Colors.i = getelementptr inbounds nuw i8, ptr %1148, i64 14804 - %DebugFlashStyleColorIdx.i = getelementptr inbounds nuw i8, ptr %1148, i64 19004 - %1151 = load i32, ptr %DebugFlashStyleColorIdx.i, align 4 - %idxprom.i678 = sext i32 %1151 to i64 + %1149 = call float @llvm.fmuladd.f32(float %call.i677, float 5.000000e-01, float 5.000000e-01) + %Colors.i = getelementptr inbounds nuw i8, ptr %1147, i64 14804 + %DebugFlashStyleColorIdx.i = getelementptr inbounds nuw i8, ptr %1147, i64 19004 + %1150 = load i32, ptr %DebugFlashStyleColorIdx.i, align 4 + %idxprom.i678 = sext i32 %1150 to i64 %arrayidx.i679 = getelementptr inbounds [53 x %struct.ImVec4], ptr %Colors.i, i64 0, i64 %idxprom.i678 %y.i680 = getelementptr inbounds nuw i8, ptr %arrayidx.i679, i64 4 %z.i = getelementptr inbounds nuw i8, ptr %arrayidx.i679, i64 8 - %call.i.i681 = call float @fmodf(float noundef %1150, float noundef 1.000000e+00) #39 + %call.i.i681 = call float @fmodf(float noundef %1149, float noundef 1.000000e+00) #39 %div.i.i682 = fdiv float %call.i.i681, 0x3FC5555560000000 %conv.i.i683 = fptosi float %div.i.i682 to i32 %conv1.i.i684 = sitofp i32 %conv.i.i683 to float %sub.i.i685 = fsub float %div.i.i682, %conv1.i.i684 - %1152 = call float @llvm.fmuladd.f32(float %sub.i.i685, float -5.000000e-01, float 1.000000e+00) - %mul4.i.i686 = fmul float %1152, 5.000000e-01 + %1151 = call float @llvm.fmuladd.f32(float %sub.i.i685, float -5.000000e-01, float 1.000000e+00) + %mul4.i.i686 = fmul float %1151, 5.000000e-01 %sub5.i.i = fsub float 1.000000e+00, %sub.i.i685 - %1153 = call float @llvm.fmuladd.f32(float %sub5.i.i, float -5.000000e-01, float 1.000000e+00) - %mul8.i.i = fmul float %1153, 5.000000e-01 + %1152 = call float @llvm.fmuladd.f32(float %sub5.i.i, float -5.000000e-01, float 1.000000e+00) + %mul8.i.i = fmul float %1152, 5.000000e-01 switch i32 %conv.i.i683, label %sw.default.i.i [ i32 0, label %_ZN5ImGui20ColorConvertHSVtoRGBEfffRfS0_S0_.exit.i i32 1, label %sw.bb9.i.i @@ -29938,31 +29937,31 @@ _ZN5ImGui20ColorConvertHSVtoRGBEfffRfS0_S0_.exit.i: ; preds = %sw.default.i.i, % store float %.sink12.i, ptr %arrayidx.i679, align 4 store float %mul8.i.sink.i, ptr %y.i680, align 4 store float %.sink.i687, ptr %z.i, align 4 - %1154 = load i32, ptr %DebugFlashStyleColorIdx.i, align 4 - %idxprom16.i = sext i32 %1154 to i64 + %1153 = load i32, ptr %DebugFlashStyleColorIdx.i, align 4 + %idxprom16.i = sext i32 %1153 to i64 %w.idx.i = shl nsw i64 %idxprom16.i, 4 %w.offs.i = or disjoint i64 %w.idx.i, 12 %w.i = getelementptr inbounds i8, ptr %Colors.i, i64 %w.offs.i store float 1.000000e+00, ptr %w.i, align 4 - %DeltaTime.i688 = getelementptr inbounds nuw i8, ptr %1148, i64 24 - %1155 = load float, ptr %DeltaTime.i688, align 8 - %1156 = load float, ptr %DebugFlashStyleColorTime.i, align 4 - %sub.i689 = fsub float %1156, %1155 + %DeltaTime.i688 = getelementptr inbounds nuw i8, ptr %1147, i64 24 + %1154 = load float, ptr %DeltaTime.i688, align 8 + %1155 = load float, ptr %DebugFlashStyleColorTime.i, align 4 + %sub.i689 = fsub float %1155, %1154 store float %sub.i689, ptr %DebugFlashStyleColorTime.i, align 4 %cmp19.i = fcmp ugt float %sub.i689, 0.000000e+00 br i1 %cmp19.i, label %_ZN5ImGuiL30UpdateDebugToolFlashStyleColorEv.exit, label %if.then20.i if.then20.i: ; preds = %_ZN5ImGui20ColorConvertHSVtoRGBEfffRfS0_S0_.exit.i - %1157 = load ptr, ptr @GImGui, align 8 - %DebugFlashStyleColorIdx.i.i = getelementptr inbounds nuw i8, ptr %1157, i64 19004 - %1158 = load i32, ptr %DebugFlashStyleColorIdx.i.i, align 4 - %cmp.not.i.i690 = icmp eq i32 %1158, 53 + %1156 = load ptr, ptr @GImGui, align 8 + %DebugFlashStyleColorIdx.i.i = getelementptr inbounds nuw i8, ptr %1156, i64 19004 + %1157 = load i32, ptr %DebugFlashStyleColorIdx.i.i, align 4 + %cmp.not.i.i690 = icmp eq i32 %1157, 53 br i1 %cmp.not.i.i690, label %_ZL24DebugFlashStyleColorStopv.exit.i, label %if.then.i.i691 if.then.i.i691: ; preds = %if.then20.i - %DebugFlashStyleColorBackup.i.i = getelementptr inbounds nuw i8, ptr %1157, i64 24616 - %Colors.i.i692 = getelementptr inbounds nuw i8, ptr %1157, i64 14804 - %idxprom.i.i693 = sext i32 %1158 to i64 + %DebugFlashStyleColorBackup.i.i = getelementptr inbounds nuw i8, ptr %1156, i64 24616 + %Colors.i.i692 = getelementptr inbounds nuw i8, ptr %1156, i64 14804 + %idxprom.i.i693 = sext i32 %1157 to i64 %arrayidx.i.i694 = getelementptr inbounds [53 x %struct.ImVec4], ptr %Colors.i.i692, i64 0, i64 %idxprom.i.i693 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 4 dereferenceable(16) %arrayidx.i.i694, ptr noundef nonnull align 8 dereferenceable(16) %DebugFlashStyleColorBackup.i.i, i64 16, i1 false) br label %_ZL24DebugFlashStyleColorStopv.exit.i @@ -29973,12 +29972,12 @@ _ZL24DebugFlashStyleColorStopv.exit.i: ; preds = %if.then.i.i691, %if _ZN5ImGuiL30UpdateDebugToolFlashStyleColorEv.exit: ; preds = %_ZN5ImGuiL27UpdateDebugToolStackQueriesEv.exit, %_ZN5ImGui20ColorConvertHSVtoRGBEfffRfS0_S0_.exit.i, %_ZL24DebugFlashStyleColorStopv.exit.i %DebugLocateFrames = getelementptr inbounds nuw i8, ptr %0, i64 24601 - %1159 = load i8, ptr %DebugLocateFrames, align 1 - %cmp355.not = icmp eq i8 %1159, 0 + %1158 = load i8, ptr %DebugLocateFrames, align 1 + %cmp355.not = icmp eq i8 %1158, 0 br i1 %cmp355.not, label %if.end362, label %land.lhs.true356 land.lhs.true356: ; preds = %_ZN5ImGuiL30UpdateDebugToolFlashStyleColorEv.exit - %dec358 = add i8 %1159, -1 + %dec358 = add i8 %1158, -1 store i8 %dec358, ptr %DebugLocateFrames, align 1 %cmp360 = icmp eq i8 %dec358, 0 br i1 %cmp360, label %if.then361, label %if.end362 @@ -29990,12 +29989,12 @@ if.then361: ; preds = %land.lhs.true356 if.end362: ; preds = %if.then361, %land.lhs.true356, %_ZN5ImGuiL30UpdateDebugToolFlashStyleColorEv.exit %DebugLogClipperAutoDisableFrames = getelementptr inbounds nuw i8, ptr %0, i64 24600 - %1160 = load i8, ptr %DebugLogClipperAutoDisableFrames, align 8 - %cmp364.not = icmp eq i8 %1160, 0 + %1159 = load i8, ptr %DebugLogClipperAutoDisableFrames, align 8 + %cmp364.not = icmp eq i8 %1159, 0 br i1 %cmp364.not, label %if.end373, label %land.lhs.true365 land.lhs.true365: ; preds = %if.end362 - %dec367 = add i8 %1160, -1 + %dec367 = add i8 %1159, -1 store i8 %dec367, ptr %DebugLogClipperAutoDisableFrames, align 8 %cmp369 = icmp eq i8 %dec367, 0 br i1 %cmp369, label %if.then370, label %if.end373 @@ -30003,69 +30002,69 @@ land.lhs.true365: ; preds = %if.end362 if.then370: ; preds = %land.lhs.true365 call void (ptr, ...) @_ZN5ImGui8DebugLogEPKcz(ptr noundef nonnull @.str.72) %DebugLogFlags371 = getelementptr inbounds nuw i8, ptr %0, i64 24556 - %1161 = load i32, ptr %DebugLogFlags371, align 4 - %and372 = and i32 %1161, -17 + %1160 = load i32, ptr %DebugLogFlags371, align 4 + %and372 = and i32 %1160, -17 store i32 %and372, ptr %DebugLogFlags371, align 4 br label %if.end373 if.end373: ; preds = %if.then370, %land.lhs.true365, %if.end362 %WithinFrameScopeWithImplicitWindow = getelementptr inbounds nuw i8, ptr %0, i64 16237 store i8 1, ptr %WithinFrameScopeWithImplicitWindow, align 1 - %1162 = load ptr, ptr @GImGui, align 8 - %NextWindowData.i = getelementptr inbounds nuw i8, ptr %1162, i64 18888 - %1163 = load i32, ptr %NextWindowData.i, align 8 - %or.i = or i32 %1163, 2 + %1161 = load ptr, ptr @GImGui, align 8 + %NextWindowData.i = getelementptr inbounds nuw i8, ptr %1161, i64 18888 + %1162 = load i32, ptr %NextWindowData.i, align 8 + %or.i = or i32 %1162, 2 store i32 %or.i, ptr %NextWindowData.i, align 8 - %SizeVal.i = getelementptr inbounds nuw i8, ptr %1162, i64 18920 + %SizeVal.i = getelementptr inbounds nuw i8, ptr %1161, i64 18920 store i32 1137180672, ptr %SizeVal.i, align 8 - %SizeVal.i.sroa_idx = getelementptr inbounds nuw i8, ptr %1162, i64 18924 + %SizeVal.i.sroa_idx = getelementptr inbounds nuw i8, ptr %1161, i64 18924 store i32 1137180672, ptr %SizeVal.i.sroa_idx, align 4 - %SizeCond.i = getelementptr inbounds nuw i8, ptr %1162, i64 18896 + %SizeCond.i = getelementptr inbounds nuw i8, ptr %1161, i64 18896 store i32 4, ptr %SizeCond.i, align 8 %call375 = call noundef zeroext i1 @_ZN5ImGui5BeginEPKcPbi(ptr noundef nonnull @.str.73, ptr noundef null, i32 noundef 0) %ConfigDebugBeginReturnValueLoop = getelementptr inbounds nuw i8, ptr %0, i64 121 - %1164 = load i8, ptr %ConfigDebugBeginReturnValueLoop, align 1 - %tobool377 = trunc i8 %1164 to i1 + %1163 = load i8, ptr %ConfigDebugBeginReturnValueLoop, align 1 + %tobool377 = trunc i8 %1163 to i1 %DebugBeginReturnValueCullDepth = getelementptr inbounds nuw i8, ptr %0, i64 24602 br i1 %tobool377, label %if.then378, label %if.end397 if.then378: ; preds = %if.end373 - %1165 = load i8, ptr %DebugBeginReturnValueCullDepth, align 2 - %cmp380 = icmp eq i8 %1165, -1 + %1164 = load i8, ptr %DebugBeginReturnValueCullDepth, align 2 + %cmp380 = icmp eq i8 %1164, -1 br i1 %cmp380, label %if.end397, label %cond.false382 cond.false382: ; preds = %if.then378 - %conv379 = sext i8 %1165 to i16 - %1166 = load i32, ptr %FrameCount, align 8 - %1167 = and i32 %1166, 3 - %cmp387 = icmp eq i32 %1167, 0 + %conv379 = sext i8 %1164 to i16 + %1165 = load i32, ptr %FrameCount, align 8 + %1166 = and i32 %1165, 3 + %cmp387 = icmp eq i32 %1166, 0 %cond388 = zext i1 %cmp387 to i16 %add389 = add nsw i16 %cond388, %conv379 %rem390795 = srem i16 %add389, 10 - %1168 = trunc nsw i16 %rem390795 to i8 + %1167 = trunc nsw i16 %rem390795 to i8 br label %if.end397 if.end397: ; preds = %if.end373, %cond.false382, %if.then378 - %.sink891 = phi i8 [ %1168, %cond.false382 ], [ 0, %if.then378 ], [ -1, %if.end373 ] + %.sink891 = phi i8 [ %1167, %cond.false382 ], [ 0, %if.then378 ], [ -1, %if.end373 ] store i8 %.sink891, ptr %DebugBeginReturnValueCullDepth, align 2 - %1169 = load ptr, ptr %Data.i.i, align 8 - %1170 = load i32, ptr %Hooks, align 8 - %idx.ext.i.i698 = sext i32 %1170 to i64 - %add.ptr.i.i699 = getelementptr inbounds %struct.ImGuiContextHook, ptr %1169, i64 %idx.ext.i.i698 - %cmp.not8.i700 = icmp eq i32 %1170, 0 + %1168 = load ptr, ptr %Data.i.i, align 8 + %1169 = load i32, ptr %Hooks, align 8 + %idx.ext.i.i698 = sext i32 %1169 to i64 + %add.ptr.i.i699 = getelementptr inbounds %struct.ImGuiContextHook, ptr %1168, i64 %idx.ext.i.i698 + %cmp.not8.i700 = icmp eq i32 %1169, 0 br i1 %cmp.not8.i700, label %_ZN5ImGui16CallContextHooksEP12ImGuiContext20ImGuiContextHookType.exit711, label %for.body.i701 for.body.i701: ; preds = %if.end397, %for.inc.i705 - %__begin1.09.i702 = phi ptr [ %incdec.ptr.i706, %for.inc.i705 ], [ %1169, %if.end397 ] + %__begin1.09.i702 = phi ptr [ %incdec.ptr.i706, %for.inc.i705 ], [ %1168, %if.end397 ] %Type.i703 = getelementptr inbounds nuw i8, ptr %__begin1.09.i702, i64 4 - %1171 = load i32, ptr %Type.i703, align 4 - %cmp2.i704 = icmp eq i32 %1171, 1 + %1170 = load i32, ptr %Type.i703, align 4 + %cmp2.i704 = icmp eq i32 %1170, 1 br i1 %cmp2.i704, label %if.then.i709, label %for.inc.i705 if.then.i709: ; preds = %for.body.i701 %Callback.i710 = getelementptr inbounds nuw i8, ptr %__begin1.09.i702, i64 16 - %1172 = load ptr, ptr %Callback.i710, align 8 - call void %1172(ptr noundef %0, ptr noundef nonnull %__begin1.09.i702) + %1171 = load ptr, ptr %Callback.i710, align 8 + call void %1171(ptr noundef %0, ptr noundef nonnull %__begin1.09.i702) br label %for.inc.i705 for.inc.i705: ; preds = %if.then.i709, %for.body.i701 diff --git a/bench/libwebp/optimized/frame_enc.c.ll b/bench/libwebp/optimized/frame_enc.c.ll index 8de5866bd7e..97a16780225 100644 --- a/bench/libwebp/optimized/frame_enc.c.ll +++ b/bench/libwebp/optimized/frame_enc.c.ll @@ -70,7 +70,7 @@ PreLoopInitialize.exit: ; preds = %30 %34 = load ptr, ptr %33, align 8 %35 = tail call i32 @WebPEncodingSetError(ptr noundef %34, i32 noundef 1) #7 %.not = icmp eq i32 %35, 0 - br i1 %.not, label %418, label %PreLoopInitialize.exit.thread + br i1 %.not, label %416, label %PreLoopInitialize.exit.thread PreLoopInitialize.exit.thread: ; preds = %26, %PreLoopInitialize.exit %36 = getelementptr inbounds nuw i8, ptr %0, i64 23616 @@ -490,12 +490,10 @@ ComputeNextQ.exit.i: ; preds = %248, %246, %242 %262 = fcmp ogt float %260, %66 %263 = select i1 %262, float %66, float %260 %264 = select i1 %261, float %63, float %263 - %265 = call float @llvm.fabs.f32(float %.0.i56.i) + %265 = call float @llvm.fabs.f32(float %259) %266 = fpext float %265 to double %267 = fcmp ugt double %266, 4.000000e-01 - %268 = or i1 %257, %267 - %269 = or i1 %256, %268 - br i1 %269, label %.outer.i, label %.loopexit66.i + br i1 %267, label %.outer.i, label %.loopexit66.i .outer.i: ; preds = %ComputeNextQ.exit.i, %240 %.sroa.23.1.i = phi double [ %.sroa.20.1.i, %ComputeNextQ.exit.i ], [ %.sroa.23.0.ph80.i, %240 ] @@ -503,283 +501,283 @@ ComputeNextQ.exit.i: ; preds = %248, %246, %242 %.sroa.8.1.i = phi float [ %264, %ComputeNextQ.exit.i ], [ %.sroa.8.0.ph82.i, %240 ] %.sroa.3.1.i = phi float [ %259, %ComputeNextQ.exit.i ], [ %.sroa.3.0.ph83.i, %240 ] %.sroa.0.1.i = phi i32 [ 0, %ComputeNextQ.exit.i ], [ %.sroa.0.0.ph84.i, %240 ] - %270 = icmp sgt i32 %.in.i, 1 - br i1 %270, label %.lr.ph.i, label %.loopexit66.i, !llvm.loop !12 + %268 = icmp sgt i32 %.in.i, 1 + br i1 %268, label %.lr.ph.i, label %.loopexit66.i, !llvm.loop !12 .loopexit66.i: ; preds = %.outer.i, %ComputeNextQ.exit.i, %239, %91 %or.cond8.i = and i1 %42, %60 - br i1 %or.cond8.i, label %290, label %271 + br i1 %or.cond8.i, label %288, label %269 -271: ; preds = %.loopexit66.i - %272 = load i32, ptr %15, align 8 - %273 = load i32, ptr %17, align 4 - %274 = mul nsw i32 %273, %272 - %.not.i.i.i = icmp eq i32 %274, 0 +269: ; preds = %.loopexit66.i + %270 = load i32, ptr %15, align 8 + %271 = load i32, ptr %17, align 4 + %272 = mul nsw i32 %271, %270 + %.not.i.i.i = icmp eq i32 %272, 0 br i1 %.not.i.i.i, label %FinalizeSkipProba.exit.i, label %CalcSkipProba.exit.i.i -CalcSkipProba.exit.i.i: ; preds = %271 - %275 = getelementptr inbounds nuw i8, ptr %0, i64 23504 - %276 = load i32, ptr %275, align 8 - %277 = sext i32 %274 to i64 - %278 = sext i32 %276 to i64 - %279 = sub nsw i64 %277, %278 - %280 = mul nsw i64 %279, 255 - %281 = udiv i64 %280, %277 - %282 = trunc i64 %281 to i8 - %283 = and i64 %281, 254 - %284 = icmp samesign ult i64 %283, 250 - %285 = zext i1 %284 to i32 +CalcSkipProba.exit.i.i: ; preds = %269 + %273 = getelementptr inbounds nuw i8, ptr %0, i64 23504 + %274 = load i32, ptr %273, align 8 + %275 = sext i32 %272 to i64 + %276 = sext i32 %274 to i64 + %277 = sub nsw i64 %275, %276 + %278 = mul nsw i64 %277, 255 + %279 = udiv i64 %278, %275 + %280 = trunc i64 %279 to i8 + %281 = and i64 %279, 254 + %282 = icmp samesign ult i64 %281, 250 + %283 = zext i1 %282 to i32 br label %FinalizeSkipProba.exit.i -FinalizeSkipProba.exit.i: ; preds = %CalcSkipProba.exit.i.i, %271 - %.sink96.i = phi i8 [ %282, %CalcSkipProba.exit.i.i ], [ -1, %271 ] - %.sink.i = phi i32 [ %285, %CalcSkipProba.exit.i.i ], [ 0, %271 ] - %286 = getelementptr inbounds nuw i8, ptr %0, i64 3619 - store i8 %.sink96.i, ptr %286, align 1 - %287 = getelementptr inbounds nuw i8, ptr %0, i64 23500 - store i32 %.sink.i, ptr %287, align 4 - %288 = getelementptr inbounds nuw i8, ptr %0, i64 3616 - %289 = call fastcc i32 @FinalizeTokenProbas(ptr noundef nonnull %288) - br label %290 - -290: ; preds = %FinalizeSkipProba.exit.i, %.loopexit66.i - %291 = getelementptr inbounds nuw i8, ptr %0, i64 3616 - call void @VP8CalculateLevelCosts(ptr noundef nonnull %291) #7 - %292 = getelementptr inbounds nuw i8, ptr %0, i64 8 - %293 = load ptr, ptr %292, align 8 - %294 = call i32 @WebPReportProgress(ptr noundef %293, i32 noundef %51, ptr noundef nonnull %49) #7 +FinalizeSkipProba.exit.i: ; preds = %CalcSkipProba.exit.i.i, %269 + %.sink96.i = phi i8 [ %280, %CalcSkipProba.exit.i.i ], [ -1, %269 ] + %.sink.i = phi i32 [ %283, %CalcSkipProba.exit.i.i ], [ 0, %269 ] + %284 = getelementptr inbounds nuw i8, ptr %0, i64 3619 + store i8 %.sink96.i, ptr %284, align 1 + %285 = getelementptr inbounds nuw i8, ptr %0, i64 23500 + store i32 %.sink.i, ptr %285, align 4 + %286 = getelementptr inbounds nuw i8, ptr %0, i64 3616 + %287 = call fastcc i32 @FinalizeTokenProbas(ptr noundef nonnull %286) + br label %288 + +288: ; preds = %FinalizeSkipProba.exit.i, %.loopexit66.i + %289 = getelementptr inbounds nuw i8, ptr %0, i64 3616 + call void @VP8CalculateLevelCosts(ptr noundef nonnull %289) #7 + %290 = getelementptr inbounds nuw i8, ptr %0, i64 8 + %291 = load ptr, ptr %290, align 8 + %292 = call i32 @WebPReportProgress(ptr noundef %291, i32 noundef %51, ptr noundef nonnull %49) #7 br label %StatLoop.exit -StatLoop.exit: ; preds = %OneStatPass.exit.i, %OneStatPass.exit.thread.i, %290 +StatLoop.exit: ; preds = %OneStatPass.exit.i, %OneStatPass.exit.thread.i, %288 call void @VP8IteratorInit(ptr noundef nonnull %0, ptr noundef nonnull %6) #7 call void @VP8InitFilter(ptr noundef nonnull %6) #7 - %295 = getelementptr inbounds nuw i8, ptr %0, i64 23500 - %296 = getelementptr inbounds nuw i8, ptr %0, i64 23620 - %297 = getelementptr inbounds nuw i8, ptr %6, i64 48 - %298 = getelementptr inbounds nuw i8, ptr %6, i64 72 - %299 = getelementptr inbounds nuw i8, ptr %6, i64 200 - %300 = getelementptr inbounds nuw i8, ptr %6, i64 56 - %301 = getelementptr inbounds nuw i8, ptr %6, i64 40 - %302 = getelementptr inbounds nuw i8, ptr %7, i64 40 - %303 = getelementptr inbounds nuw i8, ptr %6, i64 164 - %304 = getelementptr inbounds nuw i8, ptr %6, i64 132 - %305 = getelementptr inbounds nuw i8, ptr %6, i64 168 - %306 = getelementptr inbounds nuw i8, ptr %7, i64 72 - %307 = getelementptr inbounds nuw i8, ptr %7, i64 584 - %308 = getelementptr inbounds nuw i8, ptr %6, i64 304 - %309 = getelementptr inbounds nuw i8, ptr %6, i64 312 - %310 = getelementptr inbounds nuw i8, ptr %6, i64 208 + %293 = getelementptr inbounds nuw i8, ptr %0, i64 23500 + %294 = getelementptr inbounds nuw i8, ptr %0, i64 23620 + %295 = getelementptr inbounds nuw i8, ptr %6, i64 48 + %296 = getelementptr inbounds nuw i8, ptr %6, i64 72 + %297 = getelementptr inbounds nuw i8, ptr %6, i64 200 + %298 = getelementptr inbounds nuw i8, ptr %6, i64 56 + %299 = getelementptr inbounds nuw i8, ptr %6, i64 40 + %300 = getelementptr inbounds nuw i8, ptr %7, i64 40 + %301 = getelementptr inbounds nuw i8, ptr %6, i64 164 + %302 = getelementptr inbounds nuw i8, ptr %6, i64 132 + %303 = getelementptr inbounds nuw i8, ptr %6, i64 168 + %304 = getelementptr inbounds nuw i8, ptr %7, i64 72 + %305 = getelementptr inbounds nuw i8, ptr %7, i64 584 + %306 = getelementptr inbounds nuw i8, ptr %6, i64 304 + %307 = getelementptr inbounds nuw i8, ptr %6, i64 312 + %308 = getelementptr inbounds nuw i8, ptr %6, i64 208 %invariant.gep = getelementptr inbounds nuw i8, ptr %6, i64 224 - br label %311 + br label %309 -311: ; preds = %415, %StatLoop.exit - %312 = load i32, ptr %295, align 4 - %.not13 = icmp eq i32 %312, 0 - %313 = load i32, ptr %296, align 4 +309: ; preds = %413, %StatLoop.exit + %310 = load i32, ptr %293, align 4 + %.not13 = icmp eq i32 %310, 0 + %311 = load i32, ptr %294, align 4 call void @VP8IteratorImport(ptr noundef nonnull %6, ptr noundef null) #7 - %314 = call i32 @VP8Decimate(ptr noundef nonnull %6, ptr noundef nonnull %7, i32 noundef %313) #7 - %315 = icmp eq i32 %314, 0 - %or.cond = select i1 %315, i1 true, i1 %.not13 - br i1 %or.cond, label %316, label %404 + %312 = call i32 @VP8Decimate(ptr noundef nonnull %6, ptr noundef nonnull %7, i32 noundef %311) #7 + %313 = icmp eq i32 %312, 0 + %or.cond = select i1 %313, i1 true, i1 %.not13 + br i1 %or.cond, label %314, label %402 -316: ; preds = %311 - %317 = load ptr, ptr %300, align 8 +314: ; preds = %309 + %315 = load ptr, ptr %298, align 8 call void @llvm.lifetime.start.p0(i64 48, ptr nonnull %2) - %318 = load ptr, ptr %297, align 8 - %319 = load i8, ptr %318, align 4 - %320 = and i8 %319, 3 - %321 = icmp eq i8 %320, 1 - %322 = load ptr, ptr %301, align 8 + %316 = load ptr, ptr %295, align 8 + %317 = load i8, ptr %316, align 4 + %318 = and i8 %317, 3 + %319 = icmp eq i8 %318, 1 + %320 = load ptr, ptr %299, align 8 call void @VP8IteratorNzToBytes(ptr noundef nonnull %6) #7 - %323 = getelementptr inbounds nuw i8, ptr %317, i64 12 - %324 = load i32, ptr %323, align 4 - %325 = getelementptr inbounds nuw i8, ptr %317, i64 24 - %326 = load i64, ptr %325, align 8 - %327 = getelementptr inbounds nuw i8, ptr %317, i64 8 - %328 = load i32, ptr %327, align 8 - br i1 %321, label %329, label %335 - -329: ; preds = %316 - call void @VP8InitResidual(i32 noundef 0, i32 noundef 1, ptr noundef %322, ptr noundef nonnull %2) #7 - %330 = load ptr, ptr @VP8SetResidualCoeffs, align 8 - call void %330(ptr noundef nonnull %302, ptr noundef nonnull %2) #7 - %331 = load i32, ptr %303, align 4 - %332 = load i32, ptr %299, align 8 - %333 = add nsw i32 %332, %331 - %334 = call fastcc i32 @PutCoeffs(ptr noundef nonnull %317, i32 noundef %333, ptr noundef %2) - store i32 %334, ptr %299, align 8 - store i32 %334, ptr %303, align 4 - call void @VP8InitResidual(i32 noundef 1, i32 noundef 0, ptr noundef %322, ptr noundef nonnull %2) #7 + %321 = getelementptr inbounds nuw i8, ptr %315, i64 12 + %322 = load i32, ptr %321, align 4 + %323 = getelementptr inbounds nuw i8, ptr %315, i64 24 + %324 = load i64, ptr %323, align 8 + %325 = getelementptr inbounds nuw i8, ptr %315, i64 8 + %326 = load i32, ptr %325, align 8 + br i1 %319, label %327, label %333 + +327: ; preds = %314 + call void @VP8InitResidual(i32 noundef 0, i32 noundef 1, ptr noundef %320, ptr noundef nonnull %2) #7 + %328 = load ptr, ptr @VP8SetResidualCoeffs, align 8 + call void %328(ptr noundef nonnull %300, ptr noundef nonnull %2) #7 + %329 = load i32, ptr %301, align 4 + %330 = load i32, ptr %297, align 8 + %331 = add nsw i32 %330, %329 + %332 = call fastcc i32 @PutCoeffs(ptr noundef nonnull %315, i32 noundef %331, ptr noundef %2) + store i32 %332, ptr %297, align 8 + store i32 %332, ptr %301, align 4 + call void @VP8InitResidual(i32 noundef 1, i32 noundef 0, ptr noundef %320, ptr noundef nonnull %2) #7 br label %.preheader79.i.preheader -335: ; preds = %316 - call void @VP8InitResidual(i32 noundef 0, i32 noundef 3, ptr noundef %322, ptr noundef nonnull %2) #7 +333: ; preds = %314 + call void @VP8InitResidual(i32 noundef 0, i32 noundef 3, ptr noundef %320, ptr noundef nonnull %2) #7 br label %.preheader79.i.preheader -.preheader79.i.preheader: ; preds = %335, %329 +.preheader79.i.preheader: ; preds = %333, %327 br label %.preheader79.i -.preheader79.i: ; preds = %.preheader79.i.preheader, %347 - %indvars.iv86.i = phi i64 [ %indvars.iv.next87.i, %347 ], [ 0, %.preheader79.i.preheader ] - %336 = getelementptr inbounds nuw [9 x i32], ptr %305, i64 0, i64 %indvars.iv86.i - %337 = shl nuw nsw i64 %indvars.iv86.i, 2 - br label %338 - -338: ; preds = %338, %.preheader79.i - %indvars.iv.i18 = phi i64 [ 0, %.preheader79.i ], [ %indvars.iv.next.i19, %338 ] - %339 = getelementptr inbounds nuw [9 x i32], ptr %304, i64 0, i64 %indvars.iv.i18 - %340 = load i32, ptr %339, align 4 - %341 = load i32, ptr %336, align 4 - %342 = add nsw i32 %341, %340 - %343 = load ptr, ptr @VP8SetResidualCoeffs, align 8 - %344 = add nuw nsw i64 %indvars.iv.i18, %337 - %345 = getelementptr inbounds nuw [16 x [16 x i16]], ptr %306, i64 0, i64 %344 - call void %343(ptr noundef nonnull %345, ptr noundef nonnull %2) #7 - %346 = call fastcc i32 @PutCoeffs(ptr noundef %317, i32 noundef %342, ptr noundef %2) - store i32 %346, ptr %336, align 4 - store i32 %346, ptr %339, align 4 +.preheader79.i: ; preds = %.preheader79.i.preheader, %345 + %indvars.iv86.i = phi i64 [ %indvars.iv.next87.i, %345 ], [ 0, %.preheader79.i.preheader ] + %334 = getelementptr inbounds nuw [9 x i32], ptr %303, i64 0, i64 %indvars.iv86.i + %335 = shl nuw nsw i64 %indvars.iv86.i, 2 + br label %336 + +336: ; preds = %336, %.preheader79.i + %indvars.iv.i18 = phi i64 [ 0, %.preheader79.i ], [ %indvars.iv.next.i19, %336 ] + %337 = getelementptr inbounds nuw [9 x i32], ptr %302, i64 0, i64 %indvars.iv.i18 + %338 = load i32, ptr %337, align 4 + %339 = load i32, ptr %334, align 4 + %340 = add nsw i32 %339, %338 + %341 = load ptr, ptr @VP8SetResidualCoeffs, align 8 + %342 = add nuw nsw i64 %indvars.iv.i18, %335 + %343 = getelementptr inbounds nuw [16 x [16 x i16]], ptr %304, i64 0, i64 %342 + call void %341(ptr noundef nonnull %343, ptr noundef nonnull %2) #7 + %344 = call fastcc i32 @PutCoeffs(ptr noundef %315, i32 noundef %340, ptr noundef %2) + store i32 %344, ptr %334, align 4 + store i32 %344, ptr %337, align 4 %indvars.iv.next.i19 = add nuw nsw i64 %indvars.iv.i18, 1 %exitcond.not.i = icmp eq i64 %indvars.iv.next.i19, 4 - br i1 %exitcond.not.i, label %347, label %338, !llvm.loop !13 + br i1 %exitcond.not.i, label %345, label %336, !llvm.loop !13 -347: ; preds = %338 +345: ; preds = %336 %indvars.iv.next87.i = add nuw nsw i64 %indvars.iv86.i, 1 %exitcond89.not.i = icmp eq i64 %indvars.iv.next87.i, 4 - br i1 %exitcond89.not.i, label %348, label %.preheader79.i, !llvm.loop !14 + br i1 %exitcond89.not.i, label %346, label %.preheader79.i, !llvm.loop !14 -348: ; preds = %347 - %349 = load i32, ptr %323, align 4 - %350 = load i64, ptr %325, align 8 - %351 = load i32, ptr %327, align 8 - call void @VP8InitResidual(i32 noundef 0, i32 noundef 2, ptr noundef %322, ptr noundef nonnull %2) #7 +346: ; preds = %345 + %347 = load i32, ptr %321, align 4 + %348 = load i64, ptr %323, align 8 + %349 = load i32, ptr %325, align 8 + call void @VP8InitResidual(i32 noundef 0, i32 noundef 2, ptr noundef %320, ptr noundef nonnull %2) #7 br label %.preheader78.i -.preheader78.i: ; preds = %371, %348 - %352 = phi i1 [ true, %348 ], [ false, %371 ] - %indvars.iv96.i = phi i64 [ 0, %348 ], [ 2, %371 ] - %353 = or disjoint i64 %indvars.iv96.i, 4 +.preheader78.i: ; preds = %369, %346 + %350 = phi i1 [ true, %346 ], [ false, %369 ] + %indvars.iv96.i = phi i64 [ 0, %346 ], [ 2, %369 ] + %351 = or disjoint i64 %indvars.iv96.i, 4 br label %.preheader.i -.preheader.i: ; preds = %370, %.preheader78.i - %354 = phi i1 [ true, %.preheader78.i ], [ false, %370 ] - %indvars.iv93.i = phi i64 [ 0, %.preheader78.i ], [ 1, %370 ] - %355 = or disjoint i64 %indvars.iv93.i, %353 - %356 = getelementptr inbounds nuw [9 x i32], ptr %305, i64 0, i64 %355 - %357 = or disjoint i64 %indvars.iv93.i, %indvars.iv96.i - %358 = shl nuw nsw i64 %357, 1 - %.pre = load i32, ptr %356, align 4 - br label %359 - -359: ; preds = %359, %.preheader.i - %360 = phi i32 [ %.pre, %.preheader.i ], [ %369, %359 ] - %361 = phi i1 [ true, %.preheader.i ], [ false, %359 ] - %indvars.iv90.i = phi i64 [ 0, %.preheader.i ], [ 1, %359 ] - %362 = or disjoint i64 %indvars.iv90.i, %353 - %363 = getelementptr inbounds nuw [9 x i32], ptr %304, i64 0, i64 %362 - %364 = load i32, ptr %363, align 4 - %365 = add nsw i32 %360, %364 - %366 = load ptr, ptr @VP8SetResidualCoeffs, align 8 - %367 = or disjoint i64 %indvars.iv90.i, %358 - %368 = getelementptr inbounds nuw [8 x [16 x i16]], ptr %307, i64 0, i64 %367 - call void %366(ptr noundef nonnull %368, ptr noundef nonnull %2) #7 - %369 = call fastcc i32 @PutCoeffs(ptr noundef %317, i32 noundef %365, ptr noundef %2) - store i32 %369, ptr %356, align 4 - store i32 %369, ptr %363, align 4 - br i1 %361, label %359, label %370, !llvm.loop !15 - -370: ; preds = %359 - br i1 %354, label %.preheader.i, label %371, !llvm.loop !16 - -371: ; preds = %370 - br i1 %352, label %.preheader78.i, label %CodeResiduals.exit, !llvm.loop !17 - -CodeResiduals.exit: ; preds = %371 - %372 = sext i32 %351 to i64 - %373 = add i64 %350, %372 - %374 = shl i64 %373, 3 - %375 = add nsw i32 %349, 8 - %376 = sext i32 %375 to i64 - %377 = add i64 %374, %376 - %378 = sext i32 %328 to i64 - %379 = add i64 %326, %378 - %380 = lshr i8 %319, 5 - %381 = and i8 %380, 3 - %382 = load i32, ptr %323, align 4 - %383 = add nsw i32 %382, 8 - %384 = sext i32 %383 to i64 - %385 = load i64, ptr %325, align 8 - %386 = load i32, ptr %327, align 8 - %387 = sext i32 %386 to i64 - %388 = add i64 %385, %387 - %389 = shl i64 %388, 3 - %narrow.i = sub nsw i32 -8, %324 +.preheader.i: ; preds = %368, %.preheader78.i + %352 = phi i1 [ true, %.preheader78.i ], [ false, %368 ] + %indvars.iv93.i = phi i64 [ 0, %.preheader78.i ], [ 1, %368 ] + %353 = or disjoint i64 %indvars.iv93.i, %351 + %354 = getelementptr inbounds nuw [9 x i32], ptr %303, i64 0, i64 %353 + %355 = or disjoint i64 %indvars.iv93.i, %indvars.iv96.i + %356 = shl nuw nsw i64 %355, 1 + %.pre = load i32, ptr %354, align 4 + br label %357 + +357: ; preds = %357, %.preheader.i + %358 = phi i32 [ %.pre, %.preheader.i ], [ %367, %357 ] + %359 = phi i1 [ true, %.preheader.i ], [ false, %357 ] + %indvars.iv90.i = phi i64 [ 0, %.preheader.i ], [ 1, %357 ] + %360 = or disjoint i64 %indvars.iv90.i, %351 + %361 = getelementptr inbounds nuw [9 x i32], ptr %302, i64 0, i64 %360 + %362 = load i32, ptr %361, align 4 + %363 = add nsw i32 %358, %362 + %364 = load ptr, ptr @VP8SetResidualCoeffs, align 8 + %365 = or disjoint i64 %indvars.iv90.i, %356 + %366 = getelementptr inbounds nuw [8 x [16 x i16]], ptr %305, i64 0, i64 %365 + call void %364(ptr noundef nonnull %366, ptr noundef nonnull %2) #7 + %367 = call fastcc i32 @PutCoeffs(ptr noundef %315, i32 noundef %363, ptr noundef %2) + store i32 %367, ptr %354, align 4 + store i32 %367, ptr %361, align 4 + br i1 %359, label %357, label %368, !llvm.loop !15 + +368: ; preds = %357 + br i1 %352, label %.preheader.i, label %369, !llvm.loop !16 + +369: ; preds = %368 + br i1 %350, label %.preheader78.i, label %CodeResiduals.exit, !llvm.loop !17 + +CodeResiduals.exit: ; preds = %369 + %370 = sext i32 %349 to i64 + %371 = add i64 %348, %370 + %372 = shl i64 %371, 3 + %373 = add nsw i32 %347, 8 + %374 = sext i32 %373 to i64 + %375 = add i64 %372, %374 + %376 = sext i32 %326 to i64 + %377 = add i64 %324, %376 + %378 = lshr i8 %317, 5 + %379 = and i8 %378, 3 + %380 = load i32, ptr %321, align 4 + %381 = add nsw i32 %380, 8 + %382 = sext i32 %381 to i64 + %383 = load i64, ptr %323, align 8 + %384 = load i32, ptr %325, align 8 + %385 = sext i32 %384 to i64 + %386 = add i64 %383, %385 + %387 = shl i64 %386, 3 + %narrow.i = sub nsw i32 -8, %322 %.neg.i = sext i32 %narrow.i to i64 - %390 = shl i64 %379, 3 - %.neg76.i = sub i64 %.neg.i, %390 - %391 = add i64 %377, %.neg76.i - store i64 %391, ptr %308, align 8 - %392 = sub i64 %384, %377 - %393 = add i64 %389, %392 - store i64 %393, ptr %309, align 8 - %394 = zext nneg i8 %381 to i64 - %395 = zext i1 %321 to i64 - %396 = getelementptr inbounds nuw [4 x [3 x i64]], ptr %310, i64 0, i64 %394, i64 %395 - %397 = load i64, ptr %396, align 8 - %398 = add i64 %397, %391 - store i64 %398, ptr %396, align 8 - %.idx.i = mul nuw nsw i64 %394, 24 + %388 = shl i64 %377, 3 + %.neg76.i = sub i64 %.neg.i, %388 + %389 = add i64 %375, %.neg76.i + store i64 %389, ptr %306, align 8 + %390 = sub i64 %382, %375 + %391 = add i64 %387, %390 + store i64 %391, ptr %307, align 8 + %392 = zext nneg i8 %379 to i64 + %393 = zext i1 %319 to i64 + %394 = getelementptr inbounds nuw [4 x [3 x i64]], ptr %308, i64 0, i64 %392, i64 %393 + %395 = load i64, ptr %394, align 8 + %396 = add i64 %395, %389 + store i64 %396, ptr %394, align 8 + %.idx.i = mul nuw nsw i64 %392, 24 %gep = getelementptr inbounds nuw i8, ptr %invariant.gep, i64 %.idx.i - %399 = load i64, ptr %gep, align 8 - %400 = add i64 %399, %393 - store i64 %400, ptr %gep, align 8 + %397 = load i64, ptr %gep, align 8 + %398 = add i64 %397, %391 + store i64 %398, ptr %gep, align 8 call void @VP8IteratorBytesToNz(ptr noundef nonnull %6) #7 call void @llvm.lifetime.end.p0(i64 48, ptr nonnull %2) - %401 = load ptr, ptr %300, align 8 - %402 = getelementptr inbounds nuw i8, ptr %401, i64 40 - %403 = load i32, ptr %402, align 8 - %.not14 = icmp eq i32 %403, 0 + %399 = load ptr, ptr %298, align 8 + %400 = getelementptr inbounds nuw i8, ptr %399, i64 40 + %401 = load i32, ptr %400, align 8 + %.not14 = icmp eq i32 %401, 0 br i1 %.not14, label %ResetAfterSkip.exit, label %.critedge -404: ; preds = %311 - %405 = load ptr, ptr %297, align 8 - %406 = load i8, ptr %405, align 4 - %407 = and i8 %406, 3 - %408 = icmp eq i8 %407, 1 - %409 = load ptr, ptr %298, align 8 - br i1 %408, label %410, label %411 - -410: ; preds = %404 - store i32 0, ptr %409, align 4 - store i32 0, ptr %299, align 8 +402: ; preds = %309 + %403 = load ptr, ptr %295, align 8 + %404 = load i8, ptr %403, align 4 + %405 = and i8 %404, 3 + %406 = icmp eq i8 %405, 1 + %407 = load ptr, ptr %296, align 8 + br i1 %406, label %408, label %409 + +408: ; preds = %402 + store i32 0, ptr %407, align 4 + store i32 0, ptr %297, align 8 br label %ResetAfterSkip.exit -411: ; preds = %404 - %412 = load i32, ptr %409, align 4 - %413 = and i32 %412, 16777216 - store i32 %413, ptr %409, align 4 +409: ; preds = %402 + %410 = load i32, ptr %407, align 4 + %411 = and i32 %410, 16777216 + store i32 %411, ptr %407, align 4 br label %ResetAfterSkip.exit -ResetAfterSkip.exit: ; preds = %411, %410, %CodeResiduals.exit +ResetAfterSkip.exit: ; preds = %409, %408, %CodeResiduals.exit call fastcc void @StoreSideInfo(ptr noundef %6) call void @VP8StoreFilterStats(ptr noundef nonnull %6) #7 call void @VP8IteratorExport(ptr noundef nonnull %6) #7 - %414 = call i32 @VP8IteratorProgress(ptr noundef nonnull %6, i32 noundef 20) #7 + %412 = call i32 @VP8IteratorProgress(ptr noundef nonnull %6, i32 noundef 20) #7 call void @VP8IteratorSaveBoundary(ptr noundef nonnull %6) #7 - %.not15 = icmp eq i32 %414, 0 - br i1 %.not15, label %.critedge, label %415 + %.not15 = icmp eq i32 %412, 0 + br i1 %.not15, label %.critedge, label %413 -415: ; preds = %ResetAfterSkip.exit - %416 = call i32 @VP8IteratorNext(ptr noundef nonnull %6) #7 - %.not16 = icmp eq i32 %416, 0 - br i1 %.not16, label %.critedge, label %311, !llvm.loop !18 +413: ; preds = %ResetAfterSkip.exit + %414 = call i32 @VP8IteratorNext(ptr noundef nonnull %6) #7 + %.not16 = icmp eq i32 %414, 0 + br i1 %.not16, label %.critedge, label %309, !llvm.loop !18 -.critedge: ; preds = %CodeResiduals.exit, %ResetAfterSkip.exit, %415 - %.011 = phi i32 [ %414, %415 ], [ 0, %ResetAfterSkip.exit ], [ 0, %CodeResiduals.exit ] - %417 = call fastcc i32 @PostLoopFinalize(ptr noundef %6, i32 noundef %.011) - br label %418 +.critedge: ; preds = %CodeResiduals.exit, %ResetAfterSkip.exit, %413 + %.011 = phi i32 [ %412, %413 ], [ 0, %ResetAfterSkip.exit ], [ 0, %CodeResiduals.exit ] + %415 = call fastcc i32 @PostLoopFinalize(ptr noundef %6, i32 noundef %.011) + br label %416 -418: ; preds = %PreLoopInitialize.exit, %.critedge - %.0 = phi i32 [ %417, %.critedge ], [ 0, %PreLoopInitialize.exit ] +416: ; preds = %PreLoopInitialize.exit, %.critedge + %.0 = phi i32 [ %415, %.critedge ], [ 0, %PreLoopInitialize.exit ] ret i32 %.0 } diff --git a/bench/lightgbm/optimized/c_api.cpp.ll b/bench/lightgbm/optimized/c_api.cpp.ll index ea9efde6608..bb66ea5aba1 100644 --- a/bench/lightgbm/optimized/c_api.cpp.ll +++ b/bench/lightgbm/optimized/c_api.cpp.ll @@ -15553,7 +15553,7 @@ define internal void @LGBM_DatasetCreateFromCSC.omp_outlined(ptr noalias nocaptu %27 = sdiv exact i64 %26, 24 %28 = trunc i64 %27 to i32 %29 = icmp sgt i32 %28, 0 - br i1 %29, label %30, label %170 + br i1 %29, label %30, label %169 30: ; preds = %14 %31 = add nsw i32 %28, -1 @@ -15591,7 +15591,7 @@ define internal void @LGBM_DatasetCreateFromCSC.omp_outlined(ptr noalias nocaptu %50 = load i64, ptr %9, align 8 %51 = trunc nsw i64 %indvars.iv64 to i32 invoke void @_ZN15CSC_RowIteratorC1EPKviPKiS1_illi(ptr noundef nonnull align 8 dereferenceable(56) %20, ptr noundef %44, i32 noundef %45, ptr noundef %46, ptr noundef %47, i32 noundef %48, i64 noundef %49, i64 noundef %50, i32 noundef %51) - to label %.preheader unwind label %143 + to label %.preheader unwind label %142 .preheader: ; preds = %43 %52 = load i32, ptr %10, align 4 @@ -15667,152 +15667,151 @@ _ZNKSt8functionIFSt4pairIidEiEEclEi.exit.i: ; preds = %.lr.ph %78 = icmp eq i32 %56, %77 %79 = load double, ptr %41, align 8 %.0.i = select i1 %78, double %79, double 0.000000e+00 - %80 = call double @llvm.fabs.f64(double %79) + %80 = call double @llvm.fabs.f64(double %.0.i) %81 = fcmp ogt double %80, 0x38AA95A5C0000000 - %82 = select i1 %78, i1 %81, i1 false - %83 = fcmp uno double %.0.i, 0.000000e+00 - %or.cond = select i1 %82, i1 true, i1 %83 - br i1 %or.cond, label %84, label %_ZNSt6vectorIiSaIiEE12emplace_backIJRiEEEvDpOT_.exit - -84: ; preds = %.loopexit - %85 = load ptr, ptr %2, align 8 - %86 = getelementptr inbounds %"class.std::vector.13", ptr %85, i64 %indvars.iv64 - %87 = getelementptr inbounds nuw i8, ptr %86, i64 8 - %88 = load ptr, ptr %87, align 8 - %89 = getelementptr inbounds nuw i8, ptr %86, i64 16 - %90 = load ptr, ptr %89, align 8 - %.not.i = icmp eq ptr %88, %90 - br i1 %.not.i, label %94, label %91 + %82 = fcmp uno double %.0.i, 0.000000e+00 + %or.cond = select i1 %81, i1 true, i1 %82 + br i1 %or.cond, label %83, label %_ZNSt6vectorIiSaIiEE12emplace_backIJRiEEEvDpOT_.exit -91: ; preds = %84 - store double %.0.i, ptr %88, align 8 - %92 = load ptr, ptr %87, align 8 - %93 = getelementptr inbounds nuw i8, ptr %92, i64 8 - store ptr %93, ptr %87, align 8 +83: ; preds = %.loopexit + %84 = load ptr, ptr %2, align 8 + %85 = getelementptr inbounds %"class.std::vector.13", ptr %84, i64 %indvars.iv64 + %86 = getelementptr inbounds nuw i8, ptr %85, i64 8 + %87 = load ptr, ptr %86, align 8 + %88 = getelementptr inbounds nuw i8, ptr %85, i64 16 + %89 = load ptr, ptr %88, align 8 + %.not.i = icmp eq ptr %87, %89 + br i1 %.not.i, label %93, label %90 + +90: ; preds = %83 + store double %.0.i, ptr %87, align 8 + %91 = load ptr, ptr %86, align 8 + %92 = getelementptr inbounds nuw i8, ptr %91, i64 8 + store ptr %92, ptr %86, align 8 br label %_ZNSt6vectorIdSaIdEE12emplace_backIJRdEEEvDpOT_.exit -94: ; preds = %84 - %95 = load ptr, ptr %86, align 8 - %96 = ptrtoint ptr %88 to i64 - %97 = ptrtoint ptr %95 to i64 - %98 = sub i64 %96, %97 - %99 = icmp eq i64 %98, 9223372036854775800 - br i1 %99, label %.invoke, label %_ZNKSt6vectorIdSaIdEE12_M_check_lenEmPKc.exit.i.i - -_ZNKSt6vectorIdSaIdEE12_M_check_lenEmPKc.exit.i.i: ; preds = %94 - %100 = ashr exact i64 %98, 3 - %.sroa.speculated.i.i.i = call i64 @llvm.umax.i64(i64 %100, i64 1) - %101 = add nsw i64 %.sroa.speculated.i.i.i, %100 - %102 = icmp ult i64 %101, %100 - %103 = call i64 @llvm.umin.i64(i64 %101, i64 1152921504606846975) - %104 = select i1 %102, i64 1152921504606846975, i64 %103 - %.not.i.i.i33 = icmp ne i64 %104, 0 +93: ; preds = %83 + %94 = load ptr, ptr %85, align 8 + %95 = ptrtoint ptr %87 to i64 + %96 = ptrtoint ptr %94 to i64 + %97 = sub i64 %95, %96 + %98 = icmp eq i64 %97, 9223372036854775800 + br i1 %98, label %.invoke, label %_ZNKSt6vectorIdSaIdEE12_M_check_lenEmPKc.exit.i.i + +_ZNKSt6vectorIdSaIdEE12_M_check_lenEmPKc.exit.i.i: ; preds = %93 + %99 = ashr exact i64 %97, 3 + %.sroa.speculated.i.i.i = call i64 @llvm.umax.i64(i64 %99, i64 1) + %100 = add nsw i64 %.sroa.speculated.i.i.i, %99 + %101 = icmp ult i64 %100, %99 + %102 = call i64 @llvm.umin.i64(i64 %100, i64 1152921504606846975) + %103 = select i1 %101, i64 1152921504606846975, i64 %102 + %.not.i.i.i33 = icmp ne i64 %103, 0 call void @llvm.assume(i1 %.not.i.i.i33) - %105 = shl nuw nsw i64 %104, 3 - %106 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef %105) #40 + %104 = shl nuw nsw i64 %103, 3 + %105 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef %104) #40 to label %.noexc35 unwind label %.loopexit.split-lp.loopexit .noexc35: ; preds = %_ZNKSt6vectorIdSaIdEE12_M_check_lenEmPKc.exit.i.i - %107 = getelementptr inbounds i8, ptr %106, i64 %98 - store double %.0.i, ptr %107, align 8 - %108 = icmp sgt i64 %98, 0 - br i1 %108, label %109, label %_ZNSt6vectorIdSaIdEE11_S_relocateEPdS2_S2_RS0_.exit16.i.i + %106 = getelementptr inbounds i8, ptr %105, i64 %97 + store double %.0.i, ptr %106, align 8 + %107 = icmp sgt i64 %97, 0 + br i1 %107, label %108, label %_ZNSt6vectorIdSaIdEE11_S_relocateEPdS2_S2_RS0_.exit16.i.i -109: ; preds = %.noexc35 - call void @llvm.memmove.p0.p0.i64(ptr nonnull align 8 %106, ptr align 8 %95, i64 %98, i1 false) +108: ; preds = %.noexc35 + call void @llvm.memmove.p0.p0.i64(ptr nonnull align 8 %105, ptr align 8 %94, i64 %97, i1 false) br label %_ZNSt6vectorIdSaIdEE11_S_relocateEPdS2_S2_RS0_.exit16.i.i -_ZNSt6vectorIdSaIdEE11_S_relocateEPdS2_S2_RS0_.exit16.i.i: ; preds = %109, %.noexc35 - %110 = getelementptr inbounds nuw i8, ptr %107, i64 8 - %.not.i17.i.i = icmp eq ptr %95, null - br i1 %.not.i17.i.i, label %_ZNSt6vectorIdSaIdEE17_M_realloc_insertIJRdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_.exit.i, label %111 +_ZNSt6vectorIdSaIdEE11_S_relocateEPdS2_S2_RS0_.exit16.i.i: ; preds = %108, %.noexc35 + %109 = getelementptr inbounds nuw i8, ptr %106, i64 8 + %.not.i17.i.i = icmp eq ptr %94, null + br i1 %.not.i17.i.i, label %_ZNSt6vectorIdSaIdEE17_M_realloc_insertIJRdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_.exit.i, label %110 -111: ; preds = %_ZNSt6vectorIdSaIdEE11_S_relocateEPdS2_S2_RS0_.exit16.i.i - call void @_ZdlPv(ptr noundef nonnull %95) #37 +110: ; preds = %_ZNSt6vectorIdSaIdEE11_S_relocateEPdS2_S2_RS0_.exit16.i.i + call void @_ZdlPv(ptr noundef nonnull %94) #37 br label %_ZNSt6vectorIdSaIdEE17_M_realloc_insertIJRdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_.exit.i -_ZNSt6vectorIdSaIdEE17_M_realloc_insertIJRdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_.exit.i: ; preds = %111, %_ZNSt6vectorIdSaIdEE11_S_relocateEPdS2_S2_RS0_.exit16.i.i - store ptr %106, ptr %86, align 8 - store ptr %110, ptr %87, align 8 - %112 = getelementptr inbounds nuw double, ptr %106, i64 %104 - store ptr %112, ptr %89, align 8 +_ZNSt6vectorIdSaIdEE17_M_realloc_insertIJRdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_.exit.i: ; preds = %110, %_ZNSt6vectorIdSaIdEE11_S_relocateEPdS2_S2_RS0_.exit16.i.i + store ptr %105, ptr %85, align 8 + store ptr %109, ptr %86, align 8 + %111 = getelementptr inbounds nuw double, ptr %105, i64 %103 + store ptr %111, ptr %88, align 8 br label %_ZNSt6vectorIdSaIdEE12emplace_backIJRdEEEvDpOT_.exit -_ZNSt6vectorIdSaIdEE12emplace_backIJRdEEEvDpOT_.exit: ; preds = %_ZNSt6vectorIdSaIdEE17_M_realloc_insertIJRdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_.exit.i, %91 - %113 = load ptr, ptr %12, align 8 - %114 = getelementptr inbounds %"class.std::vector.18", ptr %113, i64 %indvars.iv64 - %115 = getelementptr inbounds nuw i8, ptr %114, i64 8 - %116 = load ptr, ptr %115, align 8 - %117 = getelementptr inbounds nuw i8, ptr %114, i64 16 - %118 = load ptr, ptr %117, align 8 - %.not.i36 = icmp eq ptr %116, %118 - br i1 %.not.i36, label %123, label %119 - -119: ; preds = %_ZNSt6vectorIdSaIdEE12emplace_backIJRdEEEvDpOT_.exit - %120 = trunc nuw nsw i64 %indvars.iv to i32 - store i32 %120, ptr %116, align 4 - %121 = load ptr, ptr %115, align 8 - %122 = getelementptr inbounds nuw i8, ptr %121, i64 4 - store ptr %122, ptr %115, align 8 +_ZNSt6vectorIdSaIdEE12emplace_backIJRdEEEvDpOT_.exit: ; preds = %_ZNSt6vectorIdSaIdEE17_M_realloc_insertIJRdEEEvN9__gnu_cxx17__normal_iteratorIPdS1_EEDpOT_.exit.i, %90 + %112 = load ptr, ptr %12, align 8 + %113 = getelementptr inbounds %"class.std::vector.18", ptr %112, i64 %indvars.iv64 + %114 = getelementptr inbounds nuw i8, ptr %113, i64 8 + %115 = load ptr, ptr %114, align 8 + %116 = getelementptr inbounds nuw i8, ptr %113, i64 16 + %117 = load ptr, ptr %116, align 8 + %.not.i36 = icmp eq ptr %115, %117 + br i1 %.not.i36, label %122, label %118 + +118: ; preds = %_ZNSt6vectorIdSaIdEE12emplace_backIJRdEEEvDpOT_.exit + %119 = trunc nuw nsw i64 %indvars.iv to i32 + store i32 %119, ptr %115, align 4 + %120 = load ptr, ptr %114, align 8 + %121 = getelementptr inbounds nuw i8, ptr %120, i64 4 + store ptr %121, ptr %114, align 8 br label %_ZNSt6vectorIiSaIiEE12emplace_backIJRiEEEvDpOT_.exit -123: ; preds = %_ZNSt6vectorIdSaIdEE12emplace_backIJRdEEEvDpOT_.exit - %124 = load ptr, ptr %114, align 8 - %125 = ptrtoint ptr %116 to i64 - %126 = ptrtoint ptr %124 to i64 - %127 = sub i64 %125, %126 - %128 = icmp eq i64 %127, 9223372036854775804 - br i1 %128, label %.invoke, label %_ZNKSt6vectorIiSaIiEE12_M_check_lenEmPKc.exit.i.i +122: ; preds = %_ZNSt6vectorIdSaIdEE12emplace_backIJRdEEEvDpOT_.exit + %123 = load ptr, ptr %113, align 8 + %124 = ptrtoint ptr %115 to i64 + %125 = ptrtoint ptr %123 to i64 + %126 = sub i64 %124, %125 + %127 = icmp eq i64 %126, 9223372036854775804 + br i1 %127, label %.invoke, label %_ZNKSt6vectorIiSaIiEE12_M_check_lenEmPKc.exit.i.i -.invoke: ; preds = %123, %94 +.invoke: ; preds = %122, %93 invoke void @_ZSt20__throw_length_errorPKc(ptr noundef nonnull @.str.16) #39 to label %.cont unwind label %.loopexit.split-lp.loopexit.split-lp .cont: ; preds = %.invoke unreachable -_ZNKSt6vectorIiSaIiEE12_M_check_lenEmPKc.exit.i.i: ; preds = %123 - %129 = ashr exact i64 %127, 2 - %.sroa.speculated.i.i.i37 = call i64 @llvm.umax.i64(i64 %129, i64 1) - %130 = add nsw i64 %.sroa.speculated.i.i.i37, %129 - %131 = icmp ult i64 %130, %129 - %132 = call i64 @llvm.umin.i64(i64 %130, i64 2305843009213693951) - %133 = select i1 %131, i64 2305843009213693951, i64 %132 - %.not.i.i.i38 = icmp ne i64 %133, 0 +_ZNKSt6vectorIiSaIiEE12_M_check_lenEmPKc.exit.i.i: ; preds = %122 + %128 = ashr exact i64 %126, 2 + %.sroa.speculated.i.i.i37 = call i64 @llvm.umax.i64(i64 %128, i64 1) + %129 = add nsw i64 %.sroa.speculated.i.i.i37, %128 + %130 = icmp ult i64 %129, %128 + %131 = call i64 @llvm.umin.i64(i64 %129, i64 2305843009213693951) + %132 = select i1 %130, i64 2305843009213693951, i64 %131 + %.not.i.i.i38 = icmp ne i64 %132, 0 call void @llvm.assume(i1 %.not.i.i.i38) - %134 = shl nuw nsw i64 %133, 2 - %135 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef %134) #40 + %133 = shl nuw nsw i64 %132, 2 + %134 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef %133) #40 to label %.noexc41 unwind label %.loopexit.split-lp.loopexit .noexc41: ; preds = %_ZNKSt6vectorIiSaIiEE12_M_check_lenEmPKc.exit.i.i - %136 = getelementptr inbounds i8, ptr %135, i64 %127 - %137 = trunc nuw nsw i64 %indvars.iv to i32 - store i32 %137, ptr %136, align 4 - %138 = icmp sgt i64 %127, 0 - br i1 %138, label %139, label %_ZNSt6vectorIiSaIiEE11_S_relocateEPiS2_S2_RS0_.exit16.i.i - -139: ; preds = %.noexc41 - call void @llvm.memmove.p0.p0.i64(ptr nonnull align 4 %135, ptr align 4 %124, i64 %127, i1 false) + %135 = getelementptr inbounds i8, ptr %134, i64 %126 + %136 = trunc nuw nsw i64 %indvars.iv to i32 + store i32 %136, ptr %135, align 4 + %137 = icmp sgt i64 %126, 0 + br i1 %137, label %138, label %_ZNSt6vectorIiSaIiEE11_S_relocateEPiS2_S2_RS0_.exit16.i.i + +138: ; preds = %.noexc41 + call void @llvm.memmove.p0.p0.i64(ptr nonnull align 4 %134, ptr align 4 %123, i64 %126, i1 false) br label %_ZNSt6vectorIiSaIiEE11_S_relocateEPiS2_S2_RS0_.exit16.i.i -_ZNSt6vectorIiSaIiEE11_S_relocateEPiS2_S2_RS0_.exit16.i.i: ; preds = %139, %.noexc41 - %140 = getelementptr inbounds nuw i8, ptr %136, i64 4 - %.not.i17.i.i39 = icmp eq ptr %124, null - br i1 %.not.i17.i.i39, label %_ZNSt6vectorIiSaIiEE17_M_realloc_insertIJRiEEEvN9__gnu_cxx17__normal_iteratorIPiS1_EEDpOT_.exit.i, label %141 +_ZNSt6vectorIiSaIiEE11_S_relocateEPiS2_S2_RS0_.exit16.i.i: ; preds = %138, %.noexc41 + %139 = getelementptr inbounds nuw i8, ptr %135, i64 4 + %.not.i17.i.i39 = icmp eq ptr %123, null + br i1 %.not.i17.i.i39, label %_ZNSt6vectorIiSaIiEE17_M_realloc_insertIJRiEEEvN9__gnu_cxx17__normal_iteratorIPiS1_EEDpOT_.exit.i, label %140 -141: ; preds = %_ZNSt6vectorIiSaIiEE11_S_relocateEPiS2_S2_RS0_.exit16.i.i - call void @_ZdlPv(ptr noundef nonnull %124) #37 +140: ; preds = %_ZNSt6vectorIiSaIiEE11_S_relocateEPiS2_S2_RS0_.exit16.i.i + call void @_ZdlPv(ptr noundef nonnull %123) #37 br label %_ZNSt6vectorIiSaIiEE17_M_realloc_insertIJRiEEEvN9__gnu_cxx17__normal_iteratorIPiS1_EEDpOT_.exit.i -_ZNSt6vectorIiSaIiEE17_M_realloc_insertIJRiEEEvN9__gnu_cxx17__normal_iteratorIPiS1_EEDpOT_.exit.i: ; preds = %141, %_ZNSt6vectorIiSaIiEE11_S_relocateEPiS2_S2_RS0_.exit16.i.i - store ptr %135, ptr %114, align 8 - store ptr %140, ptr %115, align 8 - %142 = getelementptr inbounds nuw i32, ptr %135, i64 %133 - store ptr %142, ptr %117, align 8 +_ZNSt6vectorIiSaIiEE17_M_realloc_insertIJRiEEEvN9__gnu_cxx17__normal_iteratorIPiS1_EEDpOT_.exit.i: ; preds = %140, %_ZNSt6vectorIiSaIiEE11_S_relocateEPiS2_S2_RS0_.exit16.i.i + store ptr %134, ptr %113, align 8 + store ptr %139, ptr %114, align 8 + %141 = getelementptr inbounds nuw i32, ptr %134, i64 %132 + store ptr %141, ptr %116, align 8 br label %_ZNSt6vectorIiSaIiEE12emplace_backIJRiEEEvDpOT_.exit -143: ; preds = %43 - %144 = landingpad { ptr, i32 } +142: ; preds = %43 + %143 = landingpad { ptr, i32 } catch ptr @_ZTISt9exception catch ptr null br label %_ZN15CSC_RowIteratorD2Ev.exit @@ -15837,88 +15836,88 @@ _ZNSt6vectorIiSaIiEE17_M_realloc_insertIJRiEEEvN9__gnu_cxx17__normal_iteratorIPi .loopexit.split-lp: ; preds = %.loopexit.split-lp.loopexit, %.loopexit.split-lp.loopexit.split-lp, %.loopexit48 %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit48 ], [ %lpad.loopexit49, %.loopexit.split-lp.loopexit ], [ %lpad.loopexit.split-lp50, %.loopexit.split-lp.loopexit.split-lp ] - %145 = load ptr, ptr %38, align 8 - %.not.i.i.i42 = icmp eq ptr %145, null - br i1 %.not.i.i.i42, label %_ZN15CSC_RowIteratorD2Ev.exit, label %146 + %144 = load ptr, ptr %38, align 8 + %.not.i.i.i42 = icmp eq ptr %144, null + br i1 %.not.i.i.i42, label %_ZN15CSC_RowIteratorD2Ev.exit, label %145 -146: ; preds = %.loopexit.split-lp - %147 = invoke noundef zeroext i1 %145(ptr noundef nonnull align 8 dereferenceable(32) %39, ptr noundef nonnull align 8 dereferenceable(32) %39, i32 noundef 3) - to label %_ZN15CSC_RowIteratorD2Ev.exit unwind label %148 +145: ; preds = %.loopexit.split-lp + %146 = invoke noundef zeroext i1 %144(ptr noundef nonnull align 8 dereferenceable(32) %39, ptr noundef nonnull align 8 dereferenceable(32) %39, i32 noundef 3) + to label %_ZN15CSC_RowIteratorD2Ev.exit unwind label %147 -148: ; preds = %146 - %149 = landingpad { ptr, i32 } +147: ; preds = %145 + %148 = landingpad { ptr, i32 } catch ptr null - %150 = extractvalue { ptr, i32 } %149, 0 - call void @__clang_call_terminate(ptr %150) #36 + %149 = extractvalue { ptr, i32 } %148, 0 + call void @__clang_call_terminate(ptr %149) #36 unreachable -_ZN15CSC_RowIteratorD2Ev.exit: ; preds = %146, %.loopexit.split-lp, %143 - %.pn = phi { ptr, i32 } [ %144, %143 ], [ %lpad.phi, %.loopexit.split-lp ], [ %lpad.phi, %146 ] +_ZN15CSC_RowIteratorD2Ev.exit: ; preds = %145, %.loopexit.split-lp, %142 + %.pn = phi { ptr, i32 } [ %143, %142 ], [ %lpad.phi, %.loopexit.split-lp ], [ %lpad.phi, %145 ] %.028 = extractvalue { ptr, i32 } %.pn, 1 %.029 = extractvalue { ptr, i32 } %.pn, 0 - %151 = call i32 @llvm.eh.typeid.for.p0(ptr nonnull @_ZTISt9exception) #22 - %152 = icmp eq i32 %.028, %151 - %153 = call ptr @__cxa_begin_catch(ptr %.029) #22 - br i1 %152, label %154, label %.invoke69 - -154: ; preds = %_ZN15CSC_RowIteratorD2Ev.exit - %155 = load ptr, ptr %153, align 8 - %156 = getelementptr inbounds nuw i8, ptr %155, i64 16 - %157 = load ptr, ptr %156, align 8 - %158 = call noundef ptr %157(ptr noundef nonnull align 8 dereferenceable(8) %153) #22 - invoke void (ptr, ...) @_ZN8LightGBM3Log7WarningEPKcz(ptr noundef %158) - to label %.invoke69 unwind label %171 + %150 = call i32 @llvm.eh.typeid.for.p0(ptr nonnull @_ZTISt9exception) #22 + %151 = icmp eq i32 %.028, %150 + %152 = call ptr @__cxa_begin_catch(ptr %.029) #22 + br i1 %151, label %153, label %.invoke69 + +153: ; preds = %_ZN15CSC_RowIteratorD2Ev.exit + %154 = load ptr, ptr %152, align 8 + %155 = getelementptr inbounds nuw i8, ptr %154, i64 16 + %156 = load ptr, ptr %155, align 8 + %157 = call noundef ptr %156(ptr noundef nonnull align 8 dereferenceable(8) %152) #22 + invoke void (ptr, ...) @_ZN8LightGBM3Log7WarningEPKcz(ptr noundef %157) + to label %.invoke69 unwind label %170 -_ZN15CSC_RowIteratorD2Ev.exit44: ; preds = %.invoke68, %165, %._crit_edge +_ZN15CSC_RowIteratorD2Ev.exit44: ; preds = %.invoke68, %164, %._crit_edge %indvars.iv.next65 = add nsw i64 %indvars.iv64, 1 - %159 = load i32, ptr %17, align 4 - %160 = sext i32 %159 to i64 - %.not.not = icmp slt i64 %indvars.iv64, %160 + %158 = load i32, ptr %17, align 4 + %159 = sext i32 %158 to i64 + %.not.not = icmp slt i64 %indvars.iv64, %159 br i1 %.not.not, label %43, label %._crit_edge61 -.invoke69: ; preds = %_ZN15CSC_RowIteratorD2Ev.exit, %154 +.invoke69: ; preds = %_ZN15CSC_RowIteratorD2Ev.exit, %153 invoke void @_ZN21ThreadExceptionHelper16CaptureExceptionEv(ptr noundef nonnull align 8 dereferenceable(48) %13) - to label %.invoke68 unwind label %171 + to label %.invoke68 unwind label %170 .invoke68: ; preds = %.invoke69 invoke void @__cxa_end_catch() - to label %_ZN15CSC_RowIteratorD2Ev.exit44 unwind label %171 + to label %_ZN15CSC_RowIteratorD2Ev.exit44 unwind label %170 -_ZNSt6vectorIiSaIiEE12emplace_backIJRiEEEvDpOT_.exit: ; preds = %.loopexit, %_ZNSt6vectorIiSaIiEE17_M_realloc_insertIJRiEEEvN9__gnu_cxx17__normal_iteratorIPiS1_EEDpOT_.exit.i, %119 +_ZNSt6vectorIiSaIiEE12emplace_backIJRiEEEvDpOT_.exit: ; preds = %.loopexit, %_ZNSt6vectorIiSaIiEE17_M_realloc_insertIJRiEEEvN9__gnu_cxx17__normal_iteratorIPiS1_EEDpOT_.exit.i, %118 %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1 - %161 = load i32, ptr %10, align 4 - %162 = sext i32 %161 to i64 - %163 = icmp slt i64 %indvars.iv.next, %162 - br i1 %163, label %.lr.ph55, label %._crit_edge, !llvm.loop !280 + %160 = load i32, ptr %10, align 4 + %161 = sext i32 %160 to i64 + %162 = icmp slt i64 %indvars.iv.next, %161 + br i1 %162, label %.lr.ph55, label %._crit_edge, !llvm.loop !280 ._crit_edge: ; preds = %_ZNSt6vectorIiSaIiEE12emplace_backIJRiEEEvDpOT_.exit, %.preheader - %164 = load ptr, ptr %38, align 8 - %.not.i.i.i43 = icmp eq ptr %164, null - br i1 %.not.i.i.i43, label %_ZN15CSC_RowIteratorD2Ev.exit44, label %165 + %163 = load ptr, ptr %38, align 8 + %.not.i.i.i43 = icmp eq ptr %163, null + br i1 %.not.i.i.i43, label %_ZN15CSC_RowIteratorD2Ev.exit44, label %164 -165: ; preds = %._crit_edge - %166 = invoke noundef zeroext i1 %164(ptr noundef nonnull align 8 dereferenceable(32) %39, ptr noundef nonnull align 8 dereferenceable(32) %39, i32 noundef 3) - to label %_ZN15CSC_RowIteratorD2Ev.exit44 unwind label %167 +164: ; preds = %._crit_edge + %165 = invoke noundef zeroext i1 %163(ptr noundef nonnull align 8 dereferenceable(32) %39, ptr noundef nonnull align 8 dereferenceable(32) %39, i32 noundef 3) + to label %_ZN15CSC_RowIteratorD2Ev.exit44 unwind label %166 -167: ; preds = %165 - %168 = landingpad { ptr, i32 } +166: ; preds = %164 + %167 = landingpad { ptr, i32 } catch ptr null - %169 = extractvalue { ptr, i32 } %168, 0 - call void @__clang_call_terminate(ptr %169) #36 + %168 = extractvalue { ptr, i32 } %167, 0 + call void @__clang_call_terminate(ptr %168) #36 unreachable ._crit_edge61: ; preds = %_ZN15CSC_RowIteratorD2Ev.exit44, %30 call void @__kmpc_for_static_fini(ptr nonnull @1, i32 %32) - br label %170 + br label %169 -170: ; preds = %._crit_edge61, %14 +169: ; preds = %._crit_edge61, %14 ret void -171: ; preds = %.invoke69, %.invoke68, %154 - %172 = landingpad { ptr, i32 } +170: ; preds = %.invoke69, %.invoke68, %153 + %171 = landingpad { ptr, i32 } catch ptr null - %173 = extractvalue { ptr, i32 } %172, 0 - call void @__clang_call_terminate(ptr %173) #36 + %172 = extractvalue { ptr, i32 } %171, 0 + call void @__clang_call_terminate(ptr %172) #36 unreachable } @@ -46259,12 +46258,12 @@ _ZNSt6vectorISt4pairIidESaIS1_EE7reserveEm.exit.i.i.i: ; preds = %_ZNSt12_Vector br label %21 21: ; preds = %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i, %.lr.ph23.i.i.i - %22 = phi ptr [ %.promoted19, %.lr.ph23.i.i.i ], [ %97, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] - %23 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %98, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] - %24 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %99, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] - %25 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %100, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] - %26 = phi ptr [ %.promoted19, %.lr.ph23.i.i.i ], [ %101, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] - %27 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %102, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] + %22 = phi ptr [ %.promoted19, %.lr.ph23.i.i.i ], [ %96, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] + %23 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %97, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] + %24 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %98, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] + %25 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %99, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] + %26 = phi ptr [ %.promoted19, %.lr.ph23.i.i.i ], [ %100, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] + %27 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %101, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] %indvars.iv.i.i.i = phi i64 [ 0, %.lr.ph23.i.i.i ], [ %indvars.iv.next.i.i.i, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] %28 = load ptr, ptr %1, align 8, !noalias !508 %29 = load ptr, ptr %28, align 8, !noalias !508 @@ -46345,90 +46344,89 @@ _ZNKSt8functionIFSt4pairIidEiEEclEi.exit.i.i.i.i: ; preds = %.lr.ph.i.i.i %61 = getelementptr inbounds nuw i8, ptr %32, i64 8 %62 = load double, ptr %61, align 8, !noalias !508 %.0.i.i.i.i = select i1 %60, double %62, double 0.000000e+00 - %63 = call double @llvm.fabs.f64(double %62) + %63 = call double @llvm.fabs.f64(double %.0.i.i.i.i) %64 = fcmp ogt double %63, 0x38AA95A5C0000000 - %65 = select i1 %60, i1 %64, i1 false - %66 = fcmp uno double %.0.i.i.i.i, 0.000000e+00 - %or.cond.i.i.i = select i1 %65, i1 true, i1 %66 - br i1 %or.cond.i.i.i, label %67, label %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i + %65 = fcmp uno double %.0.i.i.i.i, 0.000000e+00 + %or.cond.i.i.i = select i1 %64, i1 true, i1 %65 + br i1 %or.cond.i.i.i, label %66, label %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i -67: ; preds = %.loopexit.i.i.i +66: ; preds = %.loopexit.i.i.i %.not.i.i.i.i = icmp eq ptr %27, %26 - br i1 %.not.i.i.i.i, label %72, label %68 + br i1 %.not.i.i.i.i, label %71, label %67 -68: ; preds = %67 - %69 = trunc nuw nsw i64 %indvars.iv.i.i.i to i32 - store i32 %69, ptr %27, align 8, !noalias !508 - %70 = getelementptr inbounds nuw i8, ptr %27, i64 8 - store double %.0.i.i.i.i, ptr %70, align 8, !noalias !508 - %71 = getelementptr inbounds nuw i8, ptr %27, i64 16 +67: ; preds = %66 + %68 = trunc nuw nsw i64 %indvars.iv.i.i.i to i32 + store i32 %68, ptr %27, align 8, !noalias !508 + %69 = getelementptr inbounds nuw i8, ptr %27, i64 8 + store double %.0.i.i.i.i, ptr %69, align 8, !noalias !508 + %70 = getelementptr inbounds nuw i8, ptr %27, i64 16 br label %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i -72: ; preds = %67 - %73 = ptrtoint ptr %26 to i64 - %74 = ptrtoint ptr %25 to i64 - %75 = sub i64 %73, %74 - %76 = icmp eq i64 %75, 9223372036854775792 - br i1 %76, label %.invoke.i.i.i.loopexit, label %_ZNKSt6vectorISt4pairIidESaIS1_EE12_M_check_lenEmPKc.exit.i.i.i.i.i +71: ; preds = %66 + %72 = ptrtoint ptr %26 to i64 + %73 = ptrtoint ptr %25 to i64 + %74 = sub i64 %72, %73 + %75 = icmp eq i64 %74, 9223372036854775792 + br i1 %75, label %.invoke.i.i.i.loopexit, label %_ZNKSt6vectorISt4pairIidESaIS1_EE12_M_check_lenEmPKc.exit.i.i.i.i.i -.invoke.i.i.i.loopexit: ; preds = %72 +.invoke.i.i.i.loopexit: ; preds = %71 store ptr %24, ptr %20, align 8 store ptr %23, ptr %0, align 8 store ptr %22, ptr %10, align 8 br label %.invoke.i.i.i .invoke.i.i.i: ; preds = %.invoke.i.i.i.loopexit, %3 - %77 = phi ptr [ null, %3 ], [ %25, %.invoke.i.i.i.loopexit ] - %78 = phi ptr [ @.str.15, %3 ], [ @.str.16, %.invoke.i.i.i.loopexit ] - invoke void @_ZSt20__throw_length_errorPKc(ptr noundef nonnull %78) #39 + %76 = phi ptr [ null, %3 ], [ %25, %.invoke.i.i.i.loopexit ] + %77 = phi ptr [ @.str.15, %3 ], [ @.str.16, %.invoke.i.i.i.loopexit ] + invoke void @_ZSt20__throw_length_errorPKc(ptr noundef nonnull %77) #39 to label %.cont.i.i.i unwind label %.loopexit.split-lp.loopexit.split-lp.i.i.i, !noalias !508 .cont.i.i.i: ; preds = %.invoke.i.i.i unreachable -_ZNKSt6vectorISt4pairIidESaIS1_EE12_M_check_lenEmPKc.exit.i.i.i.i.i: ; preds = %72 - %79 = ashr exact i64 %75, 4 - %.sroa.speculated.i.i.i.i.i.i = call i64 @llvm.umax.i64(i64 %79, i64 1) - %80 = add nsw i64 %.sroa.speculated.i.i.i.i.i.i, %79 - %81 = icmp ult i64 %80, %79 - %82 = call i64 @llvm.umin.i64(i64 %80, i64 576460752303423487) - %83 = select i1 %81, i64 576460752303423487, i64 %82 - %.not.i.i.i8.i.i.i = icmp ne i64 %83, 0 +_ZNKSt6vectorISt4pairIidESaIS1_EE12_M_check_lenEmPKc.exit.i.i.i.i.i: ; preds = %71 + %78 = ashr exact i64 %74, 4 + %.sroa.speculated.i.i.i.i.i.i = call i64 @llvm.umax.i64(i64 %78, i64 1) + %79 = add nsw i64 %.sroa.speculated.i.i.i.i.i.i, %78 + %80 = icmp ult i64 %79, %78 + %81 = call i64 @llvm.umin.i64(i64 %79, i64 576460752303423487) + %82 = select i1 %80, i64 576460752303423487, i64 %81 + %.not.i.i.i8.i.i.i = icmp ne i64 %82, 0 call void @llvm.assume(i1 %.not.i.i.i8.i.i.i) - %84 = shl nuw nsw i64 %83, 4 - %85 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef %84) #40 + %83 = shl nuw nsw i64 %82, 4 + %84 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef %83) #40 to label %.noexc10.i.i.i unwind label %.loopexit.split-lp.loopexit.i.i.i, !noalias !508 .noexc10.i.i.i: ; preds = %_ZNKSt6vectorISt4pairIidESaIS1_EE12_M_check_lenEmPKc.exit.i.i.i.i.i - %86 = getelementptr inbounds i8, ptr %85, i64 %75 - %87 = trunc nuw nsw i64 %indvars.iv.i.i.i to i32 - store i32 %87, ptr %86, align 8, !noalias !508 - %88 = getelementptr inbounds nuw i8, ptr %86, i64 8 - store double %.0.i.i.i.i, ptr %88, align 8, !noalias !508 + %85 = getelementptr inbounds i8, ptr %84, i64 %74 + %86 = trunc nuw nsw i64 %indvars.iv.i.i.i to i32 + store i32 %86, ptr %85, align 8, !noalias !508 + %87 = getelementptr inbounds nuw i8, ptr %85, i64 8 + store double %.0.i.i.i.i, ptr %87, align 8, !noalias !508 %.not10.i.i.i.i.i.i.i.i.i = icmp eq ptr %25, %26 br i1 %.not10.i.i.i.i.i.i.i.i.i, label %_ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i, label %.lr.ph.i.i.i.i.i.i.i.i.i .lr.ph.i.i.i.i.i.i.i.i.i: ; preds = %.noexc10.i.i.i, %.lr.ph.i.i.i.i.i.i.i.i.i - %.012.i.i.i.i.i.i.i.i.i = phi ptr [ %90, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %85, %.noexc10.i.i.i ] - %.0911.i.i.i.i.i.i.i.i.i = phi ptr [ %89, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %25, %.noexc10.i.i.i ] + %.012.i.i.i.i.i.i.i.i.i = phi ptr [ %89, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %84, %.noexc10.i.i.i ] + %.0911.i.i.i.i.i.i.i.i.i = phi ptr [ %88, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %25, %.noexc10.i.i.i ] call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %.012.i.i.i.i.i.i.i.i.i, ptr noundef nonnull align 8 dereferenceable(16) %.0911.i.i.i.i.i.i.i.i.i, i64 16, i1 false), !alias.scope !509, !noalias !508 - %89 = getelementptr inbounds nuw i8, ptr %.0911.i.i.i.i.i.i.i.i.i, i64 16 - %90 = getelementptr inbounds nuw i8, ptr %.012.i.i.i.i.i.i.i.i.i, i64 16 - %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %89, %26 + %88 = getelementptr inbounds nuw i8, ptr %.0911.i.i.i.i.i.i.i.i.i, i64 16 + %89 = getelementptr inbounds nuw i8, ptr %.012.i.i.i.i.i.i.i.i.i, i64 16 + %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %88, %26 br i1 %.not.i.i.i.i.i.i.i.i.i, label %_ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i, label %.lr.ph.i.i.i.i.i.i.i.i.i, !llvm.loop !109 _ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i, %.noexc10.i.i.i - %.0.lcssa.i.i.i.i.i.i.i.i.i = phi ptr [ %85, %.noexc10.i.i.i ], [ %90, %.lr.ph.i.i.i.i.i.i.i.i.i ] - %91 = getelementptr inbounds nuw i8, ptr %.0.lcssa.i.i.i.i.i.i.i.i.i, i64 16 + %.0.lcssa.i.i.i.i.i.i.i.i.i = phi ptr [ %84, %.noexc10.i.i.i ], [ %89, %.lr.ph.i.i.i.i.i.i.i.i.i ] + %90 = getelementptr inbounds nuw i8, ptr %.0.lcssa.i.i.i.i.i.i.i.i.i, i64 16 %.not.i34.i.i.i.i.i = icmp eq ptr %25, null - br i1 %.not.i34.i.i.i.i.i, label %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i, label %92 + br i1 %.not.i34.i.i.i.i.i, label %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i, label %91 -92: ; preds = %_ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i +91: ; preds = %_ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i call void @_ZdlPv(ptr noundef nonnull %25) #37, !noalias !508 br label %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i -_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i: ; preds = %92, %_ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i - %93 = getelementptr inbounds nuw %"struct.std::pair.166", ptr %85, i64 %83 +_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i: ; preds = %91, %_ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i + %92 = getelementptr inbounds nuw %"struct.std::pair.166", ptr %84, i64 %82 br label %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i .loopexit16.i.i.i: ; preds = %_ZNKSt8functionIFSt4pairIidEiEEclEi.exit.i.i.i.i @@ -46448,41 +46446,41 @@ _ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__norm br label %.loopexit.split-lp.i.i.i .loopexit.split-lp.loopexit.split-lp.i.i.i: ; preds = %.invoke.i.i.i, %48, %_ZNSt12_Vector_baseISt4pairIidESaIS1_EE11_M_allocateEm.exit.i.i.i.i - %94 = phi ptr [ %77, %.invoke.i.i.i ], [ %25, %48 ], [ null, %_ZNSt12_Vector_baseISt4pairIidESaIS1_EE11_M_allocateEm.exit.i.i.i.i ] + %93 = phi ptr [ %76, %.invoke.i.i.i ], [ %25, %48 ], [ null, %_ZNSt12_Vector_baseISt4pairIidESaIS1_EE11_M_allocateEm.exit.i.i.i.i ] %lpad.loopexit.split-lp18.i.i.i = landingpad { ptr, i32 } cleanup br label %.loopexit.split-lp.i.i.i .loopexit.split-lp.i.i.i: ; preds = %.loopexit.split-lp.loopexit.split-lp.i.i.i, %.loopexit.split-lp.loopexit.i.i.i, %.loopexit16.i.i.i - %95 = phi ptr [ %25, %.loopexit16.i.i.i ], [ %25, %.loopexit.split-lp.loopexit.i.i.i ], [ %94, %.loopexit.split-lp.loopexit.split-lp.i.i.i ] + %94 = phi ptr [ %25, %.loopexit16.i.i.i ], [ %25, %.loopexit.split-lp.loopexit.i.i.i ], [ %93, %.loopexit.split-lp.loopexit.split-lp.i.i.i ] %lpad.phi.i.i.i = phi { ptr, i32 } [ %lpad.loopexit.i.i.i, %.loopexit16.i.i.i ], [ %lpad.loopexit17.i.i.i, %.loopexit.split-lp.loopexit.i.i.i ], [ %lpad.loopexit.split-lp18.i.i.i, %.loopexit.split-lp.loopexit.split-lp.i.i.i ] - %.not.i.i.i11.i.i.i = icmp eq ptr %95, null - br i1 %.not.i.i.i11.i.i.i, label %_ZNSt6vectorISt4pairIidESaIS1_EED2Ev.exit.i.i.i, label %96 + %.not.i.i.i11.i.i.i = icmp eq ptr %94, null + br i1 %.not.i.i.i11.i.i.i, label %_ZNSt6vectorISt4pairIidESaIS1_EED2Ev.exit.i.i.i, label %95 -96: ; preds = %.loopexit.split-lp.i.i.i - call void @_ZdlPv(ptr noundef nonnull %95) #37, !noalias !508 +95: ; preds = %.loopexit.split-lp.i.i.i + call void @_ZdlPv(ptr noundef nonnull %94) #37, !noalias !508 br label %_ZNSt6vectorISt4pairIidESaIS1_EED2Ev.exit.i.i.i -_ZNSt6vectorISt4pairIidESaIS1_EED2Ev.exit.i.i.i: ; preds = %96, %.loopexit.split-lp.i.i.i +_ZNSt6vectorISt4pairIidESaIS1_EED2Ev.exit.i.i.i: ; preds = %95, %.loopexit.split-lp.i.i.i resume { ptr, i32 } %lpad.phi.i.i.i -_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i: ; preds = %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i, %68, %.loopexit.i.i.i - %97 = phi ptr [ %22, %.loopexit.i.i.i ], [ %93, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %22, %68 ] - %98 = phi ptr [ %23, %.loopexit.i.i.i ], [ %85, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %23, %68 ] - %99 = phi ptr [ %24, %.loopexit.i.i.i ], [ %91, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %71, %68 ] - %100 = phi ptr [ %25, %.loopexit.i.i.i ], [ %85, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %25, %68 ] - %101 = phi ptr [ %26, %.loopexit.i.i.i ], [ %93, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %26, %68 ] - %102 = phi ptr [ %27, %.loopexit.i.i.i ], [ %91, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %71, %68 ] +_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i: ; preds = %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i, %67, %.loopexit.i.i.i + %96 = phi ptr [ %22, %.loopexit.i.i.i ], [ %92, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %22, %67 ] + %97 = phi ptr [ %23, %.loopexit.i.i.i ], [ %84, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %23, %67 ] + %98 = phi ptr [ %24, %.loopexit.i.i.i ], [ %90, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %70, %67 ] + %99 = phi ptr [ %25, %.loopexit.i.i.i ], [ %84, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %25, %67 ] + %100 = phi ptr [ %26, %.loopexit.i.i.i ], [ %92, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %26, %67 ] + %101 = phi ptr [ %27, %.loopexit.i.i.i ], [ %90, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %70, %67 ] %indvars.iv.next.i.i.i = add nuw nsw i64 %indvars.iv.i.i.i, 1 - %103 = load i32, ptr %5, align 8, !noalias !508 - %104 = sext i32 %103 to i64 - %105 = icmp slt i64 %indvars.iv.next.i.i.i, %104 - br i1 %105, label %21, label %"_ZSt10__invoke_rISt6vectorISt4pairIidESaIS2_EERZ31LGBM_BoosterPredictSparseOutputE3$_0JlEENSt9enable_ifIXsr6__and_ISt6__not_ISt7is_voidIT_EESt14is_convertibleINSt15__invoke_resultIT0_JDpT1_EE4typeESA_EEE5valueESA_E4typeEOSF_DpOSG_.exit.loopexit", !llvm.loop !513 + %102 = load i32, ptr %5, align 8, !noalias !508 + %103 = sext i32 %102 to i64 + %104 = icmp slt i64 %indvars.iv.next.i.i.i, %103 + br i1 %104, label %21, label %"_ZSt10__invoke_rISt6vectorISt4pairIidESaIS2_EERZ31LGBM_BoosterPredictSparseOutputE3$_0JlEENSt9enable_ifIXsr6__and_ISt6__not_ISt7is_voidIT_EESt14is_convertibleINSt15__invoke_resultIT0_JDpT1_EE4typeESA_EEE5valueESA_E4typeEOSF_DpOSG_.exit.loopexit", !llvm.loop !513 "_ZSt10__invoke_rISt6vectorISt4pairIidESaIS2_EERZ31LGBM_BoosterPredictSparseOutputE3$_0JlEENSt9enable_ifIXsr6__and_ISt6__not_ISt7is_voidIT_EESt14is_convertibleINSt15__invoke_resultIT0_JDpT1_EE4typeESA_EEE5valueESA_E4typeEOSF_DpOSG_.exit.loopexit": ; preds = %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i - store ptr %99, ptr %20, align 8 - store ptr %98, ptr %0, align 8 - store ptr %97, ptr %10, align 8 + store ptr %98, ptr %20, align 8 + store ptr %97, ptr %0, align 8 + store ptr %96, ptr %10, align 8 br label %"_ZSt10__invoke_rISt6vectorISt4pairIidESaIS2_EERZ31LGBM_BoosterPredictSparseOutputE3$_0JlEENSt9enable_ifIXsr6__and_ISt6__not_ISt7is_voidIT_EESt14is_convertibleINSt15__invoke_resultIT0_JDpT1_EE4typeESA_EEE5valueESA_E4typeEOSF_DpOSG_.exit" "_ZSt10__invoke_rISt6vectorISt4pairIidESaIS2_EERZ31LGBM_BoosterPredictSparseOutputE3$_0JlEENSt9enable_ifIXsr6__and_ISt6__not_ISt7is_voidIT_EESt14is_convertibleINSt15__invoke_resultIT0_JDpT1_EE4typeESA_EEE5valueESA_E4typeEOSF_DpOSG_.exit": ; preds = %"_ZSt10__invoke_rISt6vectorISt4pairIidESaIS2_EERZ31LGBM_BoosterPredictSparseOutputE3$_0JlEENSt9enable_ifIXsr6__and_ISt6__not_ISt7is_voidIT_EESt14is_convertibleINSt15__invoke_resultIT0_JDpT1_EE4typeESA_EEE5valueESA_E4typeEOSF_DpOSG_.exit.loopexit", %_ZNSt6vectorISt4pairIidESaIS1_EE7reserveEm.exit.i.i.i @@ -50110,12 +50108,12 @@ _ZNSt6vectorISt4pairIidESaIS1_EE7reserveEm.exit.i.i.i: ; preds = %_ZNSt12_Vector br label %20 20: ; preds = %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i, %.lr.ph23.i.i.i - %21 = phi ptr [ %.promoted19, %.lr.ph23.i.i.i ], [ %96, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] - %22 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %97, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] - %23 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %98, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] - %24 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %99, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] - %25 = phi ptr [ %.promoted19, %.lr.ph23.i.i.i ], [ %100, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] - %26 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %101, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] + %21 = phi ptr [ %.promoted19, %.lr.ph23.i.i.i ], [ %95, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] + %22 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %96, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] + %23 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %97, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] + %24 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %98, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] + %25 = phi ptr [ %.promoted19, %.lr.ph23.i.i.i ], [ %99, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] + %26 = phi ptr [ %.promoted13, %.lr.ph23.i.i.i ], [ %100, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] %indvars.iv.i.i.i = phi i64 [ 0, %.lr.ph23.i.i.i ], [ %indvars.iv.next.i.i.i, %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i ] %27 = load ptr, ptr %1, align 8, !noalias !567 %28 = load ptr, ptr %27, align 8, !noalias !567 @@ -50196,90 +50194,89 @@ _ZNKSt8functionIFSt4pairIidEiEEclEi.exit.i.i.i.i: ; preds = %.lr.ph.i.i.i %60 = getelementptr inbounds nuw i8, ptr %31, i64 8 %61 = load double, ptr %60, align 8, !noalias !567 %.0.i.i.i.i = select i1 %59, double %61, double 0.000000e+00 - %62 = call double @llvm.fabs.f64(double %61) + %62 = call double @llvm.fabs.f64(double %.0.i.i.i.i) %63 = fcmp ogt double %62, 0x38AA95A5C0000000 - %64 = select i1 %59, i1 %63, i1 false - %65 = fcmp uno double %.0.i.i.i.i, 0.000000e+00 - %or.cond.i.i.i = select i1 %64, i1 true, i1 %65 - br i1 %or.cond.i.i.i, label %66, label %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i + %64 = fcmp uno double %.0.i.i.i.i, 0.000000e+00 + %or.cond.i.i.i = select i1 %63, i1 true, i1 %64 + br i1 %or.cond.i.i.i, label %65, label %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i -66: ; preds = %.loopexit.i.i.i +65: ; preds = %.loopexit.i.i.i %.not.i.i.i.i = icmp eq ptr %26, %25 - br i1 %.not.i.i.i.i, label %71, label %67 + br i1 %.not.i.i.i.i, label %70, label %66 -67: ; preds = %66 - %68 = trunc nuw nsw i64 %indvars.iv.i.i.i to i32 - store i32 %68, ptr %26, align 8, !noalias !567 - %69 = getelementptr inbounds nuw i8, ptr %26, i64 8 - store double %.0.i.i.i.i, ptr %69, align 8, !noalias !567 - %70 = getelementptr inbounds nuw i8, ptr %26, i64 16 +66: ; preds = %65 + %67 = trunc nuw nsw i64 %indvars.iv.i.i.i to i32 + store i32 %67, ptr %26, align 8, !noalias !567 + %68 = getelementptr inbounds nuw i8, ptr %26, i64 8 + store double %.0.i.i.i.i, ptr %68, align 8, !noalias !567 + %69 = getelementptr inbounds nuw i8, ptr %26, i64 16 br label %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i -71: ; preds = %66 - %72 = ptrtoint ptr %25 to i64 - %73 = ptrtoint ptr %24 to i64 - %74 = sub i64 %72, %73 - %75 = icmp eq i64 %74, 9223372036854775792 - br i1 %75, label %.invoke.i.i.i.loopexit, label %_ZNKSt6vectorISt4pairIidESaIS1_EE12_M_check_lenEmPKc.exit.i.i.i.i.i +70: ; preds = %65 + %71 = ptrtoint ptr %25 to i64 + %72 = ptrtoint ptr %24 to i64 + %73 = sub i64 %71, %72 + %74 = icmp eq i64 %73, 9223372036854775792 + br i1 %74, label %.invoke.i.i.i.loopexit, label %_ZNKSt6vectorISt4pairIidESaIS1_EE12_M_check_lenEmPKc.exit.i.i.i.i.i -.invoke.i.i.i.loopexit: ; preds = %71 +.invoke.i.i.i.loopexit: ; preds = %70 store ptr %23, ptr %19, align 8 store ptr %22, ptr %0, align 8 store ptr %21, ptr %10, align 8 br label %.invoke.i.i.i .invoke.i.i.i: ; preds = %.invoke.i.i.i.loopexit, %3 - %76 = phi ptr [ null, %3 ], [ %24, %.invoke.i.i.i.loopexit ] - %77 = phi ptr [ @.str.15, %3 ], [ @.str.16, %.invoke.i.i.i.loopexit ] - invoke void @_ZSt20__throw_length_errorPKc(ptr noundef nonnull %77) #39 + %75 = phi ptr [ null, %3 ], [ %24, %.invoke.i.i.i.loopexit ] + %76 = phi ptr [ @.str.15, %3 ], [ @.str.16, %.invoke.i.i.i.loopexit ] + invoke void @_ZSt20__throw_length_errorPKc(ptr noundef nonnull %76) #39 to label %.cont.i.i.i unwind label %.loopexit.split-lp.loopexit.split-lp.i.i.i, !noalias !567 .cont.i.i.i: ; preds = %.invoke.i.i.i unreachable -_ZNKSt6vectorISt4pairIidESaIS1_EE12_M_check_lenEmPKc.exit.i.i.i.i.i: ; preds = %71 - %78 = ashr exact i64 %74, 4 - %.sroa.speculated.i.i.i.i.i.i = call i64 @llvm.umax.i64(i64 %78, i64 1) - %79 = add nsw i64 %.sroa.speculated.i.i.i.i.i.i, %78 - %80 = icmp ult i64 %79, %78 - %81 = call i64 @llvm.umin.i64(i64 %79, i64 576460752303423487) - %82 = select i1 %80, i64 576460752303423487, i64 %81 - %.not.i.i.i8.i.i.i = icmp ne i64 %82, 0 +_ZNKSt6vectorISt4pairIidESaIS1_EE12_M_check_lenEmPKc.exit.i.i.i.i.i: ; preds = %70 + %77 = ashr exact i64 %73, 4 + %.sroa.speculated.i.i.i.i.i.i = call i64 @llvm.umax.i64(i64 %77, i64 1) + %78 = add nsw i64 %.sroa.speculated.i.i.i.i.i.i, %77 + %79 = icmp ult i64 %78, %77 + %80 = call i64 @llvm.umin.i64(i64 %78, i64 576460752303423487) + %81 = select i1 %79, i64 576460752303423487, i64 %80 + %.not.i.i.i8.i.i.i = icmp ne i64 %81, 0 call void @llvm.assume(i1 %.not.i.i.i8.i.i.i) - %83 = shl nuw nsw i64 %82, 4 - %84 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef %83) #40 + %82 = shl nuw nsw i64 %81, 4 + %83 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef %82) #40 to label %.noexc10.i.i.i unwind label %.loopexit.split-lp.loopexit.i.i.i, !noalias !567 .noexc10.i.i.i: ; preds = %_ZNKSt6vectorISt4pairIidESaIS1_EE12_M_check_lenEmPKc.exit.i.i.i.i.i - %85 = getelementptr inbounds i8, ptr %84, i64 %74 - %86 = trunc nuw nsw i64 %indvars.iv.i.i.i to i32 - store i32 %86, ptr %85, align 8, !noalias !567 - %87 = getelementptr inbounds nuw i8, ptr %85, i64 8 - store double %.0.i.i.i.i, ptr %87, align 8, !noalias !567 + %84 = getelementptr inbounds i8, ptr %83, i64 %73 + %85 = trunc nuw nsw i64 %indvars.iv.i.i.i to i32 + store i32 %85, ptr %84, align 8, !noalias !567 + %86 = getelementptr inbounds nuw i8, ptr %84, i64 8 + store double %.0.i.i.i.i, ptr %86, align 8, !noalias !567 %.not10.i.i.i.i.i.i.i.i.i = icmp eq ptr %24, %25 br i1 %.not10.i.i.i.i.i.i.i.i.i, label %_ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i, label %.lr.ph.i.i.i.i.i.i.i.i.i .lr.ph.i.i.i.i.i.i.i.i.i: ; preds = %.noexc10.i.i.i, %.lr.ph.i.i.i.i.i.i.i.i.i - %.012.i.i.i.i.i.i.i.i.i = phi ptr [ %89, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %84, %.noexc10.i.i.i ] - %.0911.i.i.i.i.i.i.i.i.i = phi ptr [ %88, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %24, %.noexc10.i.i.i ] + %.012.i.i.i.i.i.i.i.i.i = phi ptr [ %88, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %83, %.noexc10.i.i.i ] + %.0911.i.i.i.i.i.i.i.i.i = phi ptr [ %87, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %24, %.noexc10.i.i.i ] call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %.012.i.i.i.i.i.i.i.i.i, ptr noundef nonnull align 8 dereferenceable(16) %.0911.i.i.i.i.i.i.i.i.i, i64 16, i1 false), !alias.scope !568, !noalias !567 - %88 = getelementptr inbounds nuw i8, ptr %.0911.i.i.i.i.i.i.i.i.i, i64 16 - %89 = getelementptr inbounds nuw i8, ptr %.012.i.i.i.i.i.i.i.i.i, i64 16 - %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %88, %25 + %87 = getelementptr inbounds nuw i8, ptr %.0911.i.i.i.i.i.i.i.i.i, i64 16 + %88 = getelementptr inbounds nuw i8, ptr %.012.i.i.i.i.i.i.i.i.i, i64 16 + %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %87, %25 br i1 %.not.i.i.i.i.i.i.i.i.i, label %_ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i, label %.lr.ph.i.i.i.i.i.i.i.i.i, !llvm.loop !109 _ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i, %.noexc10.i.i.i - %.0.lcssa.i.i.i.i.i.i.i.i.i = phi ptr [ %84, %.noexc10.i.i.i ], [ %89, %.lr.ph.i.i.i.i.i.i.i.i.i ] - %90 = getelementptr inbounds nuw i8, ptr %.0.lcssa.i.i.i.i.i.i.i.i.i, i64 16 + %.0.lcssa.i.i.i.i.i.i.i.i.i = phi ptr [ %83, %.noexc10.i.i.i ], [ %88, %.lr.ph.i.i.i.i.i.i.i.i.i ] + %89 = getelementptr inbounds nuw i8, ptr %.0.lcssa.i.i.i.i.i.i.i.i.i, i64 16 %.not.i34.i.i.i.i.i = icmp eq ptr %24, null - br i1 %.not.i34.i.i.i.i.i, label %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i, label %91 + br i1 %.not.i34.i.i.i.i.i, label %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i, label %90 -91: ; preds = %_ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i +90: ; preds = %_ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i call void @_ZdlPv(ptr noundef nonnull %24) #37, !noalias !567 br label %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i -_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i: ; preds = %91, %_ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i - %92 = getelementptr inbounds nuw %"struct.std::pair.166", ptr %84, i64 %82 +_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i: ; preds = %90, %_ZNSt6vectorISt4pairIidESaIS1_EE11_S_relocateEPS1_S4_S4_RS2_.exit33.i.i.i.i.i + %91 = getelementptr inbounds nuw %"struct.std::pair.166", ptr %83, i64 %81 br label %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i .loopexit16.i.i.i: ; preds = %_ZNKSt8functionIFSt4pairIidEiEEclEi.exit.i.i.i.i @@ -50299,41 +50296,41 @@ _ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__norm br label %.loopexit.split-lp.i.i.i .loopexit.split-lp.loopexit.split-lp.i.i.i: ; preds = %.invoke.i.i.i, %47, %_ZNSt12_Vector_baseISt4pairIidESaIS1_EE11_M_allocateEm.exit.i.i.i.i - %93 = phi ptr [ %76, %.invoke.i.i.i ], [ %24, %47 ], [ null, %_ZNSt12_Vector_baseISt4pairIidESaIS1_EE11_M_allocateEm.exit.i.i.i.i ] + %92 = phi ptr [ %75, %.invoke.i.i.i ], [ %24, %47 ], [ null, %_ZNSt12_Vector_baseISt4pairIidESaIS1_EE11_M_allocateEm.exit.i.i.i.i ] %lpad.loopexit.split-lp18.i.i.i = landingpad { ptr, i32 } cleanup br label %.loopexit.split-lp.i.i.i .loopexit.split-lp.i.i.i: ; preds = %.loopexit.split-lp.loopexit.split-lp.i.i.i, %.loopexit.split-lp.loopexit.i.i.i, %.loopexit16.i.i.i - %94 = phi ptr [ %24, %.loopexit16.i.i.i ], [ %24, %.loopexit.split-lp.loopexit.i.i.i ], [ %93, %.loopexit.split-lp.loopexit.split-lp.i.i.i ] + %93 = phi ptr [ %24, %.loopexit16.i.i.i ], [ %24, %.loopexit.split-lp.loopexit.i.i.i ], [ %92, %.loopexit.split-lp.loopexit.split-lp.i.i.i ] %lpad.phi.i.i.i = phi { ptr, i32 } [ %lpad.loopexit.i.i.i, %.loopexit16.i.i.i ], [ %lpad.loopexit17.i.i.i, %.loopexit.split-lp.loopexit.i.i.i ], [ %lpad.loopexit.split-lp18.i.i.i, %.loopexit.split-lp.loopexit.split-lp.i.i.i ] - %.not.i.i.i11.i.i.i = icmp eq ptr %94, null - br i1 %.not.i.i.i11.i.i.i, label %_ZNSt6vectorISt4pairIidESaIS1_EED2Ev.exit.i.i.i, label %95 + %.not.i.i.i11.i.i.i = icmp eq ptr %93, null + br i1 %.not.i.i.i11.i.i.i, label %_ZNSt6vectorISt4pairIidESaIS1_EED2Ev.exit.i.i.i, label %94 -95: ; preds = %.loopexit.split-lp.i.i.i - call void @_ZdlPv(ptr noundef nonnull %94) #37, !noalias !567 +94: ; preds = %.loopexit.split-lp.i.i.i + call void @_ZdlPv(ptr noundef nonnull %93) #37, !noalias !567 br label %_ZNSt6vectorISt4pairIidESaIS1_EED2Ev.exit.i.i.i -_ZNSt6vectorISt4pairIidESaIS1_EED2Ev.exit.i.i.i: ; preds = %95, %.loopexit.split-lp.i.i.i +_ZNSt6vectorISt4pairIidESaIS1_EED2Ev.exit.i.i.i: ; preds = %94, %.loopexit.split-lp.i.i.i resume { ptr, i32 } %lpad.phi.i.i.i -_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i: ; preds = %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i, %67, %.loopexit.i.i.i - %96 = phi ptr [ %21, %.loopexit.i.i.i ], [ %92, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %21, %67 ] - %97 = phi ptr [ %22, %.loopexit.i.i.i ], [ %84, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %22, %67 ] - %98 = phi ptr [ %23, %.loopexit.i.i.i ], [ %90, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %70, %67 ] - %99 = phi ptr [ %24, %.loopexit.i.i.i ], [ %84, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %24, %67 ] - %100 = phi ptr [ %25, %.loopexit.i.i.i ], [ %92, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %25, %67 ] - %101 = phi ptr [ %26, %.loopexit.i.i.i ], [ %90, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %70, %67 ] +_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i: ; preds = %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i, %66, %.loopexit.i.i.i + %95 = phi ptr [ %21, %.loopexit.i.i.i ], [ %91, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %21, %66 ] + %96 = phi ptr [ %22, %.loopexit.i.i.i ], [ %83, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %22, %66 ] + %97 = phi ptr [ %23, %.loopexit.i.i.i ], [ %89, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %69, %66 ] + %98 = phi ptr [ %24, %.loopexit.i.i.i ], [ %83, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %24, %66 ] + %99 = phi ptr [ %25, %.loopexit.i.i.i ], [ %91, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %25, %66 ] + %100 = phi ptr [ %26, %.loopexit.i.i.i ], [ %89, %_ZNSt6vectorISt4pairIidESaIS1_EE17_M_realloc_insertIJRiRdEEEvN9__gnu_cxx17__normal_iteratorIPS1_S3_EEDpOT_.exit.i.i.i.i ], [ %69, %66 ] %indvars.iv.next.i.i.i = add nuw nsw i64 %indvars.iv.i.i.i, 1 - %102 = load i32, ptr %5, align 8, !noalias !567 - %103 = sext i32 %102 to i64 - %104 = icmp slt i64 %indvars.iv.next.i.i.i, %103 - br i1 %104, label %20, label %"_ZSt10__invoke_rISt6vectorISt4pairIidESaIS2_EERZ25LGBM_BoosterPredictForCSCE3$_0JiEENSt9enable_ifIXsr6__and_ISt6__not_ISt7is_voidIT_EESt14is_convertibleINSt15__invoke_resultIT0_JDpT1_EE4typeESA_EEE5valueESA_E4typeEOSF_DpOSG_.exit.loopexit", !llvm.loop !572 + %101 = load i32, ptr %5, align 8, !noalias !567 + %102 = sext i32 %101 to i64 + %103 = icmp slt i64 %indvars.iv.next.i.i.i, %102 + br i1 %103, label %20, label %"_ZSt10__invoke_rISt6vectorISt4pairIidESaIS2_EERZ25LGBM_BoosterPredictForCSCE3$_0JiEENSt9enable_ifIXsr6__and_ISt6__not_ISt7is_voidIT_EESt14is_convertibleINSt15__invoke_resultIT0_JDpT1_EE4typeESA_EEE5valueESA_E4typeEOSF_DpOSG_.exit.loopexit", !llvm.loop !572 "_ZSt10__invoke_rISt6vectorISt4pairIidESaIS2_EERZ25LGBM_BoosterPredictForCSCE3$_0JiEENSt9enable_ifIXsr6__and_ISt6__not_ISt7is_voidIT_EESt14is_convertibleINSt15__invoke_resultIT0_JDpT1_EE4typeESA_EEE5valueESA_E4typeEOSF_DpOSG_.exit.loopexit": ; preds = %_ZNSt6vectorISt4pairIidESaIS1_EE12emplace_backIJRiRdEEEvDpOT_.exit.i.i.i - store ptr %98, ptr %19, align 8 - store ptr %97, ptr %0, align 8 - store ptr %96, ptr %10, align 8 + store ptr %97, ptr %19, align 8 + store ptr %96, ptr %0, align 8 + store ptr %95, ptr %10, align 8 br label %"_ZSt10__invoke_rISt6vectorISt4pairIidESaIS2_EERZ25LGBM_BoosterPredictForCSCE3$_0JiEENSt9enable_ifIXsr6__and_ISt6__not_ISt7is_voidIT_EESt14is_convertibleINSt15__invoke_resultIT0_JDpT1_EE4typeESA_EEE5valueESA_E4typeEOSF_DpOSG_.exit" "_ZSt10__invoke_rISt6vectorISt4pairIidESaIS2_EERZ25LGBM_BoosterPredictForCSCE3$_0JiEENSt9enable_ifIXsr6__and_ISt6__not_ISt7is_voidIT_EESt14is_convertibleINSt15__invoke_resultIT0_JDpT1_EE4typeESA_EEE5valueESA_E4typeEOSF_DpOSG_.exit": ; preds = %"_ZSt10__invoke_rISt6vectorISt4pairIidESaIS2_EERZ25LGBM_BoosterPredictForCSCE3$_0JiEENSt9enable_ifIXsr6__and_ISt6__not_ISt7is_voidIT_EESt14is_convertibleINSt15__invoke_resultIT0_JDpT1_EE4typeESA_EEE5valueESA_E4typeEOSF_DpOSG_.exit.loopexit", %_ZNSt6vectorISt4pairIidESaIS1_EE7reserveEm.exit.i.i.i diff --git a/bench/lightgbm/optimized/tree.cpp.ll b/bench/lightgbm/optimized/tree.cpp.ll index 65ecc16f1d2..7a9b30b8763 100644 --- a/bench/lightgbm/optimized/tree.cpp.ll +++ b/bench/lightgbm/optimized/tree.cpp.ll @@ -58109,12 +58109,12 @@ define void @_ZNK8LightGBM4Tree8TreeSHAPEPKdPdiiPNS0_11PathElementEddi(ptr nocap br label %tailrecurse tailrecurse: ; preds = %._crit_edge.thread, %9 - %.tr97 = phi i32 [ %3, %9 ], [ %166, %._crit_edge.thread ] + %.tr97 = phi i32 [ %3, %9 ], [ %165, %._crit_edge.thread ] %.tr98 = phi i32 [ %4, %9 ], [ %.pre-phi, %._crit_edge.thread ] %.tr99 = phi ptr [ %5, %9 ], [ %20, %._crit_edge.thread ] - %.tr100 = phi double [ %6, %9 ], [ %242, %._crit_edge.thread ] + %.tr100 = phi double [ %6, %9 ], [ %241, %._crit_edge.thread ] %.tr101 = phi double [ %7, %9 ], [ 0.000000e+00, %._crit_edge.thread ] - %.tr102 = phi i32 [ %8, %9 ], [ %245, %._crit_edge.thread ] + %.tr102 = phi i32 [ %8, %9 ], [ %244, %._crit_edge.thread ] %19 = sext i32 %.tr98 to i64 %20 = getelementptr inbounds %"struct.LightGBM::Tree::PathElement", ptr %.tr99, i64 %19 %21 = icmp sgt i32 %.tr98, 0 @@ -58327,77 +58327,76 @@ _ZN8LightGBM6CommonL12FindInBitsetIiEEbPKjiT_.exit.thread.i.i: ; preds = %_ZN8Li %143 = icmp ne i8 %141, 2 %or.cond.i.i = and i1 %142, %143 %.017.i.i = select i1 %or.cond.i.i, double 0.000000e+00, double %107 - switch i8 %141, label %152 [ + switch i8 %141, label %151 [ i8 1, label %144 - i8 2, label %148 + i8 2, label %147 ] 144: ; preds = %139 - %145 = tail call double @llvm.fabs.f64(double %107) - %146 = fcmp ole double %145, 0x38AA95A5C0000000 - %147 = or i1 %146, %or.cond.i.i - br i1 %147, label %150, label %152 - -148: ; preds = %139 - %149 = fcmp uno double %.017.i.i, 0.000000e+00 - br i1 %149, label %150, label %152 - -150: ; preds = %148, %144 - %151 = and i8 %110, 2 - %.not.i7.i = icmp eq i8 %151, 0 + %145 = tail call double @llvm.fabs.f64(double %.017.i.i) + %146 = fcmp ugt double %145, 0x38AA95A5C0000000 + br i1 %146, label %151, label %149 + +147: ; preds = %139 + %148 = fcmp uno double %.017.i.i, 0.000000e+00 + br i1 %148, label %149, label %151 + +149: ; preds = %147, %144 + %150 = and i8 %110, 2 + %.not.i7.i = icmp eq i8 %150, 0 br label %_ZNK8LightGBM4Tree17NumericalDecisionEdi.exit.i -152: ; preds = %148, %144, %139 - %153 = load ptr, ptr %12, align 8 - %154 = getelementptr inbounds nuw double, ptr %153, i64 %101 - %155 = load double, ptr %154, align 8 - %156 = fcmp ugt double %.017.i.i, %155 +151: ; preds = %147, %144, %139 + %152 = load ptr, ptr %12, align 8 + %153 = getelementptr inbounds nuw double, ptr %152, i64 %101 + %154 = load double, ptr %153, align 8 + %155 = fcmp ugt double %.017.i.i, %154 br label %_ZNK8LightGBM4Tree17NumericalDecisionEdi.exit.i -_ZNK8LightGBM4Tree17NumericalDecisionEdi.exit.i: ; preds = %152, %150 - %.sink20.i.i = phi i1 [ %156, %152 ], [ %.not.i7.i, %150 ] +_ZNK8LightGBM4Tree17NumericalDecisionEdi.exit.i: ; preds = %151, %149 + %.sink20.i.i = phi i1 [ %155, %151 ], [ %.not.i7.i, %149 ] %.19.i.i = select i1 %.sink20.i.i, i64 40, i64 16 br label %_ZNK8LightGBM4Tree8DecisionEdi.exit _ZNK8LightGBM4Tree8DecisionEdi.exit: ; preds = %112, %114, %_ZN8LightGBM6CommonL12FindInBitsetIiEEbPKjiT_.exit.i.i, %_ZN8LightGBM6CommonL12FindInBitsetIiEEbPKjiT_.exit.thread.i.i, %_ZNK8LightGBM4Tree17NumericalDecisionEdi.exit.i %.sink.i = phi i64 [ 40, %_ZN8LightGBM6CommonL12FindInBitsetIiEEbPKjiT_.exit.thread.i.i ], [ %.19.i.i, %_ZNK8LightGBM4Tree17NumericalDecisionEdi.exit.i ], [ 40, %112 ], [ 40, %114 ], [ 16, %_ZN8LightGBM6CommonL12FindInBitsetIiEEbPKjiT_.exit.i.i ] - %157 = getelementptr inbounds nuw i8, ptr %0, i64 %.sink.i - %158 = load ptr, ptr %157, align 8 - %159 = getelementptr inbounds nuw i32, ptr %158, i64 %101 - %.0.i = load i32, ptr %159, align 4 - %160 = load ptr, ptr %15, align 8 - %161 = getelementptr inbounds nuw i32, ptr %160, i64 %101 - %162 = load i32, ptr %161, align 4 - %163 = icmp eq i32 %.0.i, %162 - %164 = load ptr, ptr %16, align 8 - %165 = getelementptr inbounds nuw i32, ptr %164, i64 %101 - %.in = select i1 %163, ptr %165, ptr %161 - %166 = load i32, ptr %.in, align 4 - %167 = load ptr, ptr %17, align 8 - %168 = getelementptr inbounds nuw i32, ptr %167, i64 %101 - %169 = load ptr, ptr %18, align 8 - %170 = load i32, ptr %168, align 4 - %171 = sitofp i32 %170 to double - %172 = zext nneg i32 %.0.i to i64 - %173 = getelementptr inbounds nuw i32, ptr %167, i64 %172 - %174 = xor i32 %.0.i, -1 - %175 = zext nneg i32 %174 to i64 - %176 = getelementptr inbounds nuw i32, ptr %169, i64 %175 - %177 = icmp slt i32 %.0.i, 0 - %.in.i84 = select i1 %177, ptr %176, ptr %173 - %178 = load i32, ptr %.in.i84, align 4 - %179 = sitofp i32 %178 to double - %180 = fdiv double %179, %171 - %181 = zext nneg i32 %166 to i64 - %182 = getelementptr inbounds nuw i32, ptr %167, i64 %181 - %183 = xor i32 %166, -1 - %184 = zext nneg i32 %183 to i64 - %185 = getelementptr inbounds nuw i32, ptr %169, i64 %184 - %186 = icmp slt i32 %166, 0 - %.in.i85 = select i1 %186, ptr %185, ptr %182 - %187 = load i32, ptr %.in.i85, align 4 - %188 = sitofp i32 %187 to double - %189 = fdiv double %188, %171 + %156 = getelementptr inbounds nuw i8, ptr %0, i64 %.sink.i + %157 = load ptr, ptr %156, align 8 + %158 = getelementptr inbounds nuw i32, ptr %157, i64 %101 + %.0.i = load i32, ptr %158, align 4 + %159 = load ptr, ptr %15, align 8 + %160 = getelementptr inbounds nuw i32, ptr %159, i64 %101 + %161 = load i32, ptr %160, align 4 + %162 = icmp eq i32 %.0.i, %161 + %163 = load ptr, ptr %16, align 8 + %164 = getelementptr inbounds nuw i32, ptr %163, i64 %101 + %.in = select i1 %162, ptr %164, ptr %160 + %165 = load i32, ptr %.in, align 4 + %166 = load ptr, ptr %17, align 8 + %167 = getelementptr inbounds nuw i32, ptr %166, i64 %101 + %168 = load ptr, ptr %18, align 8 + %169 = load i32, ptr %167, align 4 + %170 = sitofp i32 %169 to double + %171 = zext nneg i32 %.0.i to i64 + %172 = getelementptr inbounds nuw i32, ptr %166, i64 %171 + %173 = xor i32 %.0.i, -1 + %174 = zext nneg i32 %173 to i64 + %175 = getelementptr inbounds nuw i32, ptr %168, i64 %174 + %176 = icmp slt i32 %.0.i, 0 + %.in.i84 = select i1 %176, ptr %175, ptr %172 + %177 = load i32, ptr %.in.i84, align 4 + %178 = sitofp i32 %177 to double + %179 = fdiv double %178, %170 + %180 = zext nneg i32 %165 to i64 + %181 = getelementptr inbounds nuw i32, ptr %166, i64 %180 + %182 = xor i32 %165, -1 + %183 = zext nneg i32 %182 to i64 + %184 = getelementptr inbounds nuw i32, ptr %168, i64 %183 + %185 = icmp slt i32 %165, 0 + %.in.i85 = select i1 %185, ptr %184, ptr %181 + %186 = load i32, ptr %.in.i85, align 4 + %187 = sitofp i32 %186 to double + %188 = fdiv double %187, %170 %.not106 = icmp slt i32 %.tr98, 0 %.pre133 = add i32 %.tr98, 1 br i1 %.not106, label %._crit_edge, label %.lr.ph.preheader @@ -58406,109 +58405,109 @@ _ZNK8LightGBM4Tree8DecisionEdi.exit: ; preds = %112, %114, %_ZN8Lig %wide.trip.count = zext i32 %.pre133 to i64 br label %.lr.ph -.lr.ph: ; preds = %.lr.ph.preheader, %193 - %indvars.iv = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next, %193 ] - %190 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %indvars.iv - %191 = load i32, ptr %190, align 8 - %192 = icmp eq i32 %191, %104 - br i1 %192, label %._crit_edge.loopexit, label %193 +.lr.ph: ; preds = %.lr.ph.preheader, %192 + %indvars.iv = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next, %192 ] + %189 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %indvars.iv + %190 = load i32, ptr %189, align 8 + %191 = icmp eq i32 %190, %104 + br i1 %191, label %._crit_edge.loopexit, label %192 -193: ; preds = %.lr.ph +192: ; preds = %.lr.ph %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1 %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count br i1 %exitcond.not, label %._crit_edge.thread, label %.lr.ph, !llvm.loop !384 ._crit_edge.loopexit: ; preds = %.lr.ph - %194 = trunc nuw nsw i64 %indvars.iv to i32 + %193 = trunc nuw nsw i64 %indvars.iv to i32 br label %._crit_edge ._crit_edge: ; preds = %_ZNK8LightGBM4Tree8DecisionEdi.exit, %._crit_edge.loopexit - %.0.lcssa = phi i32 [ %194, %._crit_edge.loopexit ], [ 0, %_ZNK8LightGBM4Tree8DecisionEdi.exit ] + %.0.lcssa = phi i32 [ %193, %._crit_edge.loopexit ], [ 0, %_ZNK8LightGBM4Tree8DecisionEdi.exit ] %.not78 = icmp eq i32 %.0.lcssa, %.pre133 - br i1 %.not78, label %._crit_edge.thread, label %195 - -195: ; preds = %._crit_edge - %196 = zext nneg i32 %.0.lcssa to i64 - %197 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %196 - %198 = getelementptr inbounds nuw i8, ptr %197, i64 8 - %199 = load double, ptr %198, align 8 - %200 = getelementptr inbounds nuw i8, ptr %197, i64 16 - %201 = load double, ptr %200, align 8 + br i1 %.not78, label %._crit_edge.thread, label %194 + +194: ; preds = %._crit_edge + %195 = zext nneg i32 %.0.lcssa to i64 + %196 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %195 + %197 = getelementptr inbounds nuw i8, ptr %196, i64 8 + %198 = load double, ptr %197, align 8 + %199 = getelementptr inbounds nuw i8, ptr %196, i64 16 + %200 = load double, ptr %199, align 8 br i1 %21, label %.lr.ph.i86, label %.preheader.i -.lr.ph.i86: ; preds = %195 +.lr.ph.i86: ; preds = %194 %.04951.i = add nsw i32 %.tr98, -1 - %202 = fcmp une double %201, 0.000000e+00 - %203 = uitofp nneg i32 %.pre133 to double - br i1 %202, label %.lr.ph.split.us.preheader.i92, label %.lr.ph.split.preheader.i87 + %201 = fcmp une double %200, 0.000000e+00 + %202 = uitofp nneg i32 %.pre133 to double + br i1 %201, label %.lr.ph.split.us.preheader.i92, label %.lr.ph.split.preheader.i87 .lr.ph.split.preheader.i87: ; preds = %.lr.ph.i86 - %204 = zext nneg i32 %.04951.i to i64 + %203 = zext nneg i32 %.04951.i to i64 br label %.lr.ph.split.i88 .lr.ph.split.us.preheader.i92: ; preds = %.lr.ph.i86 - %205 = zext nneg i32 %.tr98 to i64 - %206 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %205, i32 3 - %207 = load double, ptr %206, align 8 - %208 = zext nneg i32 %.04951.i to i64 + %204 = zext nneg i32 %.tr98 to i64 + %205 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %204, i32 3 + %206 = load double, ptr %205, align 8 + %207 = zext nneg i32 %.04951.i to i64 br label %.lr.ph.split.us.i93 .lr.ph.split.us.i93: ; preds = %.lr.ph.split.us.i93, %.lr.ph.split.us.preheader.i92 - %indvars.iv59.i = phi i64 [ %208, %.lr.ph.split.us.preheader.i92 ], [ %indvars.iv.next60.i, %.lr.ph.split.us.i93 ] - %.04853.us.i = phi double [ %207, %.lr.ph.split.us.preheader.i92 ], [ %221, %.lr.ph.split.us.i93 ] - %.049.in52.us.i = phi i32 [ %.tr98, %.lr.ph.split.us.preheader.i92 ], [ %216, %.lr.ph.split.us.i93 ] - %209 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %indvars.iv59.i, i32 3 - %210 = load double, ptr %209, align 8 - %211 = fmul double %.04853.us.i, %203 - %212 = uitofp nneg i32 %.049.in52.us.i to double - %213 = fmul double %201, %212 - %214 = fdiv double %211, %213 - store double %214, ptr %209, align 8 - %215 = fmul double %199, %214 - %216 = trunc i64 %indvars.iv59.i to i32 - %217 = sub i32 %.tr98, %216 - %218 = sitofp i32 %217 to double - %219 = fmul double %215, %218 - %220 = fdiv double %219, %203 - %221 = fsub double %210, %220 + %indvars.iv59.i = phi i64 [ %207, %.lr.ph.split.us.preheader.i92 ], [ %indvars.iv.next60.i, %.lr.ph.split.us.i93 ] + %.04853.us.i = phi double [ %206, %.lr.ph.split.us.preheader.i92 ], [ %220, %.lr.ph.split.us.i93 ] + %.049.in52.us.i = phi i32 [ %.tr98, %.lr.ph.split.us.preheader.i92 ], [ %215, %.lr.ph.split.us.i93 ] + %208 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %indvars.iv59.i, i32 3 + %209 = load double, ptr %208, align 8 + %210 = fmul double %.04853.us.i, %202 + %211 = uitofp nneg i32 %.049.in52.us.i to double + %212 = fmul double %200, %211 + %213 = fdiv double %210, %212 + store double %213, ptr %208, align 8 + %214 = fmul double %198, %213 + %215 = trunc i64 %indvars.iv59.i to i32 + %216 = sub i32 %.tr98, %215 + %217 = sitofp i32 %216 to double + %218 = fmul double %214, %217 + %219 = fdiv double %218, %202 + %220 = fsub double %209, %219 %indvars.iv.next60.i = add nsw i64 %indvars.iv59.i, -1 %.not66.i = icmp eq i64 %indvars.iv59.i, 0 br i1 %.not66.i, label %.preheader.i, label %.lr.ph.split.us.i93, !llvm.loop !380 -.preheader.i: ; preds = %.lr.ph.split.i88, %.lr.ph.split.us.i93, %195 - %222 = icmp slt i32 %.0.lcssa, %.tr98 - br i1 %222, label %.lr.ph56.i, label %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit +.preheader.i: ; preds = %.lr.ph.split.i88, %.lr.ph.split.us.i93, %194 + %221 = icmp slt i32 %.0.lcssa, %.tr98 + br i1 %221, label %.lr.ph56.i, label %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit .lr.ph.split.i88: ; preds = %.lr.ph.split.i88, %.lr.ph.split.preheader.i87 - %indvars.iv.i89 = phi i64 [ %204, %.lr.ph.split.preheader.i87 ], [ %indvars.iv.next.i90, %.lr.ph.split.i88 ] - %223 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %indvars.iv.i89, i32 3 - %224 = load double, ptr %223, align 8 - %225 = fmul double %224, %203 - %226 = trunc i64 %indvars.iv.i89 to i32 - %227 = sub i32 %.tr98, %226 - %228 = sitofp i32 %227 to double - %229 = fmul double %199, %228 - %230 = fdiv double %225, %229 - store double %230, ptr %223, align 8 + %indvars.iv.i89 = phi i64 [ %203, %.lr.ph.split.preheader.i87 ], [ %indvars.iv.next.i90, %.lr.ph.split.i88 ] + %222 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %indvars.iv.i89, i32 3 + %223 = load double, ptr %222, align 8 + %224 = fmul double %223, %202 + %225 = trunc i64 %indvars.iv.i89 to i32 + %226 = sub i32 %.tr98, %225 + %227 = sitofp i32 %226 to double + %228 = fmul double %198, %227 + %229 = fdiv double %224, %228 + store double %229, ptr %222, align 8 %indvars.iv.next.i90 = add nsw i64 %indvars.iv.i89, -1 %.not.i91 = icmp eq i64 %indvars.iv.i89, 0 br i1 %.not.i91, label %.preheader.i, label %.lr.ph.split.i88, !llvm.loop !380 .lr.ph56.i: ; preds = %.preheader.i, %.lr.ph56.i - %indvars.iv62.i = phi i64 [ %indvars.iv.next63.i, %.lr.ph56.i ], [ %196, %.preheader.i ] + %indvars.iv62.i = phi i64 [ %indvars.iv.next63.i, %.lr.ph56.i ], [ %195, %.preheader.i ] %indvars.iv.next63.i = add nuw nsw i64 %indvars.iv62.i, 1 - %231 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %indvars.iv.next63.i - %232 = load i32, ptr %231, align 8 - %233 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %indvars.iv62.i - store i32 %232, ptr %233, align 8 - %234 = getelementptr inbounds nuw i8, ptr %231, i64 8 - %235 = load double, ptr %234, align 8 - %236 = getelementptr inbounds nuw i8, ptr %233, i64 8 - store double %235, ptr %236, align 8 - %237 = getelementptr inbounds nuw i8, ptr %231, i64 16 - %238 = load double, ptr %237, align 8 - %239 = getelementptr inbounds nuw i8, ptr %233, i64 16 - store double %238, ptr %239, align 8 + %230 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %indvars.iv.next63.i + %231 = load i32, ptr %230, align 8 + %232 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %20, i64 %indvars.iv62.i + store i32 %231, ptr %232, align 8 + %233 = getelementptr inbounds nuw i8, ptr %230, i64 8 + %234 = load double, ptr %233, align 8 + %235 = getelementptr inbounds nuw i8, ptr %232, i64 8 + store double %234, ptr %235, align 8 + %236 = getelementptr inbounds nuw i8, ptr %230, i64 16 + %237 = load double, ptr %236, align 8 + %238 = getelementptr inbounds nuw i8, ptr %232, i64 16 + store double %237, ptr %238, align 8 %exitcond.not.i = icmp eq i64 %indvars.iv.next63.i, %19 br i1 %exitcond.not.i, label %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit, label %.lr.ph56.i, !llvm.loop !381 @@ -58518,17 +58517,17 @@ _ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit: ; preds = %.lr.ph56.i, %.pre131 = load i32, ptr %.phi.trans.insert, align 4 br label %._crit_edge.thread -._crit_edge.thread: ; preds = %193, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit, %._crit_edge - %.pre-phi = phi i32 [ %.tr98, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ %.pre133, %._crit_edge ], [ %.pre133, %193 ] - %240 = phi i32 [ %.pre131, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ %104, %._crit_edge ], [ %104, %193 ] - %.073 = phi double [ %199, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ 1.000000e+00, %._crit_edge ], [ 1.000000e+00, %193 ] - %.072 = phi double [ %201, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ 1.000000e+00, %._crit_edge ], [ 1.000000e+00, %193 ] - %241 = fmul double %180, %.073 - tail call void @_ZNK8LightGBM4Tree8TreeSHAPEPKdPdiiPNS0_11PathElementEddi(ptr noundef nonnull align 8 dereferenceable(648) %0, ptr noundef %1, ptr noundef %2, i32 noundef %.0.i, i32 noundef %.pre-phi, ptr noundef nonnull %20, double noundef %241, double noundef %.072, i32 noundef %240) - %242 = fmul double %189, %.073 - %243 = load ptr, ptr %10, align 8 - %244 = getelementptr inbounds nuw i32, ptr %243, i64 %101 - %245 = load i32, ptr %244, align 4 +._crit_edge.thread: ; preds = %192, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit, %._crit_edge + %.pre-phi = phi i32 [ %.tr98, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ %.pre133, %._crit_edge ], [ %.pre133, %192 ] + %239 = phi i32 [ %.pre131, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ %104, %._crit_edge ], [ %104, %192 ] + %.073 = phi double [ %198, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ 1.000000e+00, %._crit_edge ], [ 1.000000e+00, %192 ] + %.072 = phi double [ %200, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ 1.000000e+00, %._crit_edge ], [ 1.000000e+00, %192 ] + %240 = fmul double %179, %.073 + tail call void @_ZNK8LightGBM4Tree8TreeSHAPEPKdPdiiPNS0_11PathElementEddi(ptr noundef nonnull align 8 dereferenceable(648) %0, ptr noundef %1, ptr noundef %2, i32 noundef %.0.i, i32 noundef %.pre-phi, ptr noundef nonnull %20, double noundef %240, double noundef %.072, i32 noundef %239) + %241 = fmul double %188, %.073 + %242 = load ptr, ptr %10, align 8 + %243 = getelementptr inbounds nuw i32, ptr %242, i64 %101 + %244 = load i32, ptr %243, align 4 br label %tailrecurse ._crit_edge113: ; preds = %_ZN8LightGBM4Tree14UnwoundPathSumEPKNS0_11PathElementEii.exit.us, %.preheader @@ -58552,12 +58551,12 @@ define void @_ZNK8LightGBM4Tree13TreeSHAPByMapERKSt13unordered_mapIidSt4hashIiES br label %tailrecurse tailrecurse: ; preds = %._crit_edge.thread, %9 - %.tr124 = phi i32 [ %3, %9 ], [ %244, %._crit_edge.thread ] + %.tr124 = phi i32 [ %3, %9 ], [ %243, %._crit_edge.thread ] %.tr125 = phi i32 [ %4, %9 ], [ %.pre-phi, %._crit_edge.thread ] %.tr126 = phi ptr [ %5, %9 ], [ %23, %._crit_edge.thread ] - %.tr127 = phi double [ %6, %9 ], [ %321, %._crit_edge.thread ] + %.tr127 = phi double [ %6, %9 ], [ %320, %._crit_edge.thread ] %.tr128 = phi double [ %7, %9 ], [ 0.000000e+00, %._crit_edge.thread ] - %.tr129 = phi i32 [ %8, %9 ], [ %324, %._crit_edge.thread ] + %.tr129 = phi i32 [ %8, %9 ], [ %323, %._crit_edge.thread ] %22 = sext i32 %.tr125 to i64 %23 = getelementptr inbounds %"struct.LightGBM::Tree::PathElement", ptr %.tr126, i64 %22 %24 = icmp sgt i32 %.tr125, 0 @@ -58948,188 +58947,187 @@ _ZN8LightGBM6CommonL12FindInBitsetIiEEbPKjiT_.exit.thread.i.i: ; preds = %_ZN8Li %221 = icmp ne i8 %219, 2 %or.cond.i.i = and i1 %220, %221 %.017.i.i = select i1 %or.cond.i.i, double 0.000000e+00, double %217 - switch i8 %219, label %230 [ + switch i8 %219, label %229 [ i8 1, label %222 - i8 2, label %226 + i8 2, label %225 ] 222: ; preds = %215 - %223 = tail call double @llvm.fabs.f64(double %217) - %224 = fcmp ole double %223, 0x38AA95A5C0000000 - %225 = or i1 %224, %or.cond.i.i - br i1 %225, label %228, label %230 + %223 = tail call double @llvm.fabs.f64(double %.017.i.i) + %224 = fcmp ugt double %223, 0x38AA95A5C0000000 + br i1 %224, label %229, label %227 -226: ; preds = %215 - %227 = fcmp uno double %.017.i.i, 0.000000e+00 - br i1 %227, label %228, label %230 +225: ; preds = %215 + %226 = fcmp uno double %.017.i.i, 0.000000e+00 + br i1 %226, label %227, label %229 -228: ; preds = %226, %222 - %229 = and i8 %216, 2 - %.not.i7.i = icmp eq i8 %229, 0 +227: ; preds = %225, %222 + %228 = and i8 %216, 2 + %.not.i7.i = icmp eq i8 %228, 0 br label %_ZNK8LightGBM4Tree17NumericalDecisionEdi.exit.i -230: ; preds = %226, %222, %215 - %231 = load ptr, ptr %15, align 8 - %232 = getelementptr inbounds nuw double, ptr %231, i64 %128 - %233 = load double, ptr %232, align 8 - %234 = fcmp ugt double %.017.i.i, %233 +229: ; preds = %225, %222, %215 + %230 = load ptr, ptr %15, align 8 + %231 = getelementptr inbounds nuw double, ptr %230, i64 %128 + %232 = load double, ptr %231, align 8 + %233 = fcmp ugt double %.017.i.i, %232 br label %_ZNK8LightGBM4Tree17NumericalDecisionEdi.exit.i -_ZNK8LightGBM4Tree17NumericalDecisionEdi.exit.i: ; preds = %230, %228 - %.sink20.i.i = phi i1 [ %234, %230 ], [ %.not.i7.i, %228 ] +_ZNK8LightGBM4Tree17NumericalDecisionEdi.exit.i: ; preds = %229, %227 + %.sink20.i.i = phi i1 [ %233, %229 ], [ %.not.i7.i, %227 ] %.19.i.i = select i1 %.sink20.i.i, i64 40, i64 16 br label %_ZNK8LightGBM4Tree8DecisionEdi.exit _ZNK8LightGBM4Tree8DecisionEdi.exit: ; preds = %188, %.thread120, %_ZN8LightGBM6CommonL12FindInBitsetIiEEbPKjiT_.exit.i.i, %_ZN8LightGBM6CommonL12FindInBitsetIiEEbPKjiT_.exit.thread.i.i, %_ZNK8LightGBM4Tree17NumericalDecisionEdi.exit.i %.sink.i = phi i64 [ 40, %_ZN8LightGBM6CommonL12FindInBitsetIiEEbPKjiT_.exit.thread.i.i ], [ %.19.i.i, %_ZNK8LightGBM4Tree17NumericalDecisionEdi.exit.i ], [ 40, %188 ], [ 40, %.thread120 ], [ 16, %_ZN8LightGBM6CommonL12FindInBitsetIiEEbPKjiT_.exit.i.i ] - %235 = getelementptr inbounds nuw i8, ptr %0, i64 %.sink.i - %236 = load ptr, ptr %235, align 8 - %237 = getelementptr inbounds nuw i32, ptr %236, i64 %128 - %.0.i = load i32, ptr %237, align 4 - %238 = load ptr, ptr %18, align 8 - %239 = getelementptr inbounds nuw i32, ptr %238, i64 %128 - %240 = load i32, ptr %239, align 4 - %241 = icmp eq i32 %.0.i, %240 - %242 = load ptr, ptr %19, align 8 - %243 = getelementptr inbounds nuw i32, ptr %242, i64 %128 - %.in = select i1 %241, ptr %243, ptr %239 - %244 = load i32, ptr %.in, align 4 - %245 = load ptr, ptr %20, align 8 - %246 = getelementptr inbounds nuw i32, ptr %245, i64 %128 - %247 = load ptr, ptr %21, align 8 - %248 = load i32, ptr %246, align 4 - %249 = sitofp i32 %248 to double - %250 = zext nneg i32 %.0.i to i64 - %251 = getelementptr inbounds nuw i32, ptr %245, i64 %250 - %252 = xor i32 %.0.i, -1 - %253 = zext nneg i32 %252 to i64 - %254 = getelementptr inbounds nuw i32, ptr %247, i64 %253 - %255 = icmp slt i32 %.0.i, 0 - %.in.i101 = select i1 %255, ptr %254, ptr %251 - %256 = load i32, ptr %.in.i101, align 4 - %257 = sitofp i32 %256 to double - %258 = fdiv double %257, %249 - %259 = zext nneg i32 %244 to i64 - %260 = getelementptr inbounds nuw i32, ptr %245, i64 %259 - %261 = xor i32 %244, -1 - %262 = zext nneg i32 %261 to i64 - %263 = getelementptr inbounds nuw i32, ptr %247, i64 %262 - %264 = icmp slt i32 %244, 0 - %.in.i102 = select i1 %264, ptr %263, ptr %260 - %265 = load i32, ptr %.in.i102, align 4 - %266 = sitofp i32 %265 to double - %267 = fdiv double %266, %249 + %234 = getelementptr inbounds nuw i8, ptr %0, i64 %.sink.i + %235 = load ptr, ptr %234, align 8 + %236 = getelementptr inbounds nuw i32, ptr %235, i64 %128 + %.0.i = load i32, ptr %236, align 4 + %237 = load ptr, ptr %18, align 8 + %238 = getelementptr inbounds nuw i32, ptr %237, i64 %128 + %239 = load i32, ptr %238, align 4 + %240 = icmp eq i32 %.0.i, %239 + %241 = load ptr, ptr %19, align 8 + %242 = getelementptr inbounds nuw i32, ptr %241, i64 %128 + %.in = select i1 %240, ptr %242, ptr %238 + %243 = load i32, ptr %.in, align 4 + %244 = load ptr, ptr %20, align 8 + %245 = getelementptr inbounds nuw i32, ptr %244, i64 %128 + %246 = load ptr, ptr %21, align 8 + %247 = load i32, ptr %245, align 4 + %248 = sitofp i32 %247 to double + %249 = zext nneg i32 %.0.i to i64 + %250 = getelementptr inbounds nuw i32, ptr %244, i64 %249 + %251 = xor i32 %.0.i, -1 + %252 = zext nneg i32 %251 to i64 + %253 = getelementptr inbounds nuw i32, ptr %246, i64 %252 + %254 = icmp slt i32 %.0.i, 0 + %.in.i101 = select i1 %254, ptr %253, ptr %250 + %255 = load i32, ptr %.in.i101, align 4 + %256 = sitofp i32 %255 to double + %257 = fdiv double %256, %248 + %258 = zext nneg i32 %243 to i64 + %259 = getelementptr inbounds nuw i32, ptr %244, i64 %258 + %260 = xor i32 %243, -1 + %261 = zext nneg i32 %260 to i64 + %262 = getelementptr inbounds nuw i32, ptr %246, i64 %261 + %263 = icmp slt i32 %243, 0 + %.in.i102 = select i1 %263, ptr %262, ptr %259 + %264 = load i32, ptr %.in.i102, align 4 + %265 = sitofp i32 %264 to double + %266 = fdiv double %265, %248 %.not80156 = icmp slt i32 %.tr125, 0 %.pre207 = add i32 %.tr125, 1 br i1 %.not80156, label %._crit_edge, label %.lr.ph .lr.ph: ; preds = %_ZNK8LightGBM4Tree8DecisionEdi.exit %wide.trip.count = zext i32 %.pre207 to i64 - br label %268 + br label %267 -268: ; preds = %.lr.ph, %272 - %indvars.iv = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next, %272 ] - %269 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %indvars.iv - %270 = load i32, ptr %269, align 8 - %271 = icmp eq i32 %270, %132 - br i1 %271, label %._crit_edge.loopexit, label %272 +267: ; preds = %.lr.ph, %271 + %indvars.iv = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next, %271 ] + %268 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %indvars.iv + %269 = load i32, ptr %268, align 8 + %270 = icmp eq i32 %269, %132 + br i1 %270, label %._crit_edge.loopexit, label %271 -272: ; preds = %268 +271: ; preds = %267 %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1 %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count - br i1 %exitcond.not, label %._crit_edge.thread, label %268, !llvm.loop !388 + br i1 %exitcond.not, label %._crit_edge.thread, label %267, !llvm.loop !388 -._crit_edge.loopexit: ; preds = %268 - %273 = trunc nuw nsw i64 %indvars.iv to i32 +._crit_edge.loopexit: ; preds = %267 + %272 = trunc nuw nsw i64 %indvars.iv to i32 br label %._crit_edge ._crit_edge: ; preds = %_ZNK8LightGBM4Tree8DecisionEdi.exit, %._crit_edge.loopexit - %.0.lcssa = phi i32 [ %273, %._crit_edge.loopexit ], [ 0, %_ZNK8LightGBM4Tree8DecisionEdi.exit ] + %.0.lcssa = phi i32 [ %272, %._crit_edge.loopexit ], [ 0, %_ZNK8LightGBM4Tree8DecisionEdi.exit ] %.not81 = icmp eq i32 %.0.lcssa, %.pre207 - br i1 %.not81, label %._crit_edge.thread, label %274 - -274: ; preds = %._crit_edge - %275 = zext nneg i32 %.0.lcssa to i64 - %276 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %275 - %277 = getelementptr inbounds nuw i8, ptr %276, i64 8 - %278 = load double, ptr %277, align 8 - %279 = getelementptr inbounds nuw i8, ptr %276, i64 16 - %280 = load double, ptr %279, align 8 + br i1 %.not81, label %._crit_edge.thread, label %273 + +273: ; preds = %._crit_edge + %274 = zext nneg i32 %.0.lcssa to i64 + %275 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %274 + %276 = getelementptr inbounds nuw i8, ptr %275, i64 8 + %277 = load double, ptr %276, align 8 + %278 = getelementptr inbounds nuw i8, ptr %275, i64 16 + %279 = load double, ptr %278, align 8 br i1 %24, label %.lr.ph.i103, label %.preheader.i -.lr.ph.i103: ; preds = %274 +.lr.ph.i103: ; preds = %273 %.04951.i = add nsw i32 %.tr125, -1 - %281 = fcmp une double %280, 0.000000e+00 - %282 = uitofp nneg i32 %.pre207 to double - br i1 %281, label %.lr.ph.split.us.preheader.i109, label %.lr.ph.split.preheader.i104 + %280 = fcmp une double %279, 0.000000e+00 + %281 = uitofp nneg i32 %.pre207 to double + br i1 %280, label %.lr.ph.split.us.preheader.i109, label %.lr.ph.split.preheader.i104 .lr.ph.split.preheader.i104: ; preds = %.lr.ph.i103 - %283 = zext nneg i32 %.04951.i to i64 + %282 = zext nneg i32 %.04951.i to i64 br label %.lr.ph.split.i105 .lr.ph.split.us.preheader.i109: ; preds = %.lr.ph.i103 - %284 = zext nneg i32 %.tr125 to i64 - %285 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %284, i32 3 - %286 = load double, ptr %285, align 8 - %287 = zext nneg i32 %.04951.i to i64 + %283 = zext nneg i32 %.tr125 to i64 + %284 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %283, i32 3 + %285 = load double, ptr %284, align 8 + %286 = zext nneg i32 %.04951.i to i64 br label %.lr.ph.split.us.i110 .lr.ph.split.us.i110: ; preds = %.lr.ph.split.us.i110, %.lr.ph.split.us.preheader.i109 - %indvars.iv59.i = phi i64 [ %287, %.lr.ph.split.us.preheader.i109 ], [ %indvars.iv.next60.i, %.lr.ph.split.us.i110 ] - %.04853.us.i = phi double [ %286, %.lr.ph.split.us.preheader.i109 ], [ %300, %.lr.ph.split.us.i110 ] - %.049.in52.us.i = phi i32 [ %.tr125, %.lr.ph.split.us.preheader.i109 ], [ %295, %.lr.ph.split.us.i110 ] - %288 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %indvars.iv59.i, i32 3 - %289 = load double, ptr %288, align 8 - %290 = fmul double %.04853.us.i, %282 - %291 = uitofp nneg i32 %.049.in52.us.i to double - %292 = fmul double %280, %291 - %293 = fdiv double %290, %292 - store double %293, ptr %288, align 8 - %294 = fmul double %278, %293 - %295 = trunc i64 %indvars.iv59.i to i32 - %296 = sub i32 %.tr125, %295 - %297 = sitofp i32 %296 to double - %298 = fmul double %294, %297 - %299 = fdiv double %298, %282 - %300 = fsub double %289, %299 + %indvars.iv59.i = phi i64 [ %286, %.lr.ph.split.us.preheader.i109 ], [ %indvars.iv.next60.i, %.lr.ph.split.us.i110 ] + %.04853.us.i = phi double [ %285, %.lr.ph.split.us.preheader.i109 ], [ %299, %.lr.ph.split.us.i110 ] + %.049.in52.us.i = phi i32 [ %.tr125, %.lr.ph.split.us.preheader.i109 ], [ %294, %.lr.ph.split.us.i110 ] + %287 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %indvars.iv59.i, i32 3 + %288 = load double, ptr %287, align 8 + %289 = fmul double %.04853.us.i, %281 + %290 = uitofp nneg i32 %.049.in52.us.i to double + %291 = fmul double %279, %290 + %292 = fdiv double %289, %291 + store double %292, ptr %287, align 8 + %293 = fmul double %277, %292 + %294 = trunc i64 %indvars.iv59.i to i32 + %295 = sub i32 %.tr125, %294 + %296 = sitofp i32 %295 to double + %297 = fmul double %293, %296 + %298 = fdiv double %297, %281 + %299 = fsub double %288, %298 %indvars.iv.next60.i = add nsw i64 %indvars.iv59.i, -1 %.not66.i = icmp eq i64 %indvars.iv59.i, 0 br i1 %.not66.i, label %.preheader.i, label %.lr.ph.split.us.i110, !llvm.loop !380 -.preheader.i: ; preds = %.lr.ph.split.i105, %.lr.ph.split.us.i110, %274 - %301 = icmp slt i32 %.0.lcssa, %.tr125 - br i1 %301, label %.lr.ph56.i, label %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit +.preheader.i: ; preds = %.lr.ph.split.i105, %.lr.ph.split.us.i110, %273 + %300 = icmp slt i32 %.0.lcssa, %.tr125 + br i1 %300, label %.lr.ph56.i, label %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit .lr.ph.split.i105: ; preds = %.lr.ph.split.i105, %.lr.ph.split.preheader.i104 - %indvars.iv.i106 = phi i64 [ %283, %.lr.ph.split.preheader.i104 ], [ %indvars.iv.next.i107, %.lr.ph.split.i105 ] - %302 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %indvars.iv.i106, i32 3 - %303 = load double, ptr %302, align 8 - %304 = fmul double %303, %282 - %305 = trunc i64 %indvars.iv.i106 to i32 - %306 = sub i32 %.tr125, %305 - %307 = sitofp i32 %306 to double - %308 = fmul double %278, %307 - %309 = fdiv double %304, %308 - store double %309, ptr %302, align 8 + %indvars.iv.i106 = phi i64 [ %282, %.lr.ph.split.preheader.i104 ], [ %indvars.iv.next.i107, %.lr.ph.split.i105 ] + %301 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %indvars.iv.i106, i32 3 + %302 = load double, ptr %301, align 8 + %303 = fmul double %302, %281 + %304 = trunc i64 %indvars.iv.i106 to i32 + %305 = sub i32 %.tr125, %304 + %306 = sitofp i32 %305 to double + %307 = fmul double %277, %306 + %308 = fdiv double %303, %307 + store double %308, ptr %301, align 8 %indvars.iv.next.i107 = add nsw i64 %indvars.iv.i106, -1 %.not.i108 = icmp eq i64 %indvars.iv.i106, 0 br i1 %.not.i108, label %.preheader.i, label %.lr.ph.split.i105, !llvm.loop !380 .lr.ph56.i: ; preds = %.preheader.i, %.lr.ph56.i - %indvars.iv62.i = phi i64 [ %indvars.iv.next63.i, %.lr.ph56.i ], [ %275, %.preheader.i ] + %indvars.iv62.i = phi i64 [ %indvars.iv.next63.i, %.lr.ph56.i ], [ %274, %.preheader.i ] %indvars.iv.next63.i = add nuw nsw i64 %indvars.iv62.i, 1 - %310 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %indvars.iv.next63.i - %311 = load i32, ptr %310, align 8 - %312 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %indvars.iv62.i - store i32 %311, ptr %312, align 8 - %313 = getelementptr inbounds nuw i8, ptr %310, i64 8 - %314 = load double, ptr %313, align 8 - %315 = getelementptr inbounds nuw i8, ptr %312, i64 8 - store double %314, ptr %315, align 8 - %316 = getelementptr inbounds nuw i8, ptr %310, i64 16 - %317 = load double, ptr %316, align 8 - %318 = getelementptr inbounds nuw i8, ptr %312, i64 16 - store double %317, ptr %318, align 8 + %309 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %indvars.iv.next63.i + %310 = load i32, ptr %309, align 8 + %311 = getelementptr inbounds nuw %"struct.LightGBM::Tree::PathElement", ptr %23, i64 %indvars.iv62.i + store i32 %310, ptr %311, align 8 + %312 = getelementptr inbounds nuw i8, ptr %309, i64 8 + %313 = load double, ptr %312, align 8 + %314 = getelementptr inbounds nuw i8, ptr %311, i64 8 + store double %313, ptr %314, align 8 + %315 = getelementptr inbounds nuw i8, ptr %309, i64 16 + %316 = load double, ptr %315, align 8 + %317 = getelementptr inbounds nuw i8, ptr %311, i64 16 + store double %316, ptr %317, align 8 %exitcond.not.i = icmp eq i64 %indvars.iv.next63.i, %22 br i1 %exitcond.not.i, label %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit, label %.lr.ph56.i, !llvm.loop !381 @@ -59139,17 +59137,17 @@ _ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit: ; preds = %.lr.ph56.i, %.pre201 = load i32, ptr %.phi.trans.insert, align 4 br label %._crit_edge.thread -._crit_edge.thread: ; preds = %272, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit, %._crit_edge - %.pre-phi = phi i32 [ %.tr125, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ %.pre207, %._crit_edge ], [ %.pre207, %272 ] - %319 = phi i32 [ %.pre201, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ %132, %._crit_edge ], [ %132, %272 ] - %.075 = phi double [ %278, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ 1.000000e+00, %._crit_edge ], [ 1.000000e+00, %272 ] - %.074 = phi double [ %280, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ 1.000000e+00, %._crit_edge ], [ 1.000000e+00, %272 ] - %320 = fmul double %258, %.075 - tail call void @_ZNK8LightGBM4Tree13TreeSHAPByMapERKSt13unordered_mapIidSt4hashIiESt8equal_toIiESaISt4pairIKidEEEPSA_iiPNS0_11PathElementEddi(ptr noundef nonnull align 8 dereferenceable(648) %0, ptr noundef nonnull align 8 dereferenceable(56) %1, ptr noundef %2, i32 noundef %.0.i, i32 noundef %.pre-phi, ptr noundef %23, double noundef %320, double noundef %.074, i32 noundef %319) - %321 = fmul double %267, %.075 - %322 = load ptr, ptr %10, align 8 - %323 = getelementptr inbounds nuw i32, ptr %322, i64 %128 - %324 = load i32, ptr %323, align 4 +._crit_edge.thread: ; preds = %271, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit, %._crit_edge + %.pre-phi = phi i32 [ %.tr125, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ %.pre207, %._crit_edge ], [ %.pre207, %271 ] + %318 = phi i32 [ %.pre201, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ %132, %._crit_edge ], [ %132, %271 ] + %.075 = phi double [ %277, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ 1.000000e+00, %._crit_edge ], [ 1.000000e+00, %271 ] + %.074 = phi double [ %279, %_ZN8LightGBM4Tree10UnwindPathEPNS0_11PathElementEii.exit ], [ 1.000000e+00, %._crit_edge ], [ 1.000000e+00, %271 ] + %319 = fmul double %257, %.075 + tail call void @_ZNK8LightGBM4Tree13TreeSHAPByMapERKSt13unordered_mapIidSt4hashIiESt8equal_toIiESaISt4pairIKidEEEPSA_iiPNS0_11PathElementEddi(ptr noundef nonnull align 8 dereferenceable(648) %0, ptr noundef nonnull align 8 dereferenceable(56) %1, ptr noundef %2, i32 noundef %.0.i, i32 noundef %.pre-phi, ptr noundef %23, double noundef %319, double noundef %.074, i32 noundef %318) + %320 = fmul double %266, %.075 + %321 = load ptr, ptr %10, align 8 + %322 = getelementptr inbounds nuw i32, ptr %321, i64 %128 + %323 = load i32, ptr %322, align 4 br label %tailrecurse ._crit_edge163: ; preds = %_ZNSt13unordered_mapIidSt4hashIiESt8equal_toIiESaISt4pairIKidEEEixERS5_.exit, %.preheader diff --git a/bench/mitsuba3/optimized/area.cpp.ll b/bench/mitsuba3/optimized/area.cpp.ll index c2949c5037b..66ef96bc580 100644 --- a/bench/mitsuba3/optimized/area.cpp.ll +++ b/bench/mitsuba3/optimized/area.cpp.ll @@ -986,110 +986,109 @@ _ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EE %195 = fdiv contract float %194, %.sroa.speculated143 %196 = fsub contract float 0x3FF921FB60000000, %195 %spec.select = select i1 %191, float %196, float %195 - %197 = call float @llvm.fabs.f32(float %spec.select) - %198 = select contract i1 %narrow, float 0.000000e+00, float %197 - %199 = fmul contract float %198, 0x3FF45F3060000000 - %200 = fptosi float %199 to i32 - %201 = add nsw i32 %200, 1 - %202 = and i32 %201, -2 - %203 = shl i32 %202, 29 - %204 = bitcast float %spec.select to i32 - %205 = select i1 %narrow, i32 0, i32 %204 - %206 = xor i32 %203, %205 - %207 = and i32 %206, -2147483648 - %208 = and i32 %201, 2 - %209 = icmp eq i32 %208, 0 - %210 = fcmp contract oeq float %198, 0x7FF0000000000000 - %211 = sitofp i32 %202 to float - %212 = fmul contract float %211, 0x3FE9200000000000 - %213 = fsub contract float %198, %212 - %214 = fmul contract float %211, 0x3F2FB40000000000 + %.1 = select i1 %narrow, float 0.000000e+00, float %spec.select + %197 = call contract noundef float @llvm.fabs.f32(float %.1) + %198 = fmul contract float %197, 0x3FF45F3060000000 + %199 = fptosi float %198 to i32 + %200 = add nsw i32 %199, 1 + %201 = and i32 %200, -2 + %202 = shl i32 %201, 29 + %203 = bitcast float %.1 to i32 + %204 = xor i32 %202, %203 + %205 = and i32 %204, -2147483648 + %206 = and i32 %200, 2 + %207 = icmp eq i32 %206, 0 + %208 = fcmp contract oeq float %197, 0x7FF0000000000000 + %209 = sitofp i32 %201 to float + %210 = fmul contract float %209, 0x3FE9200000000000 + %211 = fsub contract float %197, %210 + %212 = fmul contract float %209, 0x3F2FB40000000000 + %213 = fsub contract float %211, %212 + %214 = fmul contract float %209, 0x3E64442D20000000 %215 = fsub contract float %213, %214 - %216 = fmul contract float %211, 0x3E64442D20000000 - %217 = fsub contract float %215, %216 + %216 = fmul contract float %215, %215 + %217 = select i1 %208, float 0xFFFFFFFFE0000000, float %216 %218 = fmul contract float %217, %217 - %219 = select i1 %210, float 0xFFFFFFFFE0000000, float %218 - %220 = fmul contract float %219, %219 - %221 = call contract noundef float @llvm.fma.f32(float %219, float 0x3F811073C0000000, float 0xBFC5555460000000) - %222 = call contract noundef float @llvm.fma.f32(float %220, float 0xBF29943F20000000, float %221) - %223 = fmul contract float %219, %222 - %224 = call contract noundef float @llvm.fma.f32(float %223, float %217, float %217) - %225 = call contract noundef float @llvm.fma.f32(float %219, float 0xBF56C0C340000000, float 0x3FA55554A0000000) - %226 = call contract noundef float @llvm.fma.f32(float %220, float 0x3EF99EB9C0000000, float %225) - %227 = fmul contract float %219, %226 - %228 = call contract noundef float @llvm.fma.f32(float %219, float -5.000000e-01, float 1.000000e+00) - %229 = call contract noundef float @llvm.fma.f32(float %227, float %219, float %228) - %230 = select contract i1 %209, float %224, float %229 - %231 = bitcast float %230 to i32 - %232 = xor i32 %207, %231 - %.sroa.0133.0.vec.extract = bitcast i32 %232 to float - %233 = fmul contract float %.sroa.speculated143, %.sroa.0133.0.vec.extract - %234 = fmul contract float %233, %233 - %235 = sub i32 0, %203 - %236 = and i32 %235, -2147483648 - %237 = select contract i1 %209, float %229, float %224 - %238 = bitcast float %237 to i32 - %239 = xor i32 %236, %238 - %.sroa.0133.4.vec.extract = bitcast i32 %239 to float - %240 = fmul contract float %.sroa.speculated143, %.sroa.0133.4.vec.extract - %241 = fmul contract float %240, %240 + %219 = call contract noundef float @llvm.fma.f32(float %217, float 0x3F811073C0000000, float 0xBFC5555460000000) + %220 = call contract noundef float @llvm.fma.f32(float %218, float 0xBF29943F20000000, float %219) + %221 = fmul contract float %217, %220 + %222 = call contract noundef float @llvm.fma.f32(float %221, float %215, float %215) + %223 = call contract noundef float @llvm.fma.f32(float %217, float 0xBF56C0C340000000, float 0x3FA55554A0000000) + %224 = call contract noundef float @llvm.fma.f32(float %218, float 0x3EF99EB9C0000000, float %223) + %225 = fmul contract float %217, %224 + %226 = call contract noundef float @llvm.fma.f32(float %217, float -5.000000e-01, float 1.000000e+00) + %227 = call contract noundef float @llvm.fma.f32(float %225, float %217, float %226) + %228 = select contract i1 %207, float %222, float %227 + %229 = bitcast float %228 to i32 + %230 = xor i32 %205, %229 + %.sroa.0133.0.vec.extract = bitcast i32 %230 to float + %231 = fmul contract float %.sroa.speculated143, %.sroa.0133.0.vec.extract + %232 = fmul contract float %231, %231 + %233 = sub i32 0, %202 + %234 = and i32 %233, -2147483648 + %235 = select contract i1 %207, float %227, float %222 + %236 = bitcast float %235 to i32 + %237 = xor i32 %234, %236 + %.sroa.0133.4.vec.extract = bitcast i32 %237 to float + %238 = fmul contract float %.sroa.speculated143, %.sroa.0133.4.vec.extract + %239 = fmul contract float %238, %238 call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %7), !noalias !51 - %242 = insertelement <4 x float> poison, float %240, i64 0 - %243 = fadd contract float %241, %234 - %244 = fsub contract float 1.000000e+00, %243 - %245 = fcmp contract olt float %244, 0.000000e+00 - %..i92 = select contract i1 %245, float 0.000000e+00, float %244 - %246 = call contract noundef float @llvm.sqrt.f32(float %..i92) + %240 = insertelement <4 x float> poison, float %238, i64 0 + %241 = fadd contract float %239, %232 + %242 = fsub contract float 1.000000e+00, %241 + %243 = fcmp contract olt float %242, 0.000000e+00 + %..i92 = select contract i1 %243, float 0.000000e+00, float %242 + %244 = call contract noundef float @llvm.sqrt.f32(float %..i92) call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %10) - %247 = shufflevector <4 x float> %242, <4 x float> poison, <4 x i32> zeroinitializer - %248 = load <4 x float>, ptr %85, align 16 - %249 = fmul contract <4 x float> %247, %248 - %250 = insertelement <4 x float> poison, float %233, i64 0 - %251 = shufflevector <4 x float> %250, <4 x float> poison, <4 x i32> zeroinitializer - %252 = load <4 x float>, ptr %116, align 16 - %253 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %252, <4 x float> %251, <4 x float> %249) - %254 = insertelement <4 x float> poison, float %246, i64 0 - %255 = shufflevector <4 x float> %254, <4 x float> poison, <4 x i32> zeroinitializer - %256 = load <4 x float>, ptr %86, align 16 - %257 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %256, <4 x float> %255, <4 x float> %253) - %258 = load <4 x i32>, ptr %81, align 16, !noalias !67 - %259 = and <4 x i32> %258, splat (i32 2147483647) - %260 = bitcast <4 x i32> %259 to <4 x float> - %261 = shufflevector <4 x float> %260, <4 x float> poison, <4 x i32> - %262 = call contract noundef <4 x float> @llvm.x86.sse.max.ss(<4 x float> %260, <4 x float> %261) - %263 = shufflevector <4 x float> %260, <4 x float> poison, <4 x i32> - %264 = call contract noundef <4 x float> @llvm.x86.sse.max.ss(<4 x float> %263, <4 x float> %262) - %265 = extractelement <4 x float> %264, i64 0 - %266 = fadd contract float %265, 1.000000e+00 - %267 = fmul contract float %266, 0x3F17700000000000 - %268 = load <4 x float>, ptr %82, align 16, !noalias !67 - %269 = call contract <4 x float> @llvm.x86.sse41.dpps(<4 x float> %268, <4 x float> %257, i8 113) - %bc.i.i = bitcast <4 x float> %269 to <4 x i32> - %270 = extractelement <4 x i32> %bc.i.i, i64 0 - %271 = and i32 %270, -2147483648 - %272 = bitcast float %267 to i32 - %273 = xor i32 %271, %272 - %274 = insertelement <4 x i32> poison, i32 %273, i64 0 - %275 = bitcast <4 x i32> %274 to <4 x float> - %276 = shufflevector <4 x float> %275, <4 x float> poison, <4 x i32> zeroinitializer - %277 = bitcast <4 x i32> %258 to <4 x float> - %278 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %276, <4 x float> %268, <4 x float> %277) + %245 = shufflevector <4 x float> %240, <4 x float> poison, <4 x i32> zeroinitializer + %246 = load <4 x float>, ptr %85, align 16 + %247 = fmul contract <4 x float> %245, %246 + %248 = insertelement <4 x float> poison, float %231, i64 0 + %249 = shufflevector <4 x float> %248, <4 x float> poison, <4 x i32> zeroinitializer + %250 = load <4 x float>, ptr %116, align 16 + %251 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %250, <4 x float> %249, <4 x float> %247) + %252 = insertelement <4 x float> poison, float %244, i64 0 + %253 = shufflevector <4 x float> %252, <4 x float> poison, <4 x i32> zeroinitializer + %254 = load <4 x float>, ptr %86, align 16 + %255 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %254, <4 x float> %253, <4 x float> %251) + %256 = load <4 x i32>, ptr %81, align 16, !noalias !67 + %257 = and <4 x i32> %256, splat (i32 2147483647) + %258 = bitcast <4 x i32> %257 to <4 x float> + %259 = shufflevector <4 x float> %258, <4 x float> poison, <4 x i32> + %260 = call contract noundef <4 x float> @llvm.x86.sse.max.ss(<4 x float> %258, <4 x float> %259) + %261 = shufflevector <4 x float> %258, <4 x float> poison, <4 x i32> + %262 = call contract noundef <4 x float> @llvm.x86.sse.max.ss(<4 x float> %261, <4 x float> %260) + %263 = extractelement <4 x float> %262, i64 0 + %264 = fadd contract float %263, 1.000000e+00 + %265 = fmul contract float %264, 0x3F17700000000000 + %266 = load <4 x float>, ptr %82, align 16, !noalias !67 + %267 = call contract <4 x float> @llvm.x86.sse41.dpps(<4 x float> %266, <4 x float> %255, i8 113) + %bc.i.i = bitcast <4 x float> %267 to <4 x i32> + %268 = extractelement <4 x i32> %bc.i.i, i64 0 + %269 = and i32 %268, -2147483648 + %270 = bitcast float %265 to i32 + %271 = xor i32 %269, %270 + %272 = insertelement <4 x i32> poison, i32 %271, i64 0 + %273 = bitcast <4 x i32> %272 to <4 x float> + %274 = shufflevector <4 x float> %273, <4 x float> poison, <4 x i32> zeroinitializer + %275 = bitcast <4 x i32> %256 to <4 x float> + %276 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %274, <4 x float> %266, <4 x float> %275) %.sroa.5.48..sroa_idx = getelementptr inbounds nuw i8, ptr %.sroa.5, i64 8 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %.sroa.5.48..sroa_idx, ptr noundef nonnull align 16 dereferenceable(16) %24, i64 16, i1 false) %.sroa.0.i114.16.i114.16.i114.16..sroa_idx = getelementptr inbounds nuw i8, ptr %.sroa.0.i114, i64 16 call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(240) %.sroa.0.i114.16.i114.16.i114.16..sroa_idx, i8 0, i64 240, i1 false) call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %.sroa.0.i114, ptr noundef nonnull align 16 dereferenceable(16) %9, i64 16, i1 false) - store <4 x float> %278, ptr %0, align 16 + store <4 x float> %276, ptr %0, align 16 %.sroa.2.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 16 - store <4 x float> %257, ptr %.sroa.2.0..sroa_idx, align 16 + store <4 x float> %255, ptr %.sroa.2.0..sroa_idx, align 16 %.sroa.3.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 32 store float 0x47EFFFFFE0000000, ptr %.sroa.3.0..sroa_idx, align 16 %.sroa.4.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 36 store float %2, ptr %.sroa.4.0..sroa_idx, align 4 %.sroa.5.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 40 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %.sroa.5.0..sroa_idx, ptr noundef nonnull align 8 dereferenceable(24) %.sroa.5, i64 24, i1 false) - %279 = getelementptr inbounds nuw i8, ptr %0, i64 64 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %279, ptr noundef nonnull align 16 dereferenceable(256) %.sroa.0.i114, i64 256, i1 false) + %277 = getelementptr inbounds nuw i8, ptr %0, i64 64 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %277, ptr noundef nonnull align 16 dereferenceable(256) %.sroa.0.i114, i64 256, i1 false) ret void } diff --git a/bench/mitsuba3/optimized/bsplinecurve.cpp.ll b/bench/mitsuba3/optimized/bsplinecurve.cpp.ll index 3fb71f70d58..bfa69e2c021 100644 --- a/bench/mitsuba3/optimized/bsplinecurve.cpp.ll +++ b/bench/mitsuba3/optimized/bsplinecurve.cpp.ll @@ -3274,7 +3274,7 @@ define weak_odr void @_ZNK7mitsuba12BSplineCurveIfN5drjit6MatrixINS_8SpectrumIfL %.not = icmp eq i32 %17, 0 tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(49) %0, i8 0, i64 49, i1 false) tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %13, i8 0, i64 64, i1 false) - br i1 %.not, label %327, label %_ZN5drjit6gatherIjLb0ERNS_12DynamicArrayIjEEjbEET_OT1_RKT2_RKT3_.exit1383 + br i1 %.not, label %325, label %_ZN5drjit6gatherIjLb0ERNS_12DynamicArrayIjEEjbEET_OT1_RKT2_RKT3_.exit1383 _ZN5drjit6gatherIjLb0ERNS_12DynamicArrayIjEEjbEET_OT1_RKT2_RKT3_.exit1383: ; preds = %5 %18 = getelementptr inbounds nuw i8, ptr %0, i64 96 @@ -3497,342 +3497,341 @@ _ZN5drjit6gatherIjLb0ERNS_12DynamicArrayIjEEjbEET_OT1_RKT2_RKT3_.exit1383: ; pre %209 = fdiv contract float %208, %.sroa.speculated1604 %210 = fsub contract float 0x3FF921FB60000000, %209 %spec.select = select i1 %207, float %210, float %209 - %211 = call float @llvm.fabs.f32(float %spec.select) - %212 = select contract i1 %narrow, float 0.000000e+00, float %211 - %213 = fmul contract float %212, 0x3FF45F3060000000 - %214 = fptosi float %213 to i32 - %215 = add nsw i32 %214, 1 - %216 = and i32 %215, -2 - %217 = sitofp i32 %216 to float - %218 = shl i32 %216, 29 - %219 = bitcast float %spec.select to i32 - %220 = select i1 %narrow, i32 0, i32 %219 - %221 = xor i32 %218, %220 - %222 = sub i32 0, %218 - %223 = fmul contract float %217, 0x3FE9200000000000 - %224 = fsub contract float %212, %223 - %225 = fmul contract float %217, 0x3F2FB40000000000 + %.1 = select i1 %narrow, float 0.000000e+00, float %spec.select + %211 = call contract noundef float @llvm.fabs.f32(float %.1) + %212 = fmul contract float %211, 0x3FF45F3060000000 + %213 = fptosi float %212 to i32 + %214 = add nsw i32 %213, 1 + %215 = and i32 %214, -2 + %216 = sitofp i32 %215 to float + %217 = shl i32 %215, 29 + %218 = bitcast float %.1 to i32 + %219 = xor i32 %217, %218 + %220 = sub i32 0, %217 + %221 = fmul contract float %216, 0x3FE9200000000000 + %222 = fsub contract float %211, %221 + %223 = fmul contract float %216, 0x3F2FB40000000000 + %224 = fsub contract float %222, %223 + %225 = fmul contract float %216, 0x3E64442D20000000 %226 = fsub contract float %224, %225 - %227 = fmul contract float %217, 0x3E64442D20000000 - %228 = fsub contract float %226, %227 - %229 = fmul contract float %228, %228 - %230 = fcmp contract oeq float %212, 0x7FF0000000000000 - %231 = select i1 %230, float 0xFFFFFFFFE0000000, float %229 - %232 = call contract noundef float @llvm.fma.f32(float %231, float 0x3F811073C0000000, float 0xBFC5555460000000) - %233 = fmul contract float %231, %231 - %234 = call contract noundef float @llvm.fma.f32(float %233, float 0xBF29943F20000000, float %232) - %235 = fmul contract float %231, %234 - %236 = call contract noundef float @llvm.fma.f32(float %231, float 0xBF56C0C340000000, float 0x3FA55554A0000000) - %237 = call contract noundef float @llvm.fma.f32(float %233, float 0x3EF99EB9C0000000, float %236) - %238 = fmul contract float %231, %237 - %239 = call contract noundef float @llvm.fma.f32(float %235, float %228, float %228) - %240 = call contract noundef float @llvm.fma.f32(float %231, float -5.000000e-01, float 1.000000e+00) - %241 = call contract noundef float @llvm.fma.f32(float %238, float %231, float %240) - %242 = and i32 %215, 2 - %243 = icmp eq i32 %242, 0 - %244 = select contract i1 %243, float %239, float %241 - %245 = and i32 %221, -2147483648 - %246 = bitcast float %244 to i32 - %247 = xor i32 %245, %246 - %248 = select contract i1 %243, float %241, float %239 - %249 = and i32 %222, -2147483648 - %250 = bitcast float %248 to i32 - %251 = xor i32 %249, %250 - %.sroa.01593.4.vec.extract = bitcast i32 %251 to float - %252 = fmul contract float %.sroa.speculated1604, %.sroa.01593.4.vec.extract - %.sroa.01593.0.vec.extract = bitcast i32 %247 to float - %253 = fmul contract float %.sroa.speculated1604, %.sroa.01593.0.vec.extract - %254 = fmul contract float %252, %252 - %255 = fmul contract float %253, %253 - %256 = fadd contract float %254, %255 - %257 = fsub contract float 1.000000e+00, %256 - %258 = fadd contract float %257, 1.000000e+00 - %259 = call contract noundef float @llvm.sqrt.f32(float %258) - %260 = fmul contract float %252, %259 - %261 = fmul contract float %253, %259 - %262 = insertelement <4 x float> , float %260, i64 0 - %263 = insertelement <4 x float> %262, float %261, i64 1 - %264 = insertelement <4 x float> %263, float %257, i64 2 - %265 = fneg <4 x float> %264 - %266 = shufflevector <4 x float> %265, <4 x float> poison, <4 x i32> zeroinitializer - %267 = fmul contract <4 x float> %266, %190 - %268 = shufflevector <4 x float> %265, <4 x float> poison, <4 x i32> - %269 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %196, <4 x float> %268, <4 x float> %267) - %270 = shufflevector <4 x float> %265, <4 x float> poison, <4 x i32> - %271 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %167, <4 x float> %270, <4 x float> %269) - store <4 x float> %271, ptr %13, align 16 + %227 = fmul contract float %226, %226 + %228 = fcmp contract oeq float %211, 0x7FF0000000000000 + %229 = select i1 %228, float 0xFFFFFFFFE0000000, float %227 + %230 = call contract noundef float @llvm.fma.f32(float %229, float 0x3F811073C0000000, float 0xBFC5555460000000) + %231 = fmul contract float %229, %229 + %232 = call contract noundef float @llvm.fma.f32(float %231, float 0xBF29943F20000000, float %230) + %233 = fmul contract float %229, %232 + %234 = call contract noundef float @llvm.fma.f32(float %229, float 0xBF56C0C340000000, float 0x3FA55554A0000000) + %235 = call contract noundef float @llvm.fma.f32(float %231, float 0x3EF99EB9C0000000, float %234) + %236 = fmul contract float %229, %235 + %237 = call contract noundef float @llvm.fma.f32(float %233, float %226, float %226) + %238 = call contract noundef float @llvm.fma.f32(float %229, float -5.000000e-01, float 1.000000e+00) + %239 = call contract noundef float @llvm.fma.f32(float %236, float %229, float %238) + %240 = and i32 %214, 2 + %241 = icmp eq i32 %240, 0 + %242 = select contract i1 %241, float %237, float %239 + %243 = and i32 %219, -2147483648 + %244 = bitcast float %242 to i32 + %245 = xor i32 %243, %244 + %246 = select contract i1 %241, float %239, float %237 + %247 = and i32 %220, -2147483648 + %248 = bitcast float %246 to i32 + %249 = xor i32 %247, %248 + %.sroa.01593.4.vec.extract = bitcast i32 %249 to float + %250 = fmul contract float %.sroa.speculated1604, %.sroa.01593.4.vec.extract + %.sroa.01593.0.vec.extract = bitcast i32 %245 to float + %251 = fmul contract float %.sroa.speculated1604, %.sroa.01593.0.vec.extract + %252 = fmul contract float %250, %250 + %253 = fmul contract float %251, %251 + %254 = fadd contract float %252, %253 + %255 = fsub contract float 1.000000e+00, %254 + %256 = fadd contract float %255, 1.000000e+00 + %257 = call contract noundef float @llvm.sqrt.f32(float %256) + %258 = fmul contract float %250, %257 + %259 = fmul contract float %251, %257 + %260 = insertelement <4 x float> , float %258, i64 0 + %261 = insertelement <4 x float> %260, float %259, i64 1 + %262 = insertelement <4 x float> %261, float %255, i64 2 + %263 = fneg <4 x float> %262 + %264 = shufflevector <4 x float> %263, <4 x float> poison, <4 x i32> zeroinitializer + %265 = fmul contract <4 x float> %264, %190 + %266 = shufflevector <4 x float> %263, <4 x float> poison, <4 x i32> + %267 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %196, <4 x float> %266, <4 x float> %265) + %268 = shufflevector <4 x float> %263, <4 x float> poison, <4 x i32> + %269 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %167, <4 x float> %268, <4 x float> %267) + store <4 x float> %269, ptr %13, align 16 store i32 1, ptr %12, align 4 store i32 %3, ptr %15, align 8 - %272 = fadd contract <4 x float> %138, %146 - %273 = fmul contract <4 x float> %272, %272 - %shift1664 = shufflevector <4 x float> %273, <4 x float> poison, <4 x i32> - %274 = fadd contract <4 x float> %273, %shift1664 - %shift1665 = shufflevector <4 x float> %273, <4 x float> poison, <4 x i32> - %275 = fadd contract <4 x float> %shift1665, %274 - %276 = extractelement <4 x float> %275, i64 0 - %277 = call contract noundef float @llvm.sqrt.f32(float %276) - %278 = fdiv contract float 1.000000e+00, %277 - %279 = insertelement <4 x float> poison, float %278, i64 0 - %280 = shufflevector <4 x float> %279, <4 x float> poison, <4 x i32> zeroinitializer - %281 = fmul contract <4 x float> %272, %280 - %282 = shufflevector <4 x float> %281, <4 x float> poison, <4 x i32> - %283 = shufflevector <4 x float> %281, <4 x float> poison, <4 x i32> - %284 = fmul contract <4 x float> %283, %92 - %285 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %282, <4 x float> %89, <4 x float> %284) - store <4 x float> %285, ptr %14, align 16 - %286 = shufflevector <4 x float> %271, <4 x float> poison, <4 x i32> - %287 = shufflevector <4 x float> %285, <4 x float> poison, <4 x i32> - %288 = shufflevector <4 x float> %271, <4 x float> poison, <4 x i32> - %289 = shufflevector <4 x float> %285, <4 x float> poison, <4 x i32> - %290 = fneg contract <4 x float> %289 - %291 = fmul contract <4 x float> %288, %290 - %292 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %286, <4 x float> %287, <4 x float> %291) - %293 = fmul contract <4 x float> %292, %292 - %shift1666 = shufflevector <4 x float> %293, <4 x float> poison, <4 x i32> - %294 = fadd contract <4 x float> %293, %shift1666 - %shift1667 = shufflevector <4 x float> %293, <4 x float> poison, <4 x i32> - %295 = fadd contract <4 x float> %shift1667, %294 - %296 = extractelement <4 x float> %295, i64 0 - %297 = call contract noundef float @llvm.sqrt.f32(float %296) - %298 = fdiv contract float 1.000000e+00, %297 - %299 = insertelement <4 x float> poison, float %298, i64 0 - %300 = shufflevector <4 x float> %299, <4 x float> poison, <4 x i32> zeroinitializer - %301 = fmul contract <4 x float> %292, %300 - %302 = fneg <4 x float> %167 - %303 = call contract <4 x float> @llvm.x86.sse41.dpps(<4 x float> %302, <4 x float> %301, i8 113) - %304 = extractelement <4 x float> %303, i64 0 - %305 = fcmp contract ogt float %304, 0.000000e+00 - %306 = select i1 %305, i8 7, i8 0 - %307 = fneg contract <4 x float> %301 - %308 = bitcast i8 %306 to <8 x i1> - %309 = shufflevector <8 x i1> %308, <8 x i1> poison, <4 x i32> - %310 = select contract <4 x i1> %309, <4 x float> %307, <4 x float> %301 - %311 = fneg contract <4 x float> %.sroa.01636.0.copyload - %312 = select contract i1 %41, <4 x float> %.sroa.01636.0.copyload, <4 x float> %311 - %313 = call contract <4 x float> @llvm.x86.sse41.dpps(<4 x float> %312, <4 x float> %310, i8 113) - %314 = extractelement <4 x float> %313, i64 0 - %315 = fcmp contract ogt float %314, 0.000000e+00 - %316 = select i1 %315, i8 7, i8 0 - %317 = fneg contract <4 x float> %310 - %318 = bitcast i8 %316 to <8 x i1> - %319 = shufflevector <8 x i1> %318, <8 x i1> poison, <4 x i32> - %320 = select contract <4 x i1> %319, <4 x float> %317, <4 x float> %310 - store <4 x float> %320, ptr %9, align 16 - %321 = fmul contract float %55, 0x401921FB60000000 - %322 = shl i64 %22, 1 - %323 = uitofp i64 %322 to float - %324 = fmul contract float %321, %323 - %325 = fdiv contract float 1.000000e+00, %324 - %326 = fmul contract float %325, 0x3FC45F3060000000 - store float %326, ptr %11, align 4 + %270 = fadd contract <4 x float> %138, %146 + %271 = fmul contract <4 x float> %270, %270 + %shift1664 = shufflevector <4 x float> %271, <4 x float> poison, <4 x i32> + %272 = fadd contract <4 x float> %271, %shift1664 + %shift1665 = shufflevector <4 x float> %271, <4 x float> poison, <4 x i32> + %273 = fadd contract <4 x float> %shift1665, %272 + %274 = extractelement <4 x float> %273, i64 0 + %275 = call contract noundef float @llvm.sqrt.f32(float %274) + %276 = fdiv contract float 1.000000e+00, %275 + %277 = insertelement <4 x float> poison, float %276, i64 0 + %278 = shufflevector <4 x float> %277, <4 x float> poison, <4 x i32> zeroinitializer + %279 = fmul contract <4 x float> %270, %278 + %280 = shufflevector <4 x float> %279, <4 x float> poison, <4 x i32> + %281 = shufflevector <4 x float> %279, <4 x float> poison, <4 x i32> + %282 = fmul contract <4 x float> %281, %92 + %283 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %280, <4 x float> %89, <4 x float> %282) + store <4 x float> %283, ptr %14, align 16 + %284 = shufflevector <4 x float> %269, <4 x float> poison, <4 x i32> + %285 = shufflevector <4 x float> %283, <4 x float> poison, <4 x i32> + %286 = shufflevector <4 x float> %269, <4 x float> poison, <4 x i32> + %287 = shufflevector <4 x float> %283, <4 x float> poison, <4 x i32> + %288 = fneg contract <4 x float> %287 + %289 = fmul contract <4 x float> %286, %288 + %290 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %284, <4 x float> %285, <4 x float> %289) + %291 = fmul contract <4 x float> %290, %290 + %shift1666 = shufflevector <4 x float> %291, <4 x float> poison, <4 x i32> + %292 = fadd contract <4 x float> %291, %shift1666 + %shift1667 = shufflevector <4 x float> %291, <4 x float> poison, <4 x i32> + %293 = fadd contract <4 x float> %shift1667, %292 + %294 = extractelement <4 x float> %293, i64 0 + %295 = call contract noundef float @llvm.sqrt.f32(float %294) + %296 = fdiv contract float 1.000000e+00, %295 + %297 = insertelement <4 x float> poison, float %296, i64 0 + %298 = shufflevector <4 x float> %297, <4 x float> poison, <4 x i32> zeroinitializer + %299 = fmul contract <4 x float> %290, %298 + %300 = fneg <4 x float> %167 + %301 = call contract <4 x float> @llvm.x86.sse41.dpps(<4 x float> %300, <4 x float> %299, i8 113) + %302 = extractelement <4 x float> %301, i64 0 + %303 = fcmp contract ogt float %302, 0.000000e+00 + %304 = select i1 %303, i8 7, i8 0 + %305 = fneg contract <4 x float> %299 + %306 = bitcast i8 %304 to <8 x i1> + %307 = shufflevector <8 x i1> %306, <8 x i1> poison, <4 x i32> + %308 = select contract <4 x i1> %307, <4 x float> %305, <4 x float> %299 + %309 = fneg contract <4 x float> %.sroa.01636.0.copyload + %310 = select contract i1 %41, <4 x float> %.sroa.01636.0.copyload, <4 x float> %309 + %311 = call contract <4 x float> @llvm.x86.sse41.dpps(<4 x float> %310, <4 x float> %308, i8 113) + %312 = extractelement <4 x float> %311, i64 0 + %313 = fcmp contract ogt float %312, 0.000000e+00 + %314 = select i1 %313, i8 7, i8 0 + %315 = fneg contract <4 x float> %308 + %316 = bitcast i8 %314 to <8 x i1> + %317 = shufflevector <8 x i1> %316, <8 x i1> poison, <4 x i32> + %318 = select contract <4 x i1> %317, <4 x float> %315, <4 x float> %308 + store <4 x float> %318, ptr %9, align 16 + %319 = fmul contract float %55, 0x401921FB60000000 + %320 = shl i64 %22, 1 + %321 = uitofp i64 %320 to float + %322 = fmul contract float %319, %321 + %323 = fdiv contract float 1.000000e+00, %322 + %324 = fmul contract float %323, 0x3FC45F3060000000 + store float %324, ptr %11, align 4 br label %.sink.split -327: ; preds = %5 - %328 = and i32 %3, 2 - %.not1646 = icmp eq i32 %328, 0 - br i1 %.not1646, label %493, label %329 +325: ; preds = %5 + %326 = and i32 %3, 2 + %.not1646 = icmp eq i32 %326, 0 + br i1 %.not1646, label %491, label %327 -329: ; preds = %327 - %330 = getelementptr inbounds nuw i8, ptr %2, i64 4 - %331 = load i32, ptr %330, align 4 - %332 = load i32, ptr %2, align 16 - %.sroa.2.0.insert.ext = zext i32 %332 to i64 +327: ; preds = %325 + %328 = getelementptr inbounds nuw i8, ptr %2, i64 4 + %329 = load i32, ptr %328, align 4 + %330 = load i32, ptr %2, align 16 + %.sroa.2.0.insert.ext = zext i32 %330 to i64 %.sroa.2.0.insert.shift = shl nuw i64 %.sroa.2.0.insert.ext, 32 - %.sroa.01393.0.insert.ext = zext i32 %331 to i64 + %.sroa.01393.0.insert.ext = zext i32 %329 to i64 %.sroa.01393.0.insert.insert = or disjoint i64 %.sroa.2.0.insert.shift, %.sroa.01393.0.insert.ext store i64 %.sroa.01393.0.insert.insert, ptr %10, align 16 %.sroa.020.0.copyload.cast = bitcast i64 %.sroa.01393.0.insert.insert to <2 x float> call void @_ZNK7mitsuba12BSplineCurveIfN5drjit6MatrixINS_8SpectrumIfLm4EEELm4EEEE8partialsENS_5PointIfLm2EEEb(ptr dead_on_unwind nonnull writable sret(%"class.std::__1::tuple.147") align 16 %7, ptr noundef nonnull align 16 dereferenceable(528) %1, <2 x float> %.sroa.020.0.copyload.cast, i1 noundef zeroext true) - %333 = getelementptr inbounds nuw i8, ptr %7, i64 16 - %334 = getelementptr inbounds nuw i8, ptr %7, i64 32 - %335 = getelementptr inbounds nuw i8, ptr %7, i64 48 - %336 = getelementptr inbounds nuw i8, ptr %7, i64 64 - %337 = getelementptr inbounds nuw i8, ptr %7, i64 68 - %338 = getelementptr inbounds nuw i8, ptr %7, i64 72 + %331 = getelementptr inbounds nuw i8, ptr %7, i64 16 + %332 = getelementptr inbounds nuw i8, ptr %7, i64 32 + %333 = getelementptr inbounds nuw i8, ptr %7, i64 48 + %334 = getelementptr inbounds nuw i8, ptr %7, i64 64 + %335 = getelementptr inbounds nuw i8, ptr %7, i64 68 + %336 = getelementptr inbounds nuw i8, ptr %7, i64 72 call void @_ZNK7mitsuba12BSplineCurveIfN5drjit6MatrixINS_8SpectrumIfLm4EEELm4EEEE21eval_parameterizationERKNS_5PointIfLm2EEEjb(ptr dead_on_unwind nonnull writable sret(%"struct.mitsuba::SurfaceInteraction") align 16 %8, ptr noundef nonnull align 16 dereferenceable(528) %1, ptr noundef nonnull align 4 dereferenceable(8) %10, i32 noundef 270, i1 noundef zeroext true) - %339 = getelementptr inbounds nuw i8, ptr %8, i64 32 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %0, ptr noundef nonnull align 16 dereferenceable(16) %339, i64 16, i1 false) - %340 = getelementptr inbounds nuw i8, ptr %8, i64 48 - %341 = getelementptr inbounds nuw i8, ptr %2, i64 8 - %342 = load float, ptr %341, align 8 - %343 = load <4 x float>, ptr %340, align 16 - %.sroa.01509.8.vec.extract = extractelement <4 x float> %343, i64 2 - %344 = bitcast float %.sroa.01509.8.vec.extract to i32 - %345 = and i32 %344, -2147483648 - %346 = call float @llvm.copysign.f32(float 1.000000e+00, float %.sroa.01509.8.vec.extract) - %347 = fadd contract float %.sroa.01509.8.vec.extract, %346 - %348 = fdiv contract float -1.000000e+00, %347 - %.sroa.01509.0.vec.extract = extractelement <4 x float> %343, i64 0 - %.sroa.01509.4.vec.extract = extractelement <4 x float> %343, i64 1 - %349 = fmul contract float %.sroa.01509.0.vec.extract, %.sroa.01509.4.vec.extract - %350 = fmul contract float %349, %348 - %351 = fmul contract <4 x float> %343, %343 - %352 = extractelement <4 x float> %351, i64 0 - %353 = fmul contract float %352, %348 - %354 = bitcast float %353 to i32 - %355 = xor i32 %345, %354 - %356 = bitcast i32 %355 to float - %357 = bitcast float %350 to i32 - %358 = xor i32 %345, %357 - %359 = bitcast i32 %358 to float - %360 = fcmp contract ult float %.sroa.01509.8.vec.extract, 0.000000e+00 - %361 = fneg contract float %.sroa.01509.0.vec.extract - %362 = select contract i1 %360, float %.sroa.01509.0.vec.extract, float %361 - %363 = fadd contract float %356, 1.000000e+00 - %364 = insertelement <4 x float> , float %363, i64 0 - %365 = insertelement <4 x float> %364, float %359, i64 1 - %366 = insertelement <4 x float> %365, float %362, i64 2 - %367 = fmul contract float %.sroa.01509.4.vec.extract, %348 - %368 = call contract noundef float @llvm.fma.f32(float %.sroa.01509.4.vec.extract, float %367, float %346) - %369 = fneg contract float %.sroa.01509.4.vec.extract - %370 = insertelement <4 x float> , float %350, i64 0 - %371 = insertelement <4 x float> %370, float %368, i64 1 - %372 = insertelement <4 x float> %371, float %369, i64 2 - %373 = fmul contract float %342, 0x401921FB60000000 - %374 = call contract noundef float @llvm.fabs.f32(float %373) - %375 = fmul contract float %374, 0x3FF45F3060000000 - %376 = fptosi float %375 to i32 - %377 = add nsw i32 %376, 1 - %378 = and i32 %377, -2 - %379 = sitofp i32 %378 to float - %380 = shl i32 %378, 29 - %381 = bitcast float %373 to i32 - %382 = xor i32 %380, %381 - %383 = sub i32 0, %380 - %384 = fmul contract float %379, 0x3FE9200000000000 - %385 = fsub contract float %374, %384 - %386 = fmul contract float %379, 0x3F2FB40000000000 + %337 = getelementptr inbounds nuw i8, ptr %8, i64 32 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %0, ptr noundef nonnull align 16 dereferenceable(16) %337, i64 16, i1 false) + %338 = getelementptr inbounds nuw i8, ptr %8, i64 48 + %339 = getelementptr inbounds nuw i8, ptr %2, i64 8 + %340 = load float, ptr %339, align 8 + %341 = load <4 x float>, ptr %338, align 16 + %.sroa.01509.8.vec.extract = extractelement <4 x float> %341, i64 2 + %342 = bitcast float %.sroa.01509.8.vec.extract to i32 + %343 = and i32 %342, -2147483648 + %344 = call float @llvm.copysign.f32(float 1.000000e+00, float %.sroa.01509.8.vec.extract) + %345 = fadd contract float %.sroa.01509.8.vec.extract, %344 + %346 = fdiv contract float -1.000000e+00, %345 + %.sroa.01509.0.vec.extract = extractelement <4 x float> %341, i64 0 + %.sroa.01509.4.vec.extract = extractelement <4 x float> %341, i64 1 + %347 = fmul contract float %.sroa.01509.0.vec.extract, %.sroa.01509.4.vec.extract + %348 = fmul contract float %347, %346 + %349 = fmul contract <4 x float> %341, %341 + %350 = extractelement <4 x float> %349, i64 0 + %351 = fmul contract float %350, %346 + %352 = bitcast float %351 to i32 + %353 = xor i32 %343, %352 + %354 = bitcast i32 %353 to float + %355 = bitcast float %348 to i32 + %356 = xor i32 %343, %355 + %357 = bitcast i32 %356 to float + %358 = fcmp contract ult float %.sroa.01509.8.vec.extract, 0.000000e+00 + %359 = fneg contract float %.sroa.01509.0.vec.extract + %360 = select contract i1 %358, float %.sroa.01509.0.vec.extract, float %359 + %361 = fadd contract float %354, 1.000000e+00 + %362 = insertelement <4 x float> , float %361, i64 0 + %363 = insertelement <4 x float> %362, float %357, i64 1 + %364 = insertelement <4 x float> %363, float %360, i64 2 + %365 = fmul contract float %.sroa.01509.4.vec.extract, %346 + %366 = call contract noundef float @llvm.fma.f32(float %.sroa.01509.4.vec.extract, float %365, float %344) + %367 = fneg contract float %.sroa.01509.4.vec.extract + %368 = insertelement <4 x float> , float %348, i64 0 + %369 = insertelement <4 x float> %368, float %366, i64 1 + %370 = insertelement <4 x float> %369, float %367, i64 2 + %371 = fmul contract float %340, 0x401921FB60000000 + %372 = call contract noundef float @llvm.fabs.f32(float %371) + %373 = fmul contract float %372, 0x3FF45F3060000000 + %374 = fptosi float %373 to i32 + %375 = add nsw i32 %374, 1 + %376 = and i32 %375, -2 + %377 = sitofp i32 %376 to float + %378 = shl i32 %376, 29 + %379 = bitcast float %371 to i32 + %380 = xor i32 %378, %379 + %381 = sub i32 0, %378 + %382 = fmul contract float %377, 0x3FE9200000000000 + %383 = fsub contract float %372, %382 + %384 = fmul contract float %377, 0x3F2FB40000000000 + %385 = fsub contract float %383, %384 + %386 = fmul contract float %377, 0x3E64442D20000000 %387 = fsub contract float %385, %386 - %388 = fmul contract float %379, 0x3E64442D20000000 - %389 = fsub contract float %387, %388 - %390 = fmul contract float %389, %389 - %391 = fcmp contract oeq float %374, 0x7FF0000000000000 - %392 = select i1 %391, float 0xFFFFFFFFE0000000, float %390 - %393 = call contract noundef float @llvm.fma.f32(float %392, float 0x3F811073C0000000, float 0xBFC5555460000000) - %394 = fmul contract float %392, %392 - %395 = call contract noundef float @llvm.fma.f32(float %394, float 0xBF29943F20000000, float %393) - %396 = fmul contract float %392, %395 - %397 = call contract noundef float @llvm.fma.f32(float %392, float 0xBF56C0C340000000, float 0x3FA55554A0000000) - %398 = call contract noundef float @llvm.fma.f32(float %394, float 0x3EF99EB9C0000000, float %397) - %399 = fmul contract float %392, %398 - %400 = call contract noundef float @llvm.fma.f32(float %396, float %389, float %389) - %401 = call contract noundef float @llvm.fma.f32(float %392, float -5.000000e-01, float 1.000000e+00) - %402 = call contract noundef float @llvm.fma.f32(float %399, float %392, float %401) - %403 = and i32 %377, 2 - %404 = icmp eq i32 %403, 0 - %405 = select contract i1 %404, float %400, float %402 - %406 = and i32 %382, -2147483648 - %407 = bitcast float %405 to i32 - %408 = xor i32 %406, %407 - %409 = select contract i1 %404, float %402, float %400 - %410 = and i32 %383, -2147483648 - %411 = bitcast float %409 to i32 - %412 = xor i32 %410, %411 - %413 = insertelement <4 x i32> poison, i32 %412, i64 0 - %414 = bitcast <4 x i32> %413 to <4 x float> - %415 = shufflevector <4 x float> %414, <4 x float> poison, <4 x i32> zeroinitializer - %416 = fmul contract <4 x float> %366, %415 - %417 = insertelement <4 x i32> poison, i32 %408, i64 0 - %418 = bitcast <4 x i32> %417 to <4 x float> - %419 = shufflevector <4 x float> %418, <4 x float> poison, <4 x i32> zeroinitializer - %420 = fmul contract <4 x float> %372, %419 - %421 = fadd contract <4 x float> %416, %420 - store <4 x float> %421, ptr %13, align 16 + %388 = fmul contract float %387, %387 + %389 = fcmp contract oeq float %372, 0x7FF0000000000000 + %390 = select i1 %389, float 0xFFFFFFFFE0000000, float %388 + %391 = call contract noundef float @llvm.fma.f32(float %390, float 0x3F811073C0000000, float 0xBFC5555460000000) + %392 = fmul contract float %390, %390 + %393 = call contract noundef float @llvm.fma.f32(float %392, float 0xBF29943F20000000, float %391) + %394 = fmul contract float %390, %393 + %395 = call contract noundef float @llvm.fma.f32(float %390, float 0xBF56C0C340000000, float 0x3FA55554A0000000) + %396 = call contract noundef float @llvm.fma.f32(float %392, float 0x3EF99EB9C0000000, float %395) + %397 = fmul contract float %390, %396 + %398 = call contract noundef float @llvm.fma.f32(float %394, float %387, float %387) + %399 = call contract noundef float @llvm.fma.f32(float %390, float -5.000000e-01, float 1.000000e+00) + %400 = call contract noundef float @llvm.fma.f32(float %397, float %390, float %399) + %401 = and i32 %375, 2 + %402 = icmp eq i32 %401, 0 + %403 = select contract i1 %402, float %398, float %400 + %404 = and i32 %380, -2147483648 + %405 = bitcast float %403 to i32 + %406 = xor i32 %404, %405 + %407 = select contract i1 %402, float %400, float %398 + %408 = and i32 %381, -2147483648 + %409 = bitcast float %407 to i32 + %410 = xor i32 %408, %409 + %411 = insertelement <4 x i32> poison, i32 %410, i64 0 + %412 = bitcast <4 x i32> %411 to <4 x float> + %413 = shufflevector <4 x float> %412, <4 x float> poison, <4 x i32> zeroinitializer + %414 = fmul contract <4 x float> %364, %413 + %415 = insertelement <4 x i32> poison, i32 %406, i64 0 + %416 = bitcast <4 x i32> %415 to <4 x float> + %417 = shufflevector <4 x float> %416, <4 x float> poison, <4 x i32> zeroinitializer + %418 = fmul contract <4 x float> %370, %417 + %419 = fadd contract <4 x float> %414, %418 + store <4 x float> %419, ptr %13, align 16 store i32 2, ptr %12, align 4 store i32 %3, ptr %15, align 8 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %9, ptr noundef nonnull align 16 dereferenceable(16) %340, i64 16, i1 false) - %422 = load <4 x float>, ptr %7, align 16 - %423 = fmul contract <4 x float> %422, %422 - %shift1668 = shufflevector <4 x float> %423, <4 x float> poison, <4 x i32> - %424 = fadd contract <4 x float> %423, %shift1668 - %shift1669 = shufflevector <4 x float> %423, <4 x float> poison, <4 x i32> - %425 = fadd contract <4 x float> %shift1669, %424 - %426 = load <4 x float>, ptr %333, align 16 - %427 = call contract <4 x float> @llvm.x86.sse41.dpps(<4 x float> %422, <4 x float> %426, i8 113) - %428 = extractelement <4 x float> %427, i64 0 - %429 = fmul contract <4 x float> %426, %426 - %shift1670 = shufflevector <4 x float> %429, <4 x float> poison, <4 x i32> - %430 = fadd contract <4 x float> %429, %shift1670 - %shift1671 = shufflevector <4 x float> %429, <4 x float> poison, <4 x i32> - %431 = fadd contract <4 x float> %shift1671, %430 - %432 = fmul contract <4 x float> %425, %431 - %433 = fmul contract <4 x float> %427, %427 - %434 = fsub contract <4 x float> %432, %433 - %435 = extractelement <4 x float> %434, i64 0 - %436 = fcmp contract olt float %435, 0.000000e+00 - %..i = select contract i1 %436, float 0.000000e+00, float %435 - %437 = call contract noundef float @llvm.sqrt.f32(float %..i) - %438 = fdiv contract float 1.000000e+00, %437 - %439 = fmul contract float %438, 0x3FC45F3060000000 - store float %439, ptr %11, align 4 - %440 = call contract <4 x float> @llvm.x86.sse41.dpps(<4 x float> %421, <4 x float> %422, i8 113) - %441 = fdiv contract <4 x float> %440, %425 - %442 = extractelement <4 x float> %441, i64 0 - %443 = call contract <4 x float> @llvm.x86.sse41.dpps(<4 x float> %421, <4 x float> %426, i8 113) - %444 = fdiv contract <4 x float> %443, %431 - %445 = extractelement <4 x float> %444, i64 0 - %446 = shufflevector <4 x float> %441, <4 x float> poison, <4 x i32> zeroinitializer - %447 = load <4 x float>, ptr %334, align 16 - %448 = fmul contract <4 x float> %447, %446 - %449 = shufflevector <4 x float> %444, <4 x float> poison, <4 x i32> zeroinitializer - %450 = load <4 x float>, ptr %335, align 16 - %451 = fmul contract <4 x float> %450, %449 - %452 = fadd contract <4 x float> %448, %451 - %453 = load <4 x float>, ptr %9, align 16 - %454 = shufflevector <4 x float> %453, <4 x float> poison, <4 x i32> - %455 = shufflevector <4 x float> %452, <4 x float> poison, <4 x i32> - %456 = shufflevector <4 x float> %453, <4 x float> poison, <4 x i32> - %457 = shufflevector <4 x float> %452, <4 x float> poison, <4 x i32> - %458 = fneg contract <4 x float> %457 - %459 = fmul contract <4 x float> %456, %458 - %460 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %454, <4 x float> %455, <4 x float> %459) - %461 = fmul contract <4 x float> %460, %460 - %shift1672 = shufflevector <4 x float> %461, <4 x float> poison, <4 x i32> - %462 = fadd contract <4 x float> %461, %shift1672 - %shift1673 = shufflevector <4 x float> %461, <4 x float> poison, <4 x i32> - %463 = fadd contract <4 x float> %shift1673, %462 - %464 = extractelement <4 x float> %463, i64 0 - %465 = call contract noundef float @llvm.sqrt.f32(float %464) - %466 = fdiv contract float 1.000000e+00, %465 - %467 = insertelement <4 x float> poison, float %466, i64 0 - %468 = shufflevector <4 x float> %467, <4 x float> poison, <4 x i32> zeroinitializer - %469 = fmul contract <4 x float> %460, %468 - store <4 x float> %469, ptr %14, align 16 - %470 = fmul contract <4 x float> %441, %441 - %471 = extractelement <4 x float> %470, i64 0 - %472 = load float, ptr %336, align 16 - %473 = fmul contract float %471, %472 - %474 = fmul contract float %442, 2.000000e+00 - %475 = fmul contract float %474, %445 - %476 = load float, ptr %337, align 4 - %477 = fmul contract float %475, %476 - %478 = fadd contract float %473, %477 - %479 = fmul contract <4 x float> %444, %444 - %480 = extractelement <4 x float> %479, i64 0 - %481 = load float, ptr %338, align 8 - %482 = fmul contract float %480, %481 - %483 = fadd contract float %478, %482 - %484 = fmul contract <4 x float> %425, %470 - %485 = extractelement <4 x float> %484, i64 0 - %486 = fmul contract float %428, %475 - %487 = fadd contract float %485, %486 - %488 = fmul contract <4 x float> %431, %479 - %489 = extractelement <4 x float> %488, i64 0 - %490 = fadd contract float %489, %487 - %491 = fdiv contract float %483, %490 - %492 = call contract noundef float @llvm.fabs.f32(float %491) + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %9, ptr noundef nonnull align 16 dereferenceable(16) %338, i64 16, i1 false) + %420 = load <4 x float>, ptr %7, align 16 + %421 = fmul contract <4 x float> %420, %420 + %shift1668 = shufflevector <4 x float> %421, <4 x float> poison, <4 x i32> + %422 = fadd contract <4 x float> %421, %shift1668 + %shift1669 = shufflevector <4 x float> %421, <4 x float> poison, <4 x i32> + %423 = fadd contract <4 x float> %shift1669, %422 + %424 = load <4 x float>, ptr %331, align 16 + %425 = call contract <4 x float> @llvm.x86.sse41.dpps(<4 x float> %420, <4 x float> %424, i8 113) + %426 = extractelement <4 x float> %425, i64 0 + %427 = fmul contract <4 x float> %424, %424 + %shift1670 = shufflevector <4 x float> %427, <4 x float> poison, <4 x i32> + %428 = fadd contract <4 x float> %427, %shift1670 + %shift1671 = shufflevector <4 x float> %427, <4 x float> poison, <4 x i32> + %429 = fadd contract <4 x float> %shift1671, %428 + %430 = fmul contract <4 x float> %423, %429 + %431 = fmul contract <4 x float> %425, %425 + %432 = fsub contract <4 x float> %430, %431 + %433 = extractelement <4 x float> %432, i64 0 + %434 = fcmp contract olt float %433, 0.000000e+00 + %..i = select contract i1 %434, float 0.000000e+00, float %433 + %435 = call contract noundef float @llvm.sqrt.f32(float %..i) + %436 = fdiv contract float 1.000000e+00, %435 + %437 = fmul contract float %436, 0x3FC45F3060000000 + store float %437, ptr %11, align 4 + %438 = call contract <4 x float> @llvm.x86.sse41.dpps(<4 x float> %419, <4 x float> %420, i8 113) + %439 = fdiv contract <4 x float> %438, %423 + %440 = extractelement <4 x float> %439, i64 0 + %441 = call contract <4 x float> @llvm.x86.sse41.dpps(<4 x float> %419, <4 x float> %424, i8 113) + %442 = fdiv contract <4 x float> %441, %429 + %443 = extractelement <4 x float> %442, i64 0 + %444 = shufflevector <4 x float> %439, <4 x float> poison, <4 x i32> zeroinitializer + %445 = load <4 x float>, ptr %332, align 16 + %446 = fmul contract <4 x float> %445, %444 + %447 = shufflevector <4 x float> %442, <4 x float> poison, <4 x i32> zeroinitializer + %448 = load <4 x float>, ptr %333, align 16 + %449 = fmul contract <4 x float> %448, %447 + %450 = fadd contract <4 x float> %446, %449 + %451 = load <4 x float>, ptr %9, align 16 + %452 = shufflevector <4 x float> %451, <4 x float> poison, <4 x i32> + %453 = shufflevector <4 x float> %450, <4 x float> poison, <4 x i32> + %454 = shufflevector <4 x float> %451, <4 x float> poison, <4 x i32> + %455 = shufflevector <4 x float> %450, <4 x float> poison, <4 x i32> + %456 = fneg contract <4 x float> %455 + %457 = fmul contract <4 x float> %454, %456 + %458 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %452, <4 x float> %453, <4 x float> %457) + %459 = fmul contract <4 x float> %458, %458 + %shift1672 = shufflevector <4 x float> %459, <4 x float> poison, <4 x i32> + %460 = fadd contract <4 x float> %459, %shift1672 + %shift1673 = shufflevector <4 x float> %459, <4 x float> poison, <4 x i32> + %461 = fadd contract <4 x float> %shift1673, %460 + %462 = extractelement <4 x float> %461, i64 0 + %463 = call contract noundef float @llvm.sqrt.f32(float %462) + %464 = fdiv contract float 1.000000e+00, %463 + %465 = insertelement <4 x float> poison, float %464, i64 0 + %466 = shufflevector <4 x float> %465, <4 x float> poison, <4 x i32> zeroinitializer + %467 = fmul contract <4 x float> %458, %466 + store <4 x float> %467, ptr %14, align 16 + %468 = fmul contract <4 x float> %439, %439 + %469 = extractelement <4 x float> %468, i64 0 + %470 = load float, ptr %334, align 16 + %471 = fmul contract float %469, %470 + %472 = fmul contract float %440, 2.000000e+00 + %473 = fmul contract float %472, %443 + %474 = load float, ptr %335, align 4 + %475 = fmul contract float %473, %474 + %476 = fadd contract float %471, %475 + %477 = fmul contract <4 x float> %442, %442 + %478 = extractelement <4 x float> %477, i64 0 + %479 = load float, ptr %336, align 8 + %480 = fmul contract float %478, %479 + %481 = fadd contract float %476, %480 + %482 = fmul contract <4 x float> %423, %468 + %483 = extractelement <4 x float> %482, i64 0 + %484 = fmul contract float %426, %473 + %485 = fadd contract float %483, %484 + %486 = fmul contract <4 x float> %429, %477 + %487 = extractelement <4 x float> %486, i64 0 + %488 = fadd contract float %487, %485 + %489 = fdiv contract float %481, %488 + %490 = call contract noundef float @llvm.fabs.f32(float %489) br label %.sink.split -.sink.split: ; preds = %_ZN5drjit6gatherIjLb0ERNS_12DynamicArrayIjEEjbEET_OT1_RKT2_RKT3_.exit1383, %329 - %.sink = phi float [ %492, %329 ], [ %297, %_ZN5drjit6gatherIjLb0ERNS_12DynamicArrayIjEEjbEET_OT1_RKT2_RKT3_.exit1383 ] +.sink.split: ; preds = %_ZN5drjit6gatherIjLb0ERNS_12DynamicArrayIjEEjbEET_OT1_RKT2_RKT3_.exit1383, %327 + %.sink = phi float [ %490, %327 ], [ %295, %_ZN5drjit6gatherIjLb0ERNS_12DynamicArrayIjEEjbEET_OT1_RKT2_RKT3_.exit1383 ] store float %.sink, ptr %16, align 8 - br label %493 + br label %491 -493: ; preds = %.sink.split, %327 - %494 = getelementptr inbounds nuw i8, ptr %0, i64 124 - %495 = getelementptr inbounds nuw i8, ptr %0, i64 112 - store ptr %1, ptr %495, align 16 - store float 0x3F747AE140000000, ptr %494, align 4 +491: ; preds = %.sink.split, %325 + %492 = getelementptr inbounds nuw i8, ptr %0, i64 124 + %493 = getelementptr inbounds nuw i8, ptr %0, i64 112 + store ptr %1, ptr %493, align 16 + store float 0x3F747AE140000000, ptr %492, align 4 ret void } diff --git a/bench/mitsuba3/optimized/constant.cpp.ll b/bench/mitsuba3/optimized/constant.cpp.ll index 03bce24246f..613aed9b81c 100644 --- a/bench/mitsuba3/optimized/constant.cpp.ll +++ b/bench/mitsuba3/optimized/constant.cpp.ll @@ -778,155 +778,154 @@ _ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EE %90 = fdiv contract float %89, %.sroa.speculated323 %91 = fsub contract float 0x3FF921FB60000000, %90 %spec.select = select i1 %86, float %91, float %90 - %92 = tail call float @llvm.fabs.f32(float %spec.select) - %93 = select contract i1 %narrow, float 0.000000e+00, float %92 - %94 = fmul contract float %93, 0x3FF45F3060000000 - %95 = fptosi float %94 to i32 - %96 = add nsw i32 %95, 1 - %97 = and i32 %96, -2 - %98 = shl i32 %97, 29 - %99 = bitcast float %spec.select to i32 - %100 = select i1 %narrow, i32 0, i32 %99 - %101 = xor i32 %98, %100 - %102 = and i32 %101, -2147483648 - %103 = and i32 %96, 2 - %104 = icmp eq i32 %103, 0 - %105 = fcmp contract oeq float %93, 0x7FF0000000000000 - %106 = sitofp i32 %97 to float - %107 = fmul contract float %106, 0x3FE9200000000000 - %108 = fsub contract float %93, %107 - %109 = fmul contract float %106, 0x3F2FB40000000000 + %.1 = select i1 %narrow, float 0.000000e+00, float %spec.select + %92 = tail call contract noundef float @llvm.fabs.f32(float %.1) + %93 = fmul contract float %92, 0x3FF45F3060000000 + %94 = fptosi float %93 to i32 + %95 = add nsw i32 %94, 1 + %96 = and i32 %95, -2 + %97 = shl i32 %96, 29 + %98 = bitcast float %.1 to i32 + %99 = xor i32 %97, %98 + %100 = and i32 %99, -2147483648 + %101 = and i32 %95, 2 + %102 = icmp eq i32 %101, 0 + %103 = fcmp contract oeq float %92, 0x7FF0000000000000 + %104 = sitofp i32 %96 to float + %105 = fmul contract float %104, 0x3FE9200000000000 + %106 = fsub contract float %92, %105 + %107 = fmul contract float %104, 0x3F2FB40000000000 + %108 = fsub contract float %106, %107 + %109 = fmul contract float %104, 0x3E64442D20000000 %110 = fsub contract float %108, %109 - %111 = fmul contract float %106, 0x3E64442D20000000 - %112 = fsub contract float %110, %111 + %111 = fmul contract float %110, %110 + %112 = select i1 %103, float 0xFFFFFFFFE0000000, float %111 %113 = fmul contract float %112, %112 - %114 = select i1 %105, float 0xFFFFFFFFE0000000, float %113 - %115 = fmul contract float %114, %114 - %116 = tail call contract noundef float @llvm.fma.f32(float %114, float 0x3F811073C0000000, float 0xBFC5555460000000) - %117 = tail call contract noundef float @llvm.fma.f32(float %115, float 0xBF29943F20000000, float %116) - %118 = fmul contract float %114, %117 - %119 = tail call contract noundef float @llvm.fma.f32(float %118, float %112, float %112) - %120 = tail call contract noundef float @llvm.fma.f32(float %114, float 0xBF56C0C340000000, float 0x3FA55554A0000000) - %121 = tail call contract noundef float @llvm.fma.f32(float %115, float 0x3EF99EB9C0000000, float %120) - %122 = fmul contract float %114, %121 - %123 = tail call contract noundef float @llvm.fma.f32(float %114, float -5.000000e-01, float 1.000000e+00) - %124 = tail call contract noundef float @llvm.fma.f32(float %122, float %114, float %123) - %125 = select contract i1 %104, float %119, float %124 - %126 = bitcast float %125 to i32 - %127 = xor i32 %102, %126 - %.sroa.0313.0.vec.extract = bitcast i32 %127 to float - %128 = fmul contract float %.sroa.speculated323, %.sroa.0313.0.vec.extract - %129 = fmul contract float %128, %128 - %130 = sub i32 0, %98 - %131 = and i32 %130, -2147483648 - %132 = select contract i1 %104, float %124, float %119 - %133 = bitcast float %132 to i32 - %134 = xor i32 %131, %133 - %.sroa.0313.4.vec.extract = bitcast i32 %134 to float - %135 = fmul contract float %.sroa.speculated323, %.sroa.0313.4.vec.extract - %136 = fmul contract float %135, %135 + %114 = tail call contract noundef float @llvm.fma.f32(float %112, float 0x3F811073C0000000, float 0xBFC5555460000000) + %115 = tail call contract noundef float @llvm.fma.f32(float %113, float 0xBF29943F20000000, float %114) + %116 = fmul contract float %112, %115 + %117 = tail call contract noundef float @llvm.fma.f32(float %116, float %110, float %110) + %118 = tail call contract noundef float @llvm.fma.f32(float %112, float 0xBF56C0C340000000, float 0x3FA55554A0000000) + %119 = tail call contract noundef float @llvm.fma.f32(float %113, float 0x3EF99EB9C0000000, float %118) + %120 = fmul contract float %112, %119 + %121 = tail call contract noundef float @llvm.fma.f32(float %112, float -5.000000e-01, float 1.000000e+00) + %122 = tail call contract noundef float @llvm.fma.f32(float %120, float %112, float %121) + %123 = select contract i1 %102, float %117, float %122 + %124 = bitcast float %123 to i32 + %125 = xor i32 %100, %124 + %.sroa.0313.0.vec.extract = bitcast i32 %125 to float + %126 = fmul contract float %.sroa.speculated323, %.sroa.0313.0.vec.extract + %127 = fmul contract float %126, %126 + %128 = sub i32 0, %97 + %129 = and i32 %128, -2147483648 + %130 = select contract i1 %102, float %122, float %117 + %131 = bitcast float %130 to i32 + %132 = xor i32 %129, %131 + %.sroa.0313.4.vec.extract = bitcast i32 %132 to float + %133 = fmul contract float %.sroa.speculated323, %.sroa.0313.4.vec.extract + %134 = fmul contract float %133, %133 call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %7), !noalias !20 - %137 = call contract noundef float @llvm.fma.f32(float %19, float -2.000000e+00, float 1.000000e+00) - %138 = fneg contract float %137 - %139 = call contract noundef float @llvm.fma.f32(float %138, float %137, float 1.000000e+00) - %140 = fcmp contract olt float %139, 0.000000e+00 - %..i.i = select contract i1 %140, float 0.000000e+00, float %139 - %141 = call contract noundef float @llvm.sqrt.f32(float %..i.i) - %142 = fmul contract float %20, 0x401921FB60000000 - %143 = call contract noundef float @llvm.fabs.f32(float %142) - %144 = fmul contract float %143, 0x3FF45F3060000000 - %145 = fptosi float %144 to i32 - %146 = add nsw i32 %145, 1 - %147 = and i32 %146, -2 - %148 = shl i32 %147, 29 - %149 = sub i32 0, %148 - %150 = and i32 %149, -2147483648 - %151 = and i32 %146, 2 - %152 = icmp eq i32 %151, 0 - %153 = fcmp contract oeq float %143, 0x7FF0000000000000 - %154 = sitofp i32 %147 to float - %155 = fmul contract float %154, 0x3FE9200000000000 - %156 = fsub contract float %143, %155 - %157 = fmul contract float %154, 0x3F2FB40000000000 + %135 = call contract noundef float @llvm.fma.f32(float %19, float -2.000000e+00, float 1.000000e+00) + %136 = fneg contract float %135 + %137 = call contract noundef float @llvm.fma.f32(float %136, float %135, float 1.000000e+00) + %138 = fcmp contract olt float %137, 0.000000e+00 + %..i.i = select contract i1 %138, float 0.000000e+00, float %137 + %139 = call contract noundef float @llvm.sqrt.f32(float %..i.i) + %140 = fmul contract float %20, 0x401921FB60000000 + %141 = call contract noundef float @llvm.fabs.f32(float %140) + %142 = fmul contract float %141, 0x3FF45F3060000000 + %143 = fptosi float %142 to i32 + %144 = add nsw i32 %143, 1 + %145 = and i32 %144, -2 + %146 = shl i32 %145, 29 + %147 = sub i32 0, %146 + %148 = and i32 %147, -2147483648 + %149 = and i32 %144, 2 + %150 = icmp eq i32 %149, 0 + %151 = fcmp contract oeq float %141, 0x7FF0000000000000 + %152 = sitofp i32 %145 to float + %153 = fmul contract float %152, 0x3FE9200000000000 + %154 = fsub contract float %141, %153 + %155 = fmul contract float %152, 0x3F2FB40000000000 + %156 = fsub contract float %154, %155 + %157 = fmul contract float %152, 0x3E64442D20000000 %158 = fsub contract float %156, %157 - %159 = fmul contract float %154, 0x3E64442D20000000 - %160 = fsub contract float %158, %159 + %159 = fmul contract float %158, %158 + %160 = select i1 %151, float 0xFFFFFFFFE0000000, float %159 %161 = fmul contract float %160, %160 - %162 = select i1 %153, float 0xFFFFFFFFE0000000, float %161 - %163 = fmul contract float %162, %162 - %164 = call contract noundef float @llvm.fma.f32(float %162, float 0xBF56C0C340000000, float 0x3FA55554A0000000) - %165 = call contract noundef float @llvm.fma.f32(float %163, float 0x3EF99EB9C0000000, float %164) - %166 = fmul contract float %162, %165 - %167 = call contract noundef float @llvm.fma.f32(float %162, float -5.000000e-01, float 1.000000e+00) - %168 = call contract noundef float @llvm.fma.f32(float %166, float %162, float %167) - %169 = call contract noundef float @llvm.fma.f32(float %162, float 0x3F811073C0000000, float 0xBFC5555460000000) - %170 = call contract noundef float @llvm.fma.f32(float %163, float 0xBF29943F20000000, float %169) - %171 = fmul contract float %162, %170 - %172 = call contract noundef float @llvm.fma.f32(float %171, float %160, float %160) - %173 = select contract i1 %152, float %168, float %172 - %174 = bitcast float %173 to i32 - %175 = xor i32 %150, %174 - %.sroa.0290.4.vec.extract = bitcast i32 %175 to float - %176 = fmul contract float %141, %.sroa.0290.4.vec.extract - %177 = insertelement <4 x float> , float %176, i64 0 - %178 = bitcast float %142 to i32 - %179 = xor i32 %148, %178 - %180 = and i32 %179, -2147483648 - %181 = select contract i1 %152, float %172, float %168 - %182 = bitcast float %181 to i32 - %183 = xor i32 %180, %182 - %.sroa.0290.0.vec.extract = bitcast i32 %183 to float - %184 = fmul contract float %141, %.sroa.0290.0.vec.extract - %185 = insertelement <4 x float> %177, float %184, i64 1 - %186 = insertelement <4 x float> %185, float %137, i64 2 - %187 = fneg <4 x float> %186 - %188 = fadd contract float %136, %129 - %189 = fsub contract float 1.000000e+00, %188 - %190 = fcmp contract olt float %189, 0.000000e+00 - %..i = select contract i1 %190, float 0.000000e+00, float %189 - %191 = call contract noundef float @llvm.sqrt.f32(float %..i) - %192 = insertelement <4 x float> poison, float %191, i64 0 - %193 = shufflevector <4 x float> %192, <4 x float> poison, <4 x i32> zeroinitializer - %.sroa.0280.0.vec.extract = extractelement <4 x float> %187, i64 0 - %.sroa.0280.4.vec.extract = extractelement <4 x float> %187, i64 1 - %194 = fmul contract float %.sroa.0280.0.vec.extract, %.sroa.0280.4.vec.extract - %.sroa.0280.8.vec.extract = extractelement <4 x float> %187, i64 2 - %195 = call float @llvm.copysign.f32(float 1.000000e+00, float %.sroa.0280.8.vec.extract) - %196 = fadd contract float %.sroa.0280.8.vec.extract, %195 - %197 = fdiv contract float -1.000000e+00, %196 - %198 = fmul contract float %194, %197 - %199 = insertelement <4 x float> , float %198, i64 0 - %200 = fmul contract float %.sroa.0280.4.vec.extract, %197 - %201 = call contract noundef float @llvm.fma.f32(float %.sroa.0280.4.vec.extract, float %200, float %195) - %202 = insertelement <4 x float> %199, float %201, i64 1 - %203 = fneg contract float %.sroa.0280.4.vec.extract - %204 = insertelement <4 x float> %202, float %203, i64 2 - %205 = insertelement <4 x float> poison, float %128, i64 0 - %206 = shufflevector <4 x float> %205, <4 x float> poison, <4 x i32> zeroinitializer - %207 = bitcast float %.sroa.0280.8.vec.extract to i32 - %208 = and i32 %207, -2147483648 - %209 = fmul contract float %176, %176 - %210 = fmul contract float %209, %197 - %211 = bitcast float %210 to i32 - %212 = xor i32 %208, %211 - %213 = bitcast i32 %212 to float - %214 = fadd contract float %213, 1.000000e+00 - %215 = insertelement <4 x float> , float %214, i64 0 - %216 = bitcast float %198 to i32 - %217 = xor i32 %208, %216 - %218 = bitcast i32 %217 to float - %219 = insertelement <4 x float> %215, float %218, i64 1 - %220 = fcmp contract ult float %.sroa.0280.8.vec.extract, 0.000000e+00 - %221 = fneg contract float %.sroa.0280.0.vec.extract - %222 = select contract i1 %220, float %.sroa.0280.0.vec.extract, float %221 - %223 = insertelement <4 x float> %219, float %222, i64 2 - %224 = insertelement <4 x float> poison, float %135, i64 0 - %225 = shufflevector <4 x float> %224, <4 x float> poison, <4 x i32> zeroinitializer - %226 = fmul contract <4 x float> %225, %223 - %227 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %204, <4 x float> %206, <4 x float> %226) - %228 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %187, <4 x float> %193, <4 x float> %227) - %229 = shufflevector <4 x float> %22, <4 x float> poison, <4 x i32> zeroinitializer - %230 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %186, <4 x float> %229, <4 x float> %24) + %162 = call contract noundef float @llvm.fma.f32(float %160, float 0xBF56C0C340000000, float 0x3FA55554A0000000) + %163 = call contract noundef float @llvm.fma.f32(float %161, float 0x3EF99EB9C0000000, float %162) + %164 = fmul contract float %160, %163 + %165 = call contract noundef float @llvm.fma.f32(float %160, float -5.000000e-01, float 1.000000e+00) + %166 = call contract noundef float @llvm.fma.f32(float %164, float %160, float %165) + %167 = call contract noundef float @llvm.fma.f32(float %160, float 0x3F811073C0000000, float 0xBFC5555460000000) + %168 = call contract noundef float @llvm.fma.f32(float %161, float 0xBF29943F20000000, float %167) + %169 = fmul contract float %160, %168 + %170 = call contract noundef float @llvm.fma.f32(float %169, float %158, float %158) + %171 = select contract i1 %150, float %166, float %170 + %172 = bitcast float %171 to i32 + %173 = xor i32 %148, %172 + %.sroa.0290.4.vec.extract = bitcast i32 %173 to float + %174 = fmul contract float %139, %.sroa.0290.4.vec.extract + %175 = insertelement <4 x float> , float %174, i64 0 + %176 = bitcast float %140 to i32 + %177 = xor i32 %146, %176 + %178 = and i32 %177, -2147483648 + %179 = select contract i1 %150, float %170, float %166 + %180 = bitcast float %179 to i32 + %181 = xor i32 %178, %180 + %.sroa.0290.0.vec.extract = bitcast i32 %181 to float + %182 = fmul contract float %139, %.sroa.0290.0.vec.extract + %183 = insertelement <4 x float> %175, float %182, i64 1 + %184 = insertelement <4 x float> %183, float %135, i64 2 + %185 = fneg <4 x float> %184 + %186 = fadd contract float %134, %127 + %187 = fsub contract float 1.000000e+00, %186 + %188 = fcmp contract olt float %187, 0.000000e+00 + %..i = select contract i1 %188, float 0.000000e+00, float %187 + %189 = call contract noundef float @llvm.sqrt.f32(float %..i) + %190 = insertelement <4 x float> poison, float %189, i64 0 + %191 = shufflevector <4 x float> %190, <4 x float> poison, <4 x i32> zeroinitializer + %.sroa.0280.0.vec.extract = extractelement <4 x float> %185, i64 0 + %.sroa.0280.4.vec.extract = extractelement <4 x float> %185, i64 1 + %192 = fmul contract float %.sroa.0280.0.vec.extract, %.sroa.0280.4.vec.extract + %.sroa.0280.8.vec.extract = extractelement <4 x float> %185, i64 2 + %193 = call float @llvm.copysign.f32(float 1.000000e+00, float %.sroa.0280.8.vec.extract) + %194 = fadd contract float %.sroa.0280.8.vec.extract, %193 + %195 = fdiv contract float -1.000000e+00, %194 + %196 = fmul contract float %192, %195 + %197 = insertelement <4 x float> , float %196, i64 0 + %198 = fmul contract float %.sroa.0280.4.vec.extract, %195 + %199 = call contract noundef float @llvm.fma.f32(float %.sroa.0280.4.vec.extract, float %198, float %193) + %200 = insertelement <4 x float> %197, float %199, i64 1 + %201 = fneg contract float %.sroa.0280.4.vec.extract + %202 = insertelement <4 x float> %200, float %201, i64 2 + %203 = insertelement <4 x float> poison, float %126, i64 0 + %204 = shufflevector <4 x float> %203, <4 x float> poison, <4 x i32> zeroinitializer + %205 = bitcast float %.sroa.0280.8.vec.extract to i32 + %206 = and i32 %205, -2147483648 + %207 = fmul contract float %174, %174 + %208 = fmul contract float %207, %195 + %209 = bitcast float %208 to i32 + %210 = xor i32 %206, %209 + %211 = bitcast i32 %210 to float + %212 = fadd contract float %211, 1.000000e+00 + %213 = insertelement <4 x float> , float %212, i64 0 + %214 = bitcast float %196 to i32 + %215 = xor i32 %206, %214 + %216 = bitcast i32 %215 to float + %217 = insertelement <4 x float> %213, float %216, i64 1 + %218 = fcmp contract ult float %.sroa.0280.8.vec.extract, 0.000000e+00 + %219 = fneg contract float %.sroa.0280.0.vec.extract + %220 = select contract i1 %218, float %.sroa.0280.0.vec.extract, float %219 + %221 = insertelement <4 x float> %217, float %220, i64 2 + %222 = insertelement <4 x float> poison, float %133, i64 0 + %223 = shufflevector <4 x float> %222, <4 x float> poison, <4 x i32> zeroinitializer + %224 = fmul contract <4 x float> %223, %221 + %225 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %202, <4 x float> %204, <4 x float> %224) + %226 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %185, <4 x float> %191, <4 x float> %225) + %227 = shufflevector <4 x float> %22, <4 x float> poison, <4 x i32> zeroinitializer + %228 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %184, <4 x float> %227, <4 x float> %24) call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %10) call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %11) %.sroa.5.48..sroa_idx = getelementptr inbounds nuw i8, ptr %.sroa.5, i64 8 @@ -934,17 +933,17 @@ _ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EE %.sroa.0.i.16.i.16.i.16..sroa_idx = getelementptr inbounds nuw i8, ptr %.sroa.0.i, i64 16 call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(240) %.sroa.0.i.16.i.16.i.16..sroa_idx, i8 0, i64 240, i1 false) call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %.sroa.0.i, ptr noundef nonnull align 16 dereferenceable(16) %9, i64 16, i1 false) - store <4 x float> %230, ptr %0, align 16 + store <4 x float> %228, ptr %0, align 16 %.sroa.0278.sroa.2.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 16 - store <4 x float> %228, ptr %.sroa.0278.sroa.2.0..sroa_idx, align 16 + store <4 x float> %226, ptr %.sroa.0278.sroa.2.0..sroa_idx, align 16 %.sroa.3.0..sroa_idx279 = getelementptr inbounds nuw i8, ptr %0, i64 32 store float 0x47EFFFFFE0000000, ptr %.sroa.3.0..sroa_idx279, align 16 %.sroa.4.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 36 store float %2, ptr %.sroa.4.0..sroa_idx, align 4 %.sroa.5.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 40 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %.sroa.5.0..sroa_idx, ptr noundef nonnull align 8 dereferenceable(24) %.sroa.5, i64 24, i1 false) - %231 = getelementptr inbounds nuw i8, ptr %0, i64 64 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %231, ptr noundef nonnull align 16 dereferenceable(256) %.sroa.0.i, i64 256, i1 false) + %229 = getelementptr inbounds nuw i8, ptr %0, i64 64 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %229, ptr noundef nonnull align 16 dereferenceable(256) %.sroa.0.i, i64 256, i1 false) ret void } diff --git a/bench/mitsuba3/optimized/cylinder.cpp.ll b/bench/mitsuba3/optimized/cylinder.cpp.ll index 4abc7c826a9..298b98c93cc 100644 --- a/bench/mitsuba3/optimized/cylinder.cpp.ll +++ b/bench/mitsuba3/optimized/cylinder.cpp.ll @@ -4098,7 +4098,7 @@ define weak_odr void @_ZNK7mitsuba8CylinderIfN5drjit6MatrixINS_8SpectrumIfLm4EEE 136: ; preds = %7 %137 = and i32 %4, 2 %.not1161 = icmp eq i32 %137, 0 - br i1 %.not1161, label %399, label %138 + br i1 %.not1161, label %398, label %138 138: ; preds = %136 %139 = getelementptr inbounds nuw i8, ptr %1, i64 272 @@ -4245,166 +4245,165 @@ define weak_odr void @_ZNK7mitsuba8CylinderIfN5drjit6MatrixINS_8SpectrumIfLm4EEE %268 = fdiv contract float 1.000000e+00, %157 %269 = fcmp contract ogt float %268, 1.000000e+00 %..i.i1001 = select contract i1 %269, float 1.000000e+00, float %268 - %270 = tail call float @llvm.fabs.f32(float %268) - %271 = select contract i1 %269, float 1.000000e+00, float %270 - %272 = fcmp contract ogt float %271, 5.000000e-01 - %273 = fsub contract float 1.000000e+00, %271 - %274 = fmul contract float %273, 5.000000e-01 - %275 = fmul contract float %..i.i1001, %..i.i1001 - %276 = select contract i1 %272, float %274, float %275 - %277 = tail call contract noundef float @llvm.fma.f32(float %276, float 0x3FB3301EC0000000, float 0x3FC5555C80000000) - %278 = tail call contract noundef float @llvm.fma.f32(float %276, float 0x3F98C2FC60000000, float 0x3FA747D8E0000000) - %279 = tail call contract noundef float @llvm.sqrt.f32(float %274) - %280 = select contract i1 %272, float %279, float %271 - %281 = fmul contract float %276, %276 - %282 = tail call contract noundef float @llvm.fma.f32(float %281, float %278, float %277) - %283 = fmul contract float %281, %281 - %284 = tail call contract noundef float @llvm.fma.f32(float %283, float 0x3FA5966A40000000, float %282) - %285 = fmul contract float %276, %280 - %286 = tail call contract noundef float @llvm.fma.f32(float %284, float %285, float %280) - %287 = fadd contract float %286, %286 - %288 = fsub contract float 0x3FF921FB60000000, %287 - %289 = select contract i1 %272, float %288, float %286 - %290 = tail call noundef float @llvm.copysign.f32(float %289, float %..i.i1001) - %291 = fsub contract float 0x3FF921FB60000000, %290 - %292 = fmul contract float %291, %267 - %293 = fadd contract float %181, %292 - %294 = fcmp contract olt float %293, 0.000000e+00 - %295 = fadd contract float %293, 0x401921FB60000000 - %spec.select = select i1 %294, float %295, float %293 - %296 = fcmp contract oge float %spec.select, 0x401921FB60000000 - %297 = fadd contract float %spec.select, 0xC01921FB60000000 - %.1 = select i1 %296, float %297, float %spec.select - %298 = fmul contract float %.1, 0x3FC45F3060000000 - %299 = getelementptr inbounds nuw i8, ptr %3, i64 76 - %300 = load float, ptr %299, align 4 - store float %298, ptr %10, align 16 + %270 = tail call contract noundef float @llvm.fabs.f32(float %..i.i1001) + %271 = fcmp contract ogt float %270, 5.000000e-01 + %272 = fsub contract float 1.000000e+00, %270 + %273 = fmul contract float %272, 5.000000e-01 + %274 = fmul contract float %..i.i1001, %..i.i1001 + %275 = select contract i1 %271, float %273, float %274 + %276 = tail call contract noundef float @llvm.fma.f32(float %275, float 0x3FB3301EC0000000, float 0x3FC5555C80000000) + %277 = tail call contract noundef float @llvm.fma.f32(float %275, float 0x3F98C2FC60000000, float 0x3FA747D8E0000000) + %278 = tail call contract noundef float @llvm.sqrt.f32(float %273) + %279 = select contract i1 %271, float %278, float %270 + %280 = fmul contract float %275, %275 + %281 = tail call contract noundef float @llvm.fma.f32(float %280, float %277, float %276) + %282 = fmul contract float %280, %280 + %283 = tail call contract noundef float @llvm.fma.f32(float %282, float 0x3FA5966A40000000, float %281) + %284 = fmul contract float %275, %279 + %285 = tail call contract noundef float @llvm.fma.f32(float %283, float %284, float %279) + %286 = fadd contract float %285, %285 + %287 = fsub contract float 0x3FF921FB60000000, %286 + %288 = select contract i1 %271, float %287, float %285 + %289 = tail call noundef float @llvm.copysign.f32(float %288, float %..i.i1001) + %290 = fsub contract float 0x3FF921FB60000000, %289 + %291 = fmul contract float %290, %267 + %292 = fadd contract float %181, %291 + %293 = fcmp contract olt float %292, 0.000000e+00 + %294 = fadd contract float %292, 0x401921FB60000000 + %spec.select = select i1 %293, float %294, float %292 + %295 = fcmp contract oge float %spec.select, 0x401921FB60000000 + %296 = fadd contract float %spec.select, 0xC01921FB60000000 + %.1 = select i1 %295, float %296, float %spec.select + %297 = fmul contract float %.1, 0x3FC45F3060000000 + %298 = getelementptr inbounds nuw i8, ptr %3, i64 76 + %299 = load float, ptr %298, align 4 + store float %297, ptr %10, align 16 %.sroa_idx1007 = getelementptr inbounds nuw i8, ptr %0, i64 36 - store float %300, ptr %.sroa_idx1007, align 4 - %301 = tail call contract noundef float @llvm.fabs.f32(float %.1) - %302 = fmul contract float %301, 0x3FF45F3060000000 - %303 = fptosi float %302 to i32 - %304 = add nsw i32 %303, 1 - %305 = and i32 %304, -2 - %306 = sitofp i32 %305 to float - %307 = shl i32 %305, 29 - %308 = bitcast float %.1 to i32 - %309 = xor i32 %307, %308 - %310 = sub i32 0, %307 - %311 = fmul contract float %306, 0x3FE9200000000000 - %312 = fsub contract float %301, %311 - %313 = fmul contract float %306, 0x3F2FB40000000000 - %314 = fsub contract float %312, %313 - %315 = fmul contract float %306, 0x3E64442D20000000 - %316 = fsub contract float %314, %315 - %317 = fmul contract float %316, %316 - %318 = fcmp contract oeq float %301, 0x7FF0000000000000 - %319 = select i1 %318, float 0xFFFFFFFFE0000000, float %317 - %320 = tail call contract noundef float @llvm.fma.f32(float %319, float 0x3F811073C0000000, float 0xBFC5555460000000) - %321 = fmul contract float %319, %319 - %322 = tail call contract noundef float @llvm.fma.f32(float %321, float 0xBF29943F20000000, float %320) - %323 = fmul contract float %319, %322 - %324 = tail call contract noundef float @llvm.fma.f32(float %319, float 0xBF56C0C340000000, float 0x3FA55554A0000000) - %325 = tail call contract noundef float @llvm.fma.f32(float %321, float 0x3EF99EB9C0000000, float %324) - %326 = fmul contract float %319, %325 - %327 = tail call contract noundef float @llvm.fma.f32(float %323, float %316, float %316) - %328 = tail call contract noundef float @llvm.fma.f32(float %319, float -5.000000e-01, float 1.000000e+00) - %329 = tail call contract noundef float @llvm.fma.f32(float %326, float %319, float %328) - %330 = and i32 %304, 2 - %331 = icmp eq i32 %330, 0 - %332 = select contract i1 %331, float %327, float %329 - %333 = and i32 %309, -2147483648 - %334 = bitcast float %332 to i32 - %335 = xor i32 %333, %334 - %336 = select contract i1 %331, float %329, float %327 - %337 = and i32 %310, -2147483648 - %338 = bitcast float %336 to i32 - %339 = xor i32 %337, %338 - %340 = getelementptr inbounds nuw i8, ptr %1, i64 192 - %.sroa.01059.0.copyload = load <4 x float>, ptr %340, align 16 - %341 = insertelement <4 x i32> poison, i32 %339, i64 0 - %342 = bitcast <4 x i32> %341 to <4 x float> - %343 = shufflevector <4 x float> %342, <4 x float> poison, <4 x i32> zeroinitializer - %344 = load <4 x float>, ptr %8, align 16 - %345 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %344, <4 x float> %343, <4 x float> %.sroa.01059.0.copyload) - %346 = getelementptr inbounds nuw i8, ptr %1, i64 160 - %347 = insertelement <4 x i32> poison, i32 %335, i64 0 - %348 = bitcast <4 x i32> %347 to <4 x float> - %349 = shufflevector <4 x float> %348, <4 x float> poison, <4 x i32> zeroinitializer - %350 = load <4 x float>, ptr %346, align 16 - %351 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %350, <4 x float> %349, <4 x float> %345) - %352 = getelementptr inbounds nuw i8, ptr %1, i64 176 - %353 = insertelement <4 x float> poison, float %300, i64 0 - %354 = shufflevector <4 x float> %353, <4 x float> poison, <4 x i32> zeroinitializer - %355 = load <4 x float>, ptr %352, align 16 - %356 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %355, <4 x float> %354, <4 x float> %351) - store <4 x float> %356, ptr %0, align 16 - %357 = load <4 x float>, ptr %2, align 16 - %358 = fsub contract <4 x float> %356, %357 - %359 = fmul contract <4 x float> %358, %358 - %shift1201 = shufflevector <4 x float> %359, <4 x float> poison, <4 x i32> - %360 = fadd contract <4 x float> %359, %shift1201 - %shift1202 = shufflevector <4 x float> %359, <4 x float> poison, <4 x i32> - %361 = fadd contract <4 x float> %shift1202, %360 - %362 = extractelement <4 x float> %361, i64 0 - %363 = tail call contract noundef float @llvm.sqrt.f32(float %362) - %364 = fdiv contract float 1.000000e+00, %363 - %365 = insertelement <4 x float> poison, float %364, i64 0 - %366 = shufflevector <4 x float> %365, <4 x float> poison, <4 x i32> zeroinitializer - %367 = fmul contract <4 x float> %358, %366 - store <4 x float> %367, ptr %12, align 16 - %368 = fmul contract <4 x float> %344, zeroinitializer - %369 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %350, <4 x float> zeroinitializer, <4 x float> %368) - %370 = fadd contract <4 x float> %355, %369 - %371 = fmul contract <4 x float> %370, %370 - %shift1203 = shufflevector <4 x float> %371, <4 x float> poison, <4 x i32> - %372 = fadd contract <4 x float> %371, %shift1203 - %shift1204 = shufflevector <4 x float> %371, <4 x float> poison, <4 x i32> - %373 = fadd contract <4 x float> %shift1204, %372 - %374 = extractelement <4 x float> %373, i64 0 - %375 = tail call contract noundef float @llvm.sqrt.f32(float %374) - %376 = fdiv contract float 1.000000e+00, %375 - %377 = insertelement <4 x float> poison, float %376, i64 0 - %378 = shufflevector <4 x float> %377, <4 x float> poison, <4 x i32> zeroinitializer - %379 = fmul contract <4 x float> %370, %378 - store <4 x float> %379, ptr %13, align 16 - %380 = getelementptr inbounds nuw i8, ptr %1, i64 208 - %.sroa.01109.0.copyload = load <4 x float>, ptr %380, align 16 - %381 = fmul contract <4 x float> %.sroa.01109.0.copyload, %343 - %382 = getelementptr inbounds nuw i8, ptr %1, i64 224 - %383 = load <4 x float>, ptr %382, align 16 - %384 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %383, <4 x float> %349, <4 x float> %381) - %385 = getelementptr inbounds nuw i8, ptr %1, i64 240 - %386 = load <4 x float>, ptr %385, align 16 - %387 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %386, <4 x float> zeroinitializer, <4 x float> %384) - %388 = fmul contract <4 x float> %387, %387 - %shift1205 = shufflevector <4 x float> %388, <4 x float> poison, <4 x i32> - %389 = fadd contract <4 x float> %388, %shift1205 - %shift1206 = shufflevector <4 x float> %388, <4 x float> poison, <4 x i32> - %390 = fadd contract <4 x float> %shift1206, %389 - %391 = extractelement <4 x float> %390, i64 0 - %392 = tail call contract noundef float @llvm.sqrt.f32(float %391) - %393 = fdiv contract float 1.000000e+00, %392 - %394 = insertelement <4 x float> poison, float %393, i64 0 - %395 = shufflevector <4 x float> %394, <4 x float> poison, <4 x i32> zeroinitializer - %396 = fmul contract <4 x float> %387, %395 - store <4 x float> %396, ptr %9, align 16 - %397 = fcmp contract ule float %157, 1.000000e+00 - %398 = select i1 %397, i32 0, i32 2 + store float %299, ptr %.sroa_idx1007, align 4 + %300 = tail call contract noundef float @llvm.fabs.f32(float %.1) + %301 = fmul contract float %300, 0x3FF45F3060000000 + %302 = fptosi float %301 to i32 + %303 = add nsw i32 %302, 1 + %304 = and i32 %303, -2 + %305 = sitofp i32 %304 to float + %306 = shl i32 %304, 29 + %307 = bitcast float %.1 to i32 + %308 = xor i32 %306, %307 + %309 = sub i32 0, %306 + %310 = fmul contract float %305, 0x3FE9200000000000 + %311 = fsub contract float %300, %310 + %312 = fmul contract float %305, 0x3F2FB40000000000 + %313 = fsub contract float %311, %312 + %314 = fmul contract float %305, 0x3E64442D20000000 + %315 = fsub contract float %313, %314 + %316 = fmul contract float %315, %315 + %317 = fcmp contract oeq float %300, 0x7FF0000000000000 + %318 = select i1 %317, float 0xFFFFFFFFE0000000, float %316 + %319 = tail call contract noundef float @llvm.fma.f32(float %318, float 0x3F811073C0000000, float 0xBFC5555460000000) + %320 = fmul contract float %318, %318 + %321 = tail call contract noundef float @llvm.fma.f32(float %320, float 0xBF29943F20000000, float %319) + %322 = fmul contract float %318, %321 + %323 = tail call contract noundef float @llvm.fma.f32(float %318, float 0xBF56C0C340000000, float 0x3FA55554A0000000) + %324 = tail call contract noundef float @llvm.fma.f32(float %320, float 0x3EF99EB9C0000000, float %323) + %325 = fmul contract float %318, %324 + %326 = tail call contract noundef float @llvm.fma.f32(float %322, float %315, float %315) + %327 = tail call contract noundef float @llvm.fma.f32(float %318, float -5.000000e-01, float 1.000000e+00) + %328 = tail call contract noundef float @llvm.fma.f32(float %325, float %318, float %327) + %329 = and i32 %303, 2 + %330 = icmp eq i32 %329, 0 + %331 = select contract i1 %330, float %326, float %328 + %332 = and i32 %308, -2147483648 + %333 = bitcast float %331 to i32 + %334 = xor i32 %332, %333 + %335 = select contract i1 %330, float %328, float %326 + %336 = and i32 %309, -2147483648 + %337 = bitcast float %335 to i32 + %338 = xor i32 %336, %337 + %339 = getelementptr inbounds nuw i8, ptr %1, i64 192 + %.sroa.01059.0.copyload = load <4 x float>, ptr %339, align 16 + %340 = insertelement <4 x i32> poison, i32 %338, i64 0 + %341 = bitcast <4 x i32> %340 to <4 x float> + %342 = shufflevector <4 x float> %341, <4 x float> poison, <4 x i32> zeroinitializer + %343 = load <4 x float>, ptr %8, align 16 + %344 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %343, <4 x float> %342, <4 x float> %.sroa.01059.0.copyload) + %345 = getelementptr inbounds nuw i8, ptr %1, i64 160 + %346 = insertelement <4 x i32> poison, i32 %334, i64 0 + %347 = bitcast <4 x i32> %346 to <4 x float> + %348 = shufflevector <4 x float> %347, <4 x float> poison, <4 x i32> zeroinitializer + %349 = load <4 x float>, ptr %345, align 16 + %350 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %349, <4 x float> %348, <4 x float> %344) + %351 = getelementptr inbounds nuw i8, ptr %1, i64 176 + %352 = insertelement <4 x float> poison, float %299, i64 0 + %353 = shufflevector <4 x float> %352, <4 x float> poison, <4 x i32> zeroinitializer + %354 = load <4 x float>, ptr %351, align 16 + %355 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %354, <4 x float> %353, <4 x float> %350) + store <4 x float> %355, ptr %0, align 16 + %356 = load <4 x float>, ptr %2, align 16 + %357 = fsub contract <4 x float> %355, %356 + %358 = fmul contract <4 x float> %357, %357 + %shift1201 = shufflevector <4 x float> %358, <4 x float> poison, <4 x i32> + %359 = fadd contract <4 x float> %358, %shift1201 + %shift1202 = shufflevector <4 x float> %358, <4 x float> poison, <4 x i32> + %360 = fadd contract <4 x float> %shift1202, %359 + %361 = extractelement <4 x float> %360, i64 0 + %362 = tail call contract noundef float @llvm.sqrt.f32(float %361) + %363 = fdiv contract float 1.000000e+00, %362 + %364 = insertelement <4 x float> poison, float %363, i64 0 + %365 = shufflevector <4 x float> %364, <4 x float> poison, <4 x i32> zeroinitializer + %366 = fmul contract <4 x float> %357, %365 + store <4 x float> %366, ptr %12, align 16 + %367 = fmul contract <4 x float> %343, zeroinitializer + %368 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %349, <4 x float> zeroinitializer, <4 x float> %367) + %369 = fadd contract <4 x float> %354, %368 + %370 = fmul contract <4 x float> %369, %369 + %shift1203 = shufflevector <4 x float> %370, <4 x float> poison, <4 x i32> + %371 = fadd contract <4 x float> %370, %shift1203 + %shift1204 = shufflevector <4 x float> %370, <4 x float> poison, <4 x i32> + %372 = fadd contract <4 x float> %shift1204, %371 + %373 = extractelement <4 x float> %372, i64 0 + %374 = tail call contract noundef float @llvm.sqrt.f32(float %373) + %375 = fdiv contract float 1.000000e+00, %374 + %376 = insertelement <4 x float> poison, float %375, i64 0 + %377 = shufflevector <4 x float> %376, <4 x float> poison, <4 x i32> zeroinitializer + %378 = fmul contract <4 x float> %369, %377 + store <4 x float> %378, ptr %13, align 16 + %379 = getelementptr inbounds nuw i8, ptr %1, i64 208 + %.sroa.01109.0.copyload = load <4 x float>, ptr %379, align 16 + %380 = fmul contract <4 x float> %.sroa.01109.0.copyload, %342 + %381 = getelementptr inbounds nuw i8, ptr %1, i64 224 + %382 = load <4 x float>, ptr %381, align 16 + %383 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %382, <4 x float> %348, <4 x float> %380) + %384 = getelementptr inbounds nuw i8, ptr %1, i64 240 + %385 = load <4 x float>, ptr %384, align 16 + %386 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %385, <4 x float> zeroinitializer, <4 x float> %383) + %387 = fmul contract <4 x float> %386, %386 + %shift1205 = shufflevector <4 x float> %387, <4 x float> poison, <4 x i32> + %388 = fadd contract <4 x float> %387, %shift1205 + %shift1206 = shufflevector <4 x float> %387, <4 x float> poison, <4 x i32> + %389 = fadd contract <4 x float> %shift1206, %388 + %390 = extractelement <4 x float> %389, i64 0 + %391 = tail call contract noundef float @llvm.sqrt.f32(float %390) + %392 = fdiv contract float 1.000000e+00, %391 + %393 = insertelement <4 x float> poison, float %392, i64 0 + %394 = shufflevector <4 x float> %393, <4 x float> poison, <4 x i32> zeroinitializer + %395 = fmul contract <4 x float> %386, %394 + store <4 x float> %395, ptr %9, align 16 + %396 = fcmp contract ule float %157, 1.000000e+00 + %397 = select i1 %396, i32 0, i32 2 br label %.sink.split .sink.split: ; preds = %15, %138 - %.sink = phi i32 [ %398, %138 ], [ 1, %15 ] + %.sink = phi i32 [ %397, %138 ], [ 1, %15 ] store i32 %.sink, ptr %11, align 4 - br label %399 - -399: ; preds = %.sink.split, %136 - %400 = getelementptr inbounds nuw i8, ptr %0, i64 124 - %401 = getelementptr inbounds nuw i8, ptr %0, i64 104 - %402 = getelementptr inbounds nuw i8, ptr %0, i64 112 - store i32 %4, ptr %401, align 8 - store ptr %1, ptr %402, align 16 - store float 0x3F50624DE0000000, ptr %400, align 4 + br label %398 + +398: ; preds = %.sink.split, %136 + %399 = getelementptr inbounds nuw i8, ptr %0, i64 124 + %400 = getelementptr inbounds nuw i8, ptr %0, i64 104 + %401 = getelementptr inbounds nuw i8, ptr %0, i64 112 + store i32 %4, ptr %400, align 8 + store ptr %1, ptr %401, align 16 + store float 0x3F50624DE0000000, ptr %399, align 4 ret void } diff --git a/bench/mitsuba3/optimized/diffuse.cpp.ll b/bench/mitsuba3/optimized/diffuse.cpp.ll index 2b84dafed01..c0c7f1e73fd 100644 --- a/bench/mitsuba3/optimized/diffuse.cpp.ll +++ b/bench/mitsuba3/optimized/diffuse.cpp.ll @@ -557,7 +557,7 @@ _ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_ _ZNSt3__14pairIN7mitsuba11BSDFSample3IfN5drjit6MatrixINS1_8SpectrumIfLm4EEELm4EEEEES7_EC2B8ne190000IRS8_fTnNS_9enable_ifIXclsr10_CheckArgsE23__is_pair_constructibleIT_T0_EEEiE4typeELi0EEEOSD_OSE_.exit: ; preds = %37 call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %11) - br label %148 + br label %146 .critedge196: ; preds = %_ZNK7mitsuba11BSDFContext10is_enabledENS_9BSDFFlagsEj.exit %41 = load float, ptr %5, align 4 @@ -577,173 +577,172 @@ _ZNSt3__14pairIN7mitsuba11BSDFSample3IfN5drjit6MatrixINS1_8SpectrumIfLm4EEELm4EE %52 = fdiv contract float %51, %.sroa.speculated175 %53 = fsub contract float 0x3FF921FB60000000, %52 %spec.select = select i1 %50, float %53, float %52 - %54 = tail call float @llvm.fabs.f32(float %spec.select) - %55 = select contract i1 %narrow, float 0.000000e+00, float %54 - %56 = fmul contract float %55, 0x3FF45F3060000000 - %57 = fptosi float %56 to i32 - %58 = add nsw i32 %57, 1 - %59 = and i32 %58, -2 - %60 = sitofp i32 %59 to float - %61 = shl i32 %59, 29 - %62 = bitcast float %spec.select to i32 - %63 = select i1 %narrow, i32 0, i32 %62 - %64 = xor i32 %61, %63 - %65 = sub i32 0, %61 - %66 = fmul contract float %60, 0x3FE9200000000000 - %67 = fsub contract float %55, %66 - %68 = fmul contract float %60, 0x3F2FB40000000000 + %.1 = select i1 %narrow, float 0.000000e+00, float %spec.select + %54 = tail call contract noundef float @llvm.fabs.f32(float %.1) + %55 = fmul contract float %54, 0x3FF45F3060000000 + %56 = fptosi float %55 to i32 + %57 = add nsw i32 %56, 1 + %58 = and i32 %57, -2 + %59 = sitofp i32 %58 to float + %60 = shl i32 %58, 29 + %61 = bitcast float %.1 to i32 + %62 = xor i32 %60, %61 + %63 = sub i32 0, %60 + %64 = fmul contract float %59, 0x3FE9200000000000 + %65 = fsub contract float %54, %64 + %66 = fmul contract float %59, 0x3F2FB40000000000 + %67 = fsub contract float %65, %66 + %68 = fmul contract float %59, 0x3E64442D20000000 %69 = fsub contract float %67, %68 - %70 = fmul contract float %60, 0x3E64442D20000000 - %71 = fsub contract float %69, %70 - %72 = fmul contract float %71, %71 - %73 = fcmp contract oeq float %55, 0x7FF0000000000000 - %74 = select i1 %73, float 0xFFFFFFFFE0000000, float %72 - %75 = tail call contract noundef float @llvm.fma.f32(float %74, float 0x3F811073C0000000, float 0xBFC5555460000000) - %76 = fmul contract float %74, %74 - %77 = tail call contract noundef float @llvm.fma.f32(float %76, float 0xBF29943F20000000, float %75) - %78 = fmul contract float %74, %77 - %79 = tail call contract noundef float @llvm.fma.f32(float %74, float 0xBF56C0C340000000, float 0x3FA55554A0000000) - %80 = tail call contract noundef float @llvm.fma.f32(float %76, float 0x3EF99EB9C0000000, float %79) - %81 = fmul contract float %74, %80 - %82 = tail call contract noundef float @llvm.fma.f32(float %78, float %71, float %71) - %83 = tail call contract noundef float @llvm.fma.f32(float %74, float -5.000000e-01, float 1.000000e+00) - %84 = tail call contract noundef float @llvm.fma.f32(float %81, float %74, float %83) - %85 = and i32 %58, 2 - %86 = icmp eq i32 %85, 0 - %87 = select contract i1 %86, float %82, float %84 - %88 = and i32 %64, -2147483648 - %89 = bitcast float %87 to i32 - %90 = xor i32 %88, %89 - %91 = select contract i1 %86, float %84, float %82 - %92 = and i32 %65, -2147483648 - %93 = bitcast float %91 to i32 - %94 = xor i32 %92, %93 - %.sroa.0165.4.vec.extract = bitcast i32 %94 to float - %95 = fmul contract float %.sroa.speculated175, %.sroa.0165.4.vec.extract - %.sroa.0165.0.vec.extract = bitcast i32 %90 to float - %96 = fmul contract float %.sroa.speculated175, %.sroa.0165.0.vec.extract - %97 = fmul contract float %95, %95 - %98 = fmul contract float %96, %96 - %99 = fadd contract float %97, %98 - %100 = fsub contract float 1.000000e+00, %99 - %101 = fcmp contract olt float %100, 0.000000e+00 - %..i = select contract i1 %101, float 0.000000e+00, float %100 - %102 = tail call contract noundef float @llvm.sqrt.f32(float %..i) - %103 = insertelement <4 x float> , float %95, i64 0 - %104 = insertelement <4 x float> %103, float %96, i64 1 - %105 = insertelement <4 x float> %104, float %102, i64 2 - %106 = getelementptr inbounds nuw i8, ptr %1, i64 64 - %107 = load ptr, ptr %106, align 8 + %70 = fmul contract float %69, %69 + %71 = fcmp contract oeq float %54, 0x7FF0000000000000 + %72 = select i1 %71, float 0xFFFFFFFFE0000000, float %70 + %73 = tail call contract noundef float @llvm.fma.f32(float %72, float 0x3F811073C0000000, float 0xBFC5555460000000) + %74 = fmul contract float %72, %72 + %75 = tail call contract noundef float @llvm.fma.f32(float %74, float 0xBF29943F20000000, float %73) + %76 = fmul contract float %72, %75 + %77 = tail call contract noundef float @llvm.fma.f32(float %72, float 0xBF56C0C340000000, float 0x3FA55554A0000000) + %78 = tail call contract noundef float @llvm.fma.f32(float %74, float 0x3EF99EB9C0000000, float %77) + %79 = fmul contract float %72, %78 + %80 = tail call contract noundef float @llvm.fma.f32(float %76, float %69, float %69) + %81 = tail call contract noundef float @llvm.fma.f32(float %72, float -5.000000e-01, float 1.000000e+00) + %82 = tail call contract noundef float @llvm.fma.f32(float %79, float %72, float %81) + %83 = and i32 %57, 2 + %84 = icmp eq i32 %83, 0 + %85 = select contract i1 %84, float %80, float %82 + %86 = and i32 %62, -2147483648 + %87 = bitcast float %85 to i32 + %88 = xor i32 %86, %87 + %89 = select contract i1 %84, float %82, float %80 + %90 = and i32 %63, -2147483648 + %91 = bitcast float %89 to i32 + %92 = xor i32 %90, %91 + %.sroa.0165.4.vec.extract = bitcast i32 %92 to float + %93 = fmul contract float %.sroa.speculated175, %.sroa.0165.4.vec.extract + %.sroa.0165.0.vec.extract = bitcast i32 %88 to float + %94 = fmul contract float %.sroa.speculated175, %.sroa.0165.0.vec.extract + %95 = fmul contract float %93, %93 + %96 = fmul contract float %94, %94 + %97 = fadd contract float %95, %96 + %98 = fsub contract float 1.000000e+00, %97 + %99 = fcmp contract olt float %98, 0.000000e+00 + %..i = select contract i1 %99, float 0.000000e+00, float %98 + %100 = tail call contract noundef float @llvm.sqrt.f32(float %..i) + %101 = insertelement <4 x float> , float %93, i64 0 + %102 = insertelement <4 x float> %101, float %94, i64 1 + %103 = insertelement <4 x float> %102, float %100, i64 2 + %104 = getelementptr inbounds nuw i8, ptr %1, i64 64 + %105 = load ptr, ptr %104, align 8 + %106 = load ptr, ptr %105, align 8 + %107 = getelementptr inbounds nuw i8, ptr %106, i64 72 %108 = load ptr, ptr %107, align 8 - %109 = getelementptr inbounds nuw i8, ptr %108, i64 72 - %110 = load ptr, ptr %109, align 8 - %111 = tail call <4 x float> %110(ptr noundef nonnull align 8 dereferenceable(40) %107, ptr noundef nonnull align 16 dereferenceable(240) %3, i1 noundef zeroext true) + %109 = tail call <4 x float> %108(ptr noundef nonnull align 8 dereferenceable(40) %105, ptr noundef nonnull align 16 dereferenceable(240) %3, i1 noundef zeroext true) store <4 x float> zeroinitializer, ptr %12, align 16 call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %9) - br label %112 - -112: ; preds = %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i, %.critedge196 - %.012.i = phi i64 [ 0, %.critedge196 ], [ %121, %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i ] - %113 = getelementptr inbounds nuw float, ptr %12, i64 %.012.i - %114 = load float, ptr %113, align 4 - %115 = insertelement <4 x float> poison, float %114, i64 0 - %116 = shufflevector <4 x float> %115, <4 x float> poison, <4 x i32> zeroinitializer - br label %117 - -117: ; preds = %117, %112 - %.05.i.i.i = phi i64 [ 0, %112 ], [ %119, %117 ] - %118 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %9, i64 0, i64 %.05.i.i.i - store <4 x float> %116, ptr %118, align 16 - %119 = add nuw nsw i64 %.05.i.i.i, 1 - %exitcond.not.i.i.i = icmp eq i64 %119, 4 - br i1 %exitcond.not.i.i.i, label %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i, label %117, !llvm.loop !7 - -_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i: ; preds = %117 - %120 = getelementptr inbounds nuw [4 x %"struct.drjit::Array"], ptr %15, i64 0, i64 %.012.i - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %120, ptr noundef nonnull align 16 dereferenceable(64) %9, i64 64, i1 false) - %121 = add nuw nsw i64 %.012.i, 1 - %exitcond.not.i135 = icmp eq i64 %121, 4 - br i1 %exitcond.not.i135, label %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit, label %112, !llvm.loop !9 + br label %110 + +110: ; preds = %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i, %.critedge196 + %.012.i = phi i64 [ 0, %.critedge196 ], [ %119, %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i ] + %111 = getelementptr inbounds nuw float, ptr %12, i64 %.012.i + %112 = load float, ptr %111, align 4 + %113 = insertelement <4 x float> poison, float %112, i64 0 + %114 = shufflevector <4 x float> %113, <4 x float> poison, <4 x i32> zeroinitializer + br label %115 + +115: ; preds = %115, %110 + %.05.i.i.i = phi i64 [ 0, %110 ], [ %117, %115 ] + %116 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %9, i64 0, i64 %.05.i.i.i + store <4 x float> %114, ptr %116, align 16 + %117 = add nuw nsw i64 %.05.i.i.i, 1 + %exitcond.not.i.i.i = icmp eq i64 %117, 4 + br i1 %exitcond.not.i.i.i, label %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i, label %115, !llvm.loop !7 + +_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i: ; preds = %115 + %118 = getelementptr inbounds nuw [4 x %"struct.drjit::Array"], ptr %15, i64 0, i64 %.012.i + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %118, ptr noundef nonnull align 16 dereferenceable(64) %9, i64 64, i1 false) + %119 = add nuw nsw i64 %.012.i, 1 + %exitcond.not.i135 = icmp eq i64 %119, 4 + br i1 %exitcond.not.i135, label %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit, label %110, !llvm.loop !9 _ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit: ; preds = %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %9) - br label %122 - -122: ; preds = %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit, %122 - %.0197 = phi i64 [ 0, %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit ], [ %125, %122 ] - %123 = getelementptr inbounds nuw [4 x %"struct.drjit::Array"], ptr %15, i64 0, i64 %.0197 - %124 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %123, i64 0, i64 %.0197 - store <4 x float> %111, ptr %124, align 16 - %125 = add nuw nsw i64 %.0197, 1 - %exitcond.not = icmp eq i64 %125, 4 - br i1 %exitcond.not, label %126, label %122, !llvm.loop !11 - -126: ; preds = %122 - %127 = fmul contract float %102, 0x3FD45F3060000000 + br label %120 + +120: ; preds = %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit, %120 + %.0197 = phi i64 [ 0, %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit ], [ %123, %120 ] + %121 = getelementptr inbounds nuw [4 x %"struct.drjit::Array"], ptr %15, i64 0, i64 %.0197 + %122 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %121, i64 0, i64 %.0197 + store <4 x float> %109, ptr %122, align 16 + %123 = add nuw nsw i64 %.0197, 1 + %exitcond.not = icmp eq i64 %123, 4 + br i1 %exitcond.not, label %124, label %120, !llvm.loop !11 + +124: ; preds = %120 + %125 = fmul contract float %100, 0x3FD45F3060000000 %.sroa.0.i.16.i.16..sroa_idx = getelementptr inbounds nuw i8, ptr %.sroa.0.i, i64 16 call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(240) %.sroa.0.i.16.i.16..sroa_idx, i8 0, i64 240, i1 false) call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %.sroa.0.i, ptr noundef nonnull align 16 dereferenceable(256) %15, i64 16, i1 false) - %128 = fcmp contract ogt float %127, 0.000000e+00 - %.sroa.0.0.isplat.i.i.i = select i1 %128, i32 252645135, i32 0 - br label %129 - -129: ; preds = %129, %126 - %.04.i.i.i = phi i64 [ 0, %126 ], [ %131, %129 ] - %130 = getelementptr inbounds nuw [4 x %"struct.drjit::Mask.48"], ptr %13, i64 0, i64 %.04.i.i.i - store i32 %.sroa.0.0.isplat.i.i.i, ptr %130, align 1 - %131 = add nuw nsw i64 %.04.i.i.i, 1 - %exitcond.not.i.i.i136 = icmp eq i64 %131, 4 - br i1 %exitcond.not.i.i.i136, label %_ZN5drjit4MaskINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_8MaskBaseIS4_Lm4ES5_EEIRKbNS6_IS4_Lm4ES5_EETnNSt3__19enable_ifIXaasr3stdE11is_scalar_vIu7__decayIT_EEntsrT0_14IsOldStyleMaskEiE4typeELi0EEEOSC_.exit, label %129, !llvm.loop !12 - -_ZN5drjit4MaskINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_8MaskBaseIS4_Lm4ES5_EEIRKbNS6_IS4_Lm4ES5_EETnNSt3__19enable_ifIXaasr3stdE11is_scalar_vIu7__decayIT_EEntsrT0_14IsOldStyleMaskEiE4typeELi0EEEOSC_.exit: ; preds = %129 + %126 = fcmp contract ogt float %125, 0.000000e+00 + %.sroa.0.0.isplat.i.i.i = select i1 %126, i32 252645135, i32 0 + br label %127 + +127: ; preds = %127, %124 + %.04.i.i.i = phi i64 [ 0, %124 ], [ %129, %127 ] + %128 = getelementptr inbounds nuw [4 x %"struct.drjit::Mask.48"], ptr %13, i64 0, i64 %.04.i.i.i + store i32 %.sroa.0.0.isplat.i.i.i, ptr %128, align 1 + %129 = add nuw nsw i64 %.04.i.i.i, 1 + %exitcond.not.i.i.i136 = icmp eq i64 %129, 4 + br i1 %exitcond.not.i.i.i136, label %_ZN5drjit4MaskINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_8MaskBaseIS4_Lm4ES5_EEIRKbNS6_IS4_Lm4ES5_EETnNSt3__19enable_ifIXaasr3stdE11is_scalar_vIu7__decayIT_EEntsrT0_14IsOldStyleMaskEiE4typeELi0EEEOSC_.exit, label %127, !llvm.loop !12 + +_ZN5drjit4MaskINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_8MaskBaseIS4_Lm4ES5_EEIRKbNS6_IS4_Lm4ES5_EETnNSt3__19enable_ifIXaasr3stdE11is_scalar_vIu7__decayIT_EEntsrT0_14IsOldStyleMaskEiE4typeELi0EEEOSC_.exit: ; preds = %127 call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %8) - br label %132 + br label %130 -132: ; preds = %_ZN5drjit6detail4and_INS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEENS_4MaskIS5_Lm4EEETnNSt3__19enable_ifIX14is_array_any_vIT_T0_EEiE4typeELi0EEEDaRKSB_RKSC_.exit.i, %_ZN5drjit4MaskINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_8MaskBaseIS4_Lm4ES5_EEIRKbNS6_IS4_Lm4ES5_EETnNSt3__19enable_ifIXaasr3stdE11is_scalar_vIu7__decayIT_EEntsrT0_14IsOldStyleMaskEiE4typeELi0EEEOSC_.exit - %.028.i = phi i64 [ 0, %_ZN5drjit4MaskINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_8MaskBaseIS4_Lm4ES5_EEIRKbNS6_IS4_Lm4ES5_EETnNSt3__19enable_ifIXaasr3stdE11is_scalar_vIu7__decayIT_EEntsrT0_14IsOldStyleMaskEiE4typeELi0EEEOSC_.exit ], [ %145, %_ZN5drjit6detail4and_INS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEENS_4MaskIS5_Lm4EEETnNSt3__19enable_ifIX14is_array_any_vIT_T0_EEiE4typeELi0EEEDaRKSB_RKSC_.exit.i ] - %133 = getelementptr inbounds nuw [4 x %"struct.drjit::Array"], ptr %.sroa.0.i, i64 0, i64 %.028.i - %134 = getelementptr inbounds nuw [4 x %"struct.drjit::Mask.48"], ptr %13, i64 0, i64 %.028.i +130: ; preds = %_ZN5drjit6detail4and_INS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEENS_4MaskIS5_Lm4EEETnNSt3__19enable_ifIX14is_array_any_vIT_T0_EEiE4typeELi0EEEDaRKSB_RKSC_.exit.i, %_ZN5drjit4MaskINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_8MaskBaseIS4_Lm4ES5_EEIRKbNS6_IS4_Lm4ES5_EETnNSt3__19enable_ifIXaasr3stdE11is_scalar_vIu7__decayIT_EEntsrT0_14IsOldStyleMaskEiE4typeELi0EEEOSC_.exit + %.028.i = phi i64 [ 0, %_ZN5drjit4MaskINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_8MaskBaseIS4_Lm4ES5_EEIRKbNS6_IS4_Lm4ES5_EETnNSt3__19enable_ifIXaasr3stdE11is_scalar_vIu7__decayIT_EEntsrT0_14IsOldStyleMaskEiE4typeELi0EEEOSC_.exit ], [ %143, %_ZN5drjit6detail4and_INS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEENS_4MaskIS5_Lm4EEETnNSt3__19enable_ifIX14is_array_any_vIT_T0_EEiE4typeELi0EEEDaRKSB_RKSC_.exit.i ] + %131 = getelementptr inbounds nuw [4 x %"struct.drjit::Array"], ptr %.sroa.0.i, i64 0, i64 %.028.i + %132 = getelementptr inbounds nuw [4 x %"struct.drjit::Mask.48"], ptr %13, i64 0, i64 %.028.i tail call void @llvm.experimental.noalias.scope.decl(metadata !13) tail call void @llvm.experimental.noalias.scope.decl(metadata !16) - br label %135 - -135: ; preds = %135, %132 - %.028.i.i.i = phi i64 [ 0, %132 ], [ %143, %135 ] - %136 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %133, i64 0, i64 %.028.i.i.i - %137 = getelementptr inbounds nuw [4 x %"struct.drjit::Mask.53"], ptr %134, i64 0, i64 %.028.i.i.i - %138 = load <8 x i1>, ptr %137, align 1, !noalias !19 - %139 = load <4 x float>, ptr %136, align 16 - %140 = shufflevector <8 x i1> %138, <8 x i1> poison, <4 x i32> - %141 = select contract <4 x i1> %140, <4 x float> %139, <4 x float> zeroinitializer - %142 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %8, i64 0, i64 %.028.i.i.i - store <4 x float> %141, ptr %142, align 16, !alias.scope !22, !noalias !23 - %143 = add nuw nsw i64 %.028.i.i.i, 1 - %exitcond.not.i.i.i137 = icmp eq i64 %143, 4 - br i1 %exitcond.not.i.i.i137, label %_ZN5drjit6detail4and_INS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEENS_4MaskIS5_Lm4EEETnNSt3__19enable_ifIX14is_array_any_vIT_T0_EEiE4typeELi0EEEDaRKSB_RKSC_.exit.i, label %135, !llvm.loop !24 - -_ZN5drjit6detail4and_INS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEENS_4MaskIS5_Lm4EEETnNSt3__19enable_ifIX14is_array_any_vIT_T0_EEiE4typeELi0EEEDaRKSB_RKSC_.exit.i: ; preds = %135 - %144 = getelementptr inbounds nuw [4 x %"struct.drjit::Array"], ptr %14, i64 0, i64 %.028.i - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %144, ptr noundef nonnull align 16 dereferenceable(64) %8, i64 64, i1 false) - %145 = add nuw nsw i64 %.028.i, 1 - %exitcond.not.i138 = icmp eq i64 %145, 4 - br i1 %exitcond.not.i138, label %146, label %132, !llvm.loop !25 - -146: ; preds = %_ZN5drjit6detail4and_INS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEENS_4MaskIS5_Lm4EEETnNSt3__19enable_ifIX14is_array_any_vIT_T0_EEiE4typeELi0EEEDaRKSB_RKSC_.exit.i + br label %133 + +133: ; preds = %133, %130 + %.028.i.i.i = phi i64 [ 0, %130 ], [ %141, %133 ] + %134 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %131, i64 0, i64 %.028.i.i.i + %135 = getelementptr inbounds nuw [4 x %"struct.drjit::Mask.53"], ptr %132, i64 0, i64 %.028.i.i.i + %136 = load <8 x i1>, ptr %135, align 1, !noalias !19 + %137 = load <4 x float>, ptr %134, align 16 + %138 = shufflevector <8 x i1> %136, <8 x i1> poison, <4 x i32> + %139 = select contract <4 x i1> %138, <4 x float> %137, <4 x float> zeroinitializer + %140 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %8, i64 0, i64 %.028.i.i.i + store <4 x float> %139, ptr %140, align 16, !alias.scope !22, !noalias !23 + %141 = add nuw nsw i64 %.028.i.i.i, 1 + %exitcond.not.i.i.i137 = icmp eq i64 %141, 4 + br i1 %exitcond.not.i.i.i137, label %_ZN5drjit6detail4and_INS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEENS_4MaskIS5_Lm4EEETnNSt3__19enable_ifIX14is_array_any_vIT_T0_EEiE4typeELi0EEEDaRKSB_RKSC_.exit.i, label %133, !llvm.loop !24 + +_ZN5drjit6detail4and_INS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEENS_4MaskIS5_Lm4EEETnNSt3__19enable_ifIX14is_array_any_vIT_T0_EEiE4typeELi0EEEDaRKSB_RKSC_.exit.i: ; preds = %133 + %142 = getelementptr inbounds nuw [4 x %"struct.drjit::Array"], ptr %14, i64 0, i64 %.028.i + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %142, ptr noundef nonnull align 16 dereferenceable(64) %8, i64 64, i1 false) + %143 = add nuw nsw i64 %.028.i, 1 + %exitcond.not.i138 = icmp eq i64 %143, 4 + br i1 %exitcond.not.i138, label %144, label %130, !llvm.loop !25 + +144: ; preds = %_ZN5drjit6detail4and_INS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEENS_4MaskIS5_Lm4EEETnNSt3__19enable_ifIX14is_array_any_vIT_T0_EEiE4typeELi0EEEDaRKSB_RKSC_.exit.i call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %8) - store <4 x float> %105, ptr %0, align 16 + store <4 x float> %103, ptr %0, align 16 %.sroa.5.0..sroa_idx140 = getelementptr inbounds nuw i8, ptr %0, i64 16 - store float %127, ptr %.sroa.5.0..sroa_idx140, align 16 + store float %125, ptr %.sroa.5.0..sroa_idx140, align 16 %.sroa.8.0..sroa_idx142 = getelementptr inbounds nuw i8, ptr %0, i64 20 store float 1.000000e+00, ptr %.sroa.8.0..sroa_idx142, align 4 %.sroa.10.0..sroa_idx144 = getelementptr inbounds nuw i8, ptr %0, i64 24 store i32 2, ptr %.sroa.10.0..sroa_idx144, align 8 %.sroa.12.0..sroa_idx146 = getelementptr inbounds nuw i8, ptr %0, i64 28 store i32 0, ptr %.sroa.12.0..sroa_idx146, align 4 - %147 = getelementptr inbounds nuw i8, ptr %0, i64 32 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %147, ptr noundef nonnull align 16 dereferenceable(256) %14, i64 256, i1 false) - br label %148 + %145 = getelementptr inbounds nuw i8, ptr %0, i64 32 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %145, ptr noundef nonnull align 16 dereferenceable(256) %14, i64 256, i1 false) + br label %146 -148: ; preds = %_ZNSt3__14pairIN7mitsuba11BSDFSample3IfN5drjit6MatrixINS1_8SpectrumIfLm4EEELm4EEEEES7_EC2B8ne190000IRS8_fTnNS_9enable_ifIXclsr10_CheckArgsE23__is_pair_constructibleIT_T0_EEEiE4typeELi0EEEOSD_OSE_.exit, %146 +146: ; preds = %_ZNSt3__14pairIN7mitsuba11BSDFSample3IfN5drjit6MatrixINS1_8SpectrumIfLm4EEELm4EEEEES7_EC2B8ne190000IRS8_fTnNS_9enable_ifIXclsr10_CheckArgsE23__is_pair_constructibleIT_T0_EEEiE4typeELi0EEEOSD_OSE_.exit, %144 ret void } diff --git a/bench/mitsuba3/optimized/directional.cpp.ll b/bench/mitsuba3/optimized/directional.cpp.ll index 5f5939b2708..46f7ccdd1f8 100644 --- a/bench/mitsuba3/optimized/directional.cpp.ll +++ b/bench/mitsuba3/optimized/directional.cpp.ll @@ -876,269 +876,268 @@ define weak_odr void @_ZNK7mitsuba18DirectionalEmitterIfN5drjit6MatrixINS_8Spect %33 = fdiv contract float %32, %.sroa.speculated381 %34 = fsub contract float 0x3FF921FB60000000, %33 %spec.select = select i1 %31, float %34, float %33 - %35 = tail call float @llvm.fabs.f32(float %spec.select) - %36 = select contract i1 %narrow, float 0.000000e+00, float %35 - %37 = fmul contract float %36, 0x3FF45F3060000000 - %38 = fptosi float %37 to i32 - %39 = add nsw i32 %38, 1 - %40 = and i32 %39, -2 - %41 = sitofp i32 %40 to float - %42 = shl i32 %40, 29 - %43 = bitcast float %spec.select to i32 - %44 = select i1 %narrow, i32 0, i32 %43 - %45 = xor i32 %42, %44 - %46 = sub i32 0, %42 - %47 = fmul contract float %41, 0x3FE9200000000000 - %48 = fsub contract float %36, %47 - %49 = fmul contract float %41, 0x3F2FB40000000000 + %.1 = select i1 %narrow, float 0.000000e+00, float %spec.select + %35 = tail call contract noundef float @llvm.fabs.f32(float %.1) + %36 = fmul contract float %35, 0x3FF45F3060000000 + %37 = fptosi float %36 to i32 + %38 = add nsw i32 %37, 1 + %39 = and i32 %38, -2 + %40 = sitofp i32 %39 to float + %41 = shl i32 %39, 29 + %42 = bitcast float %.1 to i32 + %43 = xor i32 %41, %42 + %44 = sub i32 0, %41 + %45 = fmul contract float %40, 0x3FE9200000000000 + %46 = fsub contract float %35, %45 + %47 = fmul contract float %40, 0x3F2FB40000000000 + %48 = fsub contract float %46, %47 + %49 = fmul contract float %40, 0x3E64442D20000000 %50 = fsub contract float %48, %49 - %51 = fmul contract float %41, 0x3E64442D20000000 - %52 = fsub contract float %50, %51 - %53 = fmul contract float %52, %52 - %54 = fcmp contract oeq float %36, 0x7FF0000000000000 - %55 = select i1 %54, float 0xFFFFFFFFE0000000, float %53 - %56 = tail call contract noundef float @llvm.fma.f32(float %55, float 0x3F811073C0000000, float 0xBFC5555460000000) - %57 = fmul contract float %55, %55 - %58 = tail call contract noundef float @llvm.fma.f32(float %57, float 0xBF29943F20000000, float %56) - %59 = fmul contract float %55, %58 - %60 = tail call contract noundef float @llvm.fma.f32(float %55, float 0xBF56C0C340000000, float 0x3FA55554A0000000) - %61 = tail call contract noundef float @llvm.fma.f32(float %57, float 0x3EF99EB9C0000000, float %60) - %62 = fmul contract float %55, %61 - %63 = tail call contract noundef float @llvm.fma.f32(float %59, float %52, float %52) - %64 = tail call contract noundef float @llvm.fma.f32(float %55, float -5.000000e-01, float 1.000000e+00) - %65 = tail call contract noundef float @llvm.fma.f32(float %62, float %55, float %64) - %66 = and i32 %39, 2 - %67 = icmp eq i32 %66, 0 - %68 = select contract i1 %67, float %63, float %65 - %69 = and i32 %45, -2147483648 - %70 = bitcast float %68 to i32 - %71 = xor i32 %69, %70 - %72 = select contract i1 %67, float %65, float %63 - %73 = and i32 %46, -2147483648 - %74 = bitcast float %72 to i32 - %75 = xor i32 %73, %74 - %.sroa.0372.4.vec.extract = bitcast i32 %75 to float - %.sroa.0372.0.vec.extract = bitcast i32 %71 to float - %76 = getelementptr inbounds nuw i8, ptr %1, i64 16 - %.sroa.0436.0.copyload = load <4 x float>, ptr %76, align 16 + %51 = fmul contract float %50, %50 + %52 = fcmp contract oeq float %35, 0x7FF0000000000000 + %53 = select i1 %52, float 0xFFFFFFFFE0000000, float %51 + %54 = tail call contract noundef float @llvm.fma.f32(float %53, float 0x3F811073C0000000, float 0xBFC5555460000000) + %55 = fmul contract float %53, %53 + %56 = tail call contract noundef float @llvm.fma.f32(float %55, float 0xBF29943F20000000, float %54) + %57 = fmul contract float %53, %56 + %58 = tail call contract noundef float @llvm.fma.f32(float %53, float 0xBF56C0C340000000, float 0x3FA55554A0000000) + %59 = tail call contract noundef float @llvm.fma.f32(float %55, float 0x3EF99EB9C0000000, float %58) + %60 = fmul contract float %53, %59 + %61 = tail call contract noundef float @llvm.fma.f32(float %57, float %50, float %50) + %62 = tail call contract noundef float @llvm.fma.f32(float %53, float -5.000000e-01, float 1.000000e+00) + %63 = tail call contract noundef float @llvm.fma.f32(float %60, float %53, float %62) + %64 = and i32 %38, 2 + %65 = icmp eq i32 %64, 0 + %66 = select contract i1 %65, float %61, float %63 + %67 = and i32 %43, -2147483648 + %68 = bitcast float %66 to i32 + %69 = xor i32 %67, %68 + %70 = select contract i1 %65, float %63, float %61 + %71 = and i32 %44, -2147483648 + %72 = bitcast float %70 to i32 + %73 = xor i32 %71, %72 + %.sroa.0372.4.vec.extract = bitcast i32 %73 to float + %.sroa.0372.0.vec.extract = bitcast i32 %69 to float + %74 = getelementptr inbounds nuw i8, ptr %1, i64 16 + %.sroa.0436.0.copyload = load <4 x float>, ptr %74, align 16 %.sroa.2.0..sroa_idx437 = getelementptr inbounds nuw i8, ptr %1, i64 32 %.sroa.2.0.copyload = load <4 x float>, ptr %.sroa.2.0..sroa_idx437, align 16 %.sroa.4.0..sroa_idx439 = getelementptr inbounds nuw i8, ptr %1, i64 48 %.sroa.4.0.copyload = load <4 x float>, ptr %.sroa.4.0..sroa_idx439, align 16 - %77 = fmul contract <4 x float> %.sroa.0436.0.copyload, zeroinitializer - %78 = fmul contract float %.sroa.speculated381, %.sroa.0372.4.vec.extract - %79 = fmul contract float %.sroa.speculated381, %.sroa.0372.0.vec.extract - %80 = insertelement <4 x float> poison, float %78, i64 0 - %81 = shufflevector <4 x float> %80, <4 x float> poison, <4 x i32> zeroinitializer - %82 = fmul contract <4 x float> %.sroa.0436.0.copyload, %81 - %83 = insertelement <4 x float> poison, float %79, i64 0 - %84 = shufflevector <4 x float> %83, <4 x float> poison, <4 x i32> zeroinitializer - %85 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %.sroa.2.0.copyload, <4 x float> %84, <4 x float> %82) - %86 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %.sroa.4.0.copyload, <4 x float> zeroinitializer, <4 x float> %85) - %87 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %.sroa.2.0.copyload, <4 x float> zeroinitializer, <4 x float> %77) - %88 = fadd contract <4 x float> %.sroa.4.0.copyload, %87 - %89 = getelementptr inbounds nuw i8, ptr %1, i64 224 - %90 = fsub contract <4 x float> %86, %88 - %91 = getelementptr inbounds nuw i8, ptr %1, i64 240 - %92 = load <4 x float>, ptr %91, align 16 - %93 = shufflevector <4 x float> %92, <4 x float> poison, <4 x i32> zeroinitializer - %94 = fmul contract <4 x float> %90, %93 - %95 = load <4 x float>, ptr %89, align 16 - %96 = fadd contract <4 x float> %95, %94 - %97 = getelementptr inbounds nuw i8, ptr %20, i64 232 - %98 = getelementptr inbounds nuw i8, ptr %20, i64 4 - %99 = getelementptr inbounds nuw i8, ptr %20, i64 16 - %100 = getelementptr inbounds nuw i8, ptr %20, i64 32 - %101 = getelementptr inbounds nuw i8, ptr %20, i64 72 - store ptr null, ptr %97, align 8 + %75 = fmul contract <4 x float> %.sroa.0436.0.copyload, zeroinitializer + %76 = fmul contract float %.sroa.speculated381, %.sroa.0372.4.vec.extract + %77 = fmul contract float %.sroa.speculated381, %.sroa.0372.0.vec.extract + %78 = insertelement <4 x float> poison, float %76, i64 0 + %79 = shufflevector <4 x float> %78, <4 x float> poison, <4 x i32> zeroinitializer + %80 = fmul contract <4 x float> %.sroa.0436.0.copyload, %79 + %81 = insertelement <4 x float> poison, float %77, i64 0 + %82 = shufflevector <4 x float> %81, <4 x float> poison, <4 x i32> zeroinitializer + %83 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %.sroa.2.0.copyload, <4 x float> %82, <4 x float> %80) + %84 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %.sroa.4.0.copyload, <4 x float> zeroinitializer, <4 x float> %83) + %85 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %.sroa.2.0.copyload, <4 x float> zeroinitializer, <4 x float> %75) + %86 = fadd contract <4 x float> %.sroa.4.0.copyload, %85 + %87 = getelementptr inbounds nuw i8, ptr %1, i64 224 + %88 = fsub contract <4 x float> %84, %86 + %89 = getelementptr inbounds nuw i8, ptr %1, i64 240 + %90 = load <4 x float>, ptr %89, align 16 + %91 = shufflevector <4 x float> %90, <4 x float> poison, <4 x i32> zeroinitializer + %92 = fmul contract <4 x float> %88, %91 + %93 = load <4 x float>, ptr %87, align 16 + %94 = fadd contract <4 x float> %93, %92 + %95 = getelementptr inbounds nuw i8, ptr %20, i64 232 + %96 = getelementptr inbounds nuw i8, ptr %20, i64 4 + %97 = getelementptr inbounds nuw i8, ptr %20, i64 16 + %98 = getelementptr inbounds nuw i8, ptr %20, i64 32 + %99 = getelementptr inbounds nuw i8, ptr %20, i64 72 + store ptr null, ptr %95, align 8 store i32 0, ptr %20, align 16 - call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(212) %99, i8 0, i64 212, i1 false) - store float %2, ptr %98, align 4 - store <4 x float> %96, ptr %100, align 16 - %102 = load i64, ptr %4, align 4 - store i64 %102, ptr %101, align 8 + call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(212) %97, i8 0, i64 212, i1 false) + store float %2, ptr %96, align 4 + store <4 x float> %94, ptr %98, align 16 + %100 = load i64, ptr %4, align 4 + store i64 %100, ptr %99, align 8 call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %18) call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %19) - %103 = getelementptr inbounds nuw i8, ptr %1, i64 208 - %104 = load ptr, ptr %103, align 16, !noalias !21 - %105 = insertelement <4 x float> poison, float %3, i64 0 - %106 = shufflevector <4 x float> %105, <4 x float> poison, <4 x i32> zeroinitializer - %107 = fadd contract <4 x float> %106, - %108 = fcmp contract ogt <4 x float> %107, splat (float 1.000000e+00) - %109 = fadd contract <4 x float> %107, splat (float -1.000000e+00) - %110 = select contract <4 x i1> %108, <4 x float> %109, <4 x float> %107 - store <4 x float> %110, ptr %19, align 16, !noalias !21 - %111 = load ptr, ptr %104, align 8, !noalias !21 - %112 = getelementptr inbounds nuw i8, ptr %111, i64 80 - %113 = load ptr, ptr %112, align 8, !noalias !21 - call void %113(ptr dead_on_unwind nonnull writable sret(%"struct.std::__1::pair.93") align 16 %18, ptr noundef nonnull align 8 dereferenceable(40) %104, ptr noundef nonnull align 16 dereferenceable(240) %20, ptr noundef nonnull align 16 dereferenceable(16) %19, i1 noundef zeroext true) + %101 = getelementptr inbounds nuw i8, ptr %1, i64 208 + %102 = load ptr, ptr %101, align 16, !noalias !21 + %103 = insertelement <4 x float> poison, float %3, i64 0 + %104 = shufflevector <4 x float> %103, <4 x float> poison, <4 x i32> zeroinitializer + %105 = fadd contract <4 x float> %104, + %106 = fcmp contract ogt <4 x float> %105, splat (float 1.000000e+00) + %107 = fadd contract <4 x float> %105, splat (float -1.000000e+00) + %108 = select contract <4 x i1> %106, <4 x float> %107, <4 x float> %105 + store <4 x float> %108, ptr %19, align 16, !noalias !21 + %109 = load ptr, ptr %102, align 8, !noalias !21 + %110 = getelementptr inbounds nuw i8, ptr %109, i64 80 + %111 = load ptr, ptr %110, align 8, !noalias !21 + call void %111(ptr dead_on_unwind nonnull writable sret(%"struct.std::__1::pair.93") align 16 %18, ptr noundef nonnull align 8 dereferenceable(40) %102, ptr noundef nonnull align 16 dereferenceable(240) %20, ptr noundef nonnull align 16 dereferenceable(16) %19, i1 noundef zeroext true) call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %17), !noalias !21 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(272) %21, ptr noundef nonnull align 16 dereferenceable(32) %18, i64 16, i1 false) - %114 = getelementptr inbounds nuw i8, ptr %21, i64 16 + %112 = getelementptr inbounds nuw i8, ptr %21, i64 16 store <4 x float> zeroinitializer, ptr %17, align 16, !noalias !21 call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %16), !noalias !21 - br label %115 - -115: ; preds = %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i.i.i, %.noexc - %.012.i.i.i = phi i64 [ 0, %.noexc ], [ %124, %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i.i.i ] - %116 = getelementptr inbounds nuw float, ptr %17, i64 %.012.i.i.i - %117 = load float, ptr %116, align 4, !noalias !21 - %118 = insertelement <4 x float> poison, float %117, i64 0 - %119 = shufflevector <4 x float> %118, <4 x float> poison, <4 x i32> zeroinitializer - br label %120 - -120: ; preds = %120, %115 - %.05.i.i.i.i.i = phi i64 [ 0, %115 ], [ %122, %120 ] - %121 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %16, i64 0, i64 %.05.i.i.i.i.i - store <4 x float> %119, ptr %121, align 16, !noalias !21 - %122 = add nuw nsw i64 %.05.i.i.i.i.i, 1 - %exitcond.not.i.i.i.i.i = icmp eq i64 %122, 4 - br i1 %exitcond.not.i.i.i.i.i, label %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i.i.i, label %120, !llvm.loop !18 - -_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i.i.i: ; preds = %120 - %123 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %114, i64 0, i64 %.012.i.i.i - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %123, ptr noundef nonnull align 16 dereferenceable(64) %16, i64 64, i1 false) - %124 = add nuw nsw i64 %.012.i.i.i, 1 - %exitcond.not.i.i.i = icmp eq i64 %124, 4 - br i1 %exitcond.not.i.i.i, label %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit.i.i, label %115, !llvm.loop !19 + br label %113 + +113: ; preds = %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i.i.i, %.noexc + %.012.i.i.i = phi i64 [ 0, %.noexc ], [ %122, %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i.i.i ] + %114 = getelementptr inbounds nuw float, ptr %17, i64 %.012.i.i.i + %115 = load float, ptr %114, align 4, !noalias !21 + %116 = insertelement <4 x float> poison, float %115, i64 0 + %117 = shufflevector <4 x float> %116, <4 x float> poison, <4 x i32> zeroinitializer + br label %118 + +118: ; preds = %118, %113 + %.05.i.i.i.i.i = phi i64 [ 0, %113 ], [ %120, %118 ] + %119 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %16, i64 0, i64 %.05.i.i.i.i.i + store <4 x float> %117, ptr %119, align 16, !noalias !21 + %120 = add nuw nsw i64 %.05.i.i.i.i.i, 1 + %exitcond.not.i.i.i.i.i = icmp eq i64 %120, 4 + br i1 %exitcond.not.i.i.i.i.i, label %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i.i.i, label %118, !llvm.loop !18 + +_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i.i.i: ; preds = %118 + %121 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %112, i64 0, i64 %.012.i.i.i + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %121, ptr noundef nonnull align 16 dereferenceable(64) %16, i64 64, i1 false) + %122 = add nuw nsw i64 %.012.i.i.i, 1 + %exitcond.not.i.i.i = icmp eq i64 %122, 4 + br i1 %exitcond.not.i.i.i, label %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit.i.i, label %113, !llvm.loop !19 _ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit.i.i: ; preds = %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i.i.i - %125 = getelementptr inbounds nuw i8, ptr %18, i64 16 + %123 = getelementptr inbounds nuw i8, ptr %18, i64 16 call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %16), !noalias !21 - br label %126 - -126: ; preds = %126, %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit.i.i - %.018.i.i = phi i64 [ 0, %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit.i.i ], [ %129, %126 ] - %127 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %114, i64 0, i64 %.018.i.i - %128 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %127, i64 0, i64 %.018.i.i - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %128, ptr noundef nonnull align 16 dereferenceable(16) %125, i64 16, i1 false) - %129 = add nuw nsw i64 %.018.i.i, 1 - %exitcond.not.i.i = icmp eq i64 %129, 4 - br i1 %exitcond.not.i.i, label %_ZN5drjit5ArrayINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_15StaticArrayImplIS4_Lm4ELb0ES5_iEEIS4_NS_6MatrixIS3_Lm4EEES5_TnNSt3__19enable_ifIXaaeqsrT1_4SizesrT0_4SizeeqsrSB_5DepthsrSC_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESC_EE.exit.i, label %126, !llvm.loop !24 - -_ZN5drjit5ArrayINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_15StaticArrayImplIS4_Lm4ELb0ES5_iEEIS4_NS_6MatrixIS3_Lm4EEES5_TnNSt3__19enable_ifIXaaeqsrT1_4SizesrT0_4SizeeqsrSB_5DepthsrSC_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESC_EE.exit.i: ; preds = %126 + br label %124 + +124: ; preds = %124, %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit.i.i + %.018.i.i = phi i64 [ 0, %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit.i.i ], [ %127, %124 ] + %125 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %112, i64 0, i64 %.018.i.i + %126 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %125, i64 0, i64 %.018.i.i + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %126, ptr noundef nonnull align 16 dereferenceable(16) %123, i64 16, i1 false) + %127 = add nuw nsw i64 %.018.i.i, 1 + %exitcond.not.i.i = icmp eq i64 %127, 4 + br i1 %exitcond.not.i.i, label %_ZN5drjit5ArrayINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_15StaticArrayImplIS4_Lm4ELb0ES5_iEEIS4_NS_6MatrixIS3_Lm4EEES5_TnNSt3__19enable_ifIXaaeqsrT1_4SizesrT0_4SizeeqsrSB_5DepthsrSC_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESC_EE.exit.i, label %124, !llvm.loop !24 + +_ZN5drjit5ArrayINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_15StaticArrayImplIS4_Lm4ELb0ES5_iEEIS4_NS_6MatrixIS3_Lm4EEES5_TnNSt3__19enable_ifIXaaeqsrT1_4SizesrT0_4SizeeqsrSB_5DepthsrSC_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESC_EE.exit.i: ; preds = %124 call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %17), !noalias !21 call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %18) call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %19) call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %14) call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %15) - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %14, ptr noundef nonnull align 16 dereferenceable(256) %114, i64 256, i1 false), !noalias !25 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %14, ptr noundef nonnull align 16 dereferenceable(256) %112, i64 256, i1 false), !noalias !25 call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %12), !noalias !25 - br label %130 - -130: ; preds = %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i, %_ZN5drjit5ArrayINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_15StaticArrayImplIS4_Lm4ELb0ES5_iEEIS4_NS_6MatrixIS3_Lm4EEES5_TnNSt3__19enable_ifIXaaeqsrT1_4SizesrT0_4SizeeqsrSB_5DepthsrSC_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESC_EE.exit.i - %.08.i.i = phi i64 [ 0, %_ZN5drjit5ArrayINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_15StaticArrayImplIS4_Lm4ELb0ES5_iEEIS4_NS_6MatrixIS3_Lm4EEES5_TnNSt3__19enable_ifIXaaeqsrT1_4SizesrT0_4SizeeqsrSB_5DepthsrSC_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESC_EE.exit.i ], [ %135, %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i ] - br label %131 - -131: ; preds = %131, %130 - %.09.i.i.i = phi i64 [ 0, %130 ], [ %133, %131 ] - %132 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %12, i64 0, i64 %.09.i.i.i - store <4 x float> splat (float 0x400921FB60000000), ptr %132, align 16, !alias.scope !28, !noalias !31 - %133 = add nuw nsw i64 %.09.i.i.i, 1 - %exitcond.not.i.i18.i = icmp eq i64 %133, 4 - br i1 %exitcond.not.i.i18.i, label %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i, label %131, !llvm.loop !34 - -_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i: ; preds = %131 - %134 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %15, i64 0, i64 %.08.i.i - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %134, ptr noundef nonnull align 16 dereferenceable(64) %12, i64 64, i1 false), !noalias !25 - %135 = add nuw nsw i64 %.08.i.i, 1 - %exitcond.not.i.i344 = icmp eq i64 %135, 4 - br i1 %exitcond.not.i.i344, label %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i, label %130, !llvm.loop !35 + br label %128 + +128: ; preds = %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i, %_ZN5drjit5ArrayINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_15StaticArrayImplIS4_Lm4ELb0ES5_iEEIS4_NS_6MatrixIS3_Lm4EEES5_TnNSt3__19enable_ifIXaaeqsrT1_4SizesrT0_4SizeeqsrSB_5DepthsrSC_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESC_EE.exit.i + %.08.i.i = phi i64 [ 0, %_ZN5drjit5ArrayINS0_IN7mitsuba8SpectrumIfLm4EEELm4EEELm4EECI2NS_15StaticArrayImplIS4_Lm4ELb0ES5_iEEIS4_NS_6MatrixIS3_Lm4EEES5_TnNSt3__19enable_ifIXaaeqsrT1_4SizesrT0_4SizeeqsrSB_5DepthsrSC_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESC_EE.exit.i ], [ %133, %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i ] + br label %129 + +129: ; preds = %129, %128 + %.09.i.i.i = phi i64 [ 0, %128 ], [ %131, %129 ] + %130 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %12, i64 0, i64 %.09.i.i.i + store <4 x float> splat (float 0x400921FB60000000), ptr %130, align 16, !alias.scope !28, !noalias !31 + %131 = add nuw nsw i64 %.09.i.i.i, 1 + %exitcond.not.i.i18.i = icmp eq i64 %131, 4 + br i1 %exitcond.not.i.i18.i, label %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i, label %129, !llvm.loop !34 + +_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i: ; preds = %129 + %132 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %15, i64 0, i64 %.08.i.i + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %132, ptr noundef nonnull align 16 dereferenceable(64) %12, i64 64, i1 false), !noalias !25 + %133 = add nuw nsw i64 %.08.i.i, 1 + %exitcond.not.i.i344 = icmp eq i64 %133, 4 + br i1 %exitcond.not.i.i344, label %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i, label %128, !llvm.loop !35 _ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i: ; preds = %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %12), !noalias !25 call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %11), !noalias !25 - br label %136 + br label %134 -136: ; preds = %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i - %.030.i.i = phi i64 [ 0, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i ], [ %148, %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i ] - %137 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %14, i64 0, i64 %.030.i.i - %138 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %15, i64 0, i64 %.030.i.i +134: ; preds = %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i + %.030.i.i = phi i64 [ 0, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i ], [ %146, %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i ] + %135 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %14, i64 0, i64 %.030.i.i + %136 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %15, i64 0, i64 %.030.i.i call void @llvm.experimental.noalias.scope.decl(metadata !36) - br label %139 - -139: ; preds = %139, %136 - %.034.i.i.i = phi i64 [ 0, %136 ], [ %146, %139 ] - %140 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %137, i64 0, i64 %.034.i.i.i - %141 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %138, i64 0, i64 %.034.i.i.i - %142 = load <4 x float>, ptr %140, align 16, !noalias !39 - %143 = load <4 x float>, ptr %141, align 16, !noalias !39 - %144 = fmul contract <4 x float> %142, %143 - %145 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %11, i64 0, i64 %.034.i.i.i - store <4 x float> %144, ptr %145, align 16, !alias.scope !36, !noalias !42 - %146 = add nuw nsw i64 %.034.i.i.i, 1 - %exitcond.not.i.i19.i = icmp eq i64 %146, 4 - br i1 %exitcond.not.i.i19.i, label %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i, label %139, !llvm.loop !43 - -_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i: ; preds = %139 - %147 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %13, i64 0, i64 %.030.i.i - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %147, ptr noundef nonnull align 16 dereferenceable(64) %11, i64 64, i1 false) - %148 = add nuw nsw i64 %.030.i.i, 1 - %exitcond.not.i20.i = icmp eq i64 %148, 4 - br i1 %exitcond.not.i20.i, label %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i, label %136, !llvm.loop !44 + br label %137 + +137: ; preds = %137, %134 + %.034.i.i.i = phi i64 [ 0, %134 ], [ %144, %137 ] + %138 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %135, i64 0, i64 %.034.i.i.i + %139 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %136, i64 0, i64 %.034.i.i.i + %140 = load <4 x float>, ptr %138, align 16, !noalias !39 + %141 = load <4 x float>, ptr %139, align 16, !noalias !39 + %142 = fmul contract <4 x float> %140, %141 + %143 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %11, i64 0, i64 %.034.i.i.i + store <4 x float> %142, ptr %143, align 16, !alias.scope !36, !noalias !42 + %144 = add nuw nsw i64 %.034.i.i.i, 1 + %exitcond.not.i.i19.i = icmp eq i64 %144, 4 + br i1 %exitcond.not.i.i19.i, label %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i, label %137, !llvm.loop !43 + +_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i: ; preds = %137 + %145 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %13, i64 0, i64 %.030.i.i + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %145, ptr noundef nonnull align 16 dereferenceable(64) %11, i64 64, i1 false) + %146 = add nuw nsw i64 %.030.i.i, 1 + %exitcond.not.i20.i = icmp eq i64 %146, 4 + br i1 %exitcond.not.i20.i, label %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i, label %134, !llvm.loop !44 _ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i: ; preds = %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %11), !noalias !25 call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %14) call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %15) - %149 = load float, ptr %91, align 16 + %147 = load float, ptr %89, align 16 call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %10) - %150 = fmul contract float %149, %149 - %151 = insertelement <4 x float> poison, float %150, i64 0 - %152 = shufflevector <4 x float> %151, <4 x float> poison, <4 x i32> zeroinitializer + %148 = fmul contract float %147, %147 + %149 = insertelement <4 x float> poison, float %148, i64 0 + %150 = shufflevector <4 x float> %149, <4 x float> poison, <4 x i32> zeroinitializer call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %8), !noalias !45 - br label %153 - -153: ; preds = %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i351, %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i - %.08.i.i348 = phi i64 [ 0, %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i ], [ %158, %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i351 ] - br label %154 - -154: ; preds = %154, %153 - %.09.i.i.i349 = phi i64 [ 0, %153 ], [ %156, %154 ] - %155 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %8, i64 0, i64 %.09.i.i.i349 - store <4 x float> %152, ptr %155, align 16, !alias.scope !48, !noalias !51 - %156 = add nuw nsw i64 %.09.i.i.i349, 1 - %exitcond.not.i.i18.i350 = icmp eq i64 %156, 4 - br i1 %exitcond.not.i.i18.i350, label %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i351, label %154, !llvm.loop !34 - -_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i351: ; preds = %154 - %157 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %10, i64 0, i64 %.08.i.i348 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %157, ptr noundef nonnull align 16 dereferenceable(64) %8, i64 64, i1 false), !noalias !45 - %158 = add nuw nsw i64 %.08.i.i348, 1 - %exitcond.not.i.i352 = icmp eq i64 %158, 4 - br i1 %exitcond.not.i.i352, label %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i353, label %153, !llvm.loop !35 + br label %151 + +151: ; preds = %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i351, %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i + %.08.i.i348 = phi i64 [ 0, %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i ], [ %156, %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i351 ] + br label %152 + +152: ; preds = %152, %151 + %.09.i.i.i349 = phi i64 [ 0, %151 ], [ %154, %152 ] + %153 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %8, i64 0, i64 %.09.i.i.i349 + store <4 x float> %150, ptr %153, align 16, !alias.scope !48, !noalias !51 + %154 = add nuw nsw i64 %.09.i.i.i349, 1 + %exitcond.not.i.i18.i350 = icmp eq i64 %154, 4 + br i1 %exitcond.not.i.i18.i350, label %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i351, label %152, !llvm.loop !34 + +_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i351: ; preds = %152 + %155 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %10, i64 0, i64 %.08.i.i348 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %155, ptr noundef nonnull align 16 dereferenceable(64) %8, i64 64, i1 false), !noalias !45 + %156 = add nuw nsw i64 %.08.i.i348, 1 + %exitcond.not.i.i352 = icmp eq i64 %156, 4 + br i1 %exitcond.not.i.i352, label %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i353, label %151, !llvm.loop !35 _ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i353: ; preds = %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i351 call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %8), !noalias !45 call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %7), !noalias !45 - br label %159 + br label %157 -159: ; preds = %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i357, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i353 - %.030.i.i354 = phi i64 [ 0, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i353 ], [ %171, %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i357 ] - %160 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %13, i64 0, i64 %.030.i.i354 - %161 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %10, i64 0, i64 %.030.i.i354 +157: ; preds = %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i357, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i353 + %.030.i.i354 = phi i64 [ 0, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i353 ], [ %169, %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i357 ] + %158 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %13, i64 0, i64 %.030.i.i354 + %159 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %10, i64 0, i64 %.030.i.i354 call void @llvm.experimental.noalias.scope.decl(metadata !54) - br label %162 - -162: ; preds = %162, %159 - %.034.i.i.i355 = phi i64 [ 0, %159 ], [ %169, %162 ] - %163 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %160, i64 0, i64 %.034.i.i.i355 - %164 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %161, i64 0, i64 %.034.i.i.i355 - %165 = load <4 x float>, ptr %163, align 16 - %166 = load <4 x float>, ptr %164, align 16, !noalias !57 - %167 = fmul contract <4 x float> %165, %166 - %168 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %7, i64 0, i64 %.034.i.i.i355 - store <4 x float> %167, ptr %168, align 16, !alias.scope !54, !noalias !60 - %169 = add nuw nsw i64 %.034.i.i.i355, 1 - %exitcond.not.i.i19.i356 = icmp eq i64 %169, 4 - br i1 %exitcond.not.i.i19.i356, label %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i357, label %162, !llvm.loop !43 - -_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i357: ; preds = %162 - %170 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %9, i64 0, i64 %.030.i.i354 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %170, ptr noundef nonnull align 16 dereferenceable(64) %7, i64 64, i1 false) - %171 = add nuw nsw i64 %.030.i.i354, 1 - %exitcond.not.i20.i358 = icmp eq i64 %171, 4 - br i1 %exitcond.not.i20.i358, label %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i359, label %159, !llvm.loop !44 + br label %160 + +160: ; preds = %160, %157 + %.034.i.i.i355 = phi i64 [ 0, %157 ], [ %167, %160 ] + %161 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %158, i64 0, i64 %.034.i.i.i355 + %162 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %159, i64 0, i64 %.034.i.i.i355 + %163 = load <4 x float>, ptr %161, align 16 + %164 = load <4 x float>, ptr %162, align 16, !noalias !57 + %165 = fmul contract <4 x float> %163, %164 + %166 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %7, i64 0, i64 %.034.i.i.i355 + store <4 x float> %165, ptr %166, align 16, !alias.scope !54, !noalias !60 + %167 = add nuw nsw i64 %.034.i.i.i355, 1 + %exitcond.not.i.i19.i356 = icmp eq i64 %167, 4 + br i1 %exitcond.not.i.i19.i356, label %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i357, label %160, !llvm.loop !43 + +_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i357: ; preds = %160 + %168 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.71"], ptr %9, i64 0, i64 %.030.i.i354 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %168, ptr noundef nonnull align 16 dereferenceable(64) %7, i64 64, i1 false) + %169 = add nuw nsw i64 %.030.i.i354, 1 + %exitcond.not.i20.i358 = icmp eq i64 %169, 4 + br i1 %exitcond.not.i20.i358, label %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i359, label %157, !llvm.loop !44 _ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i359: ; preds = %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i357 call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %7), !noalias !45 @@ -1148,17 +1147,17 @@ _ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EE %.sroa.0.i.16.i.16.i.16..sroa_idx = getelementptr inbounds nuw i8, ptr %.sroa.0.i, i64 16 call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(240) %.sroa.0.i.16.i.16.i.16..sroa_idx, i8 0, i64 240, i1 false) call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %.sroa.0.i, ptr noundef nonnull align 16 dereferenceable(16) %9, i64 16, i1 false) - store <4 x float> %96, ptr %0, align 16 + store <4 x float> %94, ptr %0, align 16 %.sroa.0363.sroa.2.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 16 - store <4 x float> %88, ptr %.sroa.0363.sroa.2.0..sroa_idx, align 16 + store <4 x float> %86, ptr %.sroa.0363.sroa.2.0..sroa_idx, align 16 %.sroa.3.0..sroa_idx364 = getelementptr inbounds nuw i8, ptr %0, i64 32 store float 0x47EFFFFFE0000000, ptr %.sroa.3.0..sroa_idx364, align 16 %.sroa.4.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 36 store float %2, ptr %.sroa.4.0..sroa_idx, align 4 %.sroa.5.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 40 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %.sroa.5.0..sroa_idx, ptr noundef nonnull align 8 dereferenceable(24) %.sroa.5, i64 24, i1 false) - %172 = getelementptr inbounds nuw i8, ptr %0, i64 64 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %172, ptr noundef nonnull align 16 dereferenceable(256) %.sroa.0.i, i64 256, i1 false) + %170 = getelementptr inbounds nuw i8, ptr %0, i64 64 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %170, ptr noundef nonnull align 16 dereferenceable(256) %.sroa.0.i, i64 256, i1 false) ret void } diff --git a/bench/mitsuba3/optimized/distant.cpp.ll b/bench/mitsuba3/optimized/distant.cpp.ll index 99fee993ca6..e1cfd6e8a65 100644 --- a/bench/mitsuba3/optimized/distant.cpp.ll +++ b/bench/mitsuba3/optimized/distant.cpp.ll @@ -6302,78 +6302,77 @@ _ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS_6MatrixIS4 %68 = fdiv contract float %67, %.sroa.speculated422 %69 = fsub contract float 0x3FF921FB60000000, %68 %spec.select = select i1 %64, float %69, float %68 - %70 = call float @llvm.fabs.f32(float %spec.select) - %71 = select contract i1 %narrow, float 0.000000e+00, float %70 - %72 = fmul contract float %71, 0x3FF45F3060000000 - %73 = fptosi float %72 to i32 - %74 = add nsw i32 %73, 1 - %75 = and i32 %74, -2 - %76 = shl i32 %75, 29 - %77 = bitcast float %spec.select to i32 - %78 = select i1 %narrow, i32 0, i32 %77 - %79 = xor i32 %76, %78 - %80 = and i32 %79, -2147483648 - %81 = and i32 %74, 2 - %82 = icmp eq i32 %81, 0 - %83 = fcmp contract oeq float %71, 0x7FF0000000000000 - %84 = sitofp i32 %75 to float - %85 = fmul contract float %84, 0x3FE9200000000000 - %86 = fsub contract float %71, %85 - %87 = fmul contract float %84, 0x3F2FB40000000000 + %.1 = select i1 %narrow, float 0.000000e+00, float %spec.select + %70 = call contract noundef float @llvm.fabs.f32(float %.1) + %71 = fmul contract float %70, 0x3FF45F3060000000 + %72 = fptosi float %71 to i32 + %73 = add nsw i32 %72, 1 + %74 = and i32 %73, -2 + %75 = shl i32 %74, 29 + %76 = bitcast float %.1 to i32 + %77 = xor i32 %75, %76 + %78 = and i32 %77, -2147483648 + %79 = and i32 %73, 2 + %80 = icmp eq i32 %79, 0 + %81 = fcmp contract oeq float %70, 0x7FF0000000000000 + %82 = sitofp i32 %74 to float + %83 = fmul contract float %82, 0x3FE9200000000000 + %84 = fsub contract float %70, %83 + %85 = fmul contract float %82, 0x3F2FB40000000000 + %86 = fsub contract float %84, %85 + %87 = fmul contract float %82, 0x3E64442D20000000 %88 = fsub contract float %86, %87 - %89 = fmul contract float %84, 0x3E64442D20000000 - %90 = fsub contract float %88, %89 + %89 = fmul contract float %88, %88 + %90 = select i1 %81, float 0xFFFFFFFFE0000000, float %89 %91 = fmul contract float %90, %90 - %92 = select i1 %83, float 0xFFFFFFFFE0000000, float %91 - %93 = fmul contract float %92, %92 - %94 = call contract noundef float @llvm.fma.f32(float %92, float 0x3F811073C0000000, float 0xBFC5555460000000) - %95 = call contract noundef float @llvm.fma.f32(float %93, float 0xBF29943F20000000, float %94) - %96 = fmul contract float %92, %95 - %97 = call contract noundef float @llvm.fma.f32(float %96, float %90, float %90) - %98 = call contract noundef float @llvm.fma.f32(float %92, float 0xBF56C0C340000000, float 0x3FA55554A0000000) - %99 = call contract noundef float @llvm.fma.f32(float %93, float 0x3EF99EB9C0000000, float %98) - %100 = fmul contract float %92, %99 - %101 = call contract noundef float @llvm.fma.f32(float %92, float -5.000000e-01, float 1.000000e+00) - %102 = call contract noundef float @llvm.fma.f32(float %100, float %92, float %101) - %103 = select contract i1 %82, float %97, float %102 - %104 = bitcast float %103 to i32 - %105 = xor i32 %80, %104 - %.sroa.0411.0.vec.extract = bitcast i32 %105 to float - %106 = fmul contract float %.sroa.speculated422, %.sroa.0411.0.vec.extract - %107 = insertelement <4 x float> poison, float %106, i64 0 - %108 = shufflevector <4 x float> %107, <4 x float> poison, <4 x i32> zeroinitializer - %109 = sub i32 0, %76 - %110 = and i32 %109, -2147483648 - %111 = select contract i1 %82, float %102, float %97 - %112 = bitcast float %111 to i32 - %113 = xor i32 %110, %112 - %.sroa.0411.4.vec.extract = bitcast i32 %113 to float - %114 = fmul contract float %.sroa.speculated422, %.sroa.0411.4.vec.extract - %115 = insertelement <4 x float> poison, float %114, i64 0 - %116 = shufflevector <4 x float> %115, <4 x float> poison, <4 x i32> zeroinitializer - %117 = fmul contract <4 x float> %.sroa.0391.0.copyload, %116 - %118 = fmul contract <4 x float> %.sroa.0391.0.copyload, zeroinitializer - %119 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %35, <4 x float> zeroinitializer, <4 x float> %118) - %120 = fadd contract <4 x float> %37, %119 - %121 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %35, <4 x float> %108, <4 x float> %117) - %122 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %37, <4 x float> zeroinitializer, <4 x float> %121) - %123 = shufflevector <4 x float> %44, <4 x float> poison, <4 x i32> zeroinitializer - %124 = fmul contract <4 x float> %122, %123 - %125 = fadd contract <4 x float> %45, %124 - %126 = fmul contract <4 x float> %120, %123 - %127 = fsub contract <4 x float> %125, %126 + %92 = call contract noundef float @llvm.fma.f32(float %90, float 0x3F811073C0000000, float 0xBFC5555460000000) + %93 = call contract noundef float @llvm.fma.f32(float %91, float 0xBF29943F20000000, float %92) + %94 = fmul contract float %90, %93 + %95 = call contract noundef float @llvm.fma.f32(float %94, float %88, float %88) + %96 = call contract noundef float @llvm.fma.f32(float %90, float 0xBF56C0C340000000, float 0x3FA55554A0000000) + %97 = call contract noundef float @llvm.fma.f32(float %91, float 0x3EF99EB9C0000000, float %96) + %98 = fmul contract float %90, %97 + %99 = call contract noundef float @llvm.fma.f32(float %90, float -5.000000e-01, float 1.000000e+00) + %100 = call contract noundef float @llvm.fma.f32(float %98, float %90, float %99) + %101 = select contract i1 %80, float %95, float %100 + %102 = bitcast float %101 to i32 + %103 = xor i32 %78, %102 + %.sroa.0411.0.vec.extract = bitcast i32 %103 to float + %104 = fmul contract float %.sroa.speculated422, %.sroa.0411.0.vec.extract + %105 = insertelement <4 x float> poison, float %104, i64 0 + %106 = shufflevector <4 x float> %105, <4 x float> poison, <4 x i32> zeroinitializer + %107 = sub i32 0, %75 + %108 = and i32 %107, -2147483648 + %109 = select contract i1 %80, float %100, float %95 + %110 = bitcast float %109 to i32 + %111 = xor i32 %108, %110 + %.sroa.0411.4.vec.extract = bitcast i32 %111 to float + %112 = fmul contract float %.sroa.speculated422, %.sroa.0411.4.vec.extract + %113 = insertelement <4 x float> poison, float %112, i64 0 + %114 = shufflevector <4 x float> %113, <4 x float> poison, <4 x i32> zeroinitializer + %115 = fmul contract <4 x float> %.sroa.0391.0.copyload, %114 + %116 = fmul contract <4 x float> %.sroa.0391.0.copyload, zeroinitializer + %117 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %35, <4 x float> zeroinitializer, <4 x float> %116) + %118 = fadd contract <4 x float> %37, %117 + %119 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %35, <4 x float> %106, <4 x float> %115) + %120 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %37, <4 x float> zeroinitializer, <4 x float> %119) + %121 = shufflevector <4 x float> %44, <4 x float> poison, <4 x i32> zeroinitializer + %122 = fmul contract <4 x float> %120, %121 + %123 = fadd contract <4 x float> %45, %122 + %124 = fmul contract <4 x float> %118, %121 + %125 = fsub contract <4 x float> %123, %124 call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %8) - store <4 x float> %127, ptr %0, align 16 + store <4 x float> %125, ptr %0, align 16 %.sroa.2.0..sroa_idx371 = getelementptr inbounds nuw i8, ptr %0, i64 16 - store <4 x float> %120, ptr %.sroa.2.0..sroa_idx371, align 16 + store <4 x float> %118, ptr %.sroa.2.0..sroa_idx371, align 16 %.sroa.4.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 32 store float 0x47EFFFFFE0000000, ptr %.sroa.4.0..sroa_idx, align 16 %.sroa.5.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 36 store float %2, ptr %.sroa.5.0..sroa_idx, align 4 %.sroa.7.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 40 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %.sroa.7.0..sroa_idx, ptr noundef nonnull align 8 dereferenceable(24) %.sroa.7, i64 24, i1 false) - %128 = getelementptr inbounds nuw i8, ptr %0, i64 64 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %128, ptr noundef nonnull align 16 dereferenceable(256) %15, i64 256, i1 false) + %126 = getelementptr inbounds nuw i8, ptr %0, i64 64 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %126, ptr noundef nonnull align 16 dereferenceable(256) %15, i64 256, i1 false) ret void } diff --git a/bench/mitsuba3/optimized/irradiancemeter.cpp.ll b/bench/mitsuba3/optimized/irradiancemeter.cpp.ll index 8fb62714b21..bdf1785e81a 100644 --- a/bench/mitsuba3/optimized/irradiancemeter.cpp.ll +++ b/bench/mitsuba3/optimized/irradiancemeter.cpp.ll @@ -495,106 +495,105 @@ _ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EE %56 = fdiv contract float %55, %.sroa.speculated265 %57 = fsub contract float 0x3FF921FB60000000, %56 %spec.select = select i1 %52, float %57, float %56 - %58 = call float @llvm.fabs.f32(float %spec.select) - %59 = select contract i1 %narrow, float 0.000000e+00, float %58 - %60 = fmul contract float %59, 0x3FF45F3060000000 - %61 = fptosi float %60 to i32 - %62 = add nsw i32 %61, 1 - %63 = and i32 %62, -2 - %64 = shl i32 %63, 29 - %65 = bitcast float %spec.select to i32 - %66 = select i1 %narrow, i32 0, i32 %65 - %67 = xor i32 %64, %66 - %68 = and i32 %67, -2147483648 - %69 = and i32 %62, 2 - %70 = icmp eq i32 %69, 0 - %71 = fcmp contract oeq float %59, 0x7FF0000000000000 - %72 = sitofp i32 %63 to float - %73 = fmul contract float %72, 0x3FE9200000000000 - %74 = fsub contract float %59, %73 - %75 = fmul contract float %72, 0x3F2FB40000000000 + %.1 = select i1 %narrow, float 0.000000e+00, float %spec.select + %58 = call contract noundef float @llvm.fabs.f32(float %.1) + %59 = fmul contract float %58, 0x3FF45F3060000000 + %60 = fptosi float %59 to i32 + %61 = add nsw i32 %60, 1 + %62 = and i32 %61, -2 + %63 = shl i32 %62, 29 + %64 = bitcast float %.1 to i32 + %65 = xor i32 %63, %64 + %66 = and i32 %65, -2147483648 + %67 = and i32 %61, 2 + %68 = icmp eq i32 %67, 0 + %69 = fcmp contract oeq float %58, 0x7FF0000000000000 + %70 = sitofp i32 %62 to float + %71 = fmul contract float %70, 0x3FE9200000000000 + %72 = fsub contract float %58, %71 + %73 = fmul contract float %70, 0x3F2FB40000000000 + %74 = fsub contract float %72, %73 + %75 = fmul contract float %70, 0x3E64442D20000000 %76 = fsub contract float %74, %75 - %77 = fmul contract float %72, 0x3E64442D20000000 - %78 = fsub contract float %76, %77 + %77 = fmul contract float %76, %76 + %78 = select i1 %69, float 0xFFFFFFFFE0000000, float %77 %79 = fmul contract float %78, %78 - %80 = select i1 %71, float 0xFFFFFFFFE0000000, float %79 - %81 = fmul contract float %80, %80 - %82 = call contract noundef float @llvm.fma.f32(float %80, float 0x3F811073C0000000, float 0xBFC5555460000000) - %83 = call contract noundef float @llvm.fma.f32(float %81, float 0xBF29943F20000000, float %82) - %84 = fmul contract float %80, %83 - %85 = call contract noundef float @llvm.fma.f32(float %84, float %78, float %78) - %86 = call contract noundef float @llvm.fma.f32(float %80, float 0xBF56C0C340000000, float 0x3FA55554A0000000) - %87 = call contract noundef float @llvm.fma.f32(float %81, float 0x3EF99EB9C0000000, float %86) - %88 = fmul contract float %80, %87 - %89 = call contract noundef float @llvm.fma.f32(float %80, float -5.000000e-01, float 1.000000e+00) - %90 = call contract noundef float @llvm.fma.f32(float %88, float %80, float %89) - %91 = select contract i1 %70, float %85, float %90 - %92 = bitcast float %91 to i32 - %93 = xor i32 %68, %92 - %.sroa.0255.0.vec.extract = bitcast i32 %93 to float - %94 = fmul contract float %.sroa.speculated265, %.sroa.0255.0.vec.extract - %95 = fmul contract float %94, %94 - %96 = sub i32 0, %64 - %97 = and i32 %96, -2147483648 - %98 = select contract i1 %70, float %90, float %85 - %99 = bitcast float %98 to i32 - %100 = xor i32 %97, %99 - %.sroa.0255.4.vec.extract = bitcast i32 %100 to float - %101 = fmul contract float %.sroa.speculated265, %.sroa.0255.4.vec.extract - %102 = fmul contract float %101, %101 + %80 = call contract noundef float @llvm.fma.f32(float %78, float 0x3F811073C0000000, float 0xBFC5555460000000) + %81 = call contract noundef float @llvm.fma.f32(float %79, float 0xBF29943F20000000, float %80) + %82 = fmul contract float %78, %81 + %83 = call contract noundef float @llvm.fma.f32(float %82, float %76, float %76) + %84 = call contract noundef float @llvm.fma.f32(float %78, float 0xBF56C0C340000000, float 0x3FA55554A0000000) + %85 = call contract noundef float @llvm.fma.f32(float %79, float 0x3EF99EB9C0000000, float %84) + %86 = fmul contract float %78, %85 + %87 = call contract noundef float @llvm.fma.f32(float %78, float -5.000000e-01, float 1.000000e+00) + %88 = call contract noundef float @llvm.fma.f32(float %86, float %78, float %87) + %89 = select contract i1 %68, float %83, float %88 + %90 = bitcast float %89 to i32 + %91 = xor i32 %66, %90 + %.sroa.0255.0.vec.extract = bitcast i32 %91 to float + %92 = fmul contract float %.sroa.speculated265, %.sroa.0255.0.vec.extract + %93 = fmul contract float %92, %92 + %94 = sub i32 0, %63 + %95 = and i32 %94, -2147483648 + %96 = select contract i1 %68, float %88, float %83 + %97 = bitcast float %96 to i32 + %98 = xor i32 %95, %97 + %.sroa.0255.4.vec.extract = bitcast i32 %98 to float + %99 = fmul contract float %.sroa.speculated265, %.sroa.0255.4.vec.extract + %100 = fmul contract float %99, %99 call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %7), !noalias !4 - %103 = fadd contract float %102, %95 - %104 = fsub contract float 1.000000e+00, %103 - %105 = fcmp contract olt float %104, 0.000000e+00 - %..i = select contract i1 %105, float 0.000000e+00, float %104 - %106 = call contract noundef float @llvm.sqrt.f32(float %..i) - %107 = insertelement <4 x float> poison, float %106, i64 0 - %108 = shufflevector <4 x float> %107, <4 x float> poison, <4 x i32> zeroinitializer + %101 = fadd contract float %100, %93 + %102 = fsub contract float 1.000000e+00, %101 + %103 = fcmp contract olt float %102, 0.000000e+00 + %..i = select contract i1 %103, float 0.000000e+00, float %102 + %104 = call contract noundef float @llvm.sqrt.f32(float %..i) + %105 = insertelement <4 x float> poison, float %104, i64 0 + %106 = shufflevector <4 x float> %105, <4 x float> poison, <4 x i32> zeroinitializer %.sroa.0.0.vec.extract = extractelement <4 x float> %27, i64 0 %.sroa.0.4.vec.extract = extractelement <4 x float> %27, i64 1 - %109 = fmul contract float %.sroa.0.0.vec.extract, %.sroa.0.4.vec.extract + %107 = fmul contract float %.sroa.0.0.vec.extract, %.sroa.0.4.vec.extract %.sroa.0.8.vec.extract = extractelement <4 x float> %27, i64 2 - %110 = call float @llvm.copysign.f32(float 1.000000e+00, float %.sroa.0.8.vec.extract) - %111 = fadd contract float %.sroa.0.8.vec.extract, %110 - %112 = fdiv contract float -1.000000e+00, %111 - %113 = fmul contract float %109, %112 - %114 = insertelement <4 x float> , float %113, i64 0 - %115 = fmul contract float %.sroa.0.4.vec.extract, %112 - %116 = call contract noundef float @llvm.fma.f32(float %.sroa.0.4.vec.extract, float %115, float %110) - %117 = insertelement <4 x float> %114, float %116, i64 1 - %118 = fneg contract float %.sroa.0.4.vec.extract - %119 = insertelement <4 x float> %117, float %118, i64 2 - %120 = insertelement <4 x float> poison, float %94, i64 0 - %121 = shufflevector <4 x float> %120, <4 x float> poison, <4 x i32> zeroinitializer - %122 = bitcast float %.sroa.0.8.vec.extract to i32 - %123 = and i32 %122, -2147483648 - %124 = fmul contract <4 x float> %27, %27 - %125 = extractelement <4 x float> %124, i64 0 - %126 = fmul contract float %125, %112 - %127 = bitcast float %126 to i32 - %128 = xor i32 %123, %127 - %129 = bitcast i32 %128 to float - %130 = fadd contract float %129, 1.000000e+00 - %131 = insertelement <4 x float> , float %130, i64 0 - %132 = bitcast float %113 to i32 - %133 = xor i32 %123, %132 - %134 = bitcast i32 %133 to float - %135 = insertelement <4 x float> %131, float %134, i64 1 - %136 = fcmp contract ult float %.sroa.0.8.vec.extract, 0.000000e+00 - %137 = fneg contract float %.sroa.0.0.vec.extract - %138 = select contract i1 %136, float %.sroa.0.0.vec.extract, float %137 - %139 = insertelement <4 x float> %135, float %138, i64 2 - %140 = insertelement <4 x float> poison, float %101, i64 0 - %141 = shufflevector <4 x float> %140, <4 x float> poison, <4 x i32> zeroinitializer - %142 = fmul contract <4 x float> %141, %139 - %143 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %119, <4 x float> %121, <4 x float> %142) - %144 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %27, <4 x float> %108, <4 x float> %143) - %145 = fmul contract <4 x float> %144, splat (float 0x3F17700000000000) - %146 = fadd contract <4 x float> %28, %145 + %108 = call float @llvm.copysign.f32(float 1.000000e+00, float %.sroa.0.8.vec.extract) + %109 = fadd contract float %.sroa.0.8.vec.extract, %108 + %110 = fdiv contract float -1.000000e+00, %109 + %111 = fmul contract float %107, %110 + %112 = insertelement <4 x float> , float %111, i64 0 + %113 = fmul contract float %.sroa.0.4.vec.extract, %110 + %114 = call contract noundef float @llvm.fma.f32(float %.sroa.0.4.vec.extract, float %113, float %108) + %115 = insertelement <4 x float> %112, float %114, i64 1 + %116 = fneg contract float %.sroa.0.4.vec.extract + %117 = insertelement <4 x float> %115, float %116, i64 2 + %118 = insertelement <4 x float> poison, float %92, i64 0 + %119 = shufflevector <4 x float> %118, <4 x float> poison, <4 x i32> zeroinitializer + %120 = bitcast float %.sroa.0.8.vec.extract to i32 + %121 = and i32 %120, -2147483648 + %122 = fmul contract <4 x float> %27, %27 + %123 = extractelement <4 x float> %122, i64 0 + %124 = fmul contract float %123, %110 + %125 = bitcast float %124 to i32 + %126 = xor i32 %121, %125 + %127 = bitcast i32 %126 to float + %128 = fadd contract float %127, 1.000000e+00 + %129 = insertelement <4 x float> , float %128, i64 0 + %130 = bitcast float %111 to i32 + %131 = xor i32 %121, %130 + %132 = bitcast i32 %131 to float + %133 = insertelement <4 x float> %129, float %132, i64 1 + %134 = fcmp contract ult float %.sroa.0.8.vec.extract, 0.000000e+00 + %135 = fneg contract float %.sroa.0.0.vec.extract + %136 = select contract i1 %134, float %.sroa.0.0.vec.extract, float %135 + %137 = insertelement <4 x float> %133, float %136, i64 2 + %138 = insertelement <4 x float> poison, float %99, i64 0 + %139 = shufflevector <4 x float> %138, <4 x float> poison, <4 x i32> zeroinitializer + %140 = fmul contract <4 x float> %139, %137 + %141 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %117, <4 x float> %119, <4 x float> %140) + %142 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %27, <4 x float> %106, <4 x float> %141) + %143 = fmul contract <4 x float> %142, splat (float 0x3F17700000000000) + %144 = fadd contract <4 x float> %28, %143 call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %10) - store <4 x float> %146, ptr %0, align 16 + store <4 x float> %144, ptr %0, align 16 %.sroa.0.sroa.2.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 16 - store <4 x float> %144, ptr %.sroa.0.sroa.2.0..sroa_idx, align 16 + store <4 x float> %142, ptr %.sroa.0.sroa.2.0..sroa_idx, align 16 %.sroa.3.0..sroa_idx234 = getelementptr inbounds nuw i8, ptr %0, i64 32 store float 0x47EFFFFFE0000000, ptr %.sroa.3.0..sroa_idx234, align 16 %.sroa.4.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 36 @@ -603,8 +602,8 @@ _ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EE call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %.sroa.6.0..sroa_idx, ptr noundef nonnull align 8 dereferenceable(24) %.sroa.6, i64 24, i1 false) %.sroa.7.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 64 call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(65) %.sroa.7.0..sroa_idx, i8 0, i64 65, i1 false) - %147 = getelementptr inbounds nuw i8, ptr %0, i64 144 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %147, ptr noundef nonnull align 16 dereferenceable(256) %9, i64 256, i1 false) + %145 = getelementptr inbounds nuw i8, ptr %0, i64 144 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %145, ptr noundef nonnull align 16 dereferenceable(256) %9, i64 256, i1 false) ret void } diff --git a/bench/mitsuba3/optimized/plastic.cpp.ll b/bench/mitsuba3/optimized/plastic.cpp.ll index b731a9d0a79..b722c326796 100644 --- a/bench/mitsuba3/optimized/plastic.cpp.ll +++ b/bench/mitsuba3/optimized/plastic.cpp.ll @@ -1447,7 +1447,7 @@ _ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_ _ZNSt3__14pairIN7mitsuba11BSDFSample3IfN5drjit6MatrixINS1_8SpectrumIfLm4EEELm4EEEEES7_EC2B8ne190000IRS8_RS6_TnNS_9enable_ifIXclsr10_CheckArgsE23__is_pair_constructibleIT_T0_EEEiE4typeELi0EEEOSE_OSF_.exit: ; preds = %41 call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %9) - br label %239 + br label %237 45: ; preds = %23 %46 = getelementptr inbounds nuw i8, ptr %1, i64 80 @@ -1541,167 +1541,166 @@ _ZNSt3__14pairIN7mitsuba11BSDFSample3IfN5drjit6MatrixINS1_8SpectrumIfLm4EEELm4EE %114 = fdiv contract float %113, %.sroa.speculated428 %115 = fsub contract float 0x3FF921FB60000000, %114 %spec.select = select i1 %112, float %115, float %114 - %116 = tail call float @llvm.fabs.f32(float %spec.select) - %117 = select contract i1 %narrow, float 0.000000e+00, float %116 - %118 = fmul contract float %117, 0x3FF45F3060000000 - %119 = fptosi float %118 to i32 - %120 = add nsw i32 %119, 1 - %121 = and i32 %120, -2 - %122 = sitofp i32 %121 to float - %123 = shl i32 %121, 29 - %124 = bitcast float %spec.select to i32 - %125 = select i1 %narrow, i32 0, i32 %124 - %126 = xor i32 %123, %125 - %127 = sub i32 0, %123 - %128 = fmul contract float %122, 0x3FE9200000000000 - %129 = fsub contract float %117, %128 - %130 = fmul contract float %122, 0x3F2FB40000000000 + %.1 = select i1 %narrow, float 0.000000e+00, float %spec.select + %116 = tail call contract noundef float @llvm.fabs.f32(float %.1) + %117 = fmul contract float %116, 0x3FF45F3060000000 + %118 = fptosi float %117 to i32 + %119 = add nsw i32 %118, 1 + %120 = and i32 %119, -2 + %121 = sitofp i32 %120 to float + %122 = shl i32 %120, 29 + %123 = bitcast float %.1 to i32 + %124 = xor i32 %122, %123 + %125 = sub i32 0, %122 + %126 = fmul contract float %121, 0x3FE9200000000000 + %127 = fsub contract float %116, %126 + %128 = fmul contract float %121, 0x3F2FB40000000000 + %129 = fsub contract float %127, %128 + %130 = fmul contract float %121, 0x3E64442D20000000 %131 = fsub contract float %129, %130 - %132 = fmul contract float %122, 0x3E64442D20000000 - %133 = fsub contract float %131, %132 - %134 = fmul contract float %133, %133 - %135 = fcmp contract oeq float %117, 0x7FF0000000000000 - %136 = select i1 %135, float 0xFFFFFFFFE0000000, float %134 - %137 = tail call contract noundef float @llvm.fma.f32(float %136, float 0x3F811073C0000000, float 0xBFC5555460000000) - %138 = fmul contract float %136, %136 - %139 = tail call contract noundef float @llvm.fma.f32(float %138, float 0xBF29943F20000000, float %137) - %140 = fmul contract float %136, %139 - %141 = tail call contract noundef float @llvm.fma.f32(float %136, float 0xBF56C0C340000000, float 0x3FA55554A0000000) - %142 = tail call contract noundef float @llvm.fma.f32(float %138, float 0x3EF99EB9C0000000, float %141) - %143 = fmul contract float %136, %142 - %144 = tail call contract noundef float @llvm.fma.f32(float %140, float %133, float %133) - %145 = tail call contract noundef float @llvm.fma.f32(float %136, float -5.000000e-01, float 1.000000e+00) - %146 = tail call contract noundef float @llvm.fma.f32(float %143, float %136, float %145) - %147 = and i32 %120, 2 - %148 = icmp eq i32 %147, 0 - %149 = select contract i1 %148, float %144, float %146 - %150 = and i32 %126, -2147483648 - %151 = bitcast float %149 to i32 - %152 = xor i32 %150, %151 - %153 = select contract i1 %148, float %146, float %144 - %154 = and i32 %127, -2147483648 - %155 = bitcast float %153 to i32 - %156 = xor i32 %154, %155 - %.sroa.0417.4.vec.extract = bitcast i32 %156 to float - %157 = fmul contract float %.sroa.speculated428, %.sroa.0417.4.vec.extract - %.sroa.0417.0.vec.extract = bitcast i32 %152 to float - %158 = fmul contract float %.sroa.speculated428, %.sroa.0417.0.vec.extract - %159 = fmul contract float %157, %157 - %160 = fmul contract float %158, %158 - %161 = fadd contract float %159, %160 - %162 = fsub contract float 1.000000e+00, %161 - %163 = fcmp contract olt float %162, 0.000000e+00 - %..i = select contract i1 %163, float 0.000000e+00, float %162 - %164 = tail call contract noundef float @llvm.sqrt.f32(float %..i) - %165 = insertelement <4 x float> , float %157, i64 0 - %166 = insertelement <4 x float> %165, float %158, i64 1 - %167 = insertelement <4 x float> %166, float %164, i64 2 - %168 = fmul contract float %164, 0x3FD45F3060000000 - %169 = fmul contract float %102, %168 - %170 = load float, ptr %46, align 8 - %171 = fcmp contract oge float %..i, 0.000000e+00 - %172 = fdiv contract float 1.000000e+00, %170 - %173 = select contract i1 %171, float %170, float %172 - %174 = select contract i1 %171, float %172, float %170 - %175 = fneg contract float %164 - %176 = tail call contract noundef float @llvm.fma.f32(float %175, float %164, float 1.000000e+00) - %177 = fmul contract float %174, %174 - %178 = fneg contract float %176 - %179 = tail call contract noundef float @llvm.fma.f32(float %178, float %177, float 1.000000e+00) - %180 = tail call contract noundef float @llvm.fabs.f32(float %164) - %181 = fcmp contract olt float %179, 0.000000e+00 - %..i.i333 = select contract i1 %181, float 0.000000e+00, float %179 - %182 = tail call contract noundef float @llvm.sqrt.f32(float %..i.i333) - %183 = fcmp contract oeq float %170, 1.000000e+00 - %184 = fcmp contract oeq float %..i, 0.000000e+00 - %185 = fneg contract float %173 - %186 = tail call contract noundef float @llvm.fma.f32(float %185, float %182, float %180) - %187 = tail call contract noundef float @llvm.fma.f32(float %173, float %182, float %180) - %188 = fdiv contract float %186, %187 - %189 = tail call contract noundef float @llvm.fma.f32(float %185, float %180, float %182) - %190 = tail call contract noundef float @llvm.fma.f32(float %173, float %180, float %182) - %191 = fdiv contract float %189, %190 - %192 = fmul contract float %188, %188 - %193 = fmul contract float %191, %191 - %194 = fadd contract float %192, %193 - %195 = fmul contract float %194, 5.000000e-01 - %196 = getelementptr inbounds nuw i8, ptr %1, i64 64 - %197 = load ptr, ptr %196, align 8 + %132 = fmul contract float %131, %131 + %133 = fcmp contract oeq float %116, 0x7FF0000000000000 + %134 = select i1 %133, float 0xFFFFFFFFE0000000, float %132 + %135 = tail call contract noundef float @llvm.fma.f32(float %134, float 0x3F811073C0000000, float 0xBFC5555460000000) + %136 = fmul contract float %134, %134 + %137 = tail call contract noundef float @llvm.fma.f32(float %136, float 0xBF29943F20000000, float %135) + %138 = fmul contract float %134, %137 + %139 = tail call contract noundef float @llvm.fma.f32(float %134, float 0xBF56C0C340000000, float 0x3FA55554A0000000) + %140 = tail call contract noundef float @llvm.fma.f32(float %136, float 0x3EF99EB9C0000000, float %139) + %141 = fmul contract float %134, %140 + %142 = tail call contract noundef float @llvm.fma.f32(float %138, float %131, float %131) + %143 = tail call contract noundef float @llvm.fma.f32(float %134, float -5.000000e-01, float 1.000000e+00) + %144 = tail call contract noundef float @llvm.fma.f32(float %141, float %134, float %143) + %145 = and i32 %119, 2 + %146 = icmp eq i32 %145, 0 + %147 = select contract i1 %146, float %142, float %144 + %148 = and i32 %124, -2147483648 + %149 = bitcast float %147 to i32 + %150 = xor i32 %148, %149 + %151 = select contract i1 %146, float %144, float %142 + %152 = and i32 %125, -2147483648 + %153 = bitcast float %151 to i32 + %154 = xor i32 %152, %153 + %.sroa.0417.4.vec.extract = bitcast i32 %154 to float + %155 = fmul contract float %.sroa.speculated428, %.sroa.0417.4.vec.extract + %.sroa.0417.0.vec.extract = bitcast i32 %150 to float + %156 = fmul contract float %.sroa.speculated428, %.sroa.0417.0.vec.extract + %157 = fmul contract float %155, %155 + %158 = fmul contract float %156, %156 + %159 = fadd contract float %157, %158 + %160 = fsub contract float 1.000000e+00, %159 + %161 = fcmp contract olt float %160, 0.000000e+00 + %..i = select contract i1 %161, float 0.000000e+00, float %160 + %162 = tail call contract noundef float @llvm.sqrt.f32(float %..i) + %163 = insertelement <4 x float> , float %155, i64 0 + %164 = insertelement <4 x float> %163, float %156, i64 1 + %165 = insertelement <4 x float> %164, float %162, i64 2 + %166 = fmul contract float %162, 0x3FD45F3060000000 + %167 = fmul contract float %102, %166 + %168 = load float, ptr %46, align 8 + %169 = fcmp contract oge float %..i, 0.000000e+00 + %170 = fdiv contract float 1.000000e+00, %168 + %171 = select contract i1 %169, float %168, float %170 + %172 = select contract i1 %169, float %170, float %168 + %173 = fneg contract float %162 + %174 = tail call contract noundef float @llvm.fma.f32(float %173, float %162, float 1.000000e+00) + %175 = fmul contract float %172, %172 + %176 = fneg contract float %174 + %177 = tail call contract noundef float @llvm.fma.f32(float %176, float %175, float 1.000000e+00) + %178 = tail call contract noundef float @llvm.fabs.f32(float %162) + %179 = fcmp contract olt float %177, 0.000000e+00 + %..i.i333 = select contract i1 %179, float 0.000000e+00, float %177 + %180 = tail call contract noundef float @llvm.sqrt.f32(float %..i.i333) + %181 = fcmp contract oeq float %168, 1.000000e+00 + %182 = fcmp contract oeq float %..i, 0.000000e+00 + %183 = fneg contract float %171 + %184 = tail call contract noundef float @llvm.fma.f32(float %183, float %180, float %178) + %185 = tail call contract noundef float @llvm.fma.f32(float %171, float %180, float %178) + %186 = fdiv contract float %184, %185 + %187 = tail call contract noundef float @llvm.fma.f32(float %183, float %178, float %180) + %188 = tail call contract noundef float @llvm.fma.f32(float %171, float %178, float %180) + %189 = fdiv contract float %187, %188 + %190 = fmul contract float %186, %186 + %191 = fmul contract float %189, %189 + %192 = fadd contract float %190, %191 + %193 = fmul contract float %192, 5.000000e-01 + %194 = getelementptr inbounds nuw i8, ptr %1, i64 64 + %195 = load ptr, ptr %194, align 8 + %196 = load ptr, ptr %195, align 8 + %197 = getelementptr inbounds nuw i8, ptr %196, i64 72 %198 = load ptr, ptr %197, align 8 - %199 = getelementptr inbounds nuw i8, ptr %198, i64 72 - %200 = load ptr, ptr %199, align 8 - %201 = tail call <4 x float> %200(ptr noundef nonnull align 8 dereferenceable(40) %197, ptr noundef nonnull align 16 dereferenceable(240) %3, i1 noundef zeroext true) - %202 = getelementptr inbounds nuw i8, ptr %1, i64 100 - %203 = load i8, ptr %202, align 4 - %204 = trunc i8 %203 to i1 - %205 = getelementptr inbounds nuw i8, ptr %1, i64 88 - %206 = load <4 x float>, ptr %205, align 8 - %207 = shufflevector <4 x float> %206, <4 x float> poison, <4 x i32> zeroinitializer - %208 = fmul contract <4 x float> %201, %207 - %209 = shufflevector <4 x float> %206, <4 x float> poison, <4 x i32> zeroinitializer - %.sroa.0344.0 = select i1 %204, <4 x float> %208, <4 x float> %209 - %210 = fsub contract <4 x float> splat (float 1.000000e+00), %.sroa.0344.0 - %211 = fdiv contract <4 x float> %201, %210 - %212 = getelementptr inbounds nuw i8, ptr %1, i64 84 - %213 = load float, ptr %212, align 4 - %214 = fmul contract float %68, %213 - %215 = fsub contract float 1.000000e+00, %195 - %216 = select i1 %184, float 0.000000e+00, float %215 - %217 = select i1 %183, float 1.000000e+00, float %216 - %218 = fmul contract float %217, %214 - %219 = fdiv contract float %218, %102 - %220 = insertelement <4 x float> poison, float %219, i64 0 - %221 = shufflevector <4 x float> %220, <4 x float> poison, <4 x i32> zeroinitializer - %222 = fmul contract <4 x float> %211, %221 + %199 = tail call <4 x float> %198(ptr noundef nonnull align 8 dereferenceable(40) %195, ptr noundef nonnull align 16 dereferenceable(240) %3, i1 noundef zeroext true) + %200 = getelementptr inbounds nuw i8, ptr %1, i64 100 + %201 = load i8, ptr %200, align 4 + %202 = trunc i8 %201 to i1 + %203 = getelementptr inbounds nuw i8, ptr %1, i64 88 + %204 = load <4 x float>, ptr %203, align 8 + %205 = shufflevector <4 x float> %204, <4 x float> poison, <4 x i32> zeroinitializer + %206 = fmul contract <4 x float> %199, %205 + %207 = shufflevector <4 x float> %204, <4 x float> poison, <4 x i32> zeroinitializer + %.sroa.0344.0 = select i1 %202, <4 x float> %206, <4 x float> %207 + %208 = fsub contract <4 x float> splat (float 1.000000e+00), %.sroa.0344.0 + %209 = fdiv contract <4 x float> %199, %208 + %210 = getelementptr inbounds nuw i8, ptr %1, i64 84 + %211 = load float, ptr %210, align 4 + %212 = fmul contract float %68, %211 + %213 = fsub contract float 1.000000e+00, %193 + %214 = select i1 %182, float 0.000000e+00, float %213 + %215 = select i1 %181, float 1.000000e+00, float %214 + %216 = fmul contract float %215, %212 + %217 = fdiv contract float %216, %102 + %218 = insertelement <4 x float> poison, float %217, i64 0 + %219 = shufflevector <4 x float> %218, <4 x float> poison, <4 x i32> zeroinitializer + %220 = fmul contract <4 x float> %209, %219 br label %.thread .thread: ; preds = %96, %82, %.critedge473 - %.sroa.0458.1 = phi <4 x float> [ %222, %.critedge473 ], [ %93, %82 ], [ %101, %96 ] + %.sroa.0458.1 = phi <4 x float> [ %220, %.critedge473 ], [ %93, %82 ], [ %101, %96 ] %.sroa.19.2 = phi i32 [ 1, %.critedge473 ], [ 0, %82 ], [ 0, %96 ] %.sroa.16.2 = phi i32 [ 2, %.critedge473 ], [ 32, %82 ], [ 32, %96 ] - %.sroa.9.2 = phi float [ %169, %.critedge473 ], [ %.0328, %82 ], [ %.0328, %96 ] - %.sroa.0445.1 = phi <4 x float> [ %167, %.critedge473 ], [ %90, %82 ], [ %90, %96 ] + %.sroa.9.2 = phi float [ %167, %.critedge473 ], [ %.0328, %82 ], [ %.0328, %96 ] + %.sroa.0445.1 = phi <4 x float> [ %165, %.critedge473 ], [ %90, %82 ], [ %90, %96 ] store <4 x float> zeroinitializer, ptr %10, align 16 call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %7) - br label %223 - -223: ; preds = %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i, %.thread - %.012.i = phi i64 [ 0, %.thread ], [ %232, %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i ] - %224 = getelementptr inbounds nuw float, ptr %10, i64 %.012.i - %225 = load float, ptr %224, align 4 - %226 = insertelement <4 x float> poison, float %225, i64 0 - %227 = shufflevector <4 x float> %226, <4 x float> poison, <4 x i32> zeroinitializer - br label %228 - -228: ; preds = %228, %223 - %.05.i.i.i = phi i64 [ 0, %223 ], [ %230, %228 ] - %229 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %7, i64 0, i64 %.05.i.i.i - store <4 x float> %227, ptr %229, align 16 - %230 = add nuw nsw i64 %.05.i.i.i, 1 - %exitcond.not.i.i.i = icmp eq i64 %230, 4 - br i1 %exitcond.not.i.i.i, label %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i, label %228, !llvm.loop !10 - -_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i: ; preds = %228 - %231 = getelementptr inbounds nuw [4 x %"struct.drjit::Array"], ptr %11, i64 0, i64 %.012.i - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %231, ptr noundef nonnull align 16 dereferenceable(64) %7, i64 64, i1 false) - %232 = add nuw nsw i64 %.012.i, 1 - %exitcond.not.i341 = icmp eq i64 %232, 4 - br i1 %exitcond.not.i341, label %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit, label %223, !llvm.loop !11 + br label %221 + +221: ; preds = %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i, %.thread + %.012.i = phi i64 [ 0, %.thread ], [ %230, %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i ] + %222 = getelementptr inbounds nuw float, ptr %10, i64 %.012.i + %223 = load float, ptr %222, align 4 + %224 = insertelement <4 x float> poison, float %223, i64 0 + %225 = shufflevector <4 x float> %224, <4 x float> poison, <4 x i32> zeroinitializer + br label %226 + +226: ; preds = %226, %221 + %.05.i.i.i = phi i64 [ 0, %221 ], [ %228, %226 ] + %227 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %7, i64 0, i64 %.05.i.i.i + store <4 x float> %225, ptr %227, align 16 + %228 = add nuw nsw i64 %.05.i.i.i, 1 + %exitcond.not.i.i.i = icmp eq i64 %228, 4 + br i1 %exitcond.not.i.i.i, label %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i, label %226, !llvm.loop !10 + +_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i: ; preds = %226 + %229 = getelementptr inbounds nuw [4 x %"struct.drjit::Array"], ptr %11, i64 0, i64 %.012.i + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %229, ptr noundef nonnull align 16 dereferenceable(64) %7, i64 64, i1 false) + %230 = add nuw nsw i64 %.012.i, 1 + %exitcond.not.i341 = icmp eq i64 %230, 4 + br i1 %exitcond.not.i341, label %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit, label %221, !llvm.loop !11 _ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit: ; preds = %_ZN5drjit5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EECI2NS_15StaticArrayImplIS3_Lm4ELb0ES4_iEEIfTnNSt3__19enable_ifIXsr3stdE11is_scalar_vIT_EEiE4typeELi0EEES8_.exit.i call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %7) - br label %233 - -233: ; preds = %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit, %233 - %.0476 = phi i64 [ 0, %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit ], [ %236, %233 ] - %234 = getelementptr inbounds nuw [4 x %"struct.drjit::Array"], ptr %11, i64 0, i64 %.0476 - %235 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %234, i64 0, i64 %.0476 - store <4 x float> %.sroa.0458.1, ptr %235, align 16 - %236 = add nuw nsw i64 %.0476, 1 - %exitcond.not = icmp eq i64 %236, 4 - br i1 %exitcond.not, label %237, label %233, !llvm.loop !12 - -237: ; preds = %233 + br label %231 + +231: ; preds = %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit, %231 + %.0476 = phi i64 [ 0, %_ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_6MatrixIS4_Lm4EEEiEC2IfS4_S7_TnNSt3__19enable_ifIXoonesrT1_4SizesrT0_4SizenesrSC_5DepthsrSD_5DepthEiE4typeELi0EEERKNS_9ArrayBaseIT_Lb0ESD_EE.exit ], [ %234, %231 ] + %232 = getelementptr inbounds nuw [4 x %"struct.drjit::Array"], ptr %11, i64 0, i64 %.0476 + %233 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %232, i64 0, i64 %.0476 + store <4 x float> %.sroa.0458.1, ptr %233, align 16 + %234 = add nuw nsw i64 %.0476, 1 + %exitcond.not = icmp eq i64 %234, 4 + br i1 %exitcond.not, label %235, label %231, !llvm.loop !12 + +235: ; preds = %231 %.sroa.0.i.16.i.16.i.16..sroa_idx = getelementptr inbounds nuw i8, ptr %.sroa.0.i, i64 16 call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(240) %.sroa.0.i.16.i.16.i.16..sroa_idx, i8 0, i64 240, i1 false) call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %.sroa.0.i, ptr noundef nonnull align 16 dereferenceable(256) %11, i64 16, i1 false) @@ -1714,11 +1713,11 @@ _ZN5drjit15StaticArrayImplINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS_ store i32 %.sroa.16.2, ptr %.sroa.16.0..sroa_idx454, align 8 %.sroa.19.0..sroa_idx456 = getelementptr inbounds nuw i8, ptr %0, i64 28 store i32 %.sroa.19.2, ptr %.sroa.19.0..sroa_idx456, align 4 - %238 = getelementptr inbounds nuw i8, ptr %0, i64 32 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %238, ptr noundef nonnull align 16 dereferenceable(256) %.sroa.0.i, i64 256, i1 false) - br label %239 + %236 = getelementptr inbounds nuw i8, ptr %0, i64 32 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %236, ptr noundef nonnull align 16 dereferenceable(256) %.sroa.0.i, i64 256, i1 false) + br label %237 -239: ; preds = %_ZNSt3__14pairIN7mitsuba11BSDFSample3IfN5drjit6MatrixINS1_8SpectrumIfLm4EEELm4EEEEES7_EC2B8ne190000IRS8_RS6_TnNS_9enable_ifIXclsr10_CheckArgsE23__is_pair_constructibleIT_T0_EEEiE4typeELi0EEEOSE_OSF_.exit, %237 +237: ; preds = %_ZNSt3__14pairIN7mitsuba11BSDFSample3IfN5drjit6MatrixINS1_8SpectrumIfLm4EEELm4EEEEES7_EC2B8ne190000IRS8_RS6_TnNS_9enable_ifIXclsr10_CheckArgsE23__is_pair_constructibleIT_T0_EEEiE4typeELi0EEEOSE_OSF_.exit, %235 ret void } diff --git a/bench/mitsuba3/optimized/sggx.cpp.ll b/bench/mitsuba3/optimized/sggx.cpp.ll index a7a01f4a19d..a319790b49b 100644 --- a/bench/mitsuba3/optimized/sggx.cpp.ll +++ b/bench/mitsuba3/optimized/sggx.cpp.ll @@ -1037,87 +1037,86 @@ _ZN5drjitmlIffLm3EEENS_6MatrixINS_6detail14replace_scalarINS2_7deepestIJT_T0_EE4 %156 = fdiv contract float %155, %.sroa.speculated578 %157 = fsub contract float 0x3FF921FB60000000, %156 %spec.select = select i1 %154, float %157, float %156 - %158 = tail call float @llvm.fabs.f32(float %spec.select) - %159 = select contract i1 %narrow, float 0.000000e+00, float %158 - %160 = fmul contract float %159, 0x3FF45F3060000000 - %161 = fptosi float %160 to i32 - %162 = add nsw i32 %161, 1 - %163 = and i32 %162, -2 - %164 = sitofp i32 %163 to float - %165 = shl i32 %163, 29 - %166 = bitcast float %spec.select to i32 - %167 = select i1 %narrow, i32 0, i32 %166 - %168 = xor i32 %165, %167 - %169 = sub i32 0, %165 - %170 = fmul contract float %164, 0x3FE9200000000000 - %171 = fsub contract float %159, %170 - %172 = fmul contract float %164, 0x3F2FB40000000000 + %.1 = select i1 %narrow, float 0.000000e+00, float %spec.select + %158 = tail call contract noundef float @llvm.fabs.f32(float %.1) + %159 = fmul contract float %158, 0x3FF45F3060000000 + %160 = fptosi float %159 to i32 + %161 = add nsw i32 %160, 1 + %162 = and i32 %161, -2 + %163 = sitofp i32 %162 to float + %164 = shl i32 %162, 29 + %165 = bitcast float %.1 to i32 + %166 = xor i32 %164, %165 + %167 = sub i32 0, %164 + %168 = fmul contract float %163, 0x3FE9200000000000 + %169 = fsub contract float %158, %168 + %170 = fmul contract float %163, 0x3F2FB40000000000 + %171 = fsub contract float %169, %170 + %172 = fmul contract float %163, 0x3E64442D20000000 %173 = fsub contract float %171, %172 - %174 = fmul contract float %164, 0x3E64442D20000000 - %175 = fsub contract float %173, %174 - %176 = fmul contract float %175, %175 - %177 = fcmp contract oeq float %159, 0x7FF0000000000000 - %178 = select i1 %177, float 0xFFFFFFFFE0000000, float %176 - %179 = tail call contract noundef float @llvm.fma.f32(float %178, float 0x3F811073C0000000, float 0xBFC5555460000000) - %180 = fmul contract float %178, %178 - %181 = tail call contract noundef float @llvm.fma.f32(float %180, float 0xBF29943F20000000, float %179) - %182 = fmul contract float %178, %181 - %183 = tail call contract noundef float @llvm.fma.f32(float %178, float 0xBF56C0C340000000, float 0x3FA55554A0000000) - %184 = tail call contract noundef float @llvm.fma.f32(float %180, float 0x3EF99EB9C0000000, float %183) - %185 = fmul contract float %178, %184 - %186 = tail call contract noundef float @llvm.fma.f32(float %182, float %175, float %175) - %187 = tail call contract noundef float @llvm.fma.f32(float %178, float -5.000000e-01, float 1.000000e+00) - %188 = tail call contract noundef float @llvm.fma.f32(float %185, float %178, float %187) - %189 = and i32 %162, 2 - %190 = icmp eq i32 %189, 0 - %191 = select contract i1 %190, float %186, float %188 - %192 = and i32 %168, -2147483648 - %193 = bitcast float %191 to i32 - %194 = xor i32 %192, %193 - %195 = select contract i1 %190, float %188, float %186 - %196 = and i32 %169, -2147483648 - %197 = bitcast float %195 to i32 - %198 = xor i32 %196, %197 - %.sroa.0568.4.vec.extract = bitcast i32 %198 to float - %199 = fmul contract float %.sroa.speculated578, %.sroa.0568.4.vec.extract - %.sroa.0568.0.vec.extract = bitcast i32 %194 to float - %200 = fmul contract float %.sroa.speculated578, %.sroa.0568.0.vec.extract - %201 = fmul contract float %199, %199 - %202 = fmul contract float %200, %200 - %203 = fadd contract float %201, %202 - %204 = fsub contract float 1.000000e+00, %203 - %205 = fcmp contract olt float %204, 0.000000e+00 - %..i524 = select contract i1 %205, float 0.000000e+00, float %204 - %206 = tail call contract noundef float @llvm.sqrt.f32(float %..i524) - %207 = insertelement <4 x float> poison, float %199, i64 0 - %208 = shufflevector <4 x float> %207, <4 x float> poison, <4 x i32> zeroinitializer - %209 = fmul contract <4 x float> %127, %208 - %210 = insertelement <4 x float> poison, float %200, i64 0 - %211 = shufflevector <4 x float> %210, <4 x float> poison, <4 x i32> zeroinitializer - %212 = fmul contract <4 x float> %138, %211 - %213 = fadd contract <4 x float> %209, %212 - %214 = insertelement <4 x float> poison, float %206, i64 0 - %215 = shufflevector <4 x float> %214, <4 x float> poison, <4 x i32> zeroinitializer - %216 = fmul contract <4 x float> %144, %215 - %217 = fadd contract <4 x float> %213, %216 - %218 = fmul contract <4 x float> %217, %217 - %shift = shufflevector <4 x float> %218, <4 x float> poison, <4 x i32> - %219 = fadd contract <4 x float> %218, %shift - %shift609 = shufflevector <4 x float> %218, <4 x float> poison, <4 x i32> - %220 = fadd contract <4 x float> %shift609, %219 - %221 = extractelement <4 x float> %220, i64 0 - %222 = tail call contract noundef float @llvm.sqrt.f32(float %221) - %223 = fdiv contract float 1.000000e+00, %222 - %224 = insertelement <4 x float> poison, float %223, i64 0 + %174 = fmul contract float %173, %173 + %175 = fcmp contract oeq float %158, 0x7FF0000000000000 + %176 = select i1 %175, float 0xFFFFFFFFE0000000, float %174 + %177 = tail call contract noundef float @llvm.fma.f32(float %176, float 0x3F811073C0000000, float 0xBFC5555460000000) + %178 = fmul contract float %176, %176 + %179 = tail call contract noundef float @llvm.fma.f32(float %178, float 0xBF29943F20000000, float %177) + %180 = fmul contract float %176, %179 + %181 = tail call contract noundef float @llvm.fma.f32(float %176, float 0xBF56C0C340000000, float 0x3FA55554A0000000) + %182 = tail call contract noundef float @llvm.fma.f32(float %178, float 0x3EF99EB9C0000000, float %181) + %183 = fmul contract float %176, %182 + %184 = tail call contract noundef float @llvm.fma.f32(float %180, float %173, float %173) + %185 = tail call contract noundef float @llvm.fma.f32(float %176, float -5.000000e-01, float 1.000000e+00) + %186 = tail call contract noundef float @llvm.fma.f32(float %183, float %176, float %185) + %187 = and i32 %161, 2 + %188 = icmp eq i32 %187, 0 + %189 = select contract i1 %188, float %184, float %186 + %190 = and i32 %166, -2147483648 + %191 = bitcast float %189 to i32 + %192 = xor i32 %190, %191 + %193 = select contract i1 %188, float %186, float %184 + %194 = and i32 %167, -2147483648 + %195 = bitcast float %193 to i32 + %196 = xor i32 %194, %195 + %.sroa.0568.4.vec.extract = bitcast i32 %196 to float + %197 = fmul contract float %.sroa.speculated578, %.sroa.0568.4.vec.extract + %.sroa.0568.0.vec.extract = bitcast i32 %192 to float + %198 = fmul contract float %.sroa.speculated578, %.sroa.0568.0.vec.extract + %199 = fmul contract float %197, %197 + %200 = fmul contract float %198, %198 + %201 = fadd contract float %199, %200 + %202 = fsub contract float 1.000000e+00, %201 + %203 = fcmp contract olt float %202, 0.000000e+00 + %..i524 = select contract i1 %203, float 0.000000e+00, float %202 + %204 = tail call contract noundef float @llvm.sqrt.f32(float %..i524) + %205 = insertelement <4 x float> poison, float %197, i64 0 + %206 = shufflevector <4 x float> %205, <4 x float> poison, <4 x i32> zeroinitializer + %207 = fmul contract <4 x float> %127, %206 + %208 = insertelement <4 x float> poison, float %198, i64 0 + %209 = shufflevector <4 x float> %208, <4 x float> poison, <4 x i32> zeroinitializer + %210 = fmul contract <4 x float> %138, %209 + %211 = fadd contract <4 x float> %207, %210 + %212 = insertelement <4 x float> poison, float %204, i64 0 + %213 = shufflevector <4 x float> %212, <4 x float> poison, <4 x i32> zeroinitializer + %214 = fmul contract <4 x float> %144, %213 + %215 = fadd contract <4 x float> %211, %214 + %216 = fmul contract <4 x float> %215, %215 + %shift = shufflevector <4 x float> %216, <4 x float> poison, <4 x i32> + %217 = fadd contract <4 x float> %216, %shift + %shift609 = shufflevector <4 x float> %216, <4 x float> poison, <4 x i32> + %218 = fadd contract <4 x float> %shift609, %217 + %219 = extractelement <4 x float> %218, i64 0 + %220 = tail call contract noundef float @llvm.sqrt.f32(float %219) + %221 = fdiv contract float 1.000000e+00, %220 + %222 = insertelement <4 x float> poison, float %221, i64 0 + %223 = shufflevector <4 x float> %222, <4 x float> poison, <4 x i32> zeroinitializer + %224 = fmul contract <4 x float> %215, %223 %225 = shufflevector <4 x float> %224, <4 x float> poison, <4 x i32> zeroinitializer - %226 = fmul contract <4 x float> %217, %225 - %227 = shufflevector <4 x float> %226, <4 x float> poison, <4 x i32> zeroinitializer - %228 = fmul contract <4 x float> %12, %227 - %229 = shufflevector <4 x float> %226, <4 x float> poison, <4 x i32> - %230 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %14, <4 x float> %229, <4 x float> %228) - %231 = shufflevector <4 x float> %226, <4 x float> poison, <4 x i32> - %232 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %16, <4 x float> %231, <4 x float> %230) - ret <4 x float> %232 + %226 = fmul contract <4 x float> %12, %225 + %227 = shufflevector <4 x float> %224, <4 x float> poison, <4 x i32> + %228 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %14, <4 x float> %227, <4 x float> %226) + %229 = shufflevector <4 x float> %224, <4 x float> poison, <4 x i32> + %230 = tail call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %16, <4 x float> %229, <4 x float> %228) + ret <4 x float> %230 } ; Function Attrs: mustprogress uwtable diff --git a/bench/mitsuba3/optimized/spot.cpp.ll b/bench/mitsuba3/optimized/spot.cpp.ll index f77a02d54b4..5aee7e94f03 100644 --- a/bench/mitsuba3/optimized/spot.cpp.ll +++ b/bench/mitsuba3/optimized/spot.cpp.ll @@ -926,285 +926,284 @@ define weak_odr void @_ZNK7mitsuba9SpotLightIfN5drjit6MatrixINS_8SpectrumIfLm4EE %32 = fdiv contract float %31, %.sroa.speculated350 %33 = fsub contract float 0x3FF921FB60000000, %32 %spec.select = select i1 %30, float %33, float %32 - %34 = tail call float @llvm.fabs.f32(float %spec.select) - %35 = select contract i1 %narrow, float 0.000000e+00, float %34 - %36 = fmul contract float %35, 0x3FF45F3060000000 - %37 = fptosi float %36 to i32 - %38 = add nsw i32 %37, 1 - %39 = and i32 %38, -2 - %40 = sitofp i32 %39 to float - %41 = shl i32 %39, 29 - %42 = bitcast float %spec.select to i32 - %43 = select i1 %narrow, i32 0, i32 %42 - %44 = xor i32 %41, %43 - %45 = sub i32 0, %41 - %46 = fmul contract float %40, 0x3FE9200000000000 - %47 = fsub contract float %35, %46 - %48 = fmul contract float %40, 0x3F2FB40000000000 + %.1 = select i1 %narrow, float 0.000000e+00, float %spec.select + %34 = tail call contract noundef float @llvm.fabs.f32(float %.1) + %35 = fmul contract float %34, 0x3FF45F3060000000 + %36 = fptosi float %35 to i32 + %37 = add nsw i32 %36, 1 + %38 = and i32 %37, -2 + %39 = sitofp i32 %38 to float + %40 = shl i32 %38, 29 + %41 = bitcast float %.1 to i32 + %42 = xor i32 %40, %41 + %43 = sub i32 0, %40 + %44 = fmul contract float %39, 0x3FE9200000000000 + %45 = fsub contract float %34, %44 + %46 = fmul contract float %39, 0x3F2FB40000000000 + %47 = fsub contract float %45, %46 + %48 = fmul contract float %39, 0x3E64442D20000000 %49 = fsub contract float %47, %48 - %50 = fmul contract float %40, 0x3E64442D20000000 - %51 = fsub contract float %49, %50 - %52 = fmul contract float %51, %51 - %53 = fcmp contract oeq float %35, 0x7FF0000000000000 - %54 = select i1 %53, float 0xFFFFFFFFE0000000, float %52 - %55 = tail call contract noundef float @llvm.fma.f32(float %54, float 0x3F811073C0000000, float 0xBFC5555460000000) - %56 = fmul contract float %54, %54 - %57 = tail call contract noundef float @llvm.fma.f32(float %56, float 0xBF29943F20000000, float %55) - %58 = fmul contract float %54, %57 - %59 = tail call contract noundef float @llvm.fma.f32(float %54, float 0xBF56C0C340000000, float 0x3FA55554A0000000) - %60 = tail call contract noundef float @llvm.fma.f32(float %56, float 0x3EF99EB9C0000000, float %59) - %61 = fmul contract float %54, %60 - %62 = tail call contract noundef float @llvm.fma.f32(float %58, float %51, float %51) - %63 = tail call contract noundef float @llvm.fma.f32(float %54, float -5.000000e-01, float 1.000000e+00) - %64 = tail call contract noundef float @llvm.fma.f32(float %61, float %54, float %63) - %65 = and i32 %38, 2 - %66 = icmp eq i32 %65, 0 - %67 = select contract i1 %66, float %62, float %64 - %68 = and i32 %44, -2147483648 - %69 = bitcast float %67 to i32 - %70 = xor i32 %68, %69 - %71 = select contract i1 %66, float %64, float %62 - %72 = and i32 %45, -2147483648 - %73 = bitcast float %71 to i32 - %74 = xor i32 %72, %73 - %.sroa.0340.4.vec.extract = bitcast i32 %74 to float - %75 = fmul contract float %.sroa.speculated350, %.sroa.0340.4.vec.extract - %.sroa.0340.0.vec.extract = bitcast i32 %70 to float - %76 = fmul contract float %.sroa.speculated350, %.sroa.0340.0.vec.extract - %77 = fmul contract float %75, %75 - %78 = fmul contract float %76, %76 - %79 = fadd contract float %77, %78 - %80 = fsub contract float 1.000000e+00, %79 - %81 = fmul contract float %20, %80 - %82 = fadd contract float %19, %81 - %83 = fmul contract float %20, %79 - %84 = fsub contract float 2.000000e+00, %83 - %85 = fmul contract float %20, %84 - %86 = fcmp contract olt float %85, 0.000000e+00 - %..i = select contract i1 %86, float 0.000000e+00, float %85 - %87 = tail call contract noundef float @llvm.sqrt.f32(float %..i) - %88 = fmul contract float %75, %87 - %89 = fmul contract float %76, %87 - %90 = insertelement <4 x float> , float %88, i64 0 - %91 = insertelement <4 x float> %90, float %89, i64 1 - %92 = insertelement <4 x float> %91, float %82, i64 2 - %93 = getelementptr inbounds nuw i8, ptr %16, i64 232 - %94 = getelementptr inbounds nuw i8, ptr %16, i64 4 - %95 = getelementptr inbounds nuw i8, ptr %16, i64 16 - %96 = getelementptr inbounds nuw i8, ptr %16, i64 32 - %97 = getelementptr inbounds nuw i8, ptr %16, i64 72 - store ptr null, ptr %93, align 8 - call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(212) %95, i8 0, i64 212, i1 false) + %50 = fmul contract float %49, %49 + %51 = fcmp contract oeq float %34, 0x7FF0000000000000 + %52 = select i1 %51, float 0xFFFFFFFFE0000000, float %50 + %53 = tail call contract noundef float @llvm.fma.f32(float %52, float 0x3F811073C0000000, float 0xBFC5555460000000) + %54 = fmul contract float %52, %52 + %55 = tail call contract noundef float @llvm.fma.f32(float %54, float 0xBF29943F20000000, float %53) + %56 = fmul contract float %52, %55 + %57 = tail call contract noundef float @llvm.fma.f32(float %52, float 0xBF56C0C340000000, float 0x3FA55554A0000000) + %58 = tail call contract noundef float @llvm.fma.f32(float %54, float 0x3EF99EB9C0000000, float %57) + %59 = fmul contract float %52, %58 + %60 = tail call contract noundef float @llvm.fma.f32(float %56, float %49, float %49) + %61 = tail call contract noundef float @llvm.fma.f32(float %52, float -5.000000e-01, float 1.000000e+00) + %62 = tail call contract noundef float @llvm.fma.f32(float %59, float %52, float %61) + %63 = and i32 %37, 2 + %64 = icmp eq i32 %63, 0 + %65 = select contract i1 %64, float %60, float %62 + %66 = and i32 %42, -2147483648 + %67 = bitcast float %65 to i32 + %68 = xor i32 %66, %67 + %69 = select contract i1 %64, float %62, float %60 + %70 = and i32 %43, -2147483648 + %71 = bitcast float %69 to i32 + %72 = xor i32 %70, %71 + %.sroa.0340.4.vec.extract = bitcast i32 %72 to float + %73 = fmul contract float %.sroa.speculated350, %.sroa.0340.4.vec.extract + %.sroa.0340.0.vec.extract = bitcast i32 %68 to float + %74 = fmul contract float %.sroa.speculated350, %.sroa.0340.0.vec.extract + %75 = fmul contract float %73, %73 + %76 = fmul contract float %74, %74 + %77 = fadd contract float %75, %76 + %78 = fsub contract float 1.000000e+00, %77 + %79 = fmul contract float %20, %78 + %80 = fadd contract float %19, %79 + %81 = fmul contract float %20, %77 + %82 = fsub contract float 2.000000e+00, %81 + %83 = fmul contract float %20, %82 + %84 = fcmp contract olt float %83, 0.000000e+00 + %..i = select contract i1 %84, float 0.000000e+00, float %83 + %85 = tail call contract noundef float @llvm.sqrt.f32(float %..i) + %86 = fmul contract float %73, %85 + %87 = fmul contract float %74, %85 + %88 = insertelement <4 x float> , float %86, i64 0 + %89 = insertelement <4 x float> %88, float %87, i64 1 + %90 = insertelement <4 x float> %89, float %80, i64 2 + %91 = getelementptr inbounds nuw i8, ptr %16, i64 232 + %92 = getelementptr inbounds nuw i8, ptr %16, i64 4 + %93 = getelementptr inbounds nuw i8, ptr %16, i64 16 + %94 = getelementptr inbounds nuw i8, ptr %16, i64 32 + %95 = getelementptr inbounds nuw i8, ptr %16, i64 72 + store ptr null, ptr %91, align 8 + call void @llvm.memset.p0.i64(ptr noundef nonnull align 16 dereferenceable(212) %93, i8 0, i64 212, i1 false) store float 0x7FF0000000000000, ptr %16, align 16 - store float %2, ptr %94, align 4 - %98 = getelementptr inbounds nuw i8, ptr %1, i64 16 - %99 = getelementptr inbounds nuw i8, ptr %1, i64 64 - %100 = load <4 x float>, ptr %99, align 16 - store <4 x float> %100, ptr %96, align 16 - %101 = fmul contract float %88, 5.000000e-01 - %102 = getelementptr inbounds nuw i8, ptr %1, i64 232 - %103 = load float, ptr %102, align 8 - %104 = fmul contract float %82, %103 - %105 = fdiv contract float %101, %104 - %106 = fadd contract float %105, 5.000000e-01 - %107 = fmul contract float %89, 5.000000e-01 - %108 = fdiv contract float %107, %104 - %109 = fadd contract float %108, 5.000000e-01 - %.sroa.0.0.vec.insert.i = insertelement <2 x float> poison, float %106, i64 0 - %.sroa.0.4.vec.insert.i300 = insertelement <2 x float> %.sroa.0.0.vec.insert.i, float %109, i64 1 - store <2 x float> %.sroa.0.4.vec.insert.i300, ptr %97, align 8 + store float %2, ptr %92, align 4 + %96 = getelementptr inbounds nuw i8, ptr %1, i64 16 + %97 = getelementptr inbounds nuw i8, ptr %1, i64 64 + %98 = load <4 x float>, ptr %97, align 16 + store <4 x float> %98, ptr %94, align 16 + %99 = fmul contract float %86, 5.000000e-01 + %100 = getelementptr inbounds nuw i8, ptr %1, i64 232 + %101 = load float, ptr %100, align 8 + %102 = fmul contract float %80, %101 + %103 = fdiv contract float %99, %102 + %104 = fadd contract float %103, 5.000000e-01 + %105 = fmul contract float %87, 5.000000e-01 + %106 = fdiv contract float %105, %102 + %107 = fadd contract float %106, 5.000000e-01 + %.sroa.0.0.vec.insert.i = insertelement <2 x float> poison, float %104, i64 0 + %.sroa.0.4.vec.insert.i300 = insertelement <2 x float> %.sroa.0.0.vec.insert.i, float %107, i64 1 + store <2 x float> %.sroa.0.4.vec.insert.i300, ptr %95, align 8 call void @_ZNK7mitsuba9SpotLightIfN5drjit6MatrixINS_8SpectrumIfLm4EEELm4EEEE18sample_wavelengthsERKNS_18SurfaceInteractionIfS5_EEfb(ptr dead_on_unwind nonnull writable sret(%"struct.std::__1::pair.41") align 16 %17, ptr noundef nonnull align 16 dereferenceable(256) %1, ptr noundef nonnull align 16 dereferenceable(240) %16, float noundef %3, i1 noundef zeroext true) - %110 = fmul contract <4 x float> %92, %92 - %shift = shufflevector <4 x float> %110, <4 x float> poison, <4 x i32> - %111 = fadd contract <4 x float> %110, %shift - %shift419 = shufflevector <4 x float> %110, <4 x float> poison, <4 x i32> - %112 = fadd contract <4 x float> %shift419, %111 - %113 = extractelement <4 x float> %112, i64 0 - %114 = call contract noundef float @llvm.sqrt.f32(float %113) - %115 = fdiv contract float 1.000000e+00, %114 - %.sroa.064.8.vec.extract.i = fmul contract float %82, %115 - %116 = getelementptr inbounds nuw i8, ptr %1, i64 236 + %108 = fmul contract <4 x float> %90, %90 + %shift = shufflevector <4 x float> %108, <4 x float> poison, <4 x i32> + %109 = fadd contract <4 x float> %108, %shift + %shift419 = shufflevector <4 x float> %108, <4 x float> poison, <4 x i32> + %110 = fadd contract <4 x float> %shift419, %109 + %111 = extractelement <4 x float> %110, i64 0 + %112 = call contract noundef float @llvm.sqrt.f32(float %111) + %113 = fdiv contract float 1.000000e+00, %112 + %.sroa.064.8.vec.extract.i = fmul contract float %80, %113 + %114 = getelementptr inbounds nuw i8, ptr %1, i64 236 + %115 = load float, ptr %114, align 4 + %116 = getelementptr inbounds nuw i8, ptr %1, i64 228 %117 = load float, ptr %116, align 4 - %118 = getelementptr inbounds nuw i8, ptr %1, i64 228 - %119 = load float, ptr %118, align 4 - %120 = call contract noundef float @llvm.fabs.f32(float %.sroa.064.8.vec.extract.i) - %121 = fcmp contract ogt float %120, 5.000000e-01 - %122 = fsub contract float 1.000000e+00, %120 - %123 = fmul contract float %122, 5.000000e-01 - %124 = fmul contract float %.sroa.064.8.vec.extract.i, %.sroa.064.8.vec.extract.i - %125 = select contract i1 %121, float %123, float %124 - %126 = call contract noundef float @llvm.fma.f32(float %125, float 0x3FB3301EC0000000, float 0x3FC5555C80000000) - %127 = call contract noundef float @llvm.fma.f32(float %125, float 0x3F98C2FC60000000, float 0x3FA747D8E0000000) - %128 = call contract noundef float @llvm.sqrt.f32(float %123) - %129 = select contract i1 %121, float %128, float %120 - %130 = fmul contract float %125, %125 - %131 = call contract noundef float @llvm.fma.f32(float %130, float %127, float %126) - %132 = fmul contract float %130, %130 - %133 = call contract noundef float @llvm.fma.f32(float %132, float 0x3FA5966A40000000, float %131) - %134 = fmul contract float %125, %129 - %135 = call contract noundef float @llvm.fma.f32(float %133, float %134, float %129) - %136 = fadd contract float %135, %135 - %137 = fcmp contract olt float %.sroa.064.8.vec.extract.i, 0.000000e+00 - %138 = fsub contract float 0x400921FB60000000, %136 - %139 = select contract i1 %137, float %138, float %136 - %140 = call float @llvm.copysign.f32(float %135, float %.sroa.064.8.vec.extract.i) - %141 = fsub contract float 0x3FF921FB60000000, %140 - %142 = select contract i1 %121, float %139, float %141 - %143 = fsub contract float %119, %142 - %144 = getelementptr inbounds nuw i8, ptr %1, i64 244 - %145 = load float, ptr %144, align 4 - %146 = fmul contract float %145, %143 - %147 = load float, ptr %18, align 16 - %148 = fcmp contract ogt float %.sroa.064.8.vec.extract.i, %147 - %.sroa.0334.0.copyload = load <4 x float>, ptr %98, align 16 - %149 = getelementptr inbounds nuw i8, ptr %1, i64 32 + %118 = call contract noundef float @llvm.fabs.f32(float %.sroa.064.8.vec.extract.i) + %119 = fcmp contract ogt float %118, 5.000000e-01 + %120 = fsub contract float 1.000000e+00, %118 + %121 = fmul contract float %120, 5.000000e-01 + %122 = fmul contract float %.sroa.064.8.vec.extract.i, %.sroa.064.8.vec.extract.i + %123 = select contract i1 %119, float %121, float %122 + %124 = call contract noundef float @llvm.fma.f32(float %123, float 0x3FB3301EC0000000, float 0x3FC5555C80000000) + %125 = call contract noundef float @llvm.fma.f32(float %123, float 0x3F98C2FC60000000, float 0x3FA747D8E0000000) + %126 = call contract noundef float @llvm.sqrt.f32(float %121) + %127 = select contract i1 %119, float %126, float %118 + %128 = fmul contract float %123, %123 + %129 = call contract noundef float @llvm.fma.f32(float %128, float %125, float %124) + %130 = fmul contract float %128, %128 + %131 = call contract noundef float @llvm.fma.f32(float %130, float 0x3FA5966A40000000, float %129) + %132 = fmul contract float %123, %127 + %133 = call contract noundef float @llvm.fma.f32(float %131, float %132, float %127) + %134 = fadd contract float %133, %133 + %135 = fcmp contract olt float %.sroa.064.8.vec.extract.i, 0.000000e+00 + %136 = fsub contract float 0x400921FB60000000, %134 + %137 = select contract i1 %135, float %136, float %134 + %138 = call float @llvm.copysign.f32(float %133, float %.sroa.064.8.vec.extract.i) + %139 = fsub contract float 0x3FF921FB60000000, %138 + %140 = select contract i1 %119, float %137, float %139 + %141 = fsub contract float %117, %140 + %142 = getelementptr inbounds nuw i8, ptr %1, i64 244 + %143 = load float, ptr %142, align 4 + %144 = fmul contract float %143, %141 + %145 = load float, ptr %18, align 16 + %146 = fcmp contract ogt float %.sroa.064.8.vec.extract.i, %145 + %.sroa.0334.0.copyload = load <4 x float>, ptr %96, align 16 + %147 = getelementptr inbounds nuw i8, ptr %1, i64 32 + %148 = load <4 x float>, ptr %147, align 16 + %149 = getelementptr inbounds nuw i8, ptr %1, i64 48 %150 = load <4 x float>, ptr %149, align 16 - %151 = getelementptr inbounds nuw i8, ptr %1, i64 48 - %152 = load <4 x float>, ptr %151, align 16 - %153 = getelementptr inbounds nuw i8, ptr %17, i64 16 - %154 = fcmp contract ult float %.sroa.064.8.vec.extract.i, %117 - %155 = select contract i1 %154, float %146, float 1.000000e+00 - %.sroa.0315.0.copyload316 = load <4 x float>, ptr %96, align 16 + %151 = getelementptr inbounds nuw i8, ptr %17, i64 16 + %152 = fcmp contract ult float %.sroa.064.8.vec.extract.i, %115 + %153 = select contract i1 %152, float %144, float 1.000000e+00 + %.sroa.0315.0.copyload316 = load <4 x float>, ptr %94, align 16 %.sroa.5.48..sroa_idx = getelementptr inbounds nuw i8, ptr %.sroa.5, i64 8 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %.sroa.5.48..sroa_idx, ptr noundef nonnull align 16 dereferenceable(16) %17, i64 16, i1 false) call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %14) call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %15) - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %14, ptr noundef nonnull align 16 dereferenceable(256) %153, i64 256, i1 false), !noalias !10 - %156 = select contract i1 %148, float %155, float 0.000000e+00 - %157 = insertelement <4 x float> poison, float %156, i64 0 - %158 = shufflevector <4 x float> %157, <4 x float> poison, <4 x i32> zeroinitializer + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %14, ptr noundef nonnull align 16 dereferenceable(256) %151, i64 256, i1 false), !noalias !10 + %154 = select contract i1 %146, float %153, float 0.000000e+00 + %155 = insertelement <4 x float> poison, float %154, i64 0 + %156 = shufflevector <4 x float> %155, <4 x float> poison, <4 x i32> zeroinitializer call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %12), !noalias !10 - br label %159 - -159: ; preds = %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i, %.critedge - %.08.i.i = phi i64 [ 0, %.critedge ], [ %164, %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i ] - br label %160 - -160: ; preds = %160, %159 - %.09.i.i.i = phi i64 [ 0, %159 ], [ %162, %160 ] - %161 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %12, i64 0, i64 %.09.i.i.i - store <4 x float> %158, ptr %161, align 16, !alias.scope !13, !noalias !16 - %162 = add nuw nsw i64 %.09.i.i.i, 1 - %exitcond.not.i.i18.i = icmp eq i64 %162, 4 - br i1 %exitcond.not.i.i18.i, label %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i, label %160, !llvm.loop !19 - -_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i: ; preds = %160 - %163 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %15, i64 0, i64 %.08.i.i - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %163, ptr noundef nonnull align 16 dereferenceable(64) %12, i64 64, i1 false), !noalias !10 - %164 = add nuw nsw i64 %.08.i.i, 1 - %exitcond.not.i.i = icmp eq i64 %164, 4 - br i1 %exitcond.not.i.i, label %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i, label %159, !llvm.loop !21 + br label %157 + +157: ; preds = %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i, %.critedge + %.08.i.i = phi i64 [ 0, %.critedge ], [ %162, %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i ] + br label %158 + +158: ; preds = %158, %157 + %.09.i.i.i = phi i64 [ 0, %157 ], [ %160, %158 ] + %159 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %12, i64 0, i64 %.09.i.i.i + store <4 x float> %156, ptr %159, align 16, !alias.scope !13, !noalias !16 + %160 = add nuw nsw i64 %.09.i.i.i, 1 + %exitcond.not.i.i18.i = icmp eq i64 %160, 4 + br i1 %exitcond.not.i.i18.i, label %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i, label %158, !llvm.loop !19 + +_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i: ; preds = %158 + %161 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %15, i64 0, i64 %.08.i.i + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %161, ptr noundef nonnull align 16 dereferenceable(64) %12, i64 64, i1 false), !noalias !10 + %162 = add nuw nsw i64 %.08.i.i, 1 + %exitcond.not.i.i = icmp eq i64 %162, 4 + br i1 %exitcond.not.i.i, label %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i, label %157, !llvm.loop !21 _ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i: ; preds = %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %12), !noalias !10 call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %11), !noalias !10 - br label %165 + br label %163 -165: ; preds = %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i - %.030.i.i = phi i64 [ 0, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i ], [ %177, %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i ] - %166 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %14, i64 0, i64 %.030.i.i - %167 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %15, i64 0, i64 %.030.i.i +163: ; preds = %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i + %.030.i.i = phi i64 [ 0, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i ], [ %175, %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i ] + %164 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %14, i64 0, i64 %.030.i.i + %165 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %15, i64 0, i64 %.030.i.i call void @llvm.experimental.noalias.scope.decl(metadata !22) - br label %168 - -168: ; preds = %168, %165 - %.034.i.i.i = phi i64 [ 0, %165 ], [ %175, %168 ] - %169 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %166, i64 0, i64 %.034.i.i.i - %170 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %167, i64 0, i64 %.034.i.i.i - %171 = load <4 x float>, ptr %169, align 16, !noalias !25 - %172 = load <4 x float>, ptr %170, align 16, !noalias !25 - %173 = fmul contract <4 x float> %171, %172 - %174 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %11, i64 0, i64 %.034.i.i.i - store <4 x float> %173, ptr %174, align 16, !alias.scope !22, !noalias !28 - %175 = add nuw nsw i64 %.034.i.i.i, 1 - %exitcond.not.i.i19.i = icmp eq i64 %175, 4 - br i1 %exitcond.not.i.i19.i, label %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i, label %168, !llvm.loop !29 - -_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i: ; preds = %168 - %176 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %13, i64 0, i64 %.030.i.i - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %176, ptr noundef nonnull align 16 dereferenceable(64) %11, i64 64, i1 false) - %177 = add nuw nsw i64 %.030.i.i, 1 - %exitcond.not.i20.i = icmp eq i64 %177, 4 - br i1 %exitcond.not.i20.i, label %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i, label %165, !llvm.loop !30 + br label %166 + +166: ; preds = %166, %163 + %.034.i.i.i = phi i64 [ 0, %163 ], [ %173, %166 ] + %167 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %164, i64 0, i64 %.034.i.i.i + %168 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %165, i64 0, i64 %.034.i.i.i + %169 = load <4 x float>, ptr %167, align 16, !noalias !25 + %170 = load <4 x float>, ptr %168, align 16, !noalias !25 + %171 = fmul contract <4 x float> %169, %170 + %172 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %11, i64 0, i64 %.034.i.i.i + store <4 x float> %171, ptr %172, align 16, !alias.scope !22, !noalias !28 + %173 = add nuw nsw i64 %.034.i.i.i, 1 + %exitcond.not.i.i19.i = icmp eq i64 %173, 4 + br i1 %exitcond.not.i.i19.i, label %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i, label %166, !llvm.loop !29 + +_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i: ; preds = %166 + %174 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %13, i64 0, i64 %.030.i.i + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %174, ptr noundef nonnull align 16 dereferenceable(64) %11, i64 64, i1 false) + %175 = add nuw nsw i64 %.030.i.i, 1 + %exitcond.not.i20.i = icmp eq i64 %175, 4 + br i1 %exitcond.not.i20.i, label %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i, label %163, !llvm.loop !30 _ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i: ; preds = %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %11), !noalias !10 call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %14) call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %15) call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %10) - %178 = fdiv contract float 0x3FC45F3060000000, %20 - %179 = insertelement <4 x float> poison, float %178, i64 0 - %180 = shufflevector <4 x float> %179, <4 x float> poison, <4 x i32> zeroinitializer - %181 = call contract noundef <4 x float> @llvm.x86.avx512.rcp14.ps.128(<4 x float> %180, <4 x float> zeroinitializer, i8 -1) - %182 = fadd contract <4 x float> %181, %181 - %183 = fneg contract <4 x float> %180 - %184 = fmul contract <4 x float> %181, %183 - %185 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %184, <4 x float> %181, <4 x float> %182) - %186 = call contract <4 x float> @llvm.x86.avx512.mask.fixupimm.ps.128(<4 x float> %185, <4 x float> %180, <4 x i32> splat (i32 8889890), i32 0, i8 -1) + %176 = fdiv contract float 0x3FC45F3060000000, %20 + %177 = insertelement <4 x float> poison, float %176, i64 0 + %178 = shufflevector <4 x float> %177, <4 x float> poison, <4 x i32> zeroinitializer + %179 = call contract noundef <4 x float> @llvm.x86.avx512.rcp14.ps.128(<4 x float> %178, <4 x float> zeroinitializer, i8 -1) + %180 = fadd contract <4 x float> %179, %179 + %181 = fneg contract <4 x float> %178 + %182 = fmul contract <4 x float> %179, %181 + %183 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %182, <4 x float> %179, <4 x float> %180) + %184 = call contract <4 x float> @llvm.x86.avx512.mask.fixupimm.ps.128(<4 x float> %183, <4 x float> %178, <4 x i32> splat (i32 8889890), i32 0, i8 -1) call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %8), !noalias !31 - br label %187 - -187: ; preds = %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i306, %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i - %.08.i.i304 = phi i64 [ 0, %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i ], [ %192, %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i306 ] - br label %188 - -188: ; preds = %188, %187 - %.09.i.i.i305 = phi i64 [ 0, %187 ], [ %190, %188 ] - %189 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %8, i64 0, i64 %.09.i.i.i305 - store <4 x float> %186, ptr %189, align 16, !alias.scope !34, !noalias !37 - %190 = add nuw nsw i64 %.09.i.i.i305, 1 - %exitcond.not.i.i47.i = icmp eq i64 %190, 4 - br i1 %exitcond.not.i.i47.i, label %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i306, label %188, !llvm.loop !19 - -_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i306: ; preds = %188 - %191 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %10, i64 0, i64 %.08.i.i304 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %191, ptr noundef nonnull align 16 dereferenceable(64) %8, i64 64, i1 false), !noalias !31 - %192 = add nuw nsw i64 %.08.i.i304, 1 - %exitcond.not.i.i307 = icmp eq i64 %192, 4 - br i1 %exitcond.not.i.i307, label %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i308, label %187, !llvm.loop !21 + br label %185 + +185: ; preds = %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i306, %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i + %.08.i.i304 = phi i64 [ 0, %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i ], [ %190, %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i306 ] + br label %186 + +186: ; preds = %186, %185 + %.09.i.i.i305 = phi i64 [ 0, %185 ], [ %188, %186 ] + %187 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %8, i64 0, i64 %.09.i.i.i305 + store <4 x float> %184, ptr %187, align 16, !alias.scope !34, !noalias !37 + %188 = add nuw nsw i64 %.09.i.i.i305, 1 + %exitcond.not.i.i47.i = icmp eq i64 %188, 4 + br i1 %exitcond.not.i.i47.i, label %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i306, label %186, !llvm.loop !19 + +_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i306: ; preds = %186 + %189 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %10, i64 0, i64 %.08.i.i304 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %189, ptr noundef nonnull align 16 dereferenceable(64) %8, i64 64, i1 false), !noalias !31 + %190 = add nuw nsw i64 %.08.i.i304, 1 + %exitcond.not.i.i307 = icmp eq i64 %190, 4 + br i1 %exitcond.not.i.i307, label %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i308, label %185, !llvm.loop !21 _ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i308: ; preds = %_ZN5drjit15StaticArrayBaseIN7mitsuba8SpectrumIfLm4EEELm4ELb0ENS_5ArrayIS3_Lm4EEEE5full_IS3_EES5_RKT_m.exit.i.i306 call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %8), !noalias !31 call void @llvm.lifetime.start.p0(i64 64, ptr nonnull %7), !noalias !31 - br label %193 + br label %191 -193: ; preds = %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i311, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i308 - %.030.i.i309 = phi i64 [ 0, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i308 ], [ %205, %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i311 ] - %194 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %13, i64 0, i64 %.030.i.i309 - %195 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %10, i64 0, i64 %.030.i.i309 +191: ; preds = %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i311, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i308 + %.030.i.i309 = phi i64 [ 0, %_ZN5drjit15StaticArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELm4ELb0ENS1_IS5_Lm4EEEE5full_IS4_EES6_RKT_m.exit.i308 ], [ %203, %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i311 ] + %192 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %13, i64 0, i64 %.030.i.i309 + %193 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %10, i64 0, i64 %.030.i.i309 call void @llvm.experimental.noalias.scope.decl(metadata !40) - br label %196 - -196: ; preds = %196, %193 - %.034.i.i.i310 = phi i64 [ 0, %193 ], [ %203, %196 ] - %197 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %194, i64 0, i64 %.034.i.i.i310 - %198 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %195, i64 0, i64 %.034.i.i.i310 - %199 = load <4 x float>, ptr %197, align 16 - %200 = load <4 x float>, ptr %198, align 16, !noalias !43 - %201 = fmul contract <4 x float> %199, %200 - %202 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %7, i64 0, i64 %.034.i.i.i310 - store <4 x float> %201, ptr %202, align 16, !alias.scope !40, !noalias !46 - %203 = add nuw nsw i64 %.034.i.i.i310, 1 - %exitcond.not.i.i48.i = icmp eq i64 %203, 4 - br i1 %exitcond.not.i.i48.i, label %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i311, label %196, !llvm.loop !29 - -_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i311: ; preds = %196 - %204 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %9, i64 0, i64 %.030.i.i309 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %204, ptr noundef nonnull align 16 dereferenceable(64) %7, i64 64, i1 false) - %205 = add nuw nsw i64 %.030.i.i309, 1 - %exitcond.not.i49.i = icmp eq i64 %205, 4 - br i1 %exitcond.not.i49.i, label %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i312, label %193, !llvm.loop !30 + br label %194 + +194: ; preds = %194, %191 + %.034.i.i.i310 = phi i64 [ 0, %191 ], [ %201, %194 ] + %195 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %192, i64 0, i64 %.034.i.i.i310 + %196 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %193, i64 0, i64 %.034.i.i.i310 + %197 = load <4 x float>, ptr %195, align 16 + %198 = load <4 x float>, ptr %196, align 16, !noalias !43 + %199 = fmul contract <4 x float> %197, %198 + %200 = getelementptr inbounds nuw [4 x %"struct.mitsuba::Spectrum"], ptr %7, i64 0, i64 %.034.i.i.i310 + store <4 x float> %199, ptr %200, align 16, !alias.scope !40, !noalias !46 + %201 = add nuw nsw i64 %.034.i.i.i310, 1 + %exitcond.not.i.i48.i = icmp eq i64 %201, 4 + br i1 %exitcond.not.i.i48.i, label %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i311, label %194, !llvm.loop !29 + +_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i311: ; preds = %194 + %202 = getelementptr inbounds nuw [4 x %"struct.drjit::Array.29"], ptr %9, i64 0, i64 %.030.i.i309 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(64) %202, ptr noundef nonnull align 16 dereferenceable(64) %7, i64 64, i1 false) + %203 = add nuw nsw i64 %.030.i.i309, 1 + %exitcond.not.i49.i = icmp eq i64 %203, 4 + br i1 %exitcond.not.i49.i, label %_ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i312, label %191, !llvm.loop !30 _ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EEEE4mul_ERKS6_.exit.i312: ; preds = %_ZNK5drjit9ArrayBaseIN7mitsuba8SpectrumIfLm4EEELb0ENS_5ArrayIS3_Lm4EEEE4mul_ERKS5_.exit.i.i311 - %206 = insertelement <4 x float> poison, float %82, i64 0 + %204 = insertelement <4 x float> poison, float %80, i64 0 + %205 = shufflevector <4 x float> %204, <4 x float> poison, <4 x i32> zeroinitializer + %206 = insertelement <4 x float> poison, float %87, i64 0 %207 = shufflevector <4 x float> %206, <4 x float> poison, <4 x i32> zeroinitializer - %208 = insertelement <4 x float> poison, float %89, i64 0 + %208 = insertelement <4 x float> poison, float %86, i64 0 %209 = shufflevector <4 x float> %208, <4 x float> poison, <4 x i32> zeroinitializer - %210 = insertelement <4 x float> poison, float %88, i64 0 - %211 = shufflevector <4 x float> %210, <4 x float> poison, <4 x i32> zeroinitializer - %212 = fmul contract <4 x float> %.sroa.0334.0.copyload, %211 - %213 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %150, <4 x float> %209, <4 x float> %212) - %214 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %152, <4 x float> %207, <4 x float> %213) + %210 = fmul contract <4 x float> %.sroa.0334.0.copyload, %209 + %211 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %148, <4 x float> %207, <4 x float> %210) + %212 = call contract noundef <4 x float> @llvm.fma.v4f32(<4 x float> %150, <4 x float> %205, <4 x float> %211) call void @llvm.lifetime.end.p0(i64 64, ptr nonnull %7), !noalias !31 call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %10) %.sroa.0.i.16.i.16.i.16..sroa_idx = getelementptr inbounds nuw i8, ptr %.sroa.0.i, i64 16 @@ -1212,15 +1211,15 @@ _ZNK5drjit9ArrayBaseINS_5ArrayIN7mitsuba8SpectrumIfLm4EEELm4EEELb0ENS1_IS5_Lm4EE call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(16) %.sroa.0.i, ptr noundef nonnull align 16 dereferenceable(16) %9, i64 16, i1 false) store <4 x float> %.sroa.0315.0.copyload316, ptr %0, align 16 %.sroa.2.0..sroa_idx317 = getelementptr inbounds nuw i8, ptr %0, i64 16 - store <4 x float> %214, ptr %.sroa.2.0..sroa_idx317, align 16 + store <4 x float> %212, ptr %.sroa.2.0..sroa_idx317, align 16 %.sroa.3.0..sroa_idx318 = getelementptr inbounds nuw i8, ptr %0, i64 32 store float 0x47EFFFFFE0000000, ptr %.sroa.3.0..sroa_idx318, align 16 %.sroa.4.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 36 store float %2, ptr %.sroa.4.0..sroa_idx, align 4 %.sroa.5.0..sroa_idx = getelementptr inbounds nuw i8, ptr %0, i64 40 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %.sroa.5.0..sroa_idx, ptr noundef nonnull align 8 dereferenceable(24) %.sroa.5, i64 24, i1 false) - %215 = getelementptr inbounds nuw i8, ptr %0, i64 64 - call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %215, ptr noundef nonnull align 16 dereferenceable(256) %.sroa.0.i, i64 256, i1 false) + %213 = getelementptr inbounds nuw i8, ptr %0, i64 64 + call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 16 dereferenceable(256) %213, ptr noundef nonnull align 16 dereferenceable(256) %.sroa.0.i, i64 256, i1 false) ret void } diff --git a/bench/oiio/optimized/texturesys.cpp.ll b/bench/oiio/optimized/texturesys.cpp.ll index 3cdcd02dd37..b1e89086977 100644 --- a/bench/oiio/optimized/texturesys.cpp.ll +++ b/bench/oiio/optimized/texturesys.cpp.ll @@ -12416,34 +12416,34 @@ if.then: ; preds = %entry %fneg20.i = fneg float %add.i.i %cu.i.0 = select i1 %cmp.i.not, float %add.i.i, float %fneg20.i %cmp.i31.i.inv = fcmp oge float %add.i62.i, -1.000000e+00 - %8 = fcmp ogt float %add.i62.i, 1.000000e+00 + %val.i30.i.0 = select i1 %cmp.i31.i.inv, float %add.i62.i, float -1.000000e+00 + %cmp1.i34.i = fcmp ogt float %val.i30.i.0, 1.000000e+00 %cmp.i.i.inv = fcmp oge float %cu.i.0, -1.000000e+00 - %9 = fcmp ogt float %cu.i.0, 1.000000e+00 - %10 = tail call float @llvm.fabs.f32(float %add.i62.i) - %11 = select i1 %8, float 1.000000e+00, float %10 - %12 = select i1 %cmp.i31.i.inv, float %11, float 1.000000e+00 - %13 = tail call float @llvm.fabs.f32(float %add.i.i) - %14 = select i1 %9, float 1.000000e+00, float %13 - %15 = select i1 %cmp.i.i.inv, float %14, float 1.000000e+00 - %mul1 = fmul float %tblur, %12 - %16 = tail call float @llvm.fmuladd.f32(float %sblur, float %15, float %mul1) - %17 = load float, ptr %majorlength, align 4 - %add2 = fadd float %17, %16 + %val.i.i.0 = select i1 %cmp.i.i.inv, float %cu.i.0, float -1.000000e+00 + %cmp1.i.i = fcmp ogt float %val.i.i.0, 1.000000e+00 + %8 = tail call float @llvm.fabs.f32(float %val.i30.i.0) + %9 = select i1 %cmp1.i34.i, float 1.000000e+00, float %8 + %10 = tail call float @llvm.fabs.f32(float %val.i.i.0) + %11 = select i1 %cmp1.i.i, float 1.000000e+00, float %10 + %mul1 = fmul float %tblur, %9 + %12 = tail call float @llvm.fmuladd.f32(float %sblur, float %11, float %mul1) + %13 = load float, ptr %majorlength, align 4 + %add2 = fadd float %13, %12 store float %add2, ptr %majorlength, align 4 - %mul3 = fmul float %tblur, %15 - %18 = tail call float @llvm.fmuladd.f32(float %sblur, float %12, float %mul3) - %19 = load float, ptr %minorlength, align 4 - %add4 = fadd float %19, %18 + %mul3 = fmul float %tblur, %11 + %14 = tail call float @llvm.fmuladd.f32(float %sblur, float %9, float %mul3) + %15 = load float, ptr %minorlength, align 4 + %add4 = fadd float %15, %14 store float %add4, ptr %minorlength, align 4 - %20 = load float, ptr %majorlength, align 4 - %cmp5 = fcmp ogt float %add4, %20 + %16 = load float, ptr %majorlength, align 4 + %cmp5 = fcmp ogt float %add4, %16 br i1 %cmp5, label %if.then6, label %if.end9 if.then6: ; preds = %if.then - store float %20, ptr %minorlength, align 4 + store float %16, ptr %minorlength, align 4 store float %add4, ptr %majorlength, align 4 - %21 = load float, ptr %theta, align 4 - %conv = fpext float %21 to double + %17 = load float, ptr %theta, align 4 + %conv = fpext float %17 to double %add7 = fadd double %conv, 0x3FF921FB54442D18 %conv8 = fptrunc double %add7 to float store float %conv8, ptr %theta, align 4 diff --git a/bench/opencv/optimized/fisheye.cpp.ll b/bench/opencv/optimized/fisheye.cpp.ll index 0b0542a1040..99a5ec10ef6 100644 --- a/bench/opencv/optimized/fisheye.cpp.ll +++ b/bench/opencv/optimized/fisheye.cpp.ll @@ -3608,7 +3608,7 @@ define void @_ZN2cv7fisheye15undistortPointsERKNS_11_InputArrayERKNS_12_OutputAr 53: ; preds = %352, %349, %_ZNK2cv11_InputArray6getMatEi.exit225, %344, %341, %_ZNK2cv11_InputArray6getMatEi.exit221, %336, %333, %_ZNK2cv11_InputArray6getMatEi.exit217, %328, %325, %322, %297, %294, %291, %282, %279, %276, %_ZN2cv3VecIdLi3EE3allEd.exit, %239, %236, %233, %203, %200, %197, %182, %179, %176, %162, %159, %156, %356, %_ZNK2cv11_InputArray6getMatEi.exit229, %.critedge, %272, %269, %227, %225, %_ZN2cv4MatxIdLi3ELi3EE3eyeEv.exit, %193, %152, %120, %116, %112, %.critedge145, %95, %93, %89, %.critedge143, %75, %71, %68, %67, %65, %63, %49, %7 %54 = landingpad { ptr, i32 } cleanup - br label %465 + br label %462 55: ; preds = %51 call void @_ZNSaIcEC1Ev(ptr noundef nonnull align 1 dereferenceable(1) %13) #22 @@ -3636,7 +3636,7 @@ define void @_ZN2cv7fisheye15undistortPointsERKNS_11_InputArrayERKNS_12_OutputAr 62: ; preds = %60, %58 %.pn = phi { ptr, i32 } [ %61, %60 ], [ %59, %58 ] call void @_ZNSaIcED1Ev(ptr noundef nonnull align 1 dereferenceable(1) %13) #22 - br label %465 + br label %462 63: ; preds = %47, %51 %64 = invoke i64 @_ZNK2cv11_InputArray4sizeEi(ptr noundef nonnull align 8 dereferenceable(24) %0, i32 noundef -1) @@ -3699,7 +3699,7 @@ define void @_ZN2cv7fisheye15undistortPointsERKNS_11_InputArrayERKNS_12_OutputAr 86: ; preds = %84, %82 %.pn122 = phi { ptr, i32 } [ %85, %84 ], [ %83, %82 ] call void @_ZNSaIcED1Ev(ptr noundef nonnull align 1 dereferenceable(1) %15) #22 - br label %465 + br label %462 .critedge143: ; preds = %73, %70, %77 %87 = invoke noundef zeroext i1 @_ZNK2cv11_InputArray5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %4) @@ -3756,7 +3756,7 @@ define void @_ZN2cv7fisheye15undistortPointsERKNS_11_InputArrayERKNS_12_OutputAr 108: ; preds = %106, %104 %.pn124 = phi { ptr, i32 } [ %107, %106 ], [ %105, %104 ] call void @_ZNSaIcED1Ev(ptr noundef nonnull align 1 dereferenceable(1) %17) #22 - br label %465 + br label %462 .critedge145: ; preds = %91, %88, %97 %109 = invoke noundef i64 @_ZNK2cv11_InputArray5totalEi(ptr noundef nonnull align 8 dereferenceable(24) %3, i32 noundef -1) @@ -3816,7 +3816,7 @@ define void @_ZN2cv7fisheye15undistortPointsERKNS_11_InputArrayERKNS_12_OutputAr 130: ; preds = %128, %126 %.pn126 = phi { ptr, i32 } [ %129, %128 ], [ %127, %126 ] call void @_ZNSaIcED1Ev(ptr noundef nonnull align 1 dereferenceable(1) %19) #22 - br label %465 + br label %462 131: ; preds = %122, %118 %132 = load i32, ptr %6, align 8 @@ -3861,7 +3861,7 @@ define void @_ZN2cv7fisheye15undistortPointsERKNS_11_InputArrayERKNS_12_OutputAr 151: ; preds = %149, %147 %.pn128 = phi { ptr, i32 } [ %150, %149 ], [ %148, %147 ] call void @_ZNSaIcED1Ev(ptr noundef nonnull align 1 dereferenceable(1) %21) #22 - br label %465 + br label %462 152: ; preds = %131 %153 = invoke noundef i32 @_ZNK2cv11_InputArray5depthEi(ptr noundef nonnull align 8 dereferenceable(24) %2, i32 noundef -1) @@ -3912,7 +3912,7 @@ _ZNK2cv11_InputArray6getMatEi.exit: ; preds = %159, %162 %175 = landingpad { ptr, i32 } cleanup call void @_ZN2cv3MatD1Ev(ptr noundef nonnull align 8 dereferenceable(96) %23) #22 - br label %465 + br label %462 176: ; preds = %154 %177 = invoke noundef i32 @_ZNK2cv11_InputArray4kindEv(ptr noundef nonnull align 8 dereferenceable(24) %2) @@ -3951,7 +3951,7 @@ _ZNK2cv11_InputArray6getMatEi.exit181: ; preds = %179, %182 %192 = landingpad { ptr, i32 } cleanup call void @_ZN2cv3MatD1Ev(ptr noundef nonnull align 8 dereferenceable(96) %25) #22 - br label %465 + br label %462 193: ; preds = %183, %.critedge324 %.sroa.4301.0 = phi double [ %173, %.critedge324 ], [ %190, %183 ] @@ -4143,13 +4143,13 @@ _ZN2cv3VecIdLi3EE3allEd.exit: ; preds = %240 265: ; preds = %217, %214, %211 %266 = landingpad { ptr, i32 } cleanup - br label %465 + br label %462 267: ; preds = %240 %268 = landingpad { ptr, i32 } cleanup call void @_ZN2cv3MatD1Ev(ptr noundef nonnull align 8 dereferenceable(96) %31) #22 - br label %465 + br label %462 269: ; preds = %229, %224 %270 = invoke noundef zeroext i1 @_ZNK2cv11_InputArray5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %4) @@ -4201,7 +4201,7 @@ _ZN2cv3VecIdLi3EE3allEd.exit: ; preds = %240 %288 = landingpad { ptr, i32 } cleanup call void @_ZN2cv3MatD1Ev(ptr noundef nonnull align 8 dereferenceable(96) %34) #22 - br label %465 + br label %462 .critedge: ; preds = %274, %286, %271, %243 %289 = invoke noundef zeroext i1 @_ZNK2cv11_InputArray5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %5) @@ -4311,7 +4311,7 @@ _ZN2cvmlIdLi3ELi3ELi3EEENS_4MatxIT_XT0_EXT1_EEERKNS1_IS2_XT0_EXT2_EEERKNS1_IS2_X 321: ; preds = %319, %317 %.pn136.pn = phi { ptr, i32 } [ %320, %319 ], [ %318, %317 ] call void @_ZN2cv3MatD1Ev(ptr noundef nonnull align 8 dereferenceable(96) %38) #22 - br label %465 + br label %462 322: ; preds = %_ZN2cvmlIdLi3ELi3ELi3EEENS_4MatxIT_XT0_EXT1_EEERKNS1_IS2_XT0_EXT2_EEERKNS1_IS2_XT2_EXT1_EEE.exit, %290 %323 = invoke noundef i32 @_ZNK2cv11_InputArray4kindEv(ptr noundef nonnull align 8 dereferenceable(24) %0) @@ -4409,8 +4409,8 @@ _ZNK2cv11_InputArray6getMatEi.exit229: ; preds = %349, %352 %.not = icmp eq i32 %138, 0 %.not139 = icmp eq i32 %133, 0 %.0112 = select i1 %.not139, i32 2147483647, i32 %135 - %.not349 = icmp eq i64 %355, 0 - br i1 %.not349, label %._crit_edge346, label %.lr.ph345 + %.not351 = icmp eq i64 %355, 0 + br i1 %.not351, label %._crit_edge346, label %.lr.ph345 .lr.ph345: ; preds = %358 %359 = icmp eq i32 %357, 5 @@ -4428,8 +4428,8 @@ _ZNK2cv11_InputArray6getMatEi.exit229: ; preds = %349, %352 %.sroa.3258.0..sroa_idx = getelementptr inbounds nuw i8, ptr %8, i64 16 br label %370 -370: ; preds = %.lr.ph345, %457 - %.0113343 = phi i64 [ 0, %.lr.ph345 ], [ %458, %457 ] +370: ; preds = %.lr.ph345, %454 + %.0113343 = phi i64 [ 0, %.lr.ph345 ], [ %455, %454 ] br i1 %359, label %.critedge327, label %377 .critedge327: ; preds = %370 @@ -4462,180 +4462,176 @@ _ZNK2cv11_InputArray6getMatEi.exit229: ; preds = %349, %352 %.sroa.speculated262 = select i1 %390, double %sqrt, double 0xBFF921FB54442D18 %391 = fcmp ogt double %.sroa.speculated262, 0x3FF921FB54442D18 %.sroa.speculated = select i1 %391, double 0x3FF921FB54442D18, double %.sroa.speculated262 - br i1 %.not, label %397, label %392 + %392 = call double @llvm.fabs.f64(double %.sroa.speculated) + %393 = fcmp ogt double %392, %140 + %or.cond348 = select i1 %.not, i1 true, i1 %393 + br i1 %or.cond348, label %394, label %424 -392: ; preds = %382 - %393 = call double @llvm.fabs.f64(double %sqrt) - %394 = select i1 %390, double %393, double 0x3FF921FB54442D18 - %395 = select i1 %391, double 0x3FF921FB54442D18, double %394 - %396 = fcmp ogt double %395, %140 - br i1 %396, label %397, label %427 - -397: ; preds = %392, %382 +394: ; preds = %382 br i1 %360, label %.lr.ph, label %._crit_edge -.lr.ph: ; preds = %397 - %398 = fneg double %.sroa.speculated - br label %399 - -399: ; preds = %.lr.ph, %421 - %.0116337 = phi double [ %.sroa.speculated, %.lr.ph ], [ %418, %421 ] - %.0120336 = phi i32 [ 0, %.lr.ph ], [ %422, %421 ] - %400 = fmul double %.0116337, %.0116337 - %401 = fmul double %400, %400 - %402 = fmul double %400, %401 - %403 = fmul double %400, %402 - %404 = fmul double %400, %361 - %405 = fmul double %401, %363 - %406 = fmul double %402, %365 - %407 = fmul double %403, %367 - %408 = fadd double %404, 1.000000e+00 - %409 = fadd double %408, %405 - %410 = fadd double %409, %406 - %411 = fadd double %410, %407 - %412 = call double @llvm.fmuladd.f64(double %.0116337, double %411, double %398) - %413 = call double @llvm.fmuladd.f64(double %404, double 3.000000e+00, double 1.000000e+00) - %414 = call double @llvm.fmuladd.f64(double %405, double 5.000000e+00, double %413) - %415 = call double @llvm.fmuladd.f64(double %406, double 7.000000e+00, double %414) - %416 = call double @llvm.fmuladd.f64(double %407, double 9.000000e+00, double %415) - %417 = fdiv double %412, %416 - %418 = fsub double %.0116337, %417 - %419 = call double @llvm.fabs.f64(double %417) - %420 = fcmp uge double %419, %140 - %or.cond348.not = select i1 %.not, i1 true, i1 %420 - br i1 %or.cond348.not, label %421, label %._crit_edge - -421: ; preds = %399 - %422 = add nuw nsw i32 %.0120336, 1 - %exitcond.not = icmp eq i32 %422, %.0112 - br i1 %exitcond.not, label %._crit_edge, label %399, !llvm.loop !363 - -._crit_edge: ; preds = %421, %399, %397 - %423 = phi i1 [ %.not, %397 ], [ true, %399 ], [ %.not, %421 ] - %.1117 = phi double [ %.sroa.speculated, %397 ], [ %418, %399 ], [ %418, %421 ] - %424 = call double @tan(double noundef %.1117) #22 - %425 = fdiv double %424, %.sroa.speculated - %426 = xor i1 %423, true - br label %427 - -427: ; preds = %392, %._crit_edge - %.0119 = phi double [ %425, %._crit_edge ], [ 0.000000e+00, %392 ] - %.2118 = phi double [ %.1117, %._crit_edge ], [ %.sroa.speculated, %392 ] - %.1115 = phi i1 [ %426, %._crit_edge ], [ false, %392 ] - %428 = fcmp olt double %.sroa.speculated, 0.000000e+00 - %429 = fcmp ogt double %.2118, 0.000000e+00 - %or.cond = and i1 %428, %429 - br i1 %or.cond, label %.thread, label %430 - -430: ; preds = %427 - %431 = fcmp ogt double %.sroa.speculated, 0.000000e+00 - %432 = fcmp olt double %.2118, 0.000000e+00 - %433 = and i1 %431, %432 - %brmerge152 = select i1 %.1115, i1 true, i1 %433 - br i1 %brmerge152, label %.thread, label %434 - -434: ; preds = %430 - %435 = fmul double %385, %.0119 - %436 = fmul double %387, %.0119 - store double %435, ptr %45, align 8 - store double %436, ptr %368, align 8 +.lr.ph: ; preds = %394 + %395 = fneg double %.sroa.speculated + br label %396 + +396: ; preds = %.lr.ph, %418 + %.0116337 = phi double [ %.sroa.speculated, %.lr.ph ], [ %415, %418 ] + %.0120336 = phi i32 [ 0, %.lr.ph ], [ %419, %418 ] + %397 = fmul double %.0116337, %.0116337 + %398 = fmul double %397, %397 + %399 = fmul double %397, %398 + %400 = fmul double %397, %399 + %401 = fmul double %397, %361 + %402 = fmul double %398, %363 + %403 = fmul double %399, %365 + %404 = fmul double %400, %367 + %405 = fadd double %401, 1.000000e+00 + %406 = fadd double %405, %402 + %407 = fadd double %406, %403 + %408 = fadd double %407, %404 + %409 = call double @llvm.fmuladd.f64(double %.0116337, double %408, double %395) + %410 = call double @llvm.fmuladd.f64(double %401, double 3.000000e+00, double 1.000000e+00) + %411 = call double @llvm.fmuladd.f64(double %402, double 5.000000e+00, double %410) + %412 = call double @llvm.fmuladd.f64(double %403, double 7.000000e+00, double %411) + %413 = call double @llvm.fmuladd.f64(double %404, double 9.000000e+00, double %412) + %414 = fdiv double %409, %413 + %415 = fsub double %.0116337, %414 + %416 = call double @llvm.fabs.f64(double %414) + %417 = fcmp uge double %416, %140 + %or.cond350.not = select i1 %.not, i1 true, i1 %417 + br i1 %or.cond350.not, label %418, label %._crit_edge + +418: ; preds = %396 + %419 = add nuw nsw i32 %.0120336, 1 + %exitcond.not = icmp eq i32 %419, %.0112 + br i1 %exitcond.not, label %._crit_edge, label %396, !llvm.loop !363 + +._crit_edge: ; preds = %418, %396, %394 + %420 = phi i1 [ %.not, %394 ], [ true, %396 ], [ %.not, %418 ] + %.1117 = phi double [ %.sroa.speculated, %394 ], [ %415, %396 ], [ %415, %418 ] + %421 = call double @tan(double noundef %.1117) #22 + %422 = fdiv double %421, %.sroa.speculated + %423 = xor i1 %420, true + br label %424 + +424: ; preds = %382, %._crit_edge + %.0119 = phi double [ %422, %._crit_edge ], [ 0.000000e+00, %382 ] + %.2118 = phi double [ %.1117, %._crit_edge ], [ %.sroa.speculated, %382 ] + %.1115 = phi i1 [ %423, %._crit_edge ], [ false, %382 ] + %425 = fcmp olt double %.sroa.speculated, 0.000000e+00 + %426 = fcmp ogt double %.2118, 0.000000e+00 + %or.cond = and i1 %425, %426 + br i1 %or.cond, label %.thread, label %427 + +427: ; preds = %424 + %428 = fcmp ogt double %.sroa.speculated, 0.000000e+00 + %429 = fcmp olt double %.2118, 0.000000e+00 + %430 = and i1 %428, %429 + %brmerge152 = select i1 %.1115, i1 true, i1 %430 + br i1 %brmerge152, label %.thread, label %431 + +431: ; preds = %427 + %432 = fmul double %385, %.0119 + %433 = fmul double %387, %.0119 + store double %432, ptr %45, align 8 + store double %433, ptr %368, align 8 store double 1.000000e+00, ptr %369, align 8 call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) br label %.preheader.i.i233 -.preheader.i.i233: ; preds = %.critedge.i.i, %434 - %indvars.iv23.i.i = phi i64 [ 0, %434 ], [ %indvars.iv.next24.i.i, %.critedge.i.i ] - %437 = mul nuw nsw i64 %indvars.iv23.i.i, 3 - br label %438 - -438: ; preds = %438, %.preheader.i.i233 - %indvars.iv.i.i234 = phi i64 [ 0, %.preheader.i.i233 ], [ %indvars.iv.next.i.i235, %438 ] - %.01619.i.i = phi double [ 0.000000e+00, %.preheader.i.i233 ], [ %444, %438 ] - %439 = add nuw nsw i64 %indvars.iv.i.i234, %437 - %440 = getelementptr inbounds nuw [9 x double], ptr %29, i64 0, i64 %439 - %441 = load double, ptr %440, align 8, !noalias !364 - %442 = getelementptr inbounds nuw [3 x double], ptr %45, i64 0, i64 %indvars.iv.i.i234 - %443 = load double, ptr %442, align 8, !noalias !364 - %444 = call double @llvm.fmuladd.f64(double %441, double %443, double %.01619.i.i) +.preheader.i.i233: ; preds = %.critedge.i.i, %431 + %indvars.iv23.i.i = phi i64 [ 0, %431 ], [ %indvars.iv.next24.i.i, %.critedge.i.i ] + %434 = mul nuw nsw i64 %indvars.iv23.i.i, 3 + br label %435 + +435: ; preds = %435, %.preheader.i.i233 + %indvars.iv.i.i234 = phi i64 [ 0, %.preheader.i.i233 ], [ %indvars.iv.next.i.i235, %435 ] + %.01619.i.i = phi double [ 0.000000e+00, %.preheader.i.i233 ], [ %441, %435 ] + %436 = add nuw nsw i64 %indvars.iv.i.i234, %434 + %437 = getelementptr inbounds nuw [9 x double], ptr %29, i64 0, i64 %436 + %438 = load double, ptr %437, align 8, !noalias !364 + %439 = getelementptr inbounds nuw [3 x double], ptr %45, i64 0, i64 %indvars.iv.i.i234 + %440 = load double, ptr %439, align 8, !noalias !364 + %441 = call double @llvm.fmuladd.f64(double %438, double %440, double %.01619.i.i) %indvars.iv.next.i.i235 = add nuw nsw i64 %indvars.iv.i.i234, 1 %exitcond.not.i.i236 = icmp eq i64 %indvars.iv.next.i.i235, 3 - br i1 %exitcond.not.i.i236, label %.critedge.i.i, label %438, !llvm.loop !367 + br i1 %exitcond.not.i.i236, label %.critedge.i.i, label %435, !llvm.loop !367 -.critedge.i.i: ; preds = %438 - %445 = getelementptr inbounds nuw [3 x double], ptr %8, i64 0, i64 %indvars.iv23.i.i - store double %444, ptr %445, align 8, !noalias !364 +.critedge.i.i: ; preds = %435 + %442 = getelementptr inbounds nuw [3 x double], ptr %8, i64 0, i64 %indvars.iv23.i.i + store double %441, ptr %442, align 8, !noalias !364 %indvars.iv.next24.i.i = add nuw nsw i64 %indvars.iv23.i.i, 1 %exitcond26.not.i.i = icmp eq i64 %indvars.iv.next24.i.i, 3 - br i1 %exitcond26.not.i.i, label %446, label %.preheader.i.i233, !llvm.loop !368 + br i1 %exitcond26.not.i.i, label %443, label %.preheader.i.i233, !llvm.loop !368 -446: ; preds = %.critedge.i.i +443: ; preds = %.critedge.i.i %.sroa.0257.0.copyload = load double, ptr %8, align 8 %.sroa.2.0.copyload = load double, ptr %.sroa.2.0..sroa_idx, align 8 %.sroa.3258.0.copyload = load double, ptr %.sroa.3258.0..sroa_idx, align 8 call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) - %447 = fdiv double %.sroa.0257.0.copyload, %.sroa.3258.0.copyload - %448 = fdiv double %.sroa.2.0.copyload, %.sroa.3258.0.copyload - br i1 %359, label %_ZNK2cv3VecIdLi2EEcvNS0_IT_Li2EEEIfEEv.exit.critedge, label %452 - -_ZNK2cv3VecIdLi2EEcvNS0_IT_Li2EEEIfEEv.exit.critedge: ; preds = %446 - %449 = fptrunc double %447 to float - %450 = fptrunc double %448 to float - %451 = getelementptr inbounds %"class.cv::Vec.6", ptr %346, i64 %.0113343 - store float %449, ptr %451, align 4 - %.sroa_idx249 = getelementptr inbounds nuw i8, ptr %451, i64 4 - store float %450, ptr %.sroa_idx249, align 4 - br label %457 - -452: ; preds = %446 - %453 = getelementptr inbounds %"class.cv::Vec.3", ptr %354, i64 %.0113343 - store double %447, ptr %453, align 8 - %.sroa.3255.0..sroa_idx = getelementptr inbounds nuw i8, ptr %453, i64 8 - store double %448, ptr %.sroa.3255.0..sroa_idx, align 8 - br label %457 - -.thread: ; preds = %427, %430 - br i1 %359, label %_ZNK2cv3VecIdLi2EEcvNS0_IT_Li2EEEIfEEv.exit239.critedge, label %455 + %444 = fdiv double %.sroa.0257.0.copyload, %.sroa.3258.0.copyload + %445 = fdiv double %.sroa.2.0.copyload, %.sroa.3258.0.copyload + br i1 %359, label %_ZNK2cv3VecIdLi2EEcvNS0_IT_Li2EEEIfEEv.exit.critedge, label %449 + +_ZNK2cv3VecIdLi2EEcvNS0_IT_Li2EEEIfEEv.exit.critedge: ; preds = %443 + %446 = fptrunc double %444 to float + %447 = fptrunc double %445 to float + %448 = getelementptr inbounds %"class.cv::Vec.6", ptr %346, i64 %.0113343 + store float %446, ptr %448, align 4 + %.sroa_idx249 = getelementptr inbounds nuw i8, ptr %448, i64 4 + store float %447, ptr %.sroa_idx249, align 4 + br label %454 + +449: ; preds = %443 + %450 = getelementptr inbounds %"class.cv::Vec.3", ptr %354, i64 %.0113343 + store double %444, ptr %450, align 8 + %.sroa.3255.0..sroa_idx = getelementptr inbounds nuw i8, ptr %450, i64 8 + store double %445, ptr %.sroa.3255.0..sroa_idx, align 8 + br label %454 + +.thread: ; preds = %424, %427 + br i1 %359, label %_ZNK2cv3VecIdLi2EEcvNS0_IT_Li2EEEIfEEv.exit239.critedge, label %452 _ZNK2cv3VecIdLi2EEcvNS0_IT_Li2EEEIfEEv.exit239.critedge: ; preds = %.thread - %454 = getelementptr inbounds %"class.cv::Vec.6", ptr %346, i64 %.0113343 - store i32 -915135488, ptr %454, align 4 - %.sroa_idx242 = getelementptr inbounds nuw i8, ptr %454, i64 4 + %451 = getelementptr inbounds %"class.cv::Vec.6", ptr %346, i64 %.0113343 + store i32 -915135488, ptr %451, align 4 + %.sroa_idx242 = getelementptr inbounds nuw i8, ptr %451, i64 4 store i32 -915135488, ptr %.sroa_idx242, align 4 - br label %457 + br label %454 -455: ; preds = %.thread - %456 = getelementptr inbounds %"class.cv::Vec.3", ptr %354, i64 %.0113343 - store double -1.000000e+06, ptr %456, align 8 - %.sroa.3246.0..sroa_idx = getelementptr inbounds nuw i8, ptr %456, i64 8 +452: ; preds = %.thread + %453 = getelementptr inbounds %"class.cv::Vec.3", ptr %354, i64 %.0113343 + store double -1.000000e+06, ptr %453, align 8 + %.sroa.3246.0..sroa_idx = getelementptr inbounds nuw i8, ptr %453, i64 8 store double -1.000000e+06, ptr %.sroa.3246.0..sroa_idx, align 8 - br label %457 + br label %454 -457: ; preds = %452, %_ZNK2cv3VecIdLi2EEcvNS0_IT_Li2EEEIfEEv.exit.critedge, %455, %_ZNK2cv3VecIdLi2EEcvNS0_IT_Li2EEEIfEEv.exit239.critedge - %458 = add nuw i64 %.0113343, 1 - %exitcond355.not = icmp eq i64 %458, %355 - br i1 %exitcond355.not, label %._crit_edge346, label %370, !llvm.loop !369 +454: ; preds = %449, %_ZNK2cv3VecIdLi2EEcvNS0_IT_Li2EEEIfEEv.exit.critedge, %452, %_ZNK2cv3VecIdLi2EEcvNS0_IT_Li2EEEIfEEv.exit239.critedge + %455 = add nuw i64 %.0113343, 1 + %exitcond357.not = icmp eq i64 %455, %355 + br i1 %exitcond357.not, label %._crit_edge346, label %370, !llvm.loop !369 -._crit_edge346: ; preds = %457, %358 - %459 = getelementptr inbounds nuw i8, ptr %11, i64 8 - %460 = load i32, ptr %459, align 8 - %.not.i240 = icmp eq i32 %460, 0 - br i1 %.not.i240, label %_ZN2cv5utils5trace7details6RegionD2Ev.exit, label %461 +._crit_edge346: ; preds = %454, %358 + %456 = getelementptr inbounds nuw i8, ptr %11, i64 8 + %457 = load i32, ptr %456, align 8 + %.not.i240 = icmp eq i32 %457, 0 + br i1 %.not.i240, label %_ZN2cv5utils5trace7details6RegionD2Ev.exit, label %458 -461: ; preds = %._crit_edge346 +458: ; preds = %._crit_edge346 invoke void @_ZN2cv5utils5trace7details6Region7destroyEv(ptr noundef nonnull align 8 dereferenceable(12) %11) - to label %_ZN2cv5utils5trace7details6RegionD2Ev.exit unwind label %462 + to label %_ZN2cv5utils5trace7details6RegionD2Ev.exit unwind label %459 -462: ; preds = %461 - %463 = landingpad { ptr, i32 } +459: ; preds = %458 + %460 = landingpad { ptr, i32 } catch ptr null - %464 = extractvalue { ptr, i32 } %463, 0 - call void @__clang_call_terminate(ptr %464) #21 + %461 = extractvalue { ptr, i32 } %460, 0 + call void @__clang_call_terminate(ptr %461) #21 unreachable -_ZN2cv5utils5trace7details6RegionD2Ev.exit: ; preds = %._crit_edge346, %461 +_ZN2cv5utils5trace7details6RegionD2Ev.exit: ; preds = %._crit_edge346, %458 ret void -465: ; preds = %265, %321, %287, %267, %191, %174, %151, %130, %108, %86, %62, %53 +462: ; preds = %265, %321, %287, %267, %191, %174, %151, %130, %108, %86, %62, %53 %.pn140 = phi { ptr, i32 } [ %54, %53 ], [ %.pn136.pn, %321 ], [ %288, %287 ], [ %268, %267 ], [ %175, %174 ], [ %192, %191 ], [ %.pn128, %151 ], [ %.pn126, %130 ], [ %.pn124, %108 ], [ %.pn122, %86 ], [ %.pn, %62 ], [ %266, %265 ] call void @_ZN2cv5utils5trace7details6RegionD2Ev(ptr noundef nonnull align 8 dereferenceable(12) %11) #22 resume { ptr, i32 } %.pn140 diff --git a/bench/opencv/optimized/moments.cpp.ll b/bench/opencv/optimized/moments.cpp.ll index 7198aa1d151..6b606943990 100644 --- a/bench/opencv/optimized/moments.cpp.ll +++ b/bench/opencv/optimized/moments.cpp.ll @@ -124,32 +124,31 @@ define void @_ZN2cv7MomentsC2Edddddddddd(ptr nocapture noundef nonnull writeonly %52 = tail call double @llvm.fmuladd.f64(double %42, double %51, double %10) %53 = getelementptr inbounds nuw i8, ptr %0, i64 128 store double %52, ptr %53, align 8 - %54 = tail call double @llvm.fabs.f64(double %23) - %55 = tail call double @llvm.sqrt.f64(double %54) - %sqrt = select i1 %22, double %55, double 0.000000e+00 - %56 = fmul double %.039, %.039 - %57 = fmul double %56, %sqrt - %58 = fmul double %56, %27 - %59 = getelementptr inbounds nuw i8, ptr %0, i64 136 - store double %58, ptr %59, align 8 - %60 = fmul double %56, %29 - %61 = getelementptr inbounds nuw i8, ptr %0, i64 144 - store double %60, ptr %61, align 8 - %62 = fmul double %56, %32 - %63 = getelementptr inbounds nuw i8, ptr %0, i64 152 - store double %62, ptr %63, align 8 - %64 = fmul double %57, %37 - %65 = getelementptr inbounds nuw i8, ptr %0, i64 160 - store double %64, ptr %65, align 8 - %66 = fmul double %57, %43 - %67 = getelementptr inbounds nuw i8, ptr %0, i64 168 - store double %66, ptr %67, align 8 - %68 = fmul double %57, %48 - %69 = getelementptr inbounds nuw i8, ptr %0, i64 176 - store double %68, ptr %69, align 8 - %70 = fmul double %57, %52 - %71 = getelementptr inbounds nuw i8, ptr %0, i64 184 - store double %70, ptr %71, align 8 + %54 = tail call noundef double @llvm.fabs.f64(double %.039) + %sqrt = tail call double @llvm.sqrt.f64(double %54) + %55 = fmul double %.039, %.039 + %56 = fmul double %55, %sqrt + %57 = fmul double %55, %27 + %58 = getelementptr inbounds nuw i8, ptr %0, i64 136 + store double %57, ptr %58, align 8 + %59 = fmul double %55, %29 + %60 = getelementptr inbounds nuw i8, ptr %0, i64 144 + store double %59, ptr %60, align 8 + %61 = fmul double %55, %32 + %62 = getelementptr inbounds nuw i8, ptr %0, i64 152 + store double %61, ptr %62, align 8 + %63 = fmul double %56, %37 + %64 = getelementptr inbounds nuw i8, ptr %0, i64 160 + store double %63, ptr %64, align 8 + %65 = fmul double %56, %43 + %66 = getelementptr inbounds nuw i8, ptr %0, i64 168 + store double %65, ptr %66, align 8 + %67 = fmul double %56, %48 + %68 = getelementptr inbounds nuw i8, ptr %0, i64 176 + store double %67, ptr %68, align 8 + %69 = fmul double %56, %52 + %70 = getelementptr inbounds nuw i8, ptr %0, i64 184 + store double %69, ptr %70, align 8 ret void } @@ -202,12 +201,12 @@ define void @_ZN2cv7momentsERKNS_11_InputArrayEb(ptr dead_on_unwind noalias writ 32: ; preds = %29 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(192) %0, ptr noundef nonnull align 8 dereferenceable(192) %9, i64 192, i1 false) - br label %445 + br label %444 33: ; preds = %41, %38, %35, %26, %24, %3 %34 = landingpad { ptr, i32 } cleanup - br label %452 + br label %451 35: ; preds = %29 %36 = invoke noundef i32 @_ZNK2cv11_InputArray4kindEv(ptr noundef nonnull align 8 dereferenceable(24) %1) @@ -271,7 +270,7 @@ _ZNK2cv11_InputArray6getMatEi.exit: ; preds = %38, %41 call void @_ZN2cv5utils5trace7details6RegionD2Ev(ptr noundef nonnull align 8 dereferenceable(12) %6) #16 br label %.body -58: ; preds = %.noexc101, %65, %_ZNK2cv11_InputArray6getMatEi.exit, %258, %60 +58: ; preds = %.noexc101, %65, %_ZNK2cv11_InputArray6getMatEi.exit, %257, %60 %59 = landingpad { ptr, i32 } cleanup br label %.body @@ -286,7 +285,7 @@ _ZNK2cv11_InputArray6getMatEi.exit: ; preds = %38, %41 %64 = and i32 %25, 6 %or.cond4 = icmp eq i32 %64, 4 %or.cond97 = and i1 %or.cond4, %63 - br i1 %or.cond97, label %65, label %235 + br i1 %or.cond97, label %65, label %234 65: ; preds = %62 call void @llvm.experimental.noalias.scope.decl(metadata !7) @@ -559,478 +558,477 @@ _ZNK2cv11_InputArray6getMatEi.exit: ; preds = %38, %41 %215 = call double @llvm.fmuladd.f64(double %206, double %214, double %183) %216 = getelementptr inbounds nuw i8, ptr %0, i64 128 store double %215, ptr %216, align 8 - %217 = call double @llvm.fabs.f64(double %187) - %218 = call double @llvm.sqrt.f64(double %217) - %sqrt.i119 = select i1 %186, double %218, double 0.000000e+00 - %219 = fmul double %.080.i116, %.080.i116 - %220 = fmul double %219, %sqrt.i119 - %221 = fmul double %219, %191 - %222 = getelementptr inbounds nuw i8, ptr %0, i64 136 - store double %221, ptr %222, align 8 - %223 = fmul double %219, %192 - %224 = getelementptr inbounds nuw i8, ptr %0, i64 144 - store double %223, ptr %224, align 8 - %225 = fmul double %219, %194 - %226 = getelementptr inbounds nuw i8, ptr %0, i64 152 - store double %225, ptr %226, align 8 - %227 = fmul double %220, %201 - %228 = getelementptr inbounds nuw i8, ptr %0, i64 160 - store double %227, ptr %228, align 8 - %229 = fmul double %220, %207 - %230 = getelementptr inbounds nuw i8, ptr %0, i64 168 - store double %229, ptr %230, align 8 - %231 = fmul double %220, %211 - %232 = getelementptr inbounds nuw i8, ptr %0, i64 176 - store double %231, ptr %232, align 8 - %233 = fmul double %220, %215 - %234 = getelementptr inbounds nuw i8, ptr %0, i64 184 - store double %233, ptr %234, align 8 + %217 = call noundef double @llvm.fabs.f64(double %.080.i116) + %sqrt.i119 = call double @llvm.sqrt.f64(double %217) + %218 = fmul double %.080.i116, %.080.i116 + %219 = fmul double %218, %sqrt.i119 + %220 = fmul double %218, %191 + %221 = getelementptr inbounds nuw i8, ptr %0, i64 136 + store double %220, ptr %221, align 8 + %222 = fmul double %218, %192 + %223 = getelementptr inbounds nuw i8, ptr %0, i64 144 + store double %222, ptr %223, align 8 + %224 = fmul double %218, %194 + %225 = getelementptr inbounds nuw i8, ptr %0, i64 152 + store double %224, ptr %225, align 8 + %226 = fmul double %219, %201 + %227 = getelementptr inbounds nuw i8, ptr %0, i64 160 + store double %226, ptr %227, align 8 + %228 = fmul double %219, %207 + %229 = getelementptr inbounds nuw i8, ptr %0, i64 168 + store double %228, ptr %229, align 8 + %230 = fmul double %219, %211 + %231 = getelementptr inbounds nuw i8, ptr %0, i64 176 + store double %230, ptr %231, align 8 + %232 = fmul double %219, %215 + %233 = getelementptr inbounds nuw i8, ptr %0, i64 184 + store double %232, ptr %233, align 8 br label %_ZN2cvL14contourMomentsERKNS_3MatE.exit _ZN2cvL14contourMomentsERKNS_3MatE.exit: ; preds = %82, %.thread.i, %._crit_edge.i, %.noexc105 call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %5) - br label %444 + br label %443 -235: ; preds = %62 - %236 = and i32 %25, 4088 - %.not = icmp eq i32 %236, 0 - br i1 %.not, label %245, label %237 +234: ; preds = %62 + %235 = and i32 %25, 4088 + %.not = icmp eq i32 %235, 0 + br i1 %.not, label %244, label %236 -237: ; preds = %235 +236: ; preds = %234 call void @_ZNSaIcEC1Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #16 invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1EPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %11, ptr noundef nonnull @.str.2, ptr noundef nonnull align 1 dereferenceable(1) %12) - to label %238 unwind label %240 + to label %237 unwind label %239 -238: ; preds = %237 +237: ; preds = %236 invoke void @_ZN2cv5errorEiRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPKcS9_i(i32 noundef -5, ptr noundef nonnull align 8 dereferenceable(32) %11, ptr noundef nonnull @__func__._ZN2cv7momentsERKNS_11_InputArrayEb, ptr noundef nonnull @.str.1, i32 noundef 622) #17 - to label %239 unwind label %242 + to label %238 unwind label %241 -239: ; preds = %238 +238: ; preds = %237 unreachable -240: ; preds = %237 - %241 = landingpad { ptr, i32 } +239: ; preds = %236 + %240 = landingpad { ptr, i32 } cleanup - br label %244 + br label %243 -242: ; preds = %238 - %243 = landingpad { ptr, i32 } +241: ; preds = %237 + %242 = landingpad { ptr, i32 } cleanup call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(32) %11) #16 - br label %244 + br label %243 -244: ; preds = %242, %240 - %.pn92 = phi { ptr, i32 } [ %243, %242 ], [ %241, %240 ] +243: ; preds = %241, %239 + %.pn92 = phi { ptr, i32 } [ %242, %241 ], [ %240, %239 ] call void @_ZNSaIcED1Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #16 br label %.body -245: ; preds = %235 - %246 = icmp eq i32 %27, 0 - %or.cond6 = or i1 %2, %246 - br i1 %or.cond6, label %258, label %247 +244: ; preds = %234 + %245 = icmp eq i32 %27, 0 + %or.cond6 = or i1 %2, %245 + br i1 %or.cond6, label %257, label %246 -247: ; preds = %245 +246: ; preds = %244 %switch.tableidx = add nsw i32 %27, -2 - %248 = icmp ult i32 %switch.tableidx, 5 - br i1 %248, label %switch.hole_check, label %249 + %247 = icmp ult i32 %switch.tableidx, 5 + br i1 %247, label %switch.hole_check, label %248 -249: ; preds = %switch.hole_check, %247 +248: ; preds = %switch.hole_check, %246 call void @_ZNSaIcEC1Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #16 invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC1EPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %13, ptr noundef nonnull @.str.3, ptr noundef nonnull align 1 dereferenceable(1) %14) - to label %250 unwind label %252 + to label %249 unwind label %251 -250: ; preds = %249 +249: ; preds = %248 invoke void @_ZN2cv5errorEiRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEPKcS9_i(i32 noundef -210, ptr noundef nonnull align 8 dereferenceable(32) %13, ptr noundef nonnull @__func__._ZN2cv7momentsERKNS_11_InputArrayEb, ptr noundef nonnull @.str.1, i32 noundef 637) #17 - to label %251 unwind label %254 + to label %250 unwind label %253 -251: ; preds = %250 +250: ; preds = %249 unreachable -252: ; preds = %249 - %253 = landingpad { ptr, i32 } +251: ; preds = %248 + %252 = landingpad { ptr, i32 } cleanup - br label %256 + br label %255 -254: ; preds = %250 - %255 = landingpad { ptr, i32 } +253: ; preds = %249 + %254 = landingpad { ptr, i32 } cleanup call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(32) %13) #16 - br label %256 + br label %255 -256: ; preds = %254, %252 - %.pn = phi { ptr, i32 } [ %255, %254 ], [ %253, %252 ] +255: ; preds = %253, %251 + %.pn = phi { ptr, i32 } [ %254, %253 ], [ %252, %251 ] call void @_ZNSaIcED1Ev(ptr noundef nonnull align 1 dereferenceable(1) %14) #16 br label %.body -switch.hole_check: ; preds = %247 +switch.hole_check: ; preds = %246 %switch.maskindex = trunc nuw nsw i32 %switch.tableidx to i8 %switch.shifted = lshr i8 27, %switch.maskindex %switch.lobit = trunc i8 %switch.shifted to i1 - br i1 %switch.lobit, label %switch.lookup, label %249 + br i1 %switch.lobit, label %switch.lookup, label %248 switch.lookup: ; preds = %switch.hole_check - %257 = zext nneg i32 %switch.tableidx to i64 - %switch.gep = getelementptr inbounds nuw [5 x ptr], ptr @switch.table._ZN2cv7momentsERKNS_11_InputArrayEb, i64 0, i64 %257 + %256 = zext nneg i32 %switch.tableidx to i64 + %switch.gep = getelementptr inbounds nuw [5 x ptr], ptr @switch.table._ZN2cv7momentsERKNS_11_InputArrayEb, i64 0, i64 %256 %switch.load = load ptr, ptr %switch.gep, align 8 - br label %258 + br label %257 -258: ; preds = %switch.lookup, %245 - %.0 = phi ptr [ @_ZN2cvL13momentsInTileIhiiEEvRKNS_3MatEPd, %245 ], [ %switch.load, %switch.lookup ] +257: ; preds = %switch.lookup, %244 + %.0 = phi ptr [ @_ZN2cvL13momentsInTileIhiiEEvRKNS_3MatEPd, %244 ], [ %switch.load, %switch.lookup ] invoke void @_ZN2cv3MatC1ERKS0_(ptr noundef nonnull align 8 dereferenceable(96) %15, ptr noundef nonnull align 8 dereferenceable(96) %10) to label %.lr.ph.us.preheader unwind label %58 -.lr.ph.us.preheader: ; preds = %258 - %259 = getelementptr inbounds nuw i8, ptr %17, i64 4 - %260 = getelementptr inbounds nuw i8, ptr %17, i64 8 - %261 = getelementptr inbounds nuw i8, ptr %17, i64 12 - %262 = getelementptr inbounds nuw i8, ptr %19, i64 16 - %263 = getelementptr inbounds nuw i8, ptr %19, i64 20 - %264 = getelementptr inbounds nuw i8, ptr %19, i64 8 - %265 = getelementptr inbounds nuw i8, ptr %20, i64 16 - %266 = getelementptr inbounds nuw i8, ptr %20, i64 8 - %267 = getelementptr inbounds nuw i8, ptr %22, i64 8 - %268 = getelementptr inbounds nuw i8, ptr %22, i64 16 - %269 = getelementptr inbounds nuw i8, ptr %23, i64 8 - %270 = getelementptr inbounds nuw i8, ptr %9, i64 8 - %271 = getelementptr inbounds nuw i8, ptr %23, i64 16 - %272 = getelementptr inbounds nuw i8, ptr %9, i64 16 - %273 = getelementptr inbounds nuw i8, ptr %23, i64 24 - %274 = getelementptr inbounds nuw i8, ptr %9, i64 24 - %275 = getelementptr inbounds nuw i8, ptr %23, i64 32 - %276 = getelementptr inbounds nuw i8, ptr %9, i64 32 - %277 = getelementptr inbounds nuw i8, ptr %23, i64 40 - %278 = getelementptr inbounds nuw i8, ptr %9, i64 40 - %279 = getelementptr inbounds nuw i8, ptr %23, i64 48 - %280 = getelementptr inbounds nuw i8, ptr %9, i64 48 - %281 = getelementptr inbounds nuw i8, ptr %23, i64 56 - %282 = getelementptr inbounds nuw i8, ptr %9, i64 56 - %283 = getelementptr inbounds nuw i8, ptr %23, i64 64 - %284 = getelementptr inbounds nuw i8, ptr %9, i64 64 - %285 = getelementptr inbounds nuw i8, ptr %23, i64 72 - %286 = getelementptr inbounds nuw i8, ptr %9, i64 72 +.lr.ph.us.preheader: ; preds = %257 + %258 = getelementptr inbounds nuw i8, ptr %17, i64 4 + %259 = getelementptr inbounds nuw i8, ptr %17, i64 8 + %260 = getelementptr inbounds nuw i8, ptr %17, i64 12 + %261 = getelementptr inbounds nuw i8, ptr %19, i64 16 + %262 = getelementptr inbounds nuw i8, ptr %19, i64 20 + %263 = getelementptr inbounds nuw i8, ptr %19, i64 8 + %264 = getelementptr inbounds nuw i8, ptr %20, i64 16 + %265 = getelementptr inbounds nuw i8, ptr %20, i64 8 + %266 = getelementptr inbounds nuw i8, ptr %22, i64 8 + %267 = getelementptr inbounds nuw i8, ptr %22, i64 16 + %268 = getelementptr inbounds nuw i8, ptr %23, i64 8 + %269 = getelementptr inbounds nuw i8, ptr %9, i64 8 + %270 = getelementptr inbounds nuw i8, ptr %23, i64 16 + %271 = getelementptr inbounds nuw i8, ptr %9, i64 16 + %272 = getelementptr inbounds nuw i8, ptr %23, i64 24 + %273 = getelementptr inbounds nuw i8, ptr %9, i64 24 + %274 = getelementptr inbounds nuw i8, ptr %23, i64 32 + %275 = getelementptr inbounds nuw i8, ptr %9, i64 32 + %276 = getelementptr inbounds nuw i8, ptr %23, i64 40 + %277 = getelementptr inbounds nuw i8, ptr %9, i64 40 + %278 = getelementptr inbounds nuw i8, ptr %23, i64 48 + %279 = getelementptr inbounds nuw i8, ptr %9, i64 48 + %280 = getelementptr inbounds nuw i8, ptr %23, i64 56 + %281 = getelementptr inbounds nuw i8, ptr %9, i64 56 + %282 = getelementptr inbounds nuw i8, ptr %23, i64 64 + %283 = getelementptr inbounds nuw i8, ptr %9, i64 64 + %284 = getelementptr inbounds nuw i8, ptr %23, i64 72 + %285 = getelementptr inbounds nuw i8, ptr %9, i64 72 br label %.lr.ph.us .lr.ph.us: ; preds = %.lr.ph.us.preheader, %._crit_edge.us - %.081145.us = phi i32 [ %363, %._crit_edge.us ], [ 0, %.lr.ph.us.preheader ] - %287 = sub nsw i32 %.sroa.4.0.extract.trunc, %.081145.us - %.sroa.speculated126.us = call i32 @llvm.smin.i32(i32 %287, i32 32) + %.081145.us = phi i32 [ %362, %._crit_edge.us ], [ 0, %.lr.ph.us.preheader ] + %286 = sub nsw i32 %.sroa.4.0.extract.trunc, %.081145.us + %.sroa.speculated126.us = call i32 @llvm.smin.i32(i32 %286, i32 32) %.sroa.3.0.insert.ext.us = zext i32 %.sroa.speculated126.us to i64 %.sroa.3.0.insert.shift.us = shl nuw i64 %.sroa.3.0.insert.ext.us, 32 - %288 = uitofp nneg i32 %.081145.us to double - br label %289 + %287 = uitofp nneg i32 %.081145.us to double + br label %288 -289: ; preds = %.lr.ph.us, %.loopexit.us - %.080144.us = phi i32 [ 0, %.lr.ph.us ], [ %358, %.loopexit.us ] - %290 = sub nsw i32 %.sroa.044.0.extract.trunc, %.080144.us - %.sroa.speculated.us = call i32 @llvm.smin.i32(i32 %290, i32 32) +288: ; preds = %.lr.ph.us, %.loopexit.us + %.080144.us = phi i32 [ 0, %.lr.ph.us ], [ %357, %.loopexit.us ] + %289 = sub nsw i32 %.sroa.044.0.extract.trunc, %.080144.us + %.sroa.speculated.us = call i32 @llvm.smin.i32(i32 %289, i32 32) store i32 %.080144.us, ptr %17, align 4 - store i32 %.081145.us, ptr %259, align 4 - store i32 %.sroa.speculated.us, ptr %260, align 4 - store i32 %.sroa.speculated126.us, ptr %261, align 4 + store i32 %.081145.us, ptr %258, align 4 + store i32 %.sroa.speculated.us, ptr %259, align 4 + store i32 %.sroa.speculated126.us, ptr %260, align 4 invoke void @_ZN2cv3MatC1ERKS0_RKNS_5Rect_IiEE(ptr noundef nonnull align 8 dereferenceable(96) %16, ptr noundef nonnull align 8 dereferenceable(96) %15, ptr noundef nonnull align 4 dereferenceable(16) %17) - to label %291 unwind label %.split.us + to label %290 unwind label %.split.us -291: ; preds = %289 - br i1 %2, label %292, label %297 +290: ; preds = %288 + br i1 %2, label %291, label %296 -292: ; preds = %291 +291: ; preds = %290 %.sroa.0.0.insert.ext.us = zext i32 %.sroa.speculated.us to i64 %.sroa.0.0.insert.insert.us = or disjoint i64 %.sroa.3.0.insert.shift.us, %.sroa.0.0.insert.ext.us invoke void @_ZN2cv3MatC1ENS_5Size_IiEEiPvm(ptr noundef nonnull align 8 dereferenceable(96) %18, i64 %.sroa.0.0.insert.insert.us, i32 noundef 0, ptr noundef nonnull %8, i64 noundef 0) - to label %293 unwind label %.split149.us + to label %292 unwind label %.split149.us -293: ; preds = %292 - store i32 0, ptr %262, align 8 - store i32 0, ptr %263, align 4 +292: ; preds = %291 + store i32 0, ptr %261, align 8 + store i32 0, ptr %262, align 4 store i32 16842752, ptr %19, align 8 - store ptr %16, ptr %264, align 8 + store ptr %16, ptr %263, align 8 store double 0.000000e+00, ptr %21, align 8 store i32 -1056833530, ptr %20, align 8 - store ptr %21, ptr %266, align 8 - store i64 4294967297, ptr %265, align 8 - store i64 0, ptr %268, align 8 + store ptr %21, ptr %265, align 8 + store i64 4294967297, ptr %264, align 8 + store i64 0, ptr %267, align 8 store i32 33619968, ptr %22, align 8 - store ptr %18, ptr %267, align 8 + store ptr %18, ptr %266, align 8 invoke void @_ZN2cv7compareERKNS_11_InputArrayES2_RKNS_12_OutputArrayEi(ptr noundef nonnull align 8 dereferenceable(24) %19, ptr noundef nonnull align 8 dereferenceable(24) %20, ptr noundef nonnull align 8 dereferenceable(24) %22, i32 noundef 5) - to label %294 unwind label %.split152.us + to label %293 unwind label %.split152.us -294: ; preds = %293 - %295 = invoke noundef nonnull align 8 dereferenceable(96) ptr @_ZN2cv3MataSERKS0_(ptr noundef nonnull align 8 dereferenceable(96) %16, ptr noundef nonnull align 8 dereferenceable(96) %18) - to label %296 unwind label %.split155.us +293: ; preds = %292 + %294 = invoke noundef nonnull align 8 dereferenceable(96) ptr @_ZN2cv3MataSERKS0_(ptr noundef nonnull align 8 dereferenceable(96) %16, ptr noundef nonnull align 8 dereferenceable(96) %18) + to label %295 unwind label %.split155.us -296: ; preds = %294 +295: ; preds = %293 call void @_ZN2cv3MatD1Ev(ptr noundef nonnull align 8 dereferenceable(96) %18) #16 - br label %297 + br label %296 -297: ; preds = %296, %291 +296: ; preds = %295, %290 invoke void %.0(ptr noundef nonnull align 8 dereferenceable(96) %16, ptr noundef nonnull %23) - to label %298 unwind label %.split149.us + to label %297 unwind label %.split149.us -298: ; preds = %297 +297: ; preds = %296 br i1 %2, label %.preheader.us, label %.loopexit.us -.loopexit.us: ; preds = %.preheader.us, %298 - %299 = uitofp nneg i32 %.080144.us to double - %300 = load double, ptr %23, align 16 - %301 = fmul double %300, %299 - %302 = fmul double %300, %288 - %303 = load double, ptr %9, align 8 - %304 = fadd double %300, %303 - store double %304, ptr %9, align 8 - %305 = load double, ptr %269, align 8 - %306 = fadd double %301, %305 - %307 = load double, ptr %270, align 8 - %308 = fadd double %307, %306 - store double %308, ptr %270, align 8 - %309 = load double, ptr %271, align 16 - %310 = fadd double %302, %309 - %311 = load double, ptr %272, align 8 - %312 = fadd double %311, %310 - store double %312, ptr %272, align 8 - %313 = load double, ptr %273, align 8 - %314 = call double @llvm.fmuladd.f64(double %305, double 2.000000e+00, double %301) - %315 = call double @llvm.fmuladd.f64(double %299, double %314, double %313) - %316 = load double, ptr %274, align 8 - %317 = fadd double %316, %315 - store double %317, ptr %274, align 8 - %318 = load double, ptr %275, align 16 - %319 = call double @llvm.fmuladd.f64(double %299, double %310, double %318) - %320 = call double @llvm.fmuladd.f64(double %288, double %305, double %319) - %321 = load double, ptr %276, align 8 - %322 = fadd double %321, %320 - store double %322, ptr %276, align 8 - %323 = load double, ptr %277, align 8 - %324 = call double @llvm.fmuladd.f64(double %309, double 2.000000e+00, double %302) - %325 = call double @llvm.fmuladd.f64(double %288, double %324, double %323) - %326 = load double, ptr %278, align 8 - %327 = fadd double %326, %325 - store double %327, ptr %278, align 8 - %328 = load double, ptr %279, align 16 - %329 = call double @llvm.fmuladd.f64(double %305, double 3.000000e+00, double %301) - %330 = fmul double %329, %299 - %331 = call double @llvm.fmuladd.f64(double %313, double 3.000000e+00, double %330) - %332 = call double @llvm.fmuladd.f64(double %299, double %331, double %328) - %333 = load double, ptr %280, align 8 - %334 = fadd double %333, %332 - store double %334, ptr %280, align 8 - %335 = load double, ptr %281, align 8 - %336 = call double @llvm.fmuladd.f64(double %288, double %305, double %318) - %337 = fmul double %310, %299 - %338 = call double @llvm.fmuladd.f64(double %336, double 2.000000e+00, double %337) - %339 = call double @llvm.fmuladd.f64(double %299, double %338, double %335) - %340 = call double @llvm.fmuladd.f64(double %288, double %313, double %339) - %341 = load double, ptr %282, align 8 - %342 = fadd double %341, %340 - store double %342, ptr %282, align 8 - %343 = load double, ptr %283, align 16 - %344 = call double @llvm.fmuladd.f64(double %299, double %309, double %318) - %345 = fmul double %306, %288 - %346 = call double @llvm.fmuladd.f64(double %344, double 2.000000e+00, double %345) - %347 = call double @llvm.fmuladd.f64(double %288, double %346, double %343) - %348 = call double @llvm.fmuladd.f64(double %299, double %323, double %347) - %349 = load double, ptr %284, align 8 - %350 = fadd double %349, %348 - store double %350, ptr %284, align 8 - %351 = load double, ptr %285, align 8 - %352 = call double @llvm.fmuladd.f64(double %309, double 3.000000e+00, double %302) - %353 = fmul double %352, %288 - %354 = call double @llvm.fmuladd.f64(double %323, double 3.000000e+00, double %353) - %355 = call double @llvm.fmuladd.f64(double %288, double %354, double %351) - %356 = load double, ptr %286, align 8 - %357 = fadd double %356, %355 - store double %357, ptr %286, align 8 +.loopexit.us: ; preds = %.preheader.us, %297 + %298 = uitofp nneg i32 %.080144.us to double + %299 = load double, ptr %23, align 16 + %300 = fmul double %299, %298 + %301 = fmul double %299, %287 + %302 = load double, ptr %9, align 8 + %303 = fadd double %299, %302 + store double %303, ptr %9, align 8 + %304 = load double, ptr %268, align 8 + %305 = fadd double %300, %304 + %306 = load double, ptr %269, align 8 + %307 = fadd double %306, %305 + store double %307, ptr %269, align 8 + %308 = load double, ptr %270, align 16 + %309 = fadd double %301, %308 + %310 = load double, ptr %271, align 8 + %311 = fadd double %310, %309 + store double %311, ptr %271, align 8 + %312 = load double, ptr %272, align 8 + %313 = call double @llvm.fmuladd.f64(double %304, double 2.000000e+00, double %300) + %314 = call double @llvm.fmuladd.f64(double %298, double %313, double %312) + %315 = load double, ptr %273, align 8 + %316 = fadd double %315, %314 + store double %316, ptr %273, align 8 + %317 = load double, ptr %274, align 16 + %318 = call double @llvm.fmuladd.f64(double %298, double %309, double %317) + %319 = call double @llvm.fmuladd.f64(double %287, double %304, double %318) + %320 = load double, ptr %275, align 8 + %321 = fadd double %320, %319 + store double %321, ptr %275, align 8 + %322 = load double, ptr %276, align 8 + %323 = call double @llvm.fmuladd.f64(double %308, double 2.000000e+00, double %301) + %324 = call double @llvm.fmuladd.f64(double %287, double %323, double %322) + %325 = load double, ptr %277, align 8 + %326 = fadd double %325, %324 + store double %326, ptr %277, align 8 + %327 = load double, ptr %278, align 16 + %328 = call double @llvm.fmuladd.f64(double %304, double 3.000000e+00, double %300) + %329 = fmul double %328, %298 + %330 = call double @llvm.fmuladd.f64(double %312, double 3.000000e+00, double %329) + %331 = call double @llvm.fmuladd.f64(double %298, double %330, double %327) + %332 = load double, ptr %279, align 8 + %333 = fadd double %332, %331 + store double %333, ptr %279, align 8 + %334 = load double, ptr %280, align 8 + %335 = call double @llvm.fmuladd.f64(double %287, double %304, double %317) + %336 = fmul double %309, %298 + %337 = call double @llvm.fmuladd.f64(double %335, double 2.000000e+00, double %336) + %338 = call double @llvm.fmuladd.f64(double %298, double %337, double %334) + %339 = call double @llvm.fmuladd.f64(double %287, double %312, double %338) + %340 = load double, ptr %281, align 8 + %341 = fadd double %340, %339 + store double %341, ptr %281, align 8 + %342 = load double, ptr %282, align 16 + %343 = call double @llvm.fmuladd.f64(double %298, double %308, double %317) + %344 = fmul double %305, %287 + %345 = call double @llvm.fmuladd.f64(double %343, double 2.000000e+00, double %344) + %346 = call double @llvm.fmuladd.f64(double %287, double %345, double %342) + %347 = call double @llvm.fmuladd.f64(double %298, double %322, double %346) + %348 = load double, ptr %283, align 8 + %349 = fadd double %348, %347 + store double %349, ptr %283, align 8 + %350 = load double, ptr %284, align 8 + %351 = call double @llvm.fmuladd.f64(double %308, double 3.000000e+00, double %301) + %352 = fmul double %351, %287 + %353 = call double @llvm.fmuladd.f64(double %322, double 3.000000e+00, double %352) + %354 = call double @llvm.fmuladd.f64(double %287, double %353, double %350) + %355 = load double, ptr %285, align 8 + %356 = fadd double %355, %354 + store double %356, ptr %285, align 8 call void @_ZN2cv3MatD1Ev(ptr noundef nonnull align 8 dereferenceable(96) %16) #16 - %358 = add nuw nsw i32 %.080144.us, 32 - %359 = icmp slt i32 %358, %.sroa.044.0.extract.trunc - br i1 %359, label %289, label %._crit_edge.us, !llvm.loop !12 - -.preheader.us: ; preds = %298, %.preheader.us - %indvars.iv = phi i64 [ %indvars.iv.next, %.preheader.us ], [ 0, %298 ] - %360 = getelementptr inbounds nuw [10 x double], ptr %23, i64 0, i64 %indvars.iv - %361 = load double, ptr %360, align 8 - %362 = fmul double %361, 0x3F70101010101010 - store double %362, ptr %360, align 8 + %357 = add nuw nsw i32 %.080144.us, 32 + %358 = icmp slt i32 %357, %.sroa.044.0.extract.trunc + br i1 %358, label %288, label %._crit_edge.us, !llvm.loop !12 + +.preheader.us: ; preds = %297, %.preheader.us + %indvars.iv = phi i64 [ %indvars.iv.next, %.preheader.us ], [ 0, %297 ] + %359 = getelementptr inbounds nuw [10 x double], ptr %23, i64 0, i64 %indvars.iv + %360 = load double, ptr %359, align 8 + %361 = fmul double %360, 0x3F70101010101010 + store double %361, ptr %359, align 8 %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1 %exitcond.not = icmp eq i64 %indvars.iv.next, 10 br i1 %exitcond.not, label %.loopexit.us, label %.preheader.us, !llvm.loop !13 ._crit_edge.us: ; preds = %.loopexit.us - %363 = add nuw nsw i32 %.081145.us, 32 - %364 = icmp slt i32 %363, %.sroa.4.0.extract.trunc - br i1 %364, label %.lr.ph.us, label %._crit_edge147, !llvm.loop !14 + %362 = add nuw nsw i32 %.081145.us, 32 + %363 = icmp slt i32 %362, %.sroa.4.0.extract.trunc + br i1 %363, label %.lr.ph.us, label %._crit_edge147, !llvm.loop !14 -.split.us: ; preds = %289 +.split.us: ; preds = %288 + %364 = landingpad { ptr, i32 } + cleanup + br label %442 + +.split149.us: ; preds = %296, %291 %365 = landingpad { ptr, i32 } cleanup - br label %443 + br label %369 -.split149.us: ; preds = %297, %292 +.split152.us: ; preds = %292 %366 = landingpad { ptr, i32 } cleanup - br label %370 + br label %368 -.split152.us: ; preds = %293 +.split155.us: ; preds = %293 %367 = landingpad { ptr, i32 } cleanup - br label %369 + br label %368 -.split155.us: ; preds = %294 - %368 = landingpad { ptr, i32 } - cleanup - br label %369 - -369: ; preds = %.split152.us, %.split155.us - %.pn87 = phi { ptr, i32 } [ %368, %.split155.us ], [ %367, %.split152.us ] +368: ; preds = %.split152.us, %.split155.us + %.pn87 = phi { ptr, i32 } [ %367, %.split155.us ], [ %366, %.split152.us ] call void @_ZN2cv3MatD1Ev(ptr noundef nonnull align 8 dereferenceable(96) %18) #16 - br label %370 + br label %369 -370: ; preds = %369, %.split149.us - %.pn89 = phi { ptr, i32 } [ %366, %.split149.us ], [ %.pn87, %369 ] +369: ; preds = %368, %.split149.us + %.pn89 = phi { ptr, i32 } [ %365, %.split149.us ], [ %.pn87, %368 ] call void @_ZN2cv3MatD1Ev(ptr noundef nonnull align 8 dereferenceable(96) %16) #16 - br label %443 + br label %442 ._crit_edge147: ; preds = %._crit_edge.us - %371 = load double, ptr %9, align 8 - %372 = call double @llvm.fabs.f64(double %371) - %373 = fcmp ogt double %372, 0x3CB0000000000000 - br i1 %373, label %374, label %._crit_edge.i108 + %370 = load double, ptr %9, align 8 + %371 = call double @llvm.fabs.f64(double %370) + %372 = fcmp ogt double %371, 0x3CB0000000000000 + br i1 %372, label %373, label %._crit_edge.i108 ._crit_edge.i108: ; preds = %._crit_edge147 %.phi.trans.insert.i = getelementptr inbounds nuw i8, ptr %9, i64 8 %.pre.i = load double, ptr %.phi.trans.insert.i, align 8 %.phi.trans.insert85.i = getelementptr inbounds nuw i8, ptr %9, i64 16 %.pre86.i = load double, ptr %.phi.trans.insert85.i, align 8 - br label %382 - -374: ; preds = %._crit_edge147 - %375 = fdiv double 1.000000e+00, %371 - %376 = getelementptr inbounds nuw i8, ptr %9, i64 8 - %377 = load double, ptr %376, align 8 - %378 = fmul double %375, %377 - %379 = getelementptr inbounds nuw i8, ptr %9, i64 16 - %380 = load double, ptr %379, align 8 - %381 = fmul double %375, %380 - br label %382 - -382: ; preds = %374, %._crit_edge.i108 - %383 = phi double [ %380, %374 ], [ %.pre86.i, %._crit_edge.i108 ] - %384 = phi double [ %377, %374 ], [ %.pre.i, %._crit_edge.i108 ] - %.080.i = phi double [ %375, %374 ], [ 0.000000e+00, %._crit_edge.i108 ] - %.079.i = phi double [ %381, %374 ], [ 0.000000e+00, %._crit_edge.i108 ] - %.0.i = phi double [ %378, %374 ], [ 0.000000e+00, %._crit_edge.i108 ] - %385 = getelementptr inbounds nuw i8, ptr %9, i64 24 - %386 = load double, ptr %385, align 8 - %387 = fneg double %384 - %388 = call double @llvm.fmuladd.f64(double %387, double %.0.i, double %386) - %389 = getelementptr inbounds nuw i8, ptr %9, i64 32 - %390 = load double, ptr %389, align 8 - %391 = call double @llvm.fmuladd.f64(double %387, double %.079.i, double %390) - %392 = getelementptr inbounds nuw i8, ptr %9, i64 40 - %393 = load double, ptr %392, align 8 - %394 = fneg double %383 - %395 = call double @llvm.fmuladd.f64(double %394, double %.079.i, double %393) - %396 = getelementptr inbounds nuw i8, ptr %9, i64 80 - store double %388, ptr %396, align 8 - %397 = getelementptr inbounds nuw i8, ptr %9, i64 88 - store double %391, ptr %397, align 8 - %398 = getelementptr inbounds nuw i8, ptr %9, i64 96 - store double %395, ptr %398, align 8 - %399 = getelementptr inbounds nuw i8, ptr %9, i64 48 - %400 = load double, ptr %399, align 8 - %401 = fmul double %384, %.0.i - %402 = call double @llvm.fmuladd.f64(double %388, double 3.000000e+00, double %401) - %403 = fneg double %.0.i - %404 = call double @llvm.fmuladd.f64(double %403, double %402, double %400) - %405 = getelementptr inbounds nuw i8, ptr %9, i64 104 - store double %404, ptr %405, align 8 - %406 = fadd double %391, %391 - %407 = getelementptr inbounds nuw i8, ptr %9, i64 56 - %408 = load double, ptr %407, align 8 - %409 = call double @llvm.fmuladd.f64(double %.0.i, double %383, double %406) - %410 = call double @llvm.fmuladd.f64(double %403, double %409, double %408) - %411 = fneg double %.079.i - %412 = call double @llvm.fmuladd.f64(double %411, double %388, double %410) - %413 = getelementptr inbounds nuw i8, ptr %9, i64 112 - store double %412, ptr %413, align 8 - %414 = getelementptr inbounds nuw i8, ptr %9, i64 64 - %415 = load double, ptr %414, align 8 - %416 = call double @llvm.fmuladd.f64(double %.079.i, double %384, double %406) - %417 = call double @llvm.fmuladd.f64(double %411, double %416, double %415) - %418 = call double @llvm.fmuladd.f64(double %403, double %395, double %417) - %419 = getelementptr inbounds nuw i8, ptr %9, i64 120 - store double %418, ptr %419, align 8 - %420 = getelementptr inbounds nuw i8, ptr %9, i64 72 - %421 = load double, ptr %420, align 8 - %422 = fmul double %383, %.079.i - %423 = call double @llvm.fmuladd.f64(double %395, double 3.000000e+00, double %422) - %424 = call double @llvm.fmuladd.f64(double %411, double %423, double %421) - %425 = getelementptr inbounds nuw i8, ptr %9, i64 128 - store double %424, ptr %425, align 8 - %426 = call noundef double @llvm.fabs.f64(double %.080.i) - %sqrt.i = call double @llvm.sqrt.f64(double %426) - %427 = fmul double %.080.i, %.080.i - %428 = fmul double %427, %sqrt.i - %429 = fmul double %427, %388 - %430 = getelementptr inbounds nuw i8, ptr %9, i64 136 - store double %429, ptr %430, align 8 - %431 = fmul double %427, %391 - %432 = getelementptr inbounds nuw i8, ptr %9, i64 144 - store double %431, ptr %432, align 8 - %433 = fmul double %427, %395 - %434 = getelementptr inbounds nuw i8, ptr %9, i64 152 - store double %433, ptr %434, align 8 - %435 = fmul double %428, %404 - %436 = getelementptr inbounds nuw i8, ptr %9, i64 160 - store double %435, ptr %436, align 8 - %437 = fmul double %428, %412 - %438 = getelementptr inbounds nuw i8, ptr %9, i64 168 - store double %437, ptr %438, align 8 - %439 = fmul double %428, %418 - %440 = getelementptr inbounds nuw i8, ptr %9, i64 176 - store double %439, ptr %440, align 8 - %441 = fmul double %428, %424 - %442 = getelementptr inbounds nuw i8, ptr %9, i64 184 - store double %441, ptr %442, align 8 + br label %381 + +373: ; preds = %._crit_edge147 + %374 = fdiv double 1.000000e+00, %370 + %375 = getelementptr inbounds nuw i8, ptr %9, i64 8 + %376 = load double, ptr %375, align 8 + %377 = fmul double %374, %376 + %378 = getelementptr inbounds nuw i8, ptr %9, i64 16 + %379 = load double, ptr %378, align 8 + %380 = fmul double %374, %379 + br label %381 + +381: ; preds = %373, %._crit_edge.i108 + %382 = phi double [ %379, %373 ], [ %.pre86.i, %._crit_edge.i108 ] + %383 = phi double [ %376, %373 ], [ %.pre.i, %._crit_edge.i108 ] + %.080.i = phi double [ %374, %373 ], [ 0.000000e+00, %._crit_edge.i108 ] + %.079.i = phi double [ %380, %373 ], [ 0.000000e+00, %._crit_edge.i108 ] + %.0.i = phi double [ %377, %373 ], [ 0.000000e+00, %._crit_edge.i108 ] + %384 = getelementptr inbounds nuw i8, ptr %9, i64 24 + %385 = load double, ptr %384, align 8 + %386 = fneg double %383 + %387 = call double @llvm.fmuladd.f64(double %386, double %.0.i, double %385) + %388 = getelementptr inbounds nuw i8, ptr %9, i64 32 + %389 = load double, ptr %388, align 8 + %390 = call double @llvm.fmuladd.f64(double %386, double %.079.i, double %389) + %391 = getelementptr inbounds nuw i8, ptr %9, i64 40 + %392 = load double, ptr %391, align 8 + %393 = fneg double %382 + %394 = call double @llvm.fmuladd.f64(double %393, double %.079.i, double %392) + %395 = getelementptr inbounds nuw i8, ptr %9, i64 80 + store double %387, ptr %395, align 8 + %396 = getelementptr inbounds nuw i8, ptr %9, i64 88 + store double %390, ptr %396, align 8 + %397 = getelementptr inbounds nuw i8, ptr %9, i64 96 + store double %394, ptr %397, align 8 + %398 = getelementptr inbounds nuw i8, ptr %9, i64 48 + %399 = load double, ptr %398, align 8 + %400 = fmul double %383, %.0.i + %401 = call double @llvm.fmuladd.f64(double %387, double 3.000000e+00, double %400) + %402 = fneg double %.0.i + %403 = call double @llvm.fmuladd.f64(double %402, double %401, double %399) + %404 = getelementptr inbounds nuw i8, ptr %9, i64 104 + store double %403, ptr %404, align 8 + %405 = fadd double %390, %390 + %406 = getelementptr inbounds nuw i8, ptr %9, i64 56 + %407 = load double, ptr %406, align 8 + %408 = call double @llvm.fmuladd.f64(double %.0.i, double %382, double %405) + %409 = call double @llvm.fmuladd.f64(double %402, double %408, double %407) + %410 = fneg double %.079.i + %411 = call double @llvm.fmuladd.f64(double %410, double %387, double %409) + %412 = getelementptr inbounds nuw i8, ptr %9, i64 112 + store double %411, ptr %412, align 8 + %413 = getelementptr inbounds nuw i8, ptr %9, i64 64 + %414 = load double, ptr %413, align 8 + %415 = call double @llvm.fmuladd.f64(double %.079.i, double %383, double %405) + %416 = call double @llvm.fmuladd.f64(double %410, double %415, double %414) + %417 = call double @llvm.fmuladd.f64(double %402, double %394, double %416) + %418 = getelementptr inbounds nuw i8, ptr %9, i64 120 + store double %417, ptr %418, align 8 + %419 = getelementptr inbounds nuw i8, ptr %9, i64 72 + %420 = load double, ptr %419, align 8 + %421 = fmul double %382, %.079.i + %422 = call double @llvm.fmuladd.f64(double %394, double 3.000000e+00, double %421) + %423 = call double @llvm.fmuladd.f64(double %410, double %422, double %420) + %424 = getelementptr inbounds nuw i8, ptr %9, i64 128 + store double %423, ptr %424, align 8 + %425 = call noundef double @llvm.fabs.f64(double %.080.i) + %sqrt.i = call double @llvm.sqrt.f64(double %425) + %426 = fmul double %.080.i, %.080.i + %427 = fmul double %426, %sqrt.i + %428 = fmul double %426, %387 + %429 = getelementptr inbounds nuw i8, ptr %9, i64 136 + store double %428, ptr %429, align 8 + %430 = fmul double %426, %390 + %431 = getelementptr inbounds nuw i8, ptr %9, i64 144 + store double %430, ptr %431, align 8 + %432 = fmul double %426, %394 + %433 = getelementptr inbounds nuw i8, ptr %9, i64 152 + store double %432, ptr %433, align 8 + %434 = fmul double %427, %403 + %435 = getelementptr inbounds nuw i8, ptr %9, i64 160 + store double %434, ptr %435, align 8 + %436 = fmul double %427, %411 + %437 = getelementptr inbounds nuw i8, ptr %9, i64 168 + store double %436, ptr %437, align 8 + %438 = fmul double %427, %417 + %439 = getelementptr inbounds nuw i8, ptr %9, i64 176 + store double %438, ptr %439, align 8 + %440 = fmul double %427, %423 + %441 = getelementptr inbounds nuw i8, ptr %9, i64 184 + store double %440, ptr %441, align 8 call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(192) %0, ptr noundef nonnull align 8 dereferenceable(192) %9, i64 192, i1 false) call void @_ZN2cv3MatD1Ev(ptr noundef nonnull align 8 dereferenceable(96) %15) #16 - br label %444 + br label %443 -443: ; preds = %370, %.split.us - %.pn89.pn = phi { ptr, i32 } [ %.pn89, %370 ], [ %365, %.split.us ] +442: ; preds = %369, %.split.us + %.pn89.pn = phi { ptr, i32 } [ %.pn89, %369 ], [ %364, %.split.us ] call void @_ZN2cv3MatD1Ev(ptr noundef nonnull align 8 dereferenceable(96) %15) #16 br label %.body -444: ; preds = %_ZN2cvL14contourMomentsERKNS_3MatE.exit, %382 +443: ; preds = %_ZN2cvL14contourMomentsERKNS_3MatE.exit, %381 call void @_ZN2cv3MatD1Ev(ptr noundef nonnull align 8 dereferenceable(96) %10) #16 - br label %445 + br label %444 -.body: ; preds = %56, %58, %81, %443, %256, %244 - %.pn94 = phi { ptr, i32 } [ %.pn92, %244 ], [ %.pn89.pn, %443 ], [ %.pn, %256 ], [ %57, %56 ], [ %.pn.i, %81 ], [ %59, %58 ] +.body: ; preds = %56, %58, %81, %442, %255, %243 + %.pn94 = phi { ptr, i32 } [ %.pn92, %243 ], [ %.pn89.pn, %442 ], [ %.pn, %255 ], [ %57, %56 ], [ %.pn.i, %81 ], [ %59, %58 ] call void @_ZN2cv3MatD1Ev(ptr noundef nonnull align 8 dereferenceable(96) %10) #16 - br label %452 + br label %451 -445: ; preds = %444, %32 - %446 = getelementptr inbounds nuw i8, ptr %7, i64 8 - %447 = load i32, ptr %446, align 8 - %.not.i = icmp eq i32 %447, 0 - br i1 %.not.i, label %_ZN2cv5utils5trace7details6RegionD2Ev.exit, label %448 +444: ; preds = %443, %32 + %445 = getelementptr inbounds nuw i8, ptr %7, i64 8 + %446 = load i32, ptr %445, align 8 + %.not.i = icmp eq i32 %446, 0 + br i1 %.not.i, label %_ZN2cv5utils5trace7details6RegionD2Ev.exit, label %447 -448: ; preds = %445 +447: ; preds = %444 invoke void @_ZN2cv5utils5trace7details6Region7destroyEv(ptr noundef nonnull align 8 dereferenceable(12) %7) - to label %_ZN2cv5utils5trace7details6RegionD2Ev.exit unwind label %449 + to label %_ZN2cv5utils5trace7details6RegionD2Ev.exit unwind label %448 -449: ; preds = %448 - %450 = landingpad { ptr, i32 } +448: ; preds = %447 + %449 = landingpad { ptr, i32 } catch ptr null - %451 = extractvalue { ptr, i32 } %450, 0 - call void @__clang_call_terminate(ptr %451) #15 + %450 = extractvalue { ptr, i32 } %449, 0 + call void @__clang_call_terminate(ptr %450) #15 unreachable -_ZN2cv5utils5trace7details6RegionD2Ev.exit: ; preds = %445, %448 +_ZN2cv5utils5trace7details6RegionD2Ev.exit: ; preds = %444, %447 ret void -452: ; preds = %.body, %33 +451: ; preds = %.body, %33 %.pn94.pn = phi { ptr, i32 } [ %.pn94, %.body ], [ %34, %33 ] call void @_ZN2cv5utils5trace7details6RegionD2Ev(ptr noundef nonnull align 8 dereferenceable(12) %7) #16 resume { ptr, i32 } %.pn94.pn diff --git a/bench/openexr/optimized/ImfRgbaYca.cpp.ll b/bench/openexr/optimized/ImfRgbaYca.cpp.ll index 4d24a1ad4d7..b368b7a71a9 100644 --- a/bench/openexr/optimized/ImfRgbaYca.cpp.ll +++ b/bench/openexr/optimized/ImfRgbaYca.cpp.ll @@ -2832,12 +2832,11 @@ if.then33: ; preds = %if.then26 %cmp.i44.i = fcmp olt float %79, 0.000000e+00 %.sroa.speculated324.i = select i1 %cmp.i44.i, float 0.000000e+00, float %79 %80 = bitcast float %.sroa.speculated324.i to i32 - %81 = tail call float @llvm.fabs.f32(float %79) - %82 = select i1 %cmp.i44.i, float 0.000000e+00, float %81 - %and.i.i.i.i = bitcast float %82 to i32 + %81 = tail call float @llvm.fabs.f32(float %.sroa.speculated324.i) + %and.i.i.i.i = bitcast float %81 to i32 %shr.i.i.i.i = lshr i32 %80, 16 - %83 = trunc nuw i32 %shr.i.i.i.i to i16 - %conv.i.i.i.i = and i16 %83, -32768 + %82 = trunc nuw i32 %shr.i.i.i.i to i16 + %conv.i.i.i.i = and i16 %82, -32768 %cmp.i.i.i.i = icmp samesign ugt i32 %and.i.i.i.i, 947912703 br i1 %cmp.i.i.i.i, label %if.then.i.i.i.i, label %if.end37.i.i.i.i @@ -2854,10 +2853,10 @@ if.end.i.i.i.i: ; preds = %if.then4.i.i.i.i %and9.i.i.i.i = lshr i32 %and.i.i.i.i, 13 %shr10.i.i.i.i = and i32 %and9.i.i.i.i, 1023 %cmp15.i.i.i.i = icmp eq i32 %shr10.i.i.i.i, 0 - %84 = zext i1 %cmp15.i.i.i.i to i16 - %85 = trunc nuw nsw i32 %shr10.i.i.i.i to i16 - %86 = or i16 %84, %85 - %conv19.i.i.i.i = or disjoint i16 %86, %conv6.i.i.i.i + %83 = zext i1 %cmp15.i.i.i.i to i16 + %84 = trunc nuw nsw i32 %shr10.i.i.i.i to i16 + %85 = or i16 %84, %83 + %conv19.i.i.i.i = or disjoint i16 %85, %conv6.i.i.i.i br label %_ZN9Imath_3_24halfaSEf.exit.i if.end20.i.i.i.i: ; preds = %if.then.i.i.i.i @@ -2911,24 +2910,23 @@ if.then55.i.i.i.i: ; preds = %lor.lhs.false.i.i.i _ZN9Imath_3_24halfaSEf.exit.i: ; preds = %if.then55.i.i.i.i, %lor.lhs.false.i.i.i.i, %if.end37.i.i.i.i, %if.end27.i.i.i.i, %if.then23.i.i.i.i, %if.end.i.i.i.i, %if.then4.i.i.i.i %retval.0.i.i.i.i = phi i16 [ %conv19.i.i.i.i, %if.end.i.i.i.i ], [ %conv26.i.i.i.i, %if.then23.i.i.i.i ], [ %conv36.i.i.i.i, %if.end27.i.i.i.i ], [ %conv6.i.i.i.i, %if.then4.i.i.i.i ], [ %conv.i.i.i.i, %if.end37.i.i.i.i ], [ %inc.i.i.i.i, %if.then55.i.i.i.i ], [ %conv49.i.i.i.i, %lor.lhs.false.i.i.i.i ] store i16 %retval.0.i.i.i.i, ptr %arrayidx23, align 2 - %87 = load i16, ptr %g.i97, align 2 - %88 = load ptr, ptr @imath_half_to_float_table, align 8 - %idxprom.i.i46.i = zext i16 %87 to i64 - %arrayidx.i.i47.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %88, i64 %idxprom.i.i46.i - %89 = load float, ptr %arrayidx.i.i47.i, align 4 - %sub12.i = fsub float %73, %89 + %86 = load i16, ptr %g.i97, align 2 + %87 = load ptr, ptr @imath_half_to_float_table, align 8 + %idxprom.i.i46.i = zext i16 %86 to i64 + %arrayidx.i.i47.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %87, i64 %idxprom.i.i46.i + %88 = load float, ptr %arrayidx.i.i47.i, align 4 + %sub12.i = fsub float %73, %88 %neg13.i = fneg float %sub12.i - %90 = tail call float @llvm.fmuladd.f32(float %neg13.i, float %div, float %73) - %cmp.i48.i = fcmp olt float %90, 0.000000e+00 - %.sroa.speculated323.i = select i1 %cmp.i48.i, float 0.000000e+00, float %90 + %89 = tail call float @llvm.fmuladd.f32(float %neg13.i, float %div, float %73) + %cmp.i48.i = fcmp olt float %89, 0.000000e+00 + %.sroa.speculated323.i = select i1 %cmp.i48.i, float 0.000000e+00, float %89 %g16.i = getelementptr inbounds nuw i8, ptr %arrayidx23, i64 2 - %91 = bitcast float %.sroa.speculated323.i to i32 - %92 = tail call float @llvm.fabs.f32(float %90) - %93 = select i1 %cmp.i48.i, float 0.000000e+00, float %92 - %and.i.i.i50.i = bitcast float %93 to i32 - %shr.i.i.i51.i = lshr i32 %91, 16 - %94 = trunc nuw i32 %shr.i.i.i51.i to i16 - %conv.i.i.i52.i = and i16 %94, -32768 + %90 = bitcast float %.sroa.speculated323.i to i32 + %91 = tail call float @llvm.fabs.f32(float %.sroa.speculated323.i) + %and.i.i.i50.i = bitcast float %91 to i32 + %shr.i.i.i51.i = lshr i32 %90, 16 + %92 = trunc nuw i32 %shr.i.i.i51.i to i16 + %conv.i.i.i52.i = and i16 %92, -32768 %cmp.i.i.i53.i = icmp samesign ugt i32 %and.i.i.i50.i, 947912703 br i1 %cmp.i.i.i53.i, label %if.then.i.i.i76.i, label %if.end37.i.i.i54.i @@ -2945,10 +2943,10 @@ if.end.i.i.i94.i: ; preds = %if.then4.i.i.i91.i %and9.i.i.i95.i = lshr i32 %and.i.i.i50.i, 13 %shr10.i.i.i96.i = and i32 %and9.i.i.i95.i, 1023 %cmp15.i.i.i97.i = icmp eq i32 %shr10.i.i.i96.i, 0 - %95 = zext i1 %cmp15.i.i.i97.i to i16 - %96 = trunc nuw nsw i32 %shr10.i.i.i96.i to i16 - %97 = or i16 %95, %96 - %conv19.i.i.i98.i = or disjoint i16 %97, %conv6.i.i.i92.i + %93 = zext i1 %cmp15.i.i.i97.i to i16 + %94 = trunc nuw nsw i32 %shr10.i.i.i96.i to i16 + %95 = or i16 %94, %93 + %conv19.i.i.i98.i = or disjoint i16 %95, %conv6.i.i.i92.i br label %_ZN9Imath_3_24halfaSEf.exit99.i if.end20.i.i.i78.i: ; preds = %if.then.i.i.i76.i @@ -3002,24 +3000,23 @@ if.then55.i.i.i73.i: ; preds = %lor.lhs.false.i.i.i _ZN9Imath_3_24halfaSEf.exit99.i: ; preds = %if.then55.i.i.i73.i, %lor.lhs.false.i.i.i68.i, %if.end37.i.i.i54.i, %if.end27.i.i.i80.i, %if.then23.i.i.i89.i, %if.end.i.i.i94.i, %if.then4.i.i.i91.i %retval.0.i.i.i75.i = phi i16 [ %conv19.i.i.i98.i, %if.end.i.i.i94.i ], [ %conv26.i.i.i90.i, %if.then23.i.i.i89.i ], [ %conv36.i.i.i88.i, %if.end27.i.i.i80.i ], [ %conv6.i.i.i92.i, %if.then4.i.i.i91.i ], [ %conv.i.i.i52.i, %if.end37.i.i.i54.i ], [ %inc.i.i.i74.i, %if.then55.i.i.i73.i ], [ %conv49.i.i.i66.i, %lor.lhs.false.i.i.i68.i ] store i16 %retval.0.i.i.i75.i, ptr %g16.i, align 2 - %98 = load i16, ptr %b.i98, align 2 - %99 = load ptr, ptr @imath_half_to_float_table, align 8 - %idxprom.i.i100.i = zext i16 %98 to i64 - %arrayidx.i.i101.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %99, i64 %idxprom.i.i100.i - %100 = load float, ptr %arrayidx.i.i101.i, align 4 - %sub21.i = fsub float %73, %100 + %96 = load i16, ptr %b.i98, align 2 + %97 = load ptr, ptr @imath_half_to_float_table, align 8 + %idxprom.i.i100.i = zext i16 %96 to i64 + %arrayidx.i.i101.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %97, i64 %idxprom.i.i100.i + %98 = load float, ptr %arrayidx.i.i101.i, align 4 + %sub21.i = fsub float %73, %98 %neg22.i = fneg float %sub21.i - %101 = tail call float @llvm.fmuladd.f32(float %neg22.i, float %div, float %73) - %cmp.i102.i = fcmp olt float %101, 0.000000e+00 - %.sroa.speculated.i = select i1 %cmp.i102.i, float 0.000000e+00, float %101 + %99 = tail call float @llvm.fmuladd.f32(float %neg22.i, float %div, float %73) + %cmp.i102.i = fcmp olt float %99, 0.000000e+00 + %.sroa.speculated.i = select i1 %cmp.i102.i, float 0.000000e+00, float %99 %b25.i = getelementptr inbounds nuw i8, ptr %arrayidx23, i64 4 - %102 = bitcast float %.sroa.speculated.i to i32 - %103 = tail call float @llvm.fabs.f32(float %101) - %104 = select i1 %cmp.i102.i, float 0.000000e+00, float %103 - %and.i.i.i104.i = bitcast float %104 to i32 - %shr.i.i.i105.i = lshr i32 %102, 16 - %105 = trunc nuw i32 %shr.i.i.i105.i to i16 - %conv.i.i.i106.i = and i16 %105, -32768 + %100 = bitcast float %.sroa.speculated.i to i32 + %101 = tail call float @llvm.fabs.f32(float %.sroa.speculated.i) + %and.i.i.i104.i = bitcast float %101 to i32 + %shr.i.i.i105.i = lshr i32 %100, 16 + %102 = trunc nuw i32 %shr.i.i.i105.i to i16 + %conv.i.i.i106.i = and i16 %102, -32768 %cmp.i.i.i107.i = icmp samesign ugt i32 %and.i.i.i104.i, 947912703 br i1 %cmp.i.i.i107.i, label %if.then.i.i.i130.i, label %if.end37.i.i.i108.i @@ -3036,10 +3033,10 @@ if.end.i.i.i148.i: ; preds = %if.then4.i.i.i145.i %and9.i.i.i149.i = lshr i32 %and.i.i.i104.i, 13 %shr10.i.i.i150.i = and i32 %and9.i.i.i149.i, 1023 %cmp15.i.i.i151.i = icmp eq i32 %shr10.i.i.i150.i, 0 - %106 = zext i1 %cmp15.i.i.i151.i to i16 - %107 = trunc nuw nsw i32 %shr10.i.i.i150.i to i16 - %108 = or i16 %106, %107 - %conv19.i.i.i152.i = or disjoint i16 %108, %conv6.i.i.i146.i + %103 = zext i1 %cmp15.i.i.i151.i to i16 + %104 = trunc nuw nsw i32 %shr10.i.i.i150.i to i16 + %105 = or i16 %104, %103 + %conv19.i.i.i152.i = or disjoint i16 %105, %conv6.i.i.i146.i br label %_ZN9Imath_3_24halfaSEf.exit153.i if.end20.i.i.i132.i: ; preds = %if.then.i.i.i130.i @@ -3095,51 +3092,51 @@ _ZN9Imath_3_24halfaSEf.exit153.i: ; preds = %if.then55.i.i.i127. store i16 %retval.0.i.i.i129.i, ptr %b25.i, align 2 %a.i = getelementptr inbounds nuw i8, ptr %arrayidx21, i64 6 %a27.i = getelementptr inbounds nuw i8, ptr %arrayidx23, i64 6 - %109 = load i16, ptr %a.i, align 2 - store i16 %109, ptr %a27.i, align 2 - %110 = load ptr, ptr @imath_half_to_float_table, align 8 - %111 = load float, ptr %yw, align 4 - %112 = load float, ptr %y.i, align 4 - %113 = load float, ptr %z.i, align 4 + %106 = load i16, ptr %a.i, align 2 + store i16 %106, ptr %a27.i, align 2 + %107 = load ptr, ptr @imath_half_to_float_table, align 8 + %108 = load float, ptr %yw, align 4 + %109 = load float, ptr %y.i, align 4 + %110 = load float, ptr %z.i, align 4 %idxprom.i.i160.i = zext i16 %retval.0.i.i.i.i to i64 - %arrayidx.i.i161.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %110, i64 %idxprom.i.i160.i - %114 = load float, ptr %arrayidx.i.i161.i, align 4 + %arrayidx.i.i161.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %107, i64 %idxprom.i.i160.i + %111 = load float, ptr %arrayidx.i.i161.i, align 4 %idxprom.i.i162.i = zext i16 %retval.0.i.i.i75.i to i64 - %arrayidx.i.i163.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %110, i64 %idxprom.i.i162.i - %115 = load float, ptr %arrayidx.i.i163.i, align 4 - %mul41.i = fmul float %112, %115 - %116 = tail call float @llvm.fmuladd.f32(float %114, float %111, float %mul41.i) + %arrayidx.i.i163.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %107, i64 %idxprom.i.i162.i + %112 = load float, ptr %arrayidx.i.i163.i, align 4 + %mul41.i = fmul float %109, %112 + %113 = tail call float @llvm.fmuladd.f32(float %111, float %108, float %mul41.i) %idxprom.i.i164.i = zext i16 %retval.0.i.i.i129.i to i64 - %arrayidx.i.i165.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %110, i64 %idxprom.i.i164.i - %117 = load float, ptr %arrayidx.i.i165.i, align 4 - %118 = tail call float @llvm.fmuladd.f32(float %117, float %113, float %116) - %cmp.i133 = fcmp ogt float %118, 0.000000e+00 + %arrayidx.i.i165.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %107, i64 %idxprom.i.i164.i + %114 = load float, ptr %arrayidx.i.i165.i, align 4 + %115 = tail call float @llvm.fmuladd.f32(float %114, float %110, float %113) + %cmp.i133 = fcmp ogt float %115, 0.000000e+00 br i1 %cmp.i133, label %if.then.i, label %for.inc if.then.i: ; preds = %_ZN9Imath_3_24halfaSEf.exit153.i - %119 = load i16, ptr %b.i98, align 2 - %idxprom.i.i158.i = zext i16 %119 to i64 - %arrayidx.i.i159.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %110, i64 %idxprom.i.i158.i - %120 = load float, ptr %arrayidx.i.i159.i, align 4 - %121 = load i16, ptr %g.i97, align 2 - %idxprom.i.i156.i = zext i16 %121 to i64 - %arrayidx.i.i157.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %110, i64 %idxprom.i.i156.i - %122 = load float, ptr %arrayidx.i.i157.i, align 4 - %123 = load i16, ptr %arrayidx21, align 2 - %idxprom.i.i154.i = zext i16 %123 to i64 - %arrayidx.i.i155.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %110, i64 %idxprom.i.i154.i - %124 = load float, ptr %arrayidx.i.i155.i, align 4 - %mul32.i = fmul float %112, %122 - %125 = tail call float @llvm.fmuladd.f32(float %124, float %111, float %mul32.i) - %126 = tail call float @llvm.fmuladd.f32(float %120, float %113, float %125) - %div.i134 = fdiv float %126, %118 - %mul.i.i = fmul float %114, %div.i134 - %127 = bitcast float %mul.i.i to i32 - %128 = tail call float @llvm.fabs.f32(float %mul.i.i) - %and.i.i.i168.i = bitcast float %128 to i32 - %shr.i.i.i169.i = lshr i32 %127, 16 - %129 = trunc nuw i32 %shr.i.i.i169.i to i16 - %conv.i.i.i170.i = and i16 %129, -32768 + %116 = load i16, ptr %b.i98, align 2 + %idxprom.i.i158.i = zext i16 %116 to i64 + %arrayidx.i.i159.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %107, i64 %idxprom.i.i158.i + %117 = load float, ptr %arrayidx.i.i159.i, align 4 + %118 = load i16, ptr %g.i97, align 2 + %idxprom.i.i156.i = zext i16 %118 to i64 + %arrayidx.i.i157.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %107, i64 %idxprom.i.i156.i + %119 = load float, ptr %arrayidx.i.i157.i, align 4 + %120 = load i16, ptr %arrayidx21, align 2 + %idxprom.i.i154.i = zext i16 %120 to i64 + %arrayidx.i.i155.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %107, i64 %idxprom.i.i154.i + %121 = load float, ptr %arrayidx.i.i155.i, align 4 + %mul32.i = fmul float %109, %119 + %122 = tail call float @llvm.fmuladd.f32(float %121, float %108, float %mul32.i) + %123 = tail call float @llvm.fmuladd.f32(float %117, float %110, float %122) + %div.i134 = fdiv float %123, %115 + %mul.i.i = fmul float %111, %div.i134 + %124 = bitcast float %mul.i.i to i32 + %125 = tail call float @llvm.fabs.f32(float %mul.i.i) + %and.i.i.i168.i = bitcast float %125 to i32 + %shr.i.i.i169.i = lshr i32 %124, 16 + %126 = trunc nuw i32 %shr.i.i.i169.i to i16 + %conv.i.i.i170.i = and i16 %126, -32768 %cmp.i.i.i171.i = icmp samesign ugt i32 %and.i.i.i168.i, 947912703 br i1 %cmp.i.i.i171.i, label %if.then.i.i.i194.i, label %if.end37.i.i.i172.i @@ -3156,10 +3153,10 @@ if.end.i.i.i212.i: ; preds = %if.then4.i.i.i209.i %and9.i.i.i213.i = lshr i32 %and.i.i.i168.i, 13 %shr10.i.i.i214.i = and i32 %and9.i.i.i213.i, 1023 %cmp15.i.i.i215.i = icmp eq i32 %shr10.i.i.i214.i, 0 - %130 = zext i1 %cmp15.i.i.i215.i to i16 - %131 = trunc nuw nsw i32 %shr10.i.i.i214.i to i16 - %132 = or i16 %131, %130 - %conv19.i.i.i216.i = or disjoint i16 %132, %conv6.i.i.i210.i + %127 = zext i1 %cmp15.i.i.i215.i to i16 + %128 = trunc nuw nsw i32 %shr10.i.i.i214.i to i16 + %129 = or i16 %128, %127 + %conv19.i.i.i216.i = or disjoint i16 %129, %conv6.i.i.i210.i br label %_ZN9Imath_3_24halfmLEf.exit.i if.end20.i.i.i196.i: ; preds = %if.then.i.i.i194.i @@ -3213,16 +3210,16 @@ if.then55.i.i.i191.i: ; preds = %lor.lhs.false.i.i.i _ZN9Imath_3_24halfmLEf.exit.i: ; preds = %if.then55.i.i.i191.i, %lor.lhs.false.i.i.i186.i, %if.end37.i.i.i172.i, %if.end27.i.i.i198.i, %if.then23.i.i.i207.i, %if.end.i.i.i212.i, %if.then4.i.i.i209.i %retval.0.i.i.i193.i = phi i16 [ %conv19.i.i.i216.i, %if.end.i.i.i212.i ], [ %conv26.i.i.i208.i, %if.then23.i.i.i207.i ], [ %conv36.i.i.i206.i, %if.end27.i.i.i198.i ], [ %conv6.i.i.i210.i, %if.then4.i.i.i209.i ], [ %conv.i.i.i170.i, %if.end37.i.i.i172.i ], [ %inc.i.i.i192.i, %if.then55.i.i.i191.i ], [ %conv49.i.i.i184.i, %lor.lhs.false.i.i.i186.i ] store i16 %retval.0.i.i.i193.i, ptr %arrayidx23, align 2 - %133 = load ptr, ptr @imath_half_to_float_table, align 8 - %arrayidx.i.i.i218.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %133, i64 %idxprom.i.i162.i - %134 = load float, ptr %arrayidx.i.i.i218.i, align 4 - %mul.i219.i = fmul float %div.i134, %134 - %135 = bitcast float %mul.i219.i to i32 - %136 = tail call float @llvm.fabs.f32(float %mul.i219.i) - %and.i.i.i220.i = bitcast float %136 to i32 - %shr.i.i.i221.i = lshr i32 %135, 16 - %137 = trunc nuw i32 %shr.i.i.i221.i to i16 - %conv.i.i.i222.i = and i16 %137, -32768 + %130 = load ptr, ptr @imath_half_to_float_table, align 8 + %arrayidx.i.i.i218.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %130, i64 %idxprom.i.i162.i + %131 = load float, ptr %arrayidx.i.i.i218.i, align 4 + %mul.i219.i = fmul float %div.i134, %131 + %132 = bitcast float %mul.i219.i to i32 + %133 = tail call float @llvm.fabs.f32(float %mul.i219.i) + %and.i.i.i220.i = bitcast float %133 to i32 + %shr.i.i.i221.i = lshr i32 %132, 16 + %134 = trunc nuw i32 %shr.i.i.i221.i to i16 + %conv.i.i.i222.i = and i16 %134, -32768 %cmp.i.i.i223.i = icmp samesign ugt i32 %and.i.i.i220.i, 947912703 br i1 %cmp.i.i.i223.i, label %if.then.i.i.i246.i, label %if.end37.i.i.i224.i @@ -3239,10 +3236,10 @@ if.end.i.i.i264.i: ; preds = %if.then4.i.i.i261.i %and9.i.i.i265.i = lshr i32 %and.i.i.i220.i, 13 %shr10.i.i.i266.i = and i32 %and9.i.i.i265.i, 1023 %cmp15.i.i.i267.i = icmp eq i32 %shr10.i.i.i266.i, 0 - %138 = zext i1 %cmp15.i.i.i267.i to i16 - %139 = trunc nuw nsw i32 %shr10.i.i.i266.i to i16 - %140 = or i16 %139, %138 - %conv19.i.i.i268.i = or disjoint i16 %140, %conv6.i.i.i262.i + %135 = zext i1 %cmp15.i.i.i267.i to i16 + %136 = trunc nuw nsw i32 %shr10.i.i.i266.i to i16 + %137 = or i16 %136, %135 + %conv19.i.i.i268.i = or disjoint i16 %137, %conv6.i.i.i262.i br label %_ZN9Imath_3_24halfmLEf.exit269.i if.end20.i.i.i248.i: ; preds = %if.then.i.i.i246.i @@ -3296,16 +3293,16 @@ if.then55.i.i.i243.i: ; preds = %lor.lhs.false.i.i.i _ZN9Imath_3_24halfmLEf.exit269.i: ; preds = %if.then55.i.i.i243.i, %lor.lhs.false.i.i.i238.i, %if.end37.i.i.i224.i, %if.end27.i.i.i250.i, %if.then23.i.i.i259.i, %if.end.i.i.i264.i, %if.then4.i.i.i261.i %retval.0.i.i.i245.i = phi i16 [ %conv19.i.i.i268.i, %if.end.i.i.i264.i ], [ %conv26.i.i.i260.i, %if.then23.i.i.i259.i ], [ %conv36.i.i.i258.i, %if.end27.i.i.i250.i ], [ %conv6.i.i.i262.i, %if.then4.i.i.i261.i ], [ %conv.i.i.i222.i, %if.end37.i.i.i224.i ], [ %inc.i.i.i244.i, %if.then55.i.i.i243.i ], [ %conv49.i.i.i236.i, %lor.lhs.false.i.i.i238.i ] store i16 %retval.0.i.i.i245.i, ptr %g16.i, align 2 - %141 = load ptr, ptr @imath_half_to_float_table, align 8 - %arrayidx.i.i.i271.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %141, i64 %idxprom.i.i164.i - %142 = load float, ptr %arrayidx.i.i.i271.i, align 4 - %mul.i272.i = fmul float %div.i134, %142 - %143 = bitcast float %mul.i272.i to i32 - %144 = tail call float @llvm.fabs.f32(float %mul.i272.i) - %and.i.i.i273.i = bitcast float %144 to i32 - %shr.i.i.i274.i = lshr i32 %143, 16 - %145 = trunc nuw i32 %shr.i.i.i274.i to i16 - %conv.i.i.i275.i = and i16 %145, -32768 + %138 = load ptr, ptr @imath_half_to_float_table, align 8 + %arrayidx.i.i.i271.i = getelementptr inbounds nuw %union.imath_half_uif, ptr %138, i64 %idxprom.i.i164.i + %139 = load float, ptr %arrayidx.i.i.i271.i, align 4 + %mul.i272.i = fmul float %div.i134, %139 + %140 = bitcast float %mul.i272.i to i32 + %141 = tail call float @llvm.fabs.f32(float %mul.i272.i) + %and.i.i.i273.i = bitcast float %141 to i32 + %shr.i.i.i274.i = lshr i32 %140, 16 + %142 = trunc nuw i32 %shr.i.i.i274.i to i16 + %conv.i.i.i275.i = and i16 %142, -32768 %cmp.i.i.i276.i = icmp samesign ugt i32 %and.i.i.i273.i, 947912703 br i1 %cmp.i.i.i276.i, label %if.then.i.i.i299.i, label %if.end37.i.i.i277.i @@ -3322,10 +3319,10 @@ if.end.i.i.i317.i: ; preds = %if.then4.i.i.i314.i %and9.i.i.i318.i = lshr i32 %and.i.i.i273.i, 13 %shr10.i.i.i319.i = and i32 %and9.i.i.i318.i, 1023 %cmp15.i.i.i320.i = icmp eq i32 %shr10.i.i.i319.i, 0 - %146 = zext i1 %cmp15.i.i.i320.i to i16 - %147 = trunc nuw nsw i32 %shr10.i.i.i319.i to i16 - %148 = or i16 %147, %146 - %conv19.i.i.i321.i = or disjoint i16 %148, %conv6.i.i.i315.i + %143 = zext i1 %cmp15.i.i.i320.i to i16 + %144 = trunc nuw nsw i32 %shr10.i.i.i319.i to i16 + %145 = or i16 %144, %143 + %conv19.i.i.i321.i = or disjoint i16 %145, %conv6.i.i.i315.i br label %_ZN9Imath_3_24halfmLEf.exit322.i if.end20.i.i.i301.i: ; preds = %if.then.i.i.i299.i @@ -3382,8 +3379,8 @@ _ZN9Imath_3_24halfmLEf.exit322.i: ; preds = %if.then55.i.i.i296. br label %for.inc if.end35: ; preds = %if.then26, %if.end - %149 = load i64, ptr %arrayidx21, align 2 - store i64 %149, ptr %arrayidx23, align 2 + %146 = load i64, ptr %arrayidx21, align 2 + store i64 %146, ptr %arrayidx23, align 2 br label %for.inc for.inc: ; preds = %_ZN9Imath_3_24halfmLEf.exit322.i, %_ZN9Imath_3_24halfaSEf.exit153.i, %if.end35 diff --git a/bench/openusd/optimized/coneMeshGenerator.cpp.ll b/bench/openusd/optimized/coneMeshGenerator.cpp.ll index 66d8d10ce6b..63d7afd2a5c 100644 --- a/bench/openusd/optimized/coneMeshGenerator.cpp.ll +++ b/bench/openusd/optimized/coneMeshGenerator.cpp.ll @@ -41,233 +41,231 @@ define weak_odr void @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilConeMeshGen %15 = fcmp ogt float %13, 0x401921FB60000000 %..i = select i1 %15, float 0x401921FB60000000, float %13 %.0.i = select i1 %14, float 0xC01921FB60000000, float %..i - %16 = tail call float @llvm.fabs.f32(float %13) + %16 = tail call noundef float @llvm.fabs.f32(float %.0.i) %17 = fpext float %16 to double %18 = fadd double %17, 0xC01921FB60000000 %19 = tail call double @llvm.fabs.f64(double %18) %20 = fcmp olt double %19, 0x3EB0C6F7A0B5ED8D - %21 = or i1 %15, %20 - %22 = or i1 %14, %21 - %23 = tail call noundef i64 @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase23_ComputeNumRadialPointsEmb(i64 noundef %0, i1 noundef zeroext %22) - %24 = icmp ugt i64 %23, 1152921504606846975 - br i1 %24, label %.noexc, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i + %21 = tail call noundef i64 @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase23_ComputeNumRadialPointsEmb(i64 noundef %0, i1 noundef zeroext %20) + %22 = icmp ugt i64 %21, 1152921504606846975 + br i1 %22, label %.noexc, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i .noexc: ; preds = %10 tail call void @_ZSt20__throw_length_errorPKc(ptr noundef nonnull @.str) #9 unreachable _ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i: ; preds = %10 - %.not.i.i.i.i = icmp eq i64 %23, 0 + %.not.i.i.i.i = icmp eq i64 %21, 0 br i1 %.not.i.i.i.i, label %._crit_edge, label %.noexc45 .noexc45: ; preds = %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i - %25 = shl nuw nsw i64 %23, 3 - %26 = tail call noalias noundef nonnull ptr @_Znwm(i64 noundef %25) #10 - %27 = getelementptr %"struct.std::array", ptr %26, i64 %23 - store i64 0, ptr %26, align 4 - %28 = icmp eq i64 %23, 1 - br i1 %28, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i.preheader + %23 = shl nuw nsw i64 %21, 3 + %24 = tail call noalias noundef nonnull ptr @_Znwm(i64 noundef %23) #10 + %25 = getelementptr %"struct.std::array", ptr %24, i64 %21 + store i64 0, ptr %24, align 4 + %26 = icmp eq i64 %21, 1 + br i1 %26, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i.preheader .lr.ph.i.i.i.i.i.i.i.i.i.preheader: ; preds = %.noexc45 - %29 = getelementptr inbounds nuw i8, ptr %26, i64 8 + %27 = getelementptr inbounds nuw i8, ptr %24, i64 8 br label %.lr.ph.i.i.i.i.i.i.i.i.i .lr.ph.i.i.i.i.i.i.i.i.i: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.preheader, %.lr.ph.i.i.i.i.i.i.i.i.i - %.06.i.i.i.i.i.i.i.i.i = phi ptr [ %31, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %29, %.lr.ph.i.i.i.i.i.i.i.i.i.preheader ] - %30 = load i64, ptr %26, align 4 - store i64 %30, ptr %.06.i.i.i.i.i.i.i.i.i, align 4 - %31 = getelementptr inbounds nuw i8, ptr %.06.i.i.i.i.i.i.i.i.i, i64 8 - %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %31, %27 + %.06.i.i.i.i.i.i.i.i.i = phi ptr [ %29, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %27, %.lr.ph.i.i.i.i.i.i.i.i.i.preheader ] + %28 = load i64, ptr %24, align 4 + store i64 %28, ptr %.06.i.i.i.i.i.i.i.i.i, align 4 + %29 = getelementptr inbounds nuw i8, ptr %.06.i.i.i.i.i.i.i.i.i, i64 8 + %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %29, %25 br i1 %.not.i.i.i.i.i.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i, !llvm.loop !4 .lr.ph: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i, %.noexc45 - %32 = uitofp i64 %0 to float - br label %33 - -33: ; preds = %.lr.ph, %33 - %.04172 = phi i64 [ 0, %.lr.ph ], [ %43, %33 ] - %34 = uitofp i64 %.04172 to float - %35 = fdiv float %34, %32 - %36 = fmul float %.0.i, %35 - %37 = tail call noundef float @cosf(float noundef %36) #11 - %38 = fmul float %1, %37 - %39 = getelementptr inbounds %"struct.std::array", ptr %26, i64 %.04172 - store float %38, ptr %39, align 4 - %40 = tail call noundef float @sinf(float noundef %36) #11 - %41 = fmul float %1, %40 - %42 = getelementptr inbounds nuw i8, ptr %39, i64 4 - store float %41, ptr %42, align 4 - %43 = add nuw i64 %.04172, 1 - %exitcond.not = icmp eq i64 %43, %23 - br i1 %exitcond.not, label %._crit_edge.loopexit, label %33, !llvm.loop !6 - -.loopexit: ; preds = %98 + %30 = uitofp i64 %0 to float + br label %31 + +31: ; preds = %.lr.ph, %31 + %.04172 = phi i64 [ 0, %.lr.ph ], [ %41, %31 ] + %32 = uitofp i64 %.04172 to float + %33 = fdiv float %32, %30 + %34 = fmul float %.0.i, %33 + %35 = tail call noundef float @cosf(float noundef %34) #11 + %36 = fmul float %1, %35 + %37 = getelementptr inbounds %"struct.std::array", ptr %24, i64 %.04172 + store float %36, ptr %37, align 4 + %38 = tail call noundef float @sinf(float noundef %34) #11 + %39 = fmul float %1, %38 + %40 = getelementptr inbounds nuw i8, ptr %37, i64 4 + store float %39, ptr %40, align 4 + %41 = add nuw i64 %.04172, 1 + %exitcond.not = icmp eq i64 %41, %21 + br i1 %exitcond.not, label %._crit_edge.loopexit, label %31, !llvm.loop !6 + +.loopexit: ; preds = %96 %lpad.loopexit = landingpad { ptr, i32 } cleanup - br label %44 + br label %42 -.loopexit.split-lp: ; preds = %63 +.loopexit.split-lp: ; preds = %61 %lpad.loopexit.split-lp = landingpad { ptr, i32 } cleanup - br label %44 + br label %42 -44: ; preds = %.loopexit.split-lp, %.loopexit +42: ; preds = %.loopexit.split-lp, %.loopexit %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] %.not.i.i.i = icmp eq ptr %.sroa.0.087, null - br i1 %.not.i.i.i, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit, label %45 + br i1 %.not.i.i.i, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit, label %43 -45: ; preds = %.thread.split.us, %44 - %46 = phi { ptr, i32 } [ %85, %.thread.split.us ], [ %lpad.phi, %44 ] - %47 = ptrtoint ptr %.sroa.0.087 to i64 - %48 = sub i64 %.sroa.10.088, %47 - call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.087, i64 noundef %48) #12 +43: ; preds = %.thread.split.us, %42 + %44 = phi { ptr, i32 } [ %83, %.thread.split.us ], [ %lpad.phi, %42 ] + %45 = ptrtoint ptr %.sroa.0.087 to i64 + %46 = sub i64 %.sroa.10.088, %45 + call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.087, i64 noundef %46) #12 br label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit -._crit_edge.loopexit: ; preds = %33 - %49 = ptrtoint ptr %27 to i64 +._crit_edge.loopexit: ; preds = %31 + %47 = ptrtoint ptr %25 to i64 br label %._crit_edge ._crit_edge: ; preds = %._crit_edge.loopexit, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i - %.sroa.10.088 = phi i64 [ 0, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %49, %._crit_edge.loopexit ] - %.sroa.0.087 = phi ptr [ null, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %26, %._crit_edge.loopexit ] - %50 = fmul float %2, 5.000000e-01 - %51 = fneg float %50 + %.sroa.10.088 = phi i64 [ 0, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %47, %._crit_edge.loopexit ] + %.sroa.0.087 = phi ptr [ null, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %24, %._crit_edge.loopexit ] + %48 = fmul float %2, 5.000000e-01 + %49 = fneg float %48 store float 0.000000e+00, ptr %6, align 4 - %52 = getelementptr inbounds nuw i8, ptr %6, i64 4 - store float 0.000000e+00, ptr %52, align 4 - %53 = getelementptr inbounds nuw i8, ptr %6, i64 8 - store float %51, ptr %53, align 4 + %50 = getelementptr inbounds nuw i8, ptr %6, i64 4 + store float 0.000000e+00, ptr %50, align 4 + %51 = getelementptr inbounds nuw i8, ptr %6, i64 8 + store float %49, ptr %51, align 4 %.unpack.i = load i64, ptr %4, align 8 %.elt2.i = getelementptr inbounds nuw i8, ptr %4, i64 8 %.unpack3.i = load i64, ptr %.elt2.i, align 8 - %54 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i - %55 = and i64 %.unpack.i, 1 - %.not.i = icmp eq i64 %55, 0 - br i1 %.not.i, label %61, label %56 - -56: ; preds = %._crit_edge - %57 = load ptr, ptr %54, align 8 - %58 = getelementptr i8, ptr %57, i64 %.unpack.i - %59 = getelementptr i8, ptr %58, i64 -1 - %60 = load ptr, ptr %59, align 8, !nosanitize !7 - br label %63 - -61: ; preds = %._crit_edge - %62 = inttoptr i64 %.unpack.i to ptr - br label %63 - -63: ; preds = %61, %56 - %64 = phi ptr [ %60, %56 ], [ %62, %61 ] - invoke void %64(ptr noundef nonnull align 8 dereferenceable(32) %54, ptr noundef nonnull align 4 dereferenceable(12) %6) + %52 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i + %53 = and i64 %.unpack.i, 1 + %.not.i = icmp eq i64 %53, 0 + br i1 %.not.i, label %59, label %54 + +54: ; preds = %._crit_edge + %55 = load ptr, ptr %52, align 8 + %56 = getelementptr i8, ptr %55, i64 %.unpack.i + %57 = getelementptr i8, ptr %56, i64 -1 + %58 = load ptr, ptr %57, align 8, !nosanitize !7 + br label %61 + +59: ; preds = %._crit_edge + %60 = inttoptr i64 %.unpack.i to ptr + br label %61 + +61: ; preds = %59, %54 + %62 = phi ptr [ %58, %54 ], [ %60, %59 ] + invoke void %62(ptr noundef nonnull align 8 dereferenceable(32) %52, ptr noundef nonnull align 4 dereferenceable(12) %6) to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader unwind label %.loopexit.split-lp -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader: ; preds = %63 - %65 = getelementptr inbounds nuw i8, ptr %7, i64 4 - %66 = getelementptr inbounds nuw i8, ptr %7, i64 8 +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader: ; preds = %61 + %63 = getelementptr inbounds nuw i8, ptr %7, i64 4 + %64 = getelementptr inbounds nuw i8, ptr %7, i64 8 br i1 %.not.i.i.i.i, label %._crit_edge79, label %.preheader71.us .preheader71.us: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader, %._crit_edge75.us - %67 = phi i1 [ false, %._crit_edge75.us ], [ true, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader ] - br label %68 - -68: ; preds = %.preheader71.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit52.us - %.03773.us = phi i64 [ 0, %.preheader71.us ], [ %84, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit52.us ] - %69 = getelementptr inbounds %"struct.std::array", ptr %.sroa.0.087, i64 %.03773.us + %65 = phi i1 [ false, %._crit_edge75.us ], [ true, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader ] + br label %66 + +66: ; preds = %.preheader71.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit52.us + %.03773.us = phi i64 [ 0, %.preheader71.us ], [ %82, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit52.us ] + %67 = getelementptr inbounds %"struct.std::array", ptr %.sroa.0.087, i64 %.03773.us + %68 = load float, ptr %67, align 4 + %69 = getelementptr inbounds nuw i8, ptr %67, i64 4 %70 = load float, ptr %69, align 4 - %71 = getelementptr inbounds nuw i8, ptr %69, i64 4 - %72 = load float, ptr %71, align 4 - store float %70, ptr %7, align 4 - store float %72, ptr %65, align 4 - store float %51, ptr %66, align 4 + store float %68, ptr %7, align 4 + store float %70, ptr %63, align 4 + store float %49, ptr %64, align 4 %.unpack.i47.us = load i64, ptr %4, align 8 %.unpack3.i49.us = load i64, ptr %.elt2.i, align 8 - %73 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i49.us - %74 = and i64 %.unpack.i47.us, 1 - %.not.i50.us = icmp eq i64 %74, 0 - br i1 %.not.i50.us, label %80, label %75 - -75: ; preds = %68 - %76 = load ptr, ptr %73, align 8 - %77 = getelementptr i8, ptr %76, i64 %.unpack.i47.us - %78 = getelementptr i8, ptr %77, i64 -1 - %79 = load ptr, ptr %78, align 8, !nosanitize !7 - br label %82 - -80: ; preds = %68 - %81 = inttoptr i64 %.unpack.i47.us to ptr - br label %82 - -82: ; preds = %80, %75 - %83 = phi ptr [ %79, %75 ], [ %81, %80 ] - invoke void %83(ptr noundef nonnull align 8 dereferenceable(32) %73, ptr noundef nonnull align 4 dereferenceable(12) %7) + %71 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i49.us + %72 = and i64 %.unpack.i47.us, 1 + %.not.i50.us = icmp eq i64 %72, 0 + br i1 %.not.i50.us, label %78, label %73 + +73: ; preds = %66 + %74 = load ptr, ptr %71, align 8 + %75 = getelementptr i8, ptr %74, i64 %.unpack.i47.us + %76 = getelementptr i8, ptr %75, i64 -1 + %77 = load ptr, ptr %76, align 8, !nosanitize !7 + br label %80 + +78: ; preds = %66 + %79 = inttoptr i64 %.unpack.i47.us to ptr + br label %80 + +80: ; preds = %78, %73 + %81 = phi ptr [ %77, %73 ], [ %79, %78 ] + invoke void %81(ptr noundef nonnull align 8 dereferenceable(32) %71, ptr noundef nonnull align 4 dereferenceable(12) %7) to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit52.us unwind label %.thread.split.us -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit52.us: ; preds = %82 - %84 = add nuw i64 %.03773.us, 1 - %exitcond83.not = icmp eq i64 %84, %23 - br i1 %exitcond83.not, label %._crit_edge75.us, label %68, !llvm.loop !8 +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit52.us: ; preds = %80 + %82 = add nuw i64 %.03773.us, 1 + %exitcond83.not = icmp eq i64 %82, %21 + br i1 %exitcond83.not, label %._crit_edge75.us, label %66, !llvm.loop !8 ._crit_edge75.us: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit52.us - br i1 %67, label %.preheader71.us, label %.lr.ph78, !llvm.loop !9 + br i1 %65, label %.preheader71.us, label %.lr.ph78, !llvm.loop !9 -.thread.split.us: ; preds = %82 - %85 = landingpad { ptr, i32 } +.thread.split.us: ; preds = %80 + %83 = landingpad { ptr, i32 } cleanup - br label %45 + br label %43 .lr.ph78: ; preds = %._crit_edge75.us - %86 = getelementptr inbounds nuw i8, ptr %8, i64 4 - %87 = getelementptr inbounds nuw i8, ptr %8, i64 8 - br label %88 + %84 = getelementptr inbounds nuw i8, ptr %8, i64 4 + %85 = getelementptr inbounds nuw i8, ptr %8, i64 8 + br label %86 -88: ; preds = %.lr.ph78, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit58 - %.077 = phi i64 [ 0, %.lr.ph78 ], [ %100, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit58 ] +86: ; preds = %.lr.ph78, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit58 + %.077 = phi i64 [ 0, %.lr.ph78 ], [ %98, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit58 ] store float 0.000000e+00, ptr %8, align 4 - store float 0.000000e+00, ptr %86, align 4 - store float %50, ptr %87, align 4 + store float 0.000000e+00, ptr %84, align 4 + store float %48, ptr %85, align 4 %.unpack.i53 = load i64, ptr %4, align 8 %.unpack3.i55 = load i64, ptr %.elt2.i, align 8 - %89 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i55 - %90 = and i64 %.unpack.i53, 1 - %.not.i56 = icmp eq i64 %90, 0 - br i1 %.not.i56, label %96, label %91 - -91: ; preds = %88 - %92 = load ptr, ptr %89, align 8 - %93 = getelementptr i8, ptr %92, i64 %.unpack.i53 - %94 = getelementptr i8, ptr %93, i64 -1 - %95 = load ptr, ptr %94, align 8, !nosanitize !7 - br label %98 - -96: ; preds = %88 - %97 = inttoptr i64 %.unpack.i53 to ptr - br label %98 - -98: ; preds = %96, %91 - %99 = phi ptr [ %95, %91 ], [ %97, %96 ] - invoke void %99(ptr noundef nonnull align 8 dereferenceable(32) %89, ptr noundef nonnull align 4 dereferenceable(12) %8) + %87 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i55 + %88 = and i64 %.unpack.i53, 1 + %.not.i56 = icmp eq i64 %88, 0 + br i1 %.not.i56, label %94, label %89 + +89: ; preds = %86 + %90 = load ptr, ptr %87, align 8 + %91 = getelementptr i8, ptr %90, i64 %.unpack.i53 + %92 = getelementptr i8, ptr %91, i64 -1 + %93 = load ptr, ptr %92, align 8, !nosanitize !7 + br label %96 + +94: ; preds = %86 + %95 = inttoptr i64 %.unpack.i53 to ptr + br label %96 + +96: ; preds = %94, %89 + %97 = phi ptr [ %93, %89 ], [ %95, %94 ] + invoke void %97(ptr noundef nonnull align 8 dereferenceable(32) %87, ptr noundef nonnull align 4 dereferenceable(12) %8) to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit58 unwind label %.loopexit -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit58: ; preds = %98 - %100 = add nuw i64 %.077, 1 - %exitcond84.not = icmp eq i64 %100, %23 - br i1 %exitcond84.not, label %._crit_edge79, label %88, !llvm.loop !10 +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit58: ; preds = %96 + %98 = add nuw i64 %.077, 1 + %exitcond84.not = icmp eq i64 %98, %21 + br i1 %exitcond84.not, label %._crit_edge79, label %86, !llvm.loop !10 ._crit_edge79: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit58, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader %.not.i.i.i59 = icmp eq ptr %.sroa.0.087, null - br i1 %.not.i.i.i59, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit60, label %101 + br i1 %.not.i.i.i59, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit60, label %99 -101: ; preds = %._crit_edge79 - %102 = ptrtoint ptr %.sroa.0.087 to i64 - %103 = sub i64 %.sroa.10.088, %102 - call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.087, i64 noundef %103) #12 +99: ; preds = %._crit_edge79 + %100 = ptrtoint ptr %.sroa.0.087 to i64 + %101 = sub i64 %.sroa.10.088, %100 + call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.087, i64 noundef %101) #12 br label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit60 -_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit60: ; preds = %101, %._crit_edge79, %5 +_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit60: ; preds = %99, %._crit_edge79, %5 ret void -_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit: ; preds = %45, %44 - %.pn = phi { ptr, i32 } [ %lpad.phi, %44 ], [ %46, %45 ] +_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit: ; preds = %43, %42 + %.pn = phi { ptr, i32 } [ %lpad.phi, %42 ], [ %44, %43 ] resume { ptr, i32 } %.pn } @@ -289,227 +287,225 @@ define weak_odr void @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilConeMeshGen %13 = fcmp ogt double %11, 0x401921FB54442D18 %..i = select i1 %13, double 0x401921FB54442D18, double %11 %.0.i = select i1 %12, double 0xC01921FB54442D18, double %..i - %14 = tail call double @llvm.fabs.f64(double %11) + %14 = tail call noundef double @llvm.fabs.f64(double %.0.i) %15 = fadd double %14, 0xC01921FB54442D18 %16 = tail call double @llvm.fabs.f64(double %15) %17 = fcmp olt double %16, 0x3EB0C6F7A0B5ED8D - %18 = or i1 %13, %17 - %19 = or i1 %12, %18 - %20 = tail call noundef i64 @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase23_ComputeNumRadialPointsEmb(i64 noundef %0, i1 noundef zeroext %19) - %21 = icmp ugt i64 %20, 576460752303423487 - br i1 %21, label %.noexc, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i + %18 = tail call noundef i64 @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase23_ComputeNumRadialPointsEmb(i64 noundef %0, i1 noundef zeroext %17) + %19 = icmp ugt i64 %18, 576460752303423487 + br i1 %19, label %.noexc, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i .noexc: ; preds = %10 tail call void @_ZSt20__throw_length_errorPKc(ptr noundef nonnull @.str) #9 unreachable _ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i: ; preds = %10 - %.not.i.i.i.i = icmp eq i64 %20, 0 + %.not.i.i.i.i = icmp eq i64 %18, 0 br i1 %.not.i.i.i.i, label %._crit_edge, label %.noexc45 .noexc45: ; preds = %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i - %22 = shl nuw nsw i64 %20, 4 - %23 = tail call noalias noundef nonnull ptr @_Znwm(i64 noundef %22) #10 - %24 = getelementptr %"struct.std::array.5", ptr %23, i64 %20 - tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %23, i8 0, i64 16, i1 false) - %25 = icmp eq i64 %20, 1 - br i1 %25, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i.preheader + %20 = shl nuw nsw i64 %18, 4 + %21 = tail call noalias noundef nonnull ptr @_Znwm(i64 noundef %20) #10 + %22 = getelementptr %"struct.std::array.5", ptr %21, i64 %18 + tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %21, i8 0, i64 16, i1 false) + %23 = icmp eq i64 %18, 1 + br i1 %23, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i.preheader .lr.ph.i.i.i.i.i.i.i.i.i.preheader: ; preds = %.noexc45 - %26 = getelementptr inbounds nuw i8, ptr %23, i64 16 + %24 = getelementptr inbounds nuw i8, ptr %21, i64 16 br label %.lr.ph.i.i.i.i.i.i.i.i.i .lr.ph.i.i.i.i.i.i.i.i.i: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.preheader, %.lr.ph.i.i.i.i.i.i.i.i.i - %.06.i.i.i.i.i.i.i.i.i = phi ptr [ %27, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %26, %.lr.ph.i.i.i.i.i.i.i.i.i.preheader ] - tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %.06.i.i.i.i.i.i.i.i.i, ptr noundef nonnull align 8 dereferenceable(16) %23, i64 16, i1 false) - %27 = getelementptr inbounds nuw i8, ptr %.06.i.i.i.i.i.i.i.i.i, i64 16 - %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %27, %24 + %.06.i.i.i.i.i.i.i.i.i = phi ptr [ %25, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %24, %.lr.ph.i.i.i.i.i.i.i.i.i.preheader ] + tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %.06.i.i.i.i.i.i.i.i.i, ptr noundef nonnull align 8 dereferenceable(16) %21, i64 16, i1 false) + %25 = getelementptr inbounds nuw i8, ptr %.06.i.i.i.i.i.i.i.i.i, i64 16 + %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %25, %22 br i1 %.not.i.i.i.i.i.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i, !llvm.loop !11 .lr.ph: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i, %.noexc45 - %28 = uitofp i64 %0 to double - br label %29 - -29: ; preds = %.lr.ph, %29 - %.04172 = phi i64 [ 0, %.lr.ph ], [ %39, %29 ] - %30 = uitofp i64 %.04172 to double - %31 = fdiv double %30, %28 - %32 = fmul double %.0.i, %31 - %33 = tail call double @cos(double noundef %32) #11 - %34 = fmul double %1, %33 - %35 = getelementptr inbounds %"struct.std::array.5", ptr %23, i64 %.04172 - store double %34, ptr %35, align 8 - %36 = tail call double @sin(double noundef %32) #11 - %37 = fmul double %1, %36 - %38 = getelementptr inbounds nuw i8, ptr %35, i64 8 - store double %37, ptr %38, align 8 - %39 = add nuw i64 %.04172, 1 - %exitcond.not = icmp eq i64 %39, %20 - br i1 %exitcond.not, label %._crit_edge.loopexit, label %29, !llvm.loop !12 - -._crit_edge.loopexit: ; preds = %29 - %40 = ptrtoint ptr %24 to i64 + %26 = uitofp i64 %0 to double + br label %27 + +27: ; preds = %.lr.ph, %27 + %.04172 = phi i64 [ 0, %.lr.ph ], [ %37, %27 ] + %28 = uitofp i64 %.04172 to double + %29 = fdiv double %28, %26 + %30 = fmul double %.0.i, %29 + %31 = tail call double @cos(double noundef %30) #11 + %32 = fmul double %1, %31 + %33 = getelementptr inbounds %"struct.std::array.5", ptr %21, i64 %.04172 + store double %32, ptr %33, align 8 + %34 = tail call double @sin(double noundef %30) #11 + %35 = fmul double %1, %34 + %36 = getelementptr inbounds nuw i8, ptr %33, i64 8 + store double %35, ptr %36, align 8 + %37 = add nuw i64 %.04172, 1 + %exitcond.not = icmp eq i64 %37, %18 + br i1 %exitcond.not, label %._crit_edge.loopexit, label %27, !llvm.loop !12 + +._crit_edge.loopexit: ; preds = %27 + %38 = ptrtoint ptr %22 to i64 br label %._crit_edge ._crit_edge: ; preds = %._crit_edge.loopexit, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i - %.sroa.10.088 = phi i64 [ 0, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %40, %._crit_edge.loopexit ] - %.sroa.0.087 = phi ptr [ null, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %23, %._crit_edge.loopexit ] - %41 = fmul double %2, 5.000000e-01 - %42 = fneg double %41 - %43 = getelementptr inbounds nuw i8, ptr %6, i64 16 + %.sroa.10.088 = phi i64 [ 0, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %38, %._crit_edge.loopexit ] + %.sroa.0.087 = phi ptr [ null, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %21, %._crit_edge.loopexit ] + %39 = fmul double %2, 5.000000e-01 + %40 = fneg double %39 + %41 = getelementptr inbounds nuw i8, ptr %6, i64 16 call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %6, i8 0, i64 16, i1 false) - store double %42, ptr %43, align 8 + store double %40, ptr %41, align 8 %.unpack.i = load i64, ptr %4, align 8 %.elt2.i = getelementptr inbounds nuw i8, ptr %4, i64 8 %.unpack3.i = load i64, ptr %.elt2.i, align 8 - %44 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i - %45 = and i64 %.unpack.i, 1 - %.not.i = icmp eq i64 %45, 0 - br i1 %.not.i, label %51, label %46 - -46: ; preds = %._crit_edge - %47 = load ptr, ptr %44, align 8 - %48 = getelementptr i8, ptr %47, i64 %.unpack.i - %49 = getelementptr i8, ptr %48, i64 -1 - %50 = load ptr, ptr %49, align 8, !nosanitize !7 - br label %53 - -51: ; preds = %._crit_edge - %52 = inttoptr i64 %.unpack.i to ptr - br label %53 - -53: ; preds = %51, %46 - %54 = phi ptr [ %50, %46 ], [ %52, %51 ] - invoke void %54(ptr noundef nonnull align 8 dereferenceable(32) %44, ptr noundef nonnull align 8 dereferenceable(24) %6) + %42 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i + %43 = and i64 %.unpack.i, 1 + %.not.i = icmp eq i64 %43, 0 + br i1 %.not.i, label %49, label %44 + +44: ; preds = %._crit_edge + %45 = load ptr, ptr %42, align 8 + %46 = getelementptr i8, ptr %45, i64 %.unpack.i + %47 = getelementptr i8, ptr %46, i64 -1 + %48 = load ptr, ptr %47, align 8, !nosanitize !7 + br label %51 + +49: ; preds = %._crit_edge + %50 = inttoptr i64 %.unpack.i to ptr + br label %51 + +51: ; preds = %49, %44 + %52 = phi ptr [ %48, %44 ], [ %50, %49 ] + invoke void %52(ptr noundef nonnull align 8 dereferenceable(32) %42, ptr noundef nonnull align 8 dereferenceable(24) %6) to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader unwind label %.loopexit.split-lp -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader: ; preds = %53 - %55 = getelementptr inbounds nuw i8, ptr %7, i64 8 - %56 = getelementptr inbounds nuw i8, ptr %7, i64 16 +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader: ; preds = %51 + %53 = getelementptr inbounds nuw i8, ptr %7, i64 8 + %54 = getelementptr inbounds nuw i8, ptr %7, i64 16 br i1 %.not.i.i.i.i, label %._crit_edge79, label %.preheader71.us .preheader71.us: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader, %._crit_edge75.us - %57 = phi i1 [ false, %._crit_edge75.us ], [ true, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader ] - br label %58 - -58: ; preds = %.preheader71.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit52.us - %.03773.us = phi i64 [ 0, %.preheader71.us ], [ %74, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit52.us ] - %59 = getelementptr inbounds %"struct.std::array.5", ptr %.sroa.0.087, i64 %.03773.us + %55 = phi i1 [ false, %._crit_edge75.us ], [ true, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader ] + br label %56 + +56: ; preds = %.preheader71.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit52.us + %.03773.us = phi i64 [ 0, %.preheader71.us ], [ %72, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit52.us ] + %57 = getelementptr inbounds %"struct.std::array.5", ptr %.sroa.0.087, i64 %.03773.us + %58 = load double, ptr %57, align 8 + %59 = getelementptr inbounds nuw i8, ptr %57, i64 8 %60 = load double, ptr %59, align 8 - %61 = getelementptr inbounds nuw i8, ptr %59, i64 8 - %62 = load double, ptr %61, align 8 - store double %60, ptr %7, align 8 - store double %62, ptr %55, align 8 - store double %42, ptr %56, align 8 + store double %58, ptr %7, align 8 + store double %60, ptr %53, align 8 + store double %40, ptr %54, align 8 %.unpack.i47.us = load i64, ptr %4, align 8 %.unpack3.i49.us = load i64, ptr %.elt2.i, align 8 - %63 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i49.us - %64 = and i64 %.unpack.i47.us, 1 - %.not.i50.us = icmp eq i64 %64, 0 - br i1 %.not.i50.us, label %70, label %65 - -65: ; preds = %58 - %66 = load ptr, ptr %63, align 8 - %67 = getelementptr i8, ptr %66, i64 %.unpack.i47.us - %68 = getelementptr i8, ptr %67, i64 -1 - %69 = load ptr, ptr %68, align 8, !nosanitize !7 - br label %72 - -70: ; preds = %58 - %71 = inttoptr i64 %.unpack.i47.us to ptr - br label %72 - -72: ; preds = %70, %65 - %73 = phi ptr [ %69, %65 ], [ %71, %70 ] - invoke void %73(ptr noundef nonnull align 8 dereferenceable(32) %63, ptr noundef nonnull align 8 dereferenceable(24) %7) + %61 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i49.us + %62 = and i64 %.unpack.i47.us, 1 + %.not.i50.us = icmp eq i64 %62, 0 + br i1 %.not.i50.us, label %68, label %63 + +63: ; preds = %56 + %64 = load ptr, ptr %61, align 8 + %65 = getelementptr i8, ptr %64, i64 %.unpack.i47.us + %66 = getelementptr i8, ptr %65, i64 -1 + %67 = load ptr, ptr %66, align 8, !nosanitize !7 + br label %70 + +68: ; preds = %56 + %69 = inttoptr i64 %.unpack.i47.us to ptr + br label %70 + +70: ; preds = %68, %63 + %71 = phi ptr [ %67, %63 ], [ %69, %68 ] + invoke void %71(ptr noundef nonnull align 8 dereferenceable(32) %61, ptr noundef nonnull align 8 dereferenceable(24) %7) to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit52.us unwind label %.thread.split.us -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit52.us: ; preds = %72 - %74 = add nuw i64 %.03773.us, 1 - %exitcond83.not = icmp eq i64 %74, %20 - br i1 %exitcond83.not, label %._crit_edge75.us, label %58, !llvm.loop !13 +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit52.us: ; preds = %70 + %72 = add nuw i64 %.03773.us, 1 + %exitcond83.not = icmp eq i64 %72, %18 + br i1 %exitcond83.not, label %._crit_edge75.us, label %56, !llvm.loop !13 ._crit_edge75.us: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit52.us - br i1 %57, label %.preheader71.us, label %.lr.ph78, !llvm.loop !14 + br i1 %55, label %.preheader71.us, label %.lr.ph78, !llvm.loop !14 -.thread.split.us: ; preds = %72 - %75 = landingpad { ptr, i32 } +.thread.split.us: ; preds = %70 + %73 = landingpad { ptr, i32 } cleanup - br label %78 + br label %76 .lr.ph78: ; preds = %._crit_edge75.us - %76 = getelementptr inbounds nuw i8, ptr %8, i64 16 - br label %82 + %74 = getelementptr inbounds nuw i8, ptr %8, i64 16 + br label %80 -.loopexit: ; preds = %92 +.loopexit: ; preds = %90 %lpad.loopexit = landingpad { ptr, i32 } cleanup - br label %77 + br label %75 -.loopexit.split-lp: ; preds = %53 +.loopexit.split-lp: ; preds = %51 %lpad.loopexit.split-lp = landingpad { ptr, i32 } cleanup - br label %77 + br label %75 -77: ; preds = %.loopexit.split-lp, %.loopexit +75: ; preds = %.loopexit.split-lp, %.loopexit %lpad.phi = phi { ptr, i32 } [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ] %.not.i.i.i = icmp eq ptr %.sroa.0.087, null - br i1 %.not.i.i.i, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit, label %78 + br i1 %.not.i.i.i, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit, label %76 -78: ; preds = %.thread.split.us, %77 - %79 = phi { ptr, i32 } [ %75, %.thread.split.us ], [ %lpad.phi, %77 ] - %80 = ptrtoint ptr %.sroa.0.087 to i64 - %81 = sub i64 %.sroa.10.088, %80 - call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.087, i64 noundef %81) #12 +76: ; preds = %.thread.split.us, %75 + %77 = phi { ptr, i32 } [ %73, %.thread.split.us ], [ %lpad.phi, %75 ] + %78 = ptrtoint ptr %.sroa.0.087 to i64 + %79 = sub i64 %.sroa.10.088, %78 + call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.087, i64 noundef %79) #12 br label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit -82: ; preds = %.lr.ph78, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit58 - %.077 = phi i64 [ 0, %.lr.ph78 ], [ %94, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit58 ] +80: ; preds = %.lr.ph78, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit58 + %.077 = phi i64 [ 0, %.lr.ph78 ], [ %92, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit58 ] call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %8, i8 0, i64 16, i1 false) - store double %41, ptr %76, align 8 + store double %39, ptr %74, align 8 %.unpack.i53 = load i64, ptr %4, align 8 %.unpack3.i55 = load i64, ptr %.elt2.i, align 8 - %83 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i55 - %84 = and i64 %.unpack.i53, 1 - %.not.i56 = icmp eq i64 %84, 0 - br i1 %.not.i56, label %90, label %85 - -85: ; preds = %82 - %86 = load ptr, ptr %83, align 8 - %87 = getelementptr i8, ptr %86, i64 %.unpack.i53 - %88 = getelementptr i8, ptr %87, i64 -1 - %89 = load ptr, ptr %88, align 8, !nosanitize !7 - br label %92 - -90: ; preds = %82 - %91 = inttoptr i64 %.unpack.i53 to ptr - br label %92 - -92: ; preds = %90, %85 - %93 = phi ptr [ %89, %85 ], [ %91, %90 ] - invoke void %93(ptr noundef nonnull align 8 dereferenceable(32) %83, ptr noundef nonnull align 8 dereferenceable(24) %8) + %81 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i55 + %82 = and i64 %.unpack.i53, 1 + %.not.i56 = icmp eq i64 %82, 0 + br i1 %.not.i56, label %88, label %83 + +83: ; preds = %80 + %84 = load ptr, ptr %81, align 8 + %85 = getelementptr i8, ptr %84, i64 %.unpack.i53 + %86 = getelementptr i8, ptr %85, i64 -1 + %87 = load ptr, ptr %86, align 8, !nosanitize !7 + br label %90 + +88: ; preds = %80 + %89 = inttoptr i64 %.unpack.i53 to ptr + br label %90 + +90: ; preds = %88, %83 + %91 = phi ptr [ %87, %83 ], [ %89, %88 ] + invoke void %91(ptr noundef nonnull align 8 dereferenceable(32) %81, ptr noundef nonnull align 8 dereferenceable(24) %8) to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit58 unwind label %.loopexit -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit58: ; preds = %92 - %94 = add nuw i64 %.077, 1 - %exitcond84.not = icmp eq i64 %94, %20 - br i1 %exitcond84.not, label %._crit_edge79, label %82, !llvm.loop !15 +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit58: ; preds = %90 + %92 = add nuw i64 %.077, 1 + %exitcond84.not = icmp eq i64 %92, %18 + br i1 %exitcond84.not, label %._crit_edge79, label %80, !llvm.loop !15 ._crit_edge79: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit58, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader %.not.i.i.i59 = icmp eq ptr %.sroa.0.087, null - br i1 %.not.i.i.i59, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit60, label %95 + br i1 %.not.i.i.i59, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit60, label %93 -95: ; preds = %._crit_edge79 - %96 = ptrtoint ptr %.sroa.0.087 to i64 - %97 = sub i64 %.sroa.10.088, %96 - call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.087, i64 noundef %97) #12 +93: ; preds = %._crit_edge79 + %94 = ptrtoint ptr %.sroa.0.087 to i64 + %95 = sub i64 %.sroa.10.088, %94 + call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.087, i64 noundef %95) #12 br label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit60 -_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit60: ; preds = %95, %._crit_edge79, %5 +_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit60: ; preds = %93, %._crit_edge79, %5 ret void -_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit: ; preds = %78, %77 - %.pn = phi { ptr, i32 } [ %lpad.phi, %77 ], [ %79, %78 ] +_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit: ; preds = %76, %75 + %.pn = phi { ptr, i32 } [ %lpad.phi, %75 ], [ %77, %76 ] resume { ptr, i32 } %.pn } diff --git a/bench/openusd/optimized/cylinderMeshGenerator.cpp.ll b/bench/openusd/optimized/cylinderMeshGenerator.cpp.ll index 09602c8180b..710e33b03d0 100644 --- a/bench/openusd/optimized/cylinderMeshGenerator.cpp.ll +++ b/bench/openusd/optimized/cylinderMeshGenerator.cpp.ll @@ -42,271 +42,269 @@ define weak_odr void @_ZN32pxrInternal_v0_24__pxrReserved__29GeomUtilCylinderMes %17 = fcmp ogt float %15, 0x401921FB60000000 %..i = select i1 %17, float 0x401921FB60000000, float %15 %.0.i = select i1 %16, float 0xC01921FB60000000, float %..i - %18 = tail call float @llvm.fabs.f32(float %15) + %18 = tail call noundef float @llvm.fabs.f32(float %.0.i) %19 = fpext float %18 to double %20 = fadd double %19, 0xC01921FB60000000 %21 = tail call double @llvm.fabs.f64(double %20) %22 = fcmp olt double %21, 0x3EB0C6F7A0B5ED8D - %23 = or i1 %17, %22 - %24 = or i1 %16, %23 - %25 = tail call noundef i64 @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase23_ComputeNumRadialPointsEmb(i64 noundef %0, i1 noundef zeroext %24) - %26 = icmp ugt i64 %25, 1152921504606846975 - br i1 %26, label %.noexc, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i + %23 = tail call noundef i64 @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase23_ComputeNumRadialPointsEmb(i64 noundef %0, i1 noundef zeroext %22) + %24 = icmp ugt i64 %23, 1152921504606846975 + br i1 %24, label %.noexc, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i .noexc: ; preds = %12 tail call void @_ZSt20__throw_length_errorPKc(ptr noundef nonnull @.str) #9 unreachable _ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i: ; preds = %12 - %.not.i.i.i.i = icmp eq i64 %25, 0 + %.not.i.i.i.i = icmp eq i64 %23, 0 br i1 %.not.i.i.i.i, label %._crit_edge, label %.noexc54 .noexc54: ; preds = %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i - %27 = shl nuw nsw i64 %25, 3 - %28 = tail call noalias noundef nonnull ptr @_Znwm(i64 noundef %27) #10 - %29 = getelementptr %"struct.std::array", ptr %28, i64 %25 - store i64 0, ptr %28, align 4 - %30 = icmp eq i64 %25, 1 - br i1 %30, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i.preheader + %25 = shl nuw nsw i64 %23, 3 + %26 = tail call noalias noundef nonnull ptr @_Znwm(i64 noundef %25) #10 + %27 = getelementptr %"struct.std::array", ptr %26, i64 %23 + store i64 0, ptr %26, align 4 + %28 = icmp eq i64 %23, 1 + br i1 %28, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i.preheader .lr.ph.i.i.i.i.i.i.i.i.i.preheader: ; preds = %.noexc54 - %31 = getelementptr inbounds nuw i8, ptr %28, i64 8 + %29 = getelementptr inbounds nuw i8, ptr %26, i64 8 br label %.lr.ph.i.i.i.i.i.i.i.i.i .lr.ph.i.i.i.i.i.i.i.i.i: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.preheader, %.lr.ph.i.i.i.i.i.i.i.i.i - %.06.i.i.i.i.i.i.i.i.i = phi ptr [ %33, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %31, %.lr.ph.i.i.i.i.i.i.i.i.i.preheader ] - %32 = load i64, ptr %28, align 4 - store i64 %32, ptr %.06.i.i.i.i.i.i.i.i.i, align 4 - %33 = getelementptr inbounds nuw i8, ptr %.06.i.i.i.i.i.i.i.i.i, i64 8 - %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %33, %29 + %.06.i.i.i.i.i.i.i.i.i = phi ptr [ %31, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %29, %.lr.ph.i.i.i.i.i.i.i.i.i.preheader ] + %30 = load i64, ptr %26, align 4 + store i64 %30, ptr %.06.i.i.i.i.i.i.i.i.i, align 4 + %31 = getelementptr inbounds nuw i8, ptr %.06.i.i.i.i.i.i.i.i.i, i64 8 + %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %31, %27 br i1 %.not.i.i.i.i.i.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i, !llvm.loop !4 .lr.ph: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i, %.noexc54 - %34 = uitofp i64 %0 to float - br label %35 - -35: ; preds = %.lr.ph, %35 - %.05093 = phi i64 [ 0, %.lr.ph ], [ %43, %35 ] - %36 = uitofp i64 %.05093 to float - %37 = fdiv float %36, %34 - %38 = fmul float %.0.i, %37 - %39 = tail call noundef float @cosf(float noundef %38) #11 - %40 = getelementptr inbounds %"struct.std::array", ptr %28, i64 %.05093 + %32 = uitofp i64 %0 to float + br label %33 + +33: ; preds = %.lr.ph, %33 + %.05093 = phi i64 [ 0, %.lr.ph ], [ %41, %33 ] + %34 = uitofp i64 %.05093 to float + %35 = fdiv float %34, %32 + %36 = fmul float %.0.i, %35 + %37 = tail call noundef float @cosf(float noundef %36) #11 + %38 = getelementptr inbounds %"struct.std::array", ptr %26, i64 %.05093 + store float %37, ptr %38, align 4 + %39 = tail call noundef float @sinf(float noundef %36) #11 + %40 = getelementptr inbounds nuw i8, ptr %38, i64 4 store float %39, ptr %40, align 4 - %41 = tail call noundef float @sinf(float noundef %38) #11 - %42 = getelementptr inbounds nuw i8, ptr %40, i64 4 - store float %41, ptr %42, align 4 - %43 = add nuw i64 %.05093, 1 - %exitcond.not = icmp eq i64 %43, %25 - br i1 %exitcond.not, label %._crit_edge.loopexit, label %35, !llvm.loop !6 - -44: ; preds = %118, %61 + %41 = add nuw i64 %.05093, 1 + %exitcond.not = icmp eq i64 %41, %23 + br i1 %exitcond.not, label %._crit_edge.loopexit, label %33, !llvm.loop !6 + +42: ; preds = %116, %59 %lpad.thr_comm.split-lp = landingpad { ptr, i32 } cleanup %.not.i.i.i = icmp eq ptr %.sroa.0.0111, null br i1 %.not.i.i.i, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit, label %.thread -.thread: ; preds = %.thread.loopexit.split.us, %.thread.loopexit.split-lp.split.us, %44 - %lpad.phi89 = phi { ptr, i32 } [ %lpad.thr_comm.split-lp, %44 ], [ %lpad.loopexit.us, %.thread.loopexit.split.us ], [ %lpad.loopexit.split-lp.us, %.thread.loopexit.split-lp.split.us ] - %45 = ptrtoint ptr %.sroa.0.0111 to i64 - %46 = sub i64 %.sroa.12.0112, %45 - call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.0111, i64 noundef %46) #12 +.thread: ; preds = %.thread.loopexit.split.us, %.thread.loopexit.split-lp.split.us, %42 + %lpad.phi89 = phi { ptr, i32 } [ %lpad.thr_comm.split-lp, %42 ], [ %lpad.loopexit.us, %.thread.loopexit.split.us ], [ %lpad.loopexit.split-lp.us, %.thread.loopexit.split-lp.split.us ] + %43 = ptrtoint ptr %.sroa.0.0111 to i64 + %44 = sub i64 %.sroa.12.0112, %43 + call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.0111, i64 noundef %44) #12 br label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit -._crit_edge.loopexit: ; preds = %35 - %47 = ptrtoint ptr %29 to i64 +._crit_edge.loopexit: ; preds = %33 + %45 = ptrtoint ptr %27 to i64 br label %._crit_edge ._crit_edge: ; preds = %._crit_edge.loopexit, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i - %.sroa.12.0112 = phi i64 [ 0, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %47, %._crit_edge.loopexit ] - %.sroa.0.0111 = phi ptr [ null, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %28, %._crit_edge.loopexit ] - %48 = fmul float %3, 5.000000e-01 - %49 = fneg float %48 + %.sroa.12.0112 = phi i64 [ 0, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %45, %._crit_edge.loopexit ] + %.sroa.0.0111 = phi ptr [ null, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %26, %._crit_edge.loopexit ] + %46 = fmul float %3, 5.000000e-01 + %47 = fneg float %46 store float 0.000000e+00, ptr %7, align 4 - %50 = getelementptr inbounds nuw i8, ptr %7, i64 4 - store float 0.000000e+00, ptr %50, align 4 - %51 = getelementptr inbounds nuw i8, ptr %7, i64 8 - store float %49, ptr %51, align 4 + %48 = getelementptr inbounds nuw i8, ptr %7, i64 4 + store float 0.000000e+00, ptr %48, align 4 + %49 = getelementptr inbounds nuw i8, ptr %7, i64 8 + store float %47, ptr %49, align 4 %.unpack.i = load i64, ptr %5, align 8 %.elt2.i = getelementptr inbounds nuw i8, ptr %5, i64 8 %.unpack3.i = load i64, ptr %.elt2.i, align 8 - %52 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i - %53 = and i64 %.unpack.i, 1 - %.not.i = icmp eq i64 %53, 0 - br i1 %.not.i, label %59, label %54 - -54: ; preds = %._crit_edge - %55 = load ptr, ptr %52, align 8 - %56 = getelementptr i8, ptr %55, i64 %.unpack.i - %57 = getelementptr i8, ptr %56, i64 -1 - %58 = load ptr, ptr %57, align 8, !nosanitize !7 - br label %61 - -59: ; preds = %._crit_edge - %60 = inttoptr i64 %.unpack.i to ptr - br label %61 - -61: ; preds = %59, %54 - %62 = phi ptr [ %58, %54 ], [ %60, %59 ] - invoke void %62(ptr noundef nonnull align 8 dereferenceable(32) %52, ptr noundef nonnull align 4 dereferenceable(12) %7) - to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader unwind label %44 - -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader: ; preds = %61 - %63 = getelementptr inbounds nuw i8, ptr %8, i64 4 - %64 = getelementptr inbounds nuw i8, ptr %8, i64 8 + %50 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i + %51 = and i64 %.unpack.i, 1 + %.not.i = icmp eq i64 %51, 0 + br i1 %.not.i, label %57, label %52 + +52: ; preds = %._crit_edge + %53 = load ptr, ptr %50, align 8 + %54 = getelementptr i8, ptr %53, i64 %.unpack.i + %55 = getelementptr i8, ptr %54, i64 -1 + %56 = load ptr, ptr %55, align 8, !nosanitize !7 + br label %59 + +57: ; preds = %._crit_edge + %58 = inttoptr i64 %.unpack.i to ptr + br label %59 + +59: ; preds = %57, %52 + %60 = phi ptr [ %56, %52 ], [ %58, %57 ] + invoke void %60(ptr noundef nonnull align 8 dereferenceable(32) %50, ptr noundef nonnull align 4 dereferenceable(12) %7) + to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader unwind label %42 + +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader: ; preds = %59 + %61 = getelementptr inbounds nuw i8, ptr %8, i64 4 + %62 = getelementptr inbounds nuw i8, ptr %8, i64 8 br i1 %.not.i.i.i.i, label %.split.us, label %.preheader92.us .preheader92.us: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader, %._crit_edge96.us - %65 = phi i1 [ false, %._crit_edge96.us ], [ true, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader ] - br label %66 - -66: ; preds = %.preheader92.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit61.us - %.04694.us = phi i64 [ 0, %.preheader92.us ], [ %84, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit61.us ] - %67 = getelementptr inbounds %"struct.std::array", ptr %.sroa.0.0111, i64 %.04694.us - %68 = load float, ptr %67, align 4 - %69 = fmul float %1, %68 - %70 = getelementptr inbounds nuw i8, ptr %67, i64 4 - %71 = load float, ptr %70, align 4 - %72 = fmul float %1, %71 - store float %69, ptr %8, align 4 - store float %72, ptr %63, align 4 - store float %49, ptr %64, align 4 + %63 = phi i1 [ false, %._crit_edge96.us ], [ true, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader ] + br label %64 + +64: ; preds = %.preheader92.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit61.us + %.04694.us = phi i64 [ 0, %.preheader92.us ], [ %82, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit61.us ] + %65 = getelementptr inbounds %"struct.std::array", ptr %.sroa.0.0111, i64 %.04694.us + %66 = load float, ptr %65, align 4 + %67 = fmul float %1, %66 + %68 = getelementptr inbounds nuw i8, ptr %65, i64 4 + %69 = load float, ptr %68, align 4 + %70 = fmul float %1, %69 + store float %67, ptr %8, align 4 + store float %70, ptr %61, align 4 + store float %47, ptr %62, align 4 %.unpack.i56.us = load i64, ptr %5, align 8 %.unpack3.i58.us = load i64, ptr %.elt2.i, align 8 - %73 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i58.us - %74 = and i64 %.unpack.i56.us, 1 - %.not.i59.us = icmp eq i64 %74, 0 - br i1 %.not.i59.us, label %80, label %75 - -75: ; preds = %66 - %76 = load ptr, ptr %73, align 8 - %77 = getelementptr i8, ptr %76, i64 %.unpack.i56.us - %78 = getelementptr i8, ptr %77, i64 -1 - %79 = load ptr, ptr %78, align 8, !nosanitize !7 - br label %82 - -80: ; preds = %66 - %81 = inttoptr i64 %.unpack.i56.us to ptr - br label %82 - -82: ; preds = %80, %75 - %83 = phi ptr [ %79, %75 ], [ %81, %80 ] - invoke void %83(ptr noundef nonnull align 8 dereferenceable(32) %73, ptr noundef nonnull align 4 dereferenceable(12) %8) + %71 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i58.us + %72 = and i64 %.unpack.i56.us, 1 + %.not.i59.us = icmp eq i64 %72, 0 + br i1 %.not.i59.us, label %78, label %73 + +73: ; preds = %64 + %74 = load ptr, ptr %71, align 8 + %75 = getelementptr i8, ptr %74, i64 %.unpack.i56.us + %76 = getelementptr i8, ptr %75, i64 -1 + %77 = load ptr, ptr %76, align 8, !nosanitize !7 + br label %80 + +78: ; preds = %64 + %79 = inttoptr i64 %.unpack.i56.us to ptr + br label %80 + +80: ; preds = %78, %73 + %81 = phi ptr [ %77, %73 ], [ %79, %78 ] + invoke void %81(ptr noundef nonnull align 8 dereferenceable(32) %71, ptr noundef nonnull align 4 dereferenceable(12) %8) to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit61.us unwind label %.thread.loopexit.split-lp.split.us -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit61.us: ; preds = %82 - %84 = add nuw i64 %.04694.us, 1 - %exitcond107.not = icmp eq i64 %84, %25 - br i1 %exitcond107.not, label %._crit_edge96.us, label %66, !llvm.loop !8 +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit61.us: ; preds = %80 + %82 = add nuw i64 %.04694.us, 1 + %exitcond107.not = icmp eq i64 %82, %23 + br i1 %exitcond107.not, label %._crit_edge96.us, label %64, !llvm.loop !8 ._crit_edge96.us: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit61.us - br i1 %65, label %.preheader92.us, label %.preheader.us.preheader, !llvm.loop !9 + br i1 %63, label %.preheader92.us, label %.preheader.us.preheader, !llvm.loop !9 -.thread.loopexit.split-lp.split.us: ; preds = %82 +.thread.loopexit.split-lp.split.us: ; preds = %80 %lpad.loopexit.split-lp.us = landingpad { ptr, i32 } cleanup br label %.thread .preheader.us.preheader: ; preds = %._crit_edge96.us - %85 = getelementptr inbounds nuw i8, ptr %9, i64 4 - %86 = getelementptr inbounds nuw i8, ptr %9, i64 8 + %83 = getelementptr inbounds nuw i8, ptr %9, i64 4 + %84 = getelementptr inbounds nuw i8, ptr %9, i64 8 br label %.preheader.us .preheader.us: ; preds = %.preheader.us.preheader, %._crit_edge100.us - %87 = phi i1 [ false, %._crit_edge100.us ], [ true, %.preheader.us.preheader ] - br label %88 - -88: ; preds = %.preheader.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit67.us - %.098.us = phi i64 [ 0, %.preheader.us ], [ %106, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit67.us ] - %89 = getelementptr inbounds %"struct.std::array", ptr %.sroa.0.0111, i64 %.098.us - %90 = load float, ptr %89, align 4 - %91 = fmul float %2, %90 - %92 = getelementptr inbounds nuw i8, ptr %89, i64 4 - %93 = load float, ptr %92, align 4 - %94 = fmul float %2, %93 - store float %91, ptr %9, align 4 - store float %94, ptr %85, align 4 - store float %48, ptr %86, align 4 + %85 = phi i1 [ false, %._crit_edge100.us ], [ true, %.preheader.us.preheader ] + br label %86 + +86: ; preds = %.preheader.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit67.us + %.098.us = phi i64 [ 0, %.preheader.us ], [ %104, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit67.us ] + %87 = getelementptr inbounds %"struct.std::array", ptr %.sroa.0.0111, i64 %.098.us + %88 = load float, ptr %87, align 4 + %89 = fmul float %2, %88 + %90 = getelementptr inbounds nuw i8, ptr %87, i64 4 + %91 = load float, ptr %90, align 4 + %92 = fmul float %2, %91 + store float %89, ptr %9, align 4 + store float %92, ptr %83, align 4 + store float %46, ptr %84, align 4 %.unpack.i62.us = load i64, ptr %5, align 8 %.unpack3.i64.us = load i64, ptr %.elt2.i, align 8 - %95 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i64.us - %96 = and i64 %.unpack.i62.us, 1 - %.not.i65.us = icmp eq i64 %96, 0 - br i1 %.not.i65.us, label %102, label %97 - -97: ; preds = %88 - %98 = load ptr, ptr %95, align 8 - %99 = getelementptr i8, ptr %98, i64 %.unpack.i62.us - %100 = getelementptr i8, ptr %99, i64 -1 - %101 = load ptr, ptr %100, align 8, !nosanitize !7 - br label %104 - -102: ; preds = %88 - %103 = inttoptr i64 %.unpack.i62.us to ptr - br label %104 - -104: ; preds = %102, %97 - %105 = phi ptr [ %101, %97 ], [ %103, %102 ] - invoke void %105(ptr noundef nonnull align 8 dereferenceable(32) %95, ptr noundef nonnull align 4 dereferenceable(12) %9) + %93 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i64.us + %94 = and i64 %.unpack.i62.us, 1 + %.not.i65.us = icmp eq i64 %94, 0 + br i1 %.not.i65.us, label %100, label %95 + +95: ; preds = %86 + %96 = load ptr, ptr %93, align 8 + %97 = getelementptr i8, ptr %96, i64 %.unpack.i62.us + %98 = getelementptr i8, ptr %97, i64 -1 + %99 = load ptr, ptr %98, align 8, !nosanitize !7 + br label %102 + +100: ; preds = %86 + %101 = inttoptr i64 %.unpack.i62.us to ptr + br label %102 + +102: ; preds = %100, %95 + %103 = phi ptr [ %99, %95 ], [ %101, %100 ] + invoke void %103(ptr noundef nonnull align 8 dereferenceable(32) %93, ptr noundef nonnull align 4 dereferenceable(12) %9) to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit67.us unwind label %.thread.loopexit.split.us -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit67.us: ; preds = %104 - %106 = add nuw i64 %.098.us, 1 - %exitcond108.not = icmp eq i64 %106, %25 - br i1 %exitcond108.not, label %._crit_edge100.us, label %88, !llvm.loop !10 +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit67.us: ; preds = %102 + %104 = add nuw i64 %.098.us, 1 + %exitcond108.not = icmp eq i64 %104, %23 + br i1 %exitcond108.not, label %._crit_edge100.us, label %86, !llvm.loop !10 ._crit_edge100.us: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit67.us - br i1 %87, label %.preheader.us, label %.split.us, !llvm.loop !11 + br i1 %85, label %.preheader.us, label %.split.us, !llvm.loop !11 -.thread.loopexit.split.us: ; preds = %104 +.thread.loopexit.split.us: ; preds = %102 %lpad.loopexit.us = landingpad { ptr, i32 } cleanup br label %.thread .split.us: ; preds = %._crit_edge100.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader store float 0.000000e+00, ptr %10, align 4 - %107 = getelementptr inbounds nuw i8, ptr %10, i64 4 - store float 0.000000e+00, ptr %107, align 4 - %108 = getelementptr inbounds nuw i8, ptr %10, i64 8 - store float %48, ptr %108, align 4 + %105 = getelementptr inbounds nuw i8, ptr %10, i64 4 + store float 0.000000e+00, ptr %105, align 4 + %106 = getelementptr inbounds nuw i8, ptr %10, i64 8 + store float %46, ptr %106, align 4 %.unpack.i68 = load i64, ptr %5, align 8 %.unpack3.i70 = load i64, ptr %.elt2.i, align 8 - %109 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i70 - %110 = and i64 %.unpack.i68, 1 - %.not.i71 = icmp eq i64 %110, 0 - br i1 %.not.i71, label %116, label %111 - -111: ; preds = %.split.us - %112 = load ptr, ptr %109, align 8 - %113 = getelementptr i8, ptr %112, i64 %.unpack.i68 - %114 = getelementptr i8, ptr %113, i64 -1 - %115 = load ptr, ptr %114, align 8, !nosanitize !7 - br label %118 - -116: ; preds = %.split.us - %117 = inttoptr i64 %.unpack.i68 to ptr - br label %118 - -118: ; preds = %116, %111 - %119 = phi ptr [ %115, %111 ], [ %117, %116 ] - invoke void %119(ptr noundef nonnull align 8 dereferenceable(32) %109, ptr noundef nonnull align 4 dereferenceable(12) %10) - to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit73 unwind label %44 - -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit73: ; preds = %118 + %107 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i70 + %108 = and i64 %.unpack.i68, 1 + %.not.i71 = icmp eq i64 %108, 0 + br i1 %.not.i71, label %114, label %109 + +109: ; preds = %.split.us + %110 = load ptr, ptr %107, align 8 + %111 = getelementptr i8, ptr %110, i64 %.unpack.i68 + %112 = getelementptr i8, ptr %111, i64 -1 + %113 = load ptr, ptr %112, align 8, !nosanitize !7 + br label %116 + +114: ; preds = %.split.us + %115 = inttoptr i64 %.unpack.i68 to ptr + br label %116 + +116: ; preds = %114, %109 + %117 = phi ptr [ %113, %109 ], [ %115, %114 ] + invoke void %117(ptr noundef nonnull align 8 dereferenceable(32) %107, ptr noundef nonnull align 4 dereferenceable(12) %10) + to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit73 unwind label %42 + +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit73: ; preds = %116 %.not.i.i.i74 = icmp eq ptr %.sroa.0.0111, null - br i1 %.not.i.i.i74, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit75, label %120 + br i1 %.not.i.i.i74, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit75, label %118 -120: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit73 - %121 = ptrtoint ptr %.sroa.0.0111 to i64 - %122 = sub i64 %.sroa.12.0112, %121 - call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.0111, i64 noundef %122) #12 +118: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit73 + %119 = ptrtoint ptr %.sroa.0.0111 to i64 + %120 = sub i64 %.sroa.12.0112, %119 + call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.0111, i64 noundef %120) #12 br label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit75 -_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit75: ; preds = %120, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit73, %6 +_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit75: ; preds = %118, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit73, %6 ret void -_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit: ; preds = %.thread, %44 - %.pn = phi { ptr, i32 } [ %lpad.thr_comm.split-lp, %44 ], [ %lpad.phi89, %.thread ] +_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit: ; preds = %.thread, %42 + %.pn = phi { ptr, i32 } [ %lpad.thr_comm.split-lp, %42 ], [ %lpad.phi89, %.thread ] resume { ptr, i32 } %.pn } @@ -329,265 +327,263 @@ define weak_odr void @_ZN32pxrInternal_v0_24__pxrReserved__29GeomUtilCylinderMes %15 = fcmp ogt double %13, 0x401921FB54442D18 %..i = select i1 %15, double 0x401921FB54442D18, double %13 %.0.i = select i1 %14, double 0xC01921FB54442D18, double %..i - %16 = tail call double @llvm.fabs.f64(double %13) + %16 = tail call noundef double @llvm.fabs.f64(double %.0.i) %17 = fadd double %16, 0xC01921FB54442D18 %18 = tail call double @llvm.fabs.f64(double %17) %19 = fcmp olt double %18, 0x3EB0C6F7A0B5ED8D - %20 = or i1 %15, %19 - %21 = or i1 %14, %20 - %22 = tail call noundef i64 @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase23_ComputeNumRadialPointsEmb(i64 noundef %0, i1 noundef zeroext %21) - %23 = icmp ugt i64 %22, 576460752303423487 - br i1 %23, label %.noexc, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i + %20 = tail call noundef i64 @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase23_ComputeNumRadialPointsEmb(i64 noundef %0, i1 noundef zeroext %19) + %21 = icmp ugt i64 %20, 576460752303423487 + br i1 %21, label %.noexc, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i .noexc: ; preds = %12 tail call void @_ZSt20__throw_length_errorPKc(ptr noundef nonnull @.str) #9 unreachable _ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i: ; preds = %12 - %.not.i.i.i.i = icmp eq i64 %22, 0 + %.not.i.i.i.i = icmp eq i64 %20, 0 br i1 %.not.i.i.i.i, label %._crit_edge, label %.noexc54 .noexc54: ; preds = %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i - %24 = shl nuw nsw i64 %22, 4 - %25 = tail call noalias noundef nonnull ptr @_Znwm(i64 noundef %24) #10 - %26 = getelementptr %"struct.std::array.5", ptr %25, i64 %22 - tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %25, i8 0, i64 16, i1 false) - %27 = icmp eq i64 %22, 1 - br i1 %27, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i.preheader + %22 = shl nuw nsw i64 %20, 4 + %23 = tail call noalias noundef nonnull ptr @_Znwm(i64 noundef %22) #10 + %24 = getelementptr %"struct.std::array.5", ptr %23, i64 %20 + tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %23, i8 0, i64 16, i1 false) + %25 = icmp eq i64 %20, 1 + br i1 %25, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i.preheader .lr.ph.i.i.i.i.i.i.i.i.i.preheader: ; preds = %.noexc54 - %28 = getelementptr inbounds nuw i8, ptr %25, i64 16 + %26 = getelementptr inbounds nuw i8, ptr %23, i64 16 br label %.lr.ph.i.i.i.i.i.i.i.i.i .lr.ph.i.i.i.i.i.i.i.i.i: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.preheader, %.lr.ph.i.i.i.i.i.i.i.i.i - %.06.i.i.i.i.i.i.i.i.i = phi ptr [ %29, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %28, %.lr.ph.i.i.i.i.i.i.i.i.i.preheader ] - tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %.06.i.i.i.i.i.i.i.i.i, ptr noundef nonnull align 8 dereferenceable(16) %25, i64 16, i1 false) - %29 = getelementptr inbounds nuw i8, ptr %.06.i.i.i.i.i.i.i.i.i, i64 16 - %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %29, %26 + %.06.i.i.i.i.i.i.i.i.i = phi ptr [ %27, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %26, %.lr.ph.i.i.i.i.i.i.i.i.i.preheader ] + tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %.06.i.i.i.i.i.i.i.i.i, ptr noundef nonnull align 8 dereferenceable(16) %23, i64 16, i1 false) + %27 = getelementptr inbounds nuw i8, ptr %.06.i.i.i.i.i.i.i.i.i, i64 16 + %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %27, %24 br i1 %.not.i.i.i.i.i.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i, !llvm.loop !12 .lr.ph: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i, %.noexc54 - %30 = uitofp i64 %0 to double - br label %31 - -31: ; preds = %.lr.ph, %31 - %.05093 = phi i64 [ 0, %.lr.ph ], [ %39, %31 ] - %32 = uitofp i64 %.05093 to double - %33 = fdiv double %32, %30 - %34 = fmul double %.0.i, %33 - %35 = tail call double @cos(double noundef %34) #11 - %36 = getelementptr inbounds %"struct.std::array.5", ptr %25, i64 %.05093 + %28 = uitofp i64 %0 to double + br label %29 + +29: ; preds = %.lr.ph, %29 + %.05093 = phi i64 [ 0, %.lr.ph ], [ %37, %29 ] + %30 = uitofp i64 %.05093 to double + %31 = fdiv double %30, %28 + %32 = fmul double %.0.i, %31 + %33 = tail call double @cos(double noundef %32) #11 + %34 = getelementptr inbounds %"struct.std::array.5", ptr %23, i64 %.05093 + store double %33, ptr %34, align 8 + %35 = tail call double @sin(double noundef %32) #11 + %36 = getelementptr inbounds nuw i8, ptr %34, i64 8 store double %35, ptr %36, align 8 - %37 = tail call double @sin(double noundef %34) #11 - %38 = getelementptr inbounds nuw i8, ptr %36, i64 8 - store double %37, ptr %38, align 8 - %39 = add nuw i64 %.05093, 1 - %exitcond.not = icmp eq i64 %39, %22 - br i1 %exitcond.not, label %._crit_edge.loopexit, label %31, !llvm.loop !13 - -._crit_edge.loopexit: ; preds = %31 - %40 = ptrtoint ptr %26 to i64 + %37 = add nuw i64 %.05093, 1 + %exitcond.not = icmp eq i64 %37, %20 + br i1 %exitcond.not, label %._crit_edge.loopexit, label %29, !llvm.loop !13 + +._crit_edge.loopexit: ; preds = %29 + %38 = ptrtoint ptr %24 to i64 br label %._crit_edge ._crit_edge: ; preds = %._crit_edge.loopexit, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i - %.sroa.12.0112 = phi i64 [ 0, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %40, %._crit_edge.loopexit ] - %.sroa.0.0111 = phi ptr [ null, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %25, %._crit_edge.loopexit ] - %41 = fmul double %3, 5.000000e-01 - %42 = fneg double %41 - %43 = getelementptr inbounds nuw i8, ptr %7, i64 16 + %.sroa.12.0112 = phi i64 [ 0, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %38, %._crit_edge.loopexit ] + %.sroa.0.0111 = phi ptr [ null, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %23, %._crit_edge.loopexit ] + %39 = fmul double %3, 5.000000e-01 + %40 = fneg double %39 + %41 = getelementptr inbounds nuw i8, ptr %7, i64 16 call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %7, i8 0, i64 16, i1 false) - store double %42, ptr %43, align 8 + store double %40, ptr %41, align 8 %.unpack.i = load i64, ptr %5, align 8 %.elt2.i = getelementptr inbounds nuw i8, ptr %5, i64 8 %.unpack3.i = load i64, ptr %.elt2.i, align 8 - %44 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i - %45 = and i64 %.unpack.i, 1 - %.not.i = icmp eq i64 %45, 0 - br i1 %.not.i, label %51, label %46 - -46: ; preds = %._crit_edge - %47 = load ptr, ptr %44, align 8 - %48 = getelementptr i8, ptr %47, i64 %.unpack.i - %49 = getelementptr i8, ptr %48, i64 -1 - %50 = load ptr, ptr %49, align 8, !nosanitize !7 - br label %53 - -51: ; preds = %._crit_edge - %52 = inttoptr i64 %.unpack.i to ptr - br label %53 - -53: ; preds = %51, %46 - %54 = phi ptr [ %50, %46 ], [ %52, %51 ] - invoke void %54(ptr noundef nonnull align 8 dereferenceable(32) %44, ptr noundef nonnull align 8 dereferenceable(24) %7) - to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader unwind label %99 - -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader: ; preds = %53 - %55 = getelementptr inbounds nuw i8, ptr %8, i64 8 - %56 = getelementptr inbounds nuw i8, ptr %8, i64 16 + %42 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i + %43 = and i64 %.unpack.i, 1 + %.not.i = icmp eq i64 %43, 0 + br i1 %.not.i, label %49, label %44 + +44: ; preds = %._crit_edge + %45 = load ptr, ptr %42, align 8 + %46 = getelementptr i8, ptr %45, i64 %.unpack.i + %47 = getelementptr i8, ptr %46, i64 -1 + %48 = load ptr, ptr %47, align 8, !nosanitize !7 + br label %51 + +49: ; preds = %._crit_edge + %50 = inttoptr i64 %.unpack.i to ptr + br label %51 + +51: ; preds = %49, %44 + %52 = phi ptr [ %48, %44 ], [ %50, %49 ] + invoke void %52(ptr noundef nonnull align 8 dereferenceable(32) %42, ptr noundef nonnull align 8 dereferenceable(24) %7) + to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader unwind label %97 + +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader: ; preds = %51 + %53 = getelementptr inbounds nuw i8, ptr %8, i64 8 + %54 = getelementptr inbounds nuw i8, ptr %8, i64 16 br i1 %.not.i.i.i.i, label %.split.us, label %.preheader92.us .preheader92.us: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader, %._crit_edge96.us - %57 = phi i1 [ false, %._crit_edge96.us ], [ true, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader ] - br label %58 - -58: ; preds = %.preheader92.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit61.us - %.04694.us = phi i64 [ 0, %.preheader92.us ], [ %76, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit61.us ] - %59 = getelementptr inbounds %"struct.std::array.5", ptr %.sroa.0.0111, i64 %.04694.us - %60 = load double, ptr %59, align 8 - %61 = fmul double %1, %60 - %62 = getelementptr inbounds nuw i8, ptr %59, i64 8 - %63 = load double, ptr %62, align 8 - %64 = fmul double %1, %63 - store double %61, ptr %8, align 8 - store double %64, ptr %55, align 8 - store double %42, ptr %56, align 8 + %55 = phi i1 [ false, %._crit_edge96.us ], [ true, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader ] + br label %56 + +56: ; preds = %.preheader92.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit61.us + %.04694.us = phi i64 [ 0, %.preheader92.us ], [ %74, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit61.us ] + %57 = getelementptr inbounds %"struct.std::array.5", ptr %.sroa.0.0111, i64 %.04694.us + %58 = load double, ptr %57, align 8 + %59 = fmul double %1, %58 + %60 = getelementptr inbounds nuw i8, ptr %57, i64 8 + %61 = load double, ptr %60, align 8 + %62 = fmul double %1, %61 + store double %59, ptr %8, align 8 + store double %62, ptr %53, align 8 + store double %40, ptr %54, align 8 %.unpack.i56.us = load i64, ptr %5, align 8 %.unpack3.i58.us = load i64, ptr %.elt2.i, align 8 - %65 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i58.us - %66 = and i64 %.unpack.i56.us, 1 - %.not.i59.us = icmp eq i64 %66, 0 - br i1 %.not.i59.us, label %72, label %67 - -67: ; preds = %58 - %68 = load ptr, ptr %65, align 8 - %69 = getelementptr i8, ptr %68, i64 %.unpack.i56.us - %70 = getelementptr i8, ptr %69, i64 -1 - %71 = load ptr, ptr %70, align 8, !nosanitize !7 - br label %74 - -72: ; preds = %58 - %73 = inttoptr i64 %.unpack.i56.us to ptr - br label %74 - -74: ; preds = %72, %67 - %75 = phi ptr [ %71, %67 ], [ %73, %72 ] - invoke void %75(ptr noundef nonnull align 8 dereferenceable(32) %65, ptr noundef nonnull align 8 dereferenceable(24) %8) + %63 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i58.us + %64 = and i64 %.unpack.i56.us, 1 + %.not.i59.us = icmp eq i64 %64, 0 + br i1 %.not.i59.us, label %70, label %65 + +65: ; preds = %56 + %66 = load ptr, ptr %63, align 8 + %67 = getelementptr i8, ptr %66, i64 %.unpack.i56.us + %68 = getelementptr i8, ptr %67, i64 -1 + %69 = load ptr, ptr %68, align 8, !nosanitize !7 + br label %72 + +70: ; preds = %56 + %71 = inttoptr i64 %.unpack.i56.us to ptr + br label %72 + +72: ; preds = %70, %65 + %73 = phi ptr [ %69, %65 ], [ %71, %70 ] + invoke void %73(ptr noundef nonnull align 8 dereferenceable(32) %63, ptr noundef nonnull align 8 dereferenceable(24) %8) to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit61.us unwind label %.thread.loopexit.split-lp.split.us -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit61.us: ; preds = %74 - %76 = add nuw i64 %.04694.us, 1 - %exitcond107.not = icmp eq i64 %76, %22 - br i1 %exitcond107.not, label %._crit_edge96.us, label %58, !llvm.loop !14 +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit61.us: ; preds = %72 + %74 = add nuw i64 %.04694.us, 1 + %exitcond107.not = icmp eq i64 %74, %20 + br i1 %exitcond107.not, label %._crit_edge96.us, label %56, !llvm.loop !14 ._crit_edge96.us: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit61.us - br i1 %57, label %.preheader92.us, label %.preheader.us.preheader, !llvm.loop !15 + br i1 %55, label %.preheader92.us, label %.preheader.us.preheader, !llvm.loop !15 -.thread.loopexit.split-lp.split.us: ; preds = %74 +.thread.loopexit.split-lp.split.us: ; preds = %72 %lpad.loopexit.split-lp.us = landingpad { ptr, i32 } cleanup br label %.thread .preheader.us.preheader: ; preds = %._crit_edge96.us - %77 = getelementptr inbounds nuw i8, ptr %9, i64 8 - %78 = getelementptr inbounds nuw i8, ptr %9, i64 16 + %75 = getelementptr inbounds nuw i8, ptr %9, i64 8 + %76 = getelementptr inbounds nuw i8, ptr %9, i64 16 br label %.preheader.us .preheader.us: ; preds = %.preheader.us.preheader, %._crit_edge100.us - %79 = phi i1 [ false, %._crit_edge100.us ], [ true, %.preheader.us.preheader ] - br label %80 - -80: ; preds = %.preheader.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit67.us - %.098.us = phi i64 [ 0, %.preheader.us ], [ %98, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit67.us ] - %81 = getelementptr inbounds %"struct.std::array.5", ptr %.sroa.0.0111, i64 %.098.us - %82 = load double, ptr %81, align 8 - %83 = fmul double %2, %82 - %84 = getelementptr inbounds nuw i8, ptr %81, i64 8 - %85 = load double, ptr %84, align 8 - %86 = fmul double %2, %85 - store double %83, ptr %9, align 8 - store double %86, ptr %77, align 8 - store double %41, ptr %78, align 8 + %77 = phi i1 [ false, %._crit_edge100.us ], [ true, %.preheader.us.preheader ] + br label %78 + +78: ; preds = %.preheader.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit67.us + %.098.us = phi i64 [ 0, %.preheader.us ], [ %96, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit67.us ] + %79 = getelementptr inbounds %"struct.std::array.5", ptr %.sroa.0.0111, i64 %.098.us + %80 = load double, ptr %79, align 8 + %81 = fmul double %2, %80 + %82 = getelementptr inbounds nuw i8, ptr %79, i64 8 + %83 = load double, ptr %82, align 8 + %84 = fmul double %2, %83 + store double %81, ptr %9, align 8 + store double %84, ptr %75, align 8 + store double %39, ptr %76, align 8 %.unpack.i62.us = load i64, ptr %5, align 8 %.unpack3.i64.us = load i64, ptr %.elt2.i, align 8 - %87 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i64.us - %88 = and i64 %.unpack.i62.us, 1 - %.not.i65.us = icmp eq i64 %88, 0 - br i1 %.not.i65.us, label %94, label %89 - -89: ; preds = %80 - %90 = load ptr, ptr %87, align 8 - %91 = getelementptr i8, ptr %90, i64 %.unpack.i62.us - %92 = getelementptr i8, ptr %91, i64 -1 - %93 = load ptr, ptr %92, align 8, !nosanitize !7 - br label %96 - -94: ; preds = %80 - %95 = inttoptr i64 %.unpack.i62.us to ptr - br label %96 - -96: ; preds = %94, %89 - %97 = phi ptr [ %93, %89 ], [ %95, %94 ] - invoke void %97(ptr noundef nonnull align 8 dereferenceable(32) %87, ptr noundef nonnull align 8 dereferenceable(24) %9) + %85 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i64.us + %86 = and i64 %.unpack.i62.us, 1 + %.not.i65.us = icmp eq i64 %86, 0 + br i1 %.not.i65.us, label %92, label %87 + +87: ; preds = %78 + %88 = load ptr, ptr %85, align 8 + %89 = getelementptr i8, ptr %88, i64 %.unpack.i62.us + %90 = getelementptr i8, ptr %89, i64 -1 + %91 = load ptr, ptr %90, align 8, !nosanitize !7 + br label %94 + +92: ; preds = %78 + %93 = inttoptr i64 %.unpack.i62.us to ptr + br label %94 + +94: ; preds = %92, %87 + %95 = phi ptr [ %91, %87 ], [ %93, %92 ] + invoke void %95(ptr noundef nonnull align 8 dereferenceable(32) %85, ptr noundef nonnull align 8 dereferenceable(24) %9) to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit67.us unwind label %.thread.loopexit.split.us -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit67.us: ; preds = %96 - %98 = add nuw i64 %.098.us, 1 - %exitcond108.not = icmp eq i64 %98, %22 - br i1 %exitcond108.not, label %._crit_edge100.us, label %80, !llvm.loop !16 +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit67.us: ; preds = %94 + %96 = add nuw i64 %.098.us, 1 + %exitcond108.not = icmp eq i64 %96, %20 + br i1 %exitcond108.not, label %._crit_edge100.us, label %78, !llvm.loop !16 ._crit_edge100.us: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit67.us - br i1 %79, label %.preheader.us, label %.split.us, !llvm.loop !17 + br i1 %77, label %.preheader.us, label %.split.us, !llvm.loop !17 -.thread.loopexit.split.us: ; preds = %96 +.thread.loopexit.split.us: ; preds = %94 %lpad.loopexit.us = landingpad { ptr, i32 } cleanup br label %.thread -99: ; preds = %112, %53 +97: ; preds = %110, %51 %lpad.thr_comm.split-lp = landingpad { ptr, i32 } cleanup %.not.i.i.i = icmp eq ptr %.sroa.0.0111, null br i1 %.not.i.i.i, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit, label %.thread -.thread: ; preds = %.thread.loopexit.split.us, %.thread.loopexit.split-lp.split.us, %99 - %lpad.phi89 = phi { ptr, i32 } [ %lpad.thr_comm.split-lp, %99 ], [ %lpad.loopexit.us, %.thread.loopexit.split.us ], [ %lpad.loopexit.split-lp.us, %.thread.loopexit.split-lp.split.us ] - %100 = ptrtoint ptr %.sroa.0.0111 to i64 - %101 = sub i64 %.sroa.12.0112, %100 - call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.0111, i64 noundef %101) #12 +.thread: ; preds = %.thread.loopexit.split.us, %.thread.loopexit.split-lp.split.us, %97 + %lpad.phi89 = phi { ptr, i32 } [ %lpad.thr_comm.split-lp, %97 ], [ %lpad.loopexit.us, %.thread.loopexit.split.us ], [ %lpad.loopexit.split-lp.us, %.thread.loopexit.split-lp.split.us ] + %98 = ptrtoint ptr %.sroa.0.0111 to i64 + %99 = sub i64 %.sroa.12.0112, %98 + call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.0111, i64 noundef %99) #12 br label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit .split.us: ; preds = %._crit_edge100.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader - %102 = getelementptr inbounds nuw i8, ptr %10, i64 16 + %100 = getelementptr inbounds nuw i8, ptr %10, i64 16 call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %10, i8 0, i64 16, i1 false) - store double %41, ptr %102, align 8 + store double %39, ptr %100, align 8 %.unpack.i68 = load i64, ptr %5, align 8 %.unpack3.i70 = load i64, ptr %.elt2.i, align 8 - %103 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i70 - %104 = and i64 %.unpack.i68, 1 - %.not.i71 = icmp eq i64 %104, 0 - br i1 %.not.i71, label %110, label %105 - -105: ; preds = %.split.us - %106 = load ptr, ptr %103, align 8 - %107 = getelementptr i8, ptr %106, i64 %.unpack.i68 - %108 = getelementptr i8, ptr %107, i64 -1 - %109 = load ptr, ptr %108, align 8, !nosanitize !7 - br label %112 - -110: ; preds = %.split.us - %111 = inttoptr i64 %.unpack.i68 to ptr - br label %112 - -112: ; preds = %110, %105 - %113 = phi ptr [ %109, %105 ], [ %111, %110 ] - invoke void %113(ptr noundef nonnull align 8 dereferenceable(32) %103, ptr noundef nonnull align 8 dereferenceable(24) %10) - to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit73 unwind label %99 - -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit73: ; preds = %112 + %101 = getelementptr inbounds i8, ptr %5, i64 %.unpack3.i70 + %102 = and i64 %.unpack.i68, 1 + %.not.i71 = icmp eq i64 %102, 0 + br i1 %.not.i71, label %108, label %103 + +103: ; preds = %.split.us + %104 = load ptr, ptr %101, align 8 + %105 = getelementptr i8, ptr %104, i64 %.unpack.i68 + %106 = getelementptr i8, ptr %105, i64 -1 + %107 = load ptr, ptr %106, align 8, !nosanitize !7 + br label %110 + +108: ; preds = %.split.us + %109 = inttoptr i64 %.unpack.i68 to ptr + br label %110 + +110: ; preds = %108, %103 + %111 = phi ptr [ %107, %103 ], [ %109, %108 ] + invoke void %111(ptr noundef nonnull align 8 dereferenceable(32) %101, ptr noundef nonnull align 8 dereferenceable(24) %10) + to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit73 unwind label %97 + +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit73: ; preds = %110 %.not.i.i.i74 = icmp eq ptr %.sroa.0.0111, null - br i1 %.not.i.i.i74, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit75, label %114 + br i1 %.not.i.i.i74, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit75, label %112 -114: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit73 - %115 = ptrtoint ptr %.sroa.0.0111 to i64 - %116 = sub i64 %.sroa.12.0112, %115 - call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.0111, i64 noundef %116) #12 +112: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit73 + %113 = ptrtoint ptr %.sroa.0.0111 to i64 + %114 = sub i64 %.sroa.12.0112, %113 + call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.0111, i64 noundef %114) #12 br label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit75 -_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit75: ; preds = %114, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit73, %6 +_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit75: ; preds = %112, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit73, %6 ret void -_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit: ; preds = %.thread, %99 - %.pn = phi { ptr, i32 } [ %lpad.thr_comm.split-lp, %99 ], [ %lpad.phi89, %.thread ] +_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit: ; preds = %.thread, %97 + %.pn = phi { ptr, i32 } [ %lpad.thr_comm.split-lp, %97 ], [ %lpad.phi89, %.thread ] resume { ptr, i32 } %.pn } diff --git a/bench/openusd/optimized/sphereMeshGenerator.cpp.ll b/bench/openusd/optimized/sphereMeshGenerator.cpp.ll index 2269bba7ea5..c3ab7a9fee7 100644 --- a/bench/openusd/optimized/sphereMeshGenerator.cpp.ll +++ b/bench/openusd/optimized/sphereMeshGenerator.cpp.ll @@ -43,246 +43,244 @@ define weak_odr void @_ZN32pxrInternal_v0_24__pxrReserved__27GeomUtilSphereMeshG %16 = fcmp ogt float %14, 0x401921FB60000000 %..i = select i1 %16, float 0x401921FB60000000, float %14 %.0.i = select i1 %15, float 0xC01921FB60000000, float %..i - %17 = tail call float @llvm.fabs.f32(float %14) + %17 = tail call noundef float @llvm.fabs.f32(float %.0.i) %18 = fpext float %17 to double %19 = fadd double %18, 0xC01921FB60000000 %20 = tail call double @llvm.fabs.f64(double %19) %21 = fcmp olt double %20, 0x3EB0C6F7A0B5ED8D - %22 = or i1 %16, %21 - %23 = or i1 %15, %22 - %24 = tail call noundef i64 @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase23_ComputeNumRadialPointsEmb(i64 noundef %0, i1 noundef zeroext %23) - %25 = icmp ugt i64 %24, 1152921504606846975 - br i1 %25, label %.noexc, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i + %22 = tail call noundef i64 @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase23_ComputeNumRadialPointsEmb(i64 noundef %0, i1 noundef zeroext %21) + %23 = icmp ugt i64 %22, 1152921504606846975 + br i1 %23, label %.noexc, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i .noexc: ; preds = %11 tail call void @_ZSt20__throw_length_errorPKc(ptr noundef nonnull @.str) #9 unreachable _ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i: ; preds = %11 - %.not.i.i.i.i = icmp eq i64 %24, 0 + %.not.i.i.i.i = icmp eq i64 %22, 0 br i1 %.not.i.i.i.i, label %._crit_edge, label %.noexc50 .noexc50: ; preds = %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i - %26 = shl nuw nsw i64 %24, 3 - %27 = tail call noalias noundef nonnull ptr @_Znwm(i64 noundef %26) #10 - %28 = getelementptr %"struct.std::array", ptr %27, i64 %24 - store i64 0, ptr %27, align 4 - %29 = icmp eq i64 %24, 1 - br i1 %29, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i.preheader + %24 = shl nuw nsw i64 %22, 3 + %25 = tail call noalias noundef nonnull ptr @_Znwm(i64 noundef %24) #10 + %26 = getelementptr %"struct.std::array", ptr %25, i64 %22 + store i64 0, ptr %25, align 4 + %27 = icmp eq i64 %22, 1 + br i1 %27, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i.preheader .lr.ph.i.i.i.i.i.i.i.i.i.preheader: ; preds = %.noexc50 - %30 = getelementptr inbounds nuw i8, ptr %27, i64 8 + %28 = getelementptr inbounds nuw i8, ptr %25, i64 8 br label %.lr.ph.i.i.i.i.i.i.i.i.i .lr.ph.i.i.i.i.i.i.i.i.i: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.preheader, %.lr.ph.i.i.i.i.i.i.i.i.i - %.06.i.i.i.i.i.i.i.i.i = phi ptr [ %32, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %30, %.lr.ph.i.i.i.i.i.i.i.i.i.preheader ] - %31 = load i64, ptr %27, align 4 - store i64 %31, ptr %.06.i.i.i.i.i.i.i.i.i, align 4 - %32 = getelementptr inbounds nuw i8, ptr %.06.i.i.i.i.i.i.i.i.i, i64 8 - %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %32, %28 + %.06.i.i.i.i.i.i.i.i.i = phi ptr [ %30, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %28, %.lr.ph.i.i.i.i.i.i.i.i.i.preheader ] + %29 = load i64, ptr %25, align 4 + store i64 %29, ptr %.06.i.i.i.i.i.i.i.i.i, align 4 + %30 = getelementptr inbounds nuw i8, ptr %.06.i.i.i.i.i.i.i.i.i, i64 8 + %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %30, %26 br i1 %.not.i.i.i.i.i.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i, !llvm.loop !4 .lr.ph: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i, %.noexc50 - %33 = uitofp i64 %0 to float - br label %34 - -34: ; preds = %.lr.ph, %34 - %.04476 = phi i64 [ 0, %.lr.ph ], [ %44, %34 ] - %35 = uitofp i64 %.04476 to float - %36 = fdiv float %35, %33 - %37 = fmul float %.0.i, %36 - %38 = tail call noundef float @cosf(float noundef %37) #11 - %39 = fmul float %2, %38 - %40 = getelementptr inbounds %"struct.std::array", ptr %27, i64 %.04476 - store float %39, ptr %40, align 4 - %41 = tail call noundef float @sinf(float noundef %37) #11 - %42 = fmul float %2, %41 - %43 = getelementptr inbounds nuw i8, ptr %40, i64 4 - store float %42, ptr %43, align 4 - %44 = add nuw i64 %.04476, 1 - %exitcond.not = icmp eq i64 %44, %24 - br i1 %exitcond.not, label %._crit_edge.loopexit, label %34, !llvm.loop !6 - -45: ; preds = %120, %64 - %46 = landingpad { ptr, i32 } + %31 = uitofp i64 %0 to float + br label %32 + +32: ; preds = %.lr.ph, %32 + %.04476 = phi i64 [ 0, %.lr.ph ], [ %42, %32 ] + %33 = uitofp i64 %.04476 to float + %34 = fdiv float %33, %31 + %35 = fmul float %.0.i, %34 + %36 = tail call noundef float @cosf(float noundef %35) #11 + %37 = fmul float %2, %36 + %38 = getelementptr inbounds %"struct.std::array", ptr %25, i64 %.04476 + store float %37, ptr %38, align 4 + %39 = tail call noundef float @sinf(float noundef %35) #11 + %40 = fmul float %2, %39 + %41 = getelementptr inbounds nuw i8, ptr %38, i64 4 + store float %40, ptr %41, align 4 + %42 = add nuw i64 %.04476, 1 + %exitcond.not = icmp eq i64 %42, %22 + br i1 %exitcond.not, label %._crit_edge.loopexit, label %32, !llvm.loop !6 + +43: ; preds = %118, %62 + %44 = landingpad { ptr, i32 } cleanup %.not.i.i.i = icmp eq ptr %.sroa.0.091, null - br i1 %.not.i.i.i, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit, label %47 + br i1 %.not.i.i.i, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit, label %45 -47: ; preds = %.thread.split.us, %45 - %48 = phi { ptr, i32 } [ %99, %.thread.split.us ], [ %46, %45 ] - %49 = ptrtoint ptr %.sroa.0.091 to i64 - %50 = sub i64 %.sroa.10.092, %49 - call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.091, i64 noundef %50) #12 +45: ; preds = %.thread.split.us, %43 + %46 = phi { ptr, i32 } [ %97, %.thread.split.us ], [ %44, %43 ] + %47 = ptrtoint ptr %.sroa.0.091 to i64 + %48 = sub i64 %.sroa.10.092, %47 + call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.091, i64 noundef %48) #12 br label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit -._crit_edge.loopexit: ; preds = %34 - %51 = ptrtoint ptr %28 to i64 +._crit_edge.loopexit: ; preds = %32 + %49 = ptrtoint ptr %26 to i64 br label %._crit_edge ._crit_edge: ; preds = %._crit_edge.loopexit, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i - %.sroa.10.092 = phi i64 [ 0, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %51, %._crit_edge.loopexit ] - %.sroa.0.091 = phi ptr [ null, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %27, %._crit_edge.loopexit ] - %52 = fneg float %2 + %.sroa.10.092 = phi i64 [ 0, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %49, %._crit_edge.loopexit ] + %.sroa.0.091 = phi ptr [ null, %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %25, %._crit_edge.loopexit ] + %50 = fneg float %2 store float 0.000000e+00, ptr %6, align 4 - %53 = getelementptr inbounds nuw i8, ptr %6, i64 4 - store float 0.000000e+00, ptr %53, align 4 - %54 = getelementptr inbounds nuw i8, ptr %6, i64 8 - store float %52, ptr %54, align 4 + %51 = getelementptr inbounds nuw i8, ptr %6, i64 4 + store float 0.000000e+00, ptr %51, align 4 + %52 = getelementptr inbounds nuw i8, ptr %6, i64 8 + store float %50, ptr %52, align 4 %.unpack.i = load i64, ptr %4, align 8 %.elt2.i = getelementptr inbounds nuw i8, ptr %4, i64 8 %.unpack3.i = load i64, ptr %.elt2.i, align 8 - %55 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i - %56 = and i64 %.unpack.i, 1 - %.not.i = icmp eq i64 %56, 0 - br i1 %.not.i, label %62, label %57 - -57: ; preds = %._crit_edge - %58 = load ptr, ptr %55, align 8 - %59 = getelementptr i8, ptr %58, i64 %.unpack.i - %60 = getelementptr i8, ptr %59, i64 -1 - %61 = load ptr, ptr %60, align 8, !nosanitize !7 - br label %64 - -62: ; preds = %._crit_edge - %63 = inttoptr i64 %.unpack.i to ptr - br label %64 - -64: ; preds = %62, %57 - %65 = phi ptr [ %61, %57 ], [ %63, %62 ] - invoke void %65(ptr noundef nonnull align 8 dereferenceable(32) %55, ptr noundef nonnull align 4 dereferenceable(12) %6) - to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader unwind label %45 - -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader: ; preds = %64 - %66 = icmp ugt i64 %1, 1 - br i1 %66, label %.lr.ph82, label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit._crit_edge + %53 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i + %54 = and i64 %.unpack.i, 1 + %.not.i = icmp eq i64 %54, 0 + br i1 %.not.i, label %60, label %55 + +55: ; preds = %._crit_edge + %56 = load ptr, ptr %53, align 8 + %57 = getelementptr i8, ptr %56, i64 %.unpack.i + %58 = getelementptr i8, ptr %57, i64 -1 + %59 = load ptr, ptr %58, align 8, !nosanitize !7 + br label %62 + +60: ; preds = %._crit_edge + %61 = inttoptr i64 %.unpack.i to ptr + br label %62 + +62: ; preds = %60, %55 + %63 = phi ptr [ %59, %55 ], [ %61, %60 ] + invoke void %63(ptr noundef nonnull align 8 dereferenceable(32) %53, ptr noundef nonnull align 4 dereferenceable(12) %6) + to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader unwind label %43 + +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader: ; preds = %62 + %64 = icmp ugt i64 %1, 1 + br i1 %64, label %.lr.ph82, label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit._crit_edge .lr.ph82: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader - %67 = uitofp i64 %1 to float - %68 = getelementptr inbounds nuw i8, ptr %7, i64 4 - %69 = getelementptr inbounds nuw i8, ptr %7, i64 8 + %65 = uitofp i64 %1 to float + %66 = getelementptr inbounds nuw i8, ptr %7, i64 4 + %67 = getelementptr inbounds nuw i8, ptr %7, i64 8 br i1 %.not.i.i.i.i, label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit, label %.lr.ph79.us .lr.ph79.us: ; preds = %.lr.ph82, %._crit_edge80.us - %.04581.us = phi i64 [ %98, %._crit_edge80.us ], [ 1, %.lr.ph82 ] - %70 = uitofp i64 %.04581.us to float - %71 = fdiv float %70, %67 - %72 = fpext float %71 to double - %73 = fadd double %72, -5.000000e-01 - %74 = fmul double %73, 0x400921FB54442D18 - %75 = fptrunc double %74 to float - %76 = call noundef float @cosf(float noundef %75) #11 - %77 = call noundef float @sinf(float noundef %75) #11 - %78 = fmul float %2, %77 - br label %79 - -79: ; preds = %.lr.ph79.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit57.us - %.077.us = phi i64 [ 0, %.lr.ph79.us ], [ %97, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit57.us ] - %80 = getelementptr inbounds %"struct.std::array", ptr %.sroa.0.091, i64 %.077.us - %81 = load float, ptr %80, align 4 - %82 = fmul float %76, %81 - %83 = getelementptr inbounds nuw i8, ptr %80, i64 4 - %84 = load float, ptr %83, align 4 - %85 = fmul float %76, %84 - store float %82, ptr %7, align 4 - store float %85, ptr %68, align 4 - store float %78, ptr %69, align 4 + %.04581.us = phi i64 [ %96, %._crit_edge80.us ], [ 1, %.lr.ph82 ] + %68 = uitofp i64 %.04581.us to float + %69 = fdiv float %68, %65 + %70 = fpext float %69 to double + %71 = fadd double %70, -5.000000e-01 + %72 = fmul double %71, 0x400921FB54442D18 + %73 = fptrunc double %72 to float + %74 = call noundef float @cosf(float noundef %73) #11 + %75 = call noundef float @sinf(float noundef %73) #11 + %76 = fmul float %2, %75 + br label %77 + +77: ; preds = %.lr.ph79.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit57.us + %.077.us = phi i64 [ 0, %.lr.ph79.us ], [ %95, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit57.us ] + %78 = getelementptr inbounds %"struct.std::array", ptr %.sroa.0.091, i64 %.077.us + %79 = load float, ptr %78, align 4 + %80 = fmul float %74, %79 + %81 = getelementptr inbounds nuw i8, ptr %78, i64 4 + %82 = load float, ptr %81, align 4 + %83 = fmul float %74, %82 + store float %80, ptr %7, align 4 + store float %83, ptr %66, align 4 + store float %76, ptr %67, align 4 %.unpack.i52.us = load i64, ptr %4, align 8 %.unpack3.i54.us = load i64, ptr %.elt2.i, align 8 - %86 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i54.us - %87 = and i64 %.unpack.i52.us, 1 - %.not.i55.us = icmp eq i64 %87, 0 - br i1 %.not.i55.us, label %93, label %88 - -88: ; preds = %79 - %89 = load ptr, ptr %86, align 8 - %90 = getelementptr i8, ptr %89, i64 %.unpack.i52.us - %91 = getelementptr i8, ptr %90, i64 -1 - %92 = load ptr, ptr %91, align 8, !nosanitize !7 - br label %95 - -93: ; preds = %79 - %94 = inttoptr i64 %.unpack.i52.us to ptr - br label %95 - -95: ; preds = %93, %88 - %96 = phi ptr [ %92, %88 ], [ %94, %93 ] - invoke void %96(ptr noundef nonnull align 8 dereferenceable(32) %86, ptr noundef nonnull align 4 dereferenceable(12) %7) + %84 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i54.us + %85 = and i64 %.unpack.i52.us, 1 + %.not.i55.us = icmp eq i64 %85, 0 + br i1 %.not.i55.us, label %91, label %86 + +86: ; preds = %77 + %87 = load ptr, ptr %84, align 8 + %88 = getelementptr i8, ptr %87, i64 %.unpack.i52.us + %89 = getelementptr i8, ptr %88, i64 -1 + %90 = load ptr, ptr %89, align 8, !nosanitize !7 + br label %93 + +91: ; preds = %77 + %92 = inttoptr i64 %.unpack.i52.us to ptr + br label %93 + +93: ; preds = %91, %86 + %94 = phi ptr [ %90, %86 ], [ %92, %91 ] + invoke void %94(ptr noundef nonnull align 8 dereferenceable(32) %84, ptr noundef nonnull align 4 dereferenceable(12) %7) to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit57.us unwind label %.thread.split.us -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit57.us: ; preds = %95 - %97 = add nuw i64 %.077.us, 1 - %exitcond86.not = icmp eq i64 %97, %24 - br i1 %exitcond86.not, label %._crit_edge80.us, label %79, !llvm.loop !8 +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit57.us: ; preds = %93 + %95 = add nuw i64 %.077.us, 1 + %exitcond86.not = icmp eq i64 %95, %22 + br i1 %exitcond86.not, label %._crit_edge80.us, label %77, !llvm.loop !8 ._crit_edge80.us: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit57.us - %98 = add nuw i64 %.04581.us, 1 - %exitcond87.not = icmp eq i64 %98, %1 + %96 = add nuw i64 %.04581.us, 1 + %exitcond87.not = icmp eq i64 %96, %1 br i1 %exitcond87.not, label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit._crit_edge, label %.lr.ph79.us, !llvm.loop !9 -.thread.split.us: ; preds = %95 - %99 = landingpad { ptr, i32 } +.thread.split.us: ; preds = %93 + %97 = landingpad { ptr, i32 } cleanup - br label %47 + br label %45 _ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit: ; preds = %.lr.ph82, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit - %.04581 = phi i64 [ %108, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit ], [ 1, %.lr.ph82 ] - %100 = uitofp i64 %.04581 to float - %101 = fdiv float %100, %67 - %102 = fpext float %101 to double - %103 = fadd double %102, -5.000000e-01 - %104 = fmul double %103, 0x400921FB54442D18 - %105 = fptrunc double %104 to float - %106 = call noundef float @cosf(float noundef %105) #11 - %107 = call noundef float @sinf(float noundef %105) #11 - %108 = add nuw i64 %.04581, 1 - %exitcond88.not = icmp eq i64 %108, %1 + %.04581 = phi i64 [ %106, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit ], [ 1, %.lr.ph82 ] + %98 = uitofp i64 %.04581 to float + %99 = fdiv float %98, %65 + %100 = fpext float %99 to double + %101 = fadd double %100, -5.000000e-01 + %102 = fmul double %101, 0x400921FB54442D18 + %103 = fptrunc double %102 to float + %104 = call noundef float @cosf(float noundef %103) #11 + %105 = call noundef float @sinf(float noundef %103) #11 + %106 = add nuw i64 %.04581, 1 + %exitcond88.not = icmp eq i64 %106, %1 br i1 %exitcond88.not, label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit._crit_edge, label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit, !llvm.loop !9 _ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit._crit_edge: ; preds = %._crit_edge80.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit.preheader store float 0.000000e+00, ptr %8, align 4 - %109 = getelementptr inbounds nuw i8, ptr %8, i64 4 - store float 0.000000e+00, ptr %109, align 4 - %110 = getelementptr inbounds nuw i8, ptr %8, i64 8 - store float %2, ptr %110, align 4 + %107 = getelementptr inbounds nuw i8, ptr %8, i64 4 + store float 0.000000e+00, ptr %107, align 4 + %108 = getelementptr inbounds nuw i8, ptr %8, i64 8 + store float %2, ptr %108, align 4 %.unpack.i58 = load i64, ptr %4, align 8 %.unpack3.i60 = load i64, ptr %.elt2.i, align 8 - %111 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i60 - %112 = and i64 %.unpack.i58, 1 - %.not.i61 = icmp eq i64 %112, 0 - br i1 %.not.i61, label %118, label %113 - -113: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit._crit_edge - %114 = load ptr, ptr %111, align 8 - %115 = getelementptr i8, ptr %114, i64 %.unpack.i58 - %116 = getelementptr i8, ptr %115, i64 -1 - %117 = load ptr, ptr %116, align 8, !nosanitize !7 - br label %120 - -118: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit._crit_edge - %119 = inttoptr i64 %.unpack.i58 to ptr - br label %120 - -120: ; preds = %118, %113 - %121 = phi ptr [ %117, %113 ], [ %119, %118 ] - invoke void %121(ptr noundef nonnull align 8 dereferenceable(32) %111, ptr noundef nonnull align 4 dereferenceable(12) %8) - to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit63 unwind label %45 - -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit63: ; preds = %120 + %109 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i60 + %110 = and i64 %.unpack.i58, 1 + %.not.i61 = icmp eq i64 %110, 0 + br i1 %.not.i61, label %116, label %111 + +111: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit._crit_edge + %112 = load ptr, ptr %109, align 8 + %113 = getelementptr i8, ptr %112, i64 %.unpack.i58 + %114 = getelementptr i8, ptr %113, i64 -1 + %115 = load ptr, ptr %114, align 8, !nosanitize !7 + br label %118 + +116: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit._crit_edge + %117 = inttoptr i64 %.unpack.i58 to ptr + br label %118 + +118: ; preds = %116, %111 + %119 = phi ptr [ %115, %111 ], [ %117, %116 ] + invoke void %119(ptr noundef nonnull align 8 dereferenceable(32) %109, ptr noundef nonnull align 4 dereferenceable(12) %8) + to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit63 unwind label %43 + +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit63: ; preds = %118 %.not.i.i.i64 = icmp eq ptr %.sroa.0.091, null - br i1 %.not.i.i.i64, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit65, label %122 + br i1 %.not.i.i.i64, label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit65, label %120 -122: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit63 - %123 = ptrtoint ptr %.sroa.0.091 to i64 - %124 = sub i64 %.sroa.10.092, %123 - call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.091, i64 noundef %124) #12 +120: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit63 + %121 = ptrtoint ptr %.sroa.0.091 to i64 + %122 = sub i64 %.sroa.10.092, %121 + call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.091, i64 noundef %122) #12 br label %_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit65 -_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit65: ; preds = %122, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit63, %5 +_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit65: ; preds = %120, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3fEE5WriteERKS2_.exit63, %5 ret void -_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit: ; preds = %47, %45 - %.pn = phi { ptr, i32 } [ %46, %45 ], [ %48, %47 ] +_ZNSt6vectorISt5arrayIfLm2EESaIS1_EED2Ev.exit: ; preds = %45, %43 + %.pn = phi { ptr, i32 } [ %44, %43 ], [ %46, %45 ] resume { ptr, i32 } %.pn } @@ -306,236 +304,234 @@ define weak_odr void @_ZN32pxrInternal_v0_24__pxrReserved__27GeomUtilSphereMeshG %14 = fcmp ogt double %12, 0x401921FB54442D18 %..i = select i1 %14, double 0x401921FB54442D18, double %12 %.0.i = select i1 %13, double 0xC01921FB54442D18, double %..i - %15 = tail call double @llvm.fabs.f64(double %12) + %15 = tail call noundef double @llvm.fabs.f64(double %.0.i) %16 = fadd double %15, 0xC01921FB54442D18 %17 = tail call double @llvm.fabs.f64(double %16) %18 = fcmp olt double %17, 0x3EB0C6F7A0B5ED8D - %19 = or i1 %14, %18 - %20 = or i1 %13, %19 - %21 = tail call noundef i64 @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase23_ComputeNumRadialPointsEmb(i64 noundef %0, i1 noundef zeroext %20) - %22 = icmp ugt i64 %21, 576460752303423487 - br i1 %22, label %.noexc, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i + %19 = tail call noundef i64 @_ZN32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase23_ComputeNumRadialPointsEmb(i64 noundef %0, i1 noundef zeroext %18) + %20 = icmp ugt i64 %19, 576460752303423487 + br i1 %20, label %.noexc, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i .noexc: ; preds = %11 tail call void @_ZSt20__throw_length_errorPKc(ptr noundef nonnull @.str) #9 unreachable _ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i: ; preds = %11 - %.not.i.i.i.i = icmp eq i64 %21, 0 + %.not.i.i.i.i = icmp eq i64 %19, 0 br i1 %.not.i.i.i.i, label %._crit_edge, label %.noexc50 .noexc50: ; preds = %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i - %23 = shl nuw nsw i64 %21, 4 - %24 = tail call noalias noundef nonnull ptr @_Znwm(i64 noundef %23) #10 - %25 = getelementptr %"struct.std::array.5", ptr %24, i64 %21 - tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %24, i8 0, i64 16, i1 false) - %26 = icmp eq i64 %21, 1 - br i1 %26, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i.preheader + %21 = shl nuw nsw i64 %19, 4 + %22 = tail call noalias noundef nonnull ptr @_Znwm(i64 noundef %21) #10 + %23 = getelementptr %"struct.std::array.5", ptr %22, i64 %19 + tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %22, i8 0, i64 16, i1 false) + %24 = icmp eq i64 %19, 1 + br i1 %24, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i.preheader .lr.ph.i.i.i.i.i.i.i.i.i.preheader: ; preds = %.noexc50 - %27 = getelementptr inbounds nuw i8, ptr %24, i64 16 + %25 = getelementptr inbounds nuw i8, ptr %22, i64 16 br label %.lr.ph.i.i.i.i.i.i.i.i.i .lr.ph.i.i.i.i.i.i.i.i.i: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i.preheader, %.lr.ph.i.i.i.i.i.i.i.i.i - %.06.i.i.i.i.i.i.i.i.i = phi ptr [ %28, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %27, %.lr.ph.i.i.i.i.i.i.i.i.i.preheader ] - tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %.06.i.i.i.i.i.i.i.i.i, ptr noundef nonnull align 8 dereferenceable(16) %24, i64 16, i1 false) - %28 = getelementptr inbounds nuw i8, ptr %.06.i.i.i.i.i.i.i.i.i, i64 16 - %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %28, %25 + %.06.i.i.i.i.i.i.i.i.i = phi ptr [ %26, %.lr.ph.i.i.i.i.i.i.i.i.i ], [ %25, %.lr.ph.i.i.i.i.i.i.i.i.i.preheader ] + tail call void @llvm.memcpy.p0.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %.06.i.i.i.i.i.i.i.i.i, ptr noundef nonnull align 8 dereferenceable(16) %22, i64 16, i1 false) + %26 = getelementptr inbounds nuw i8, ptr %.06.i.i.i.i.i.i.i.i.i, i64 16 + %.not.i.i.i.i.i.i.i.i.i = icmp eq ptr %26, %23 br i1 %.not.i.i.i.i.i.i.i.i.i, label %.lr.ph, label %.lr.ph.i.i.i.i.i.i.i.i.i, !llvm.loop !10 .lr.ph: ; preds = %.lr.ph.i.i.i.i.i.i.i.i.i, %.noexc50 - %29 = uitofp i64 %0 to double - br label %30 - -30: ; preds = %.lr.ph, %30 - %.04476 = phi i64 [ 0, %.lr.ph ], [ %40, %30 ] - %31 = uitofp i64 %.04476 to double - %32 = fdiv double %31, %29 - %33 = fmul double %.0.i, %32 - %34 = tail call double @cos(double noundef %33) #11 - %35 = fmul double %2, %34 - %36 = getelementptr inbounds %"struct.std::array.5", ptr %24, i64 %.04476 - store double %35, ptr %36, align 8 - %37 = tail call double @sin(double noundef %33) #11 - %38 = fmul double %2, %37 - %39 = getelementptr inbounds nuw i8, ptr %36, i64 8 - store double %38, ptr %39, align 8 - %40 = add nuw i64 %.04476, 1 - %exitcond.not = icmp eq i64 %40, %21 - br i1 %exitcond.not, label %._crit_edge.loopexit, label %30, !llvm.loop !11 - -._crit_edge.loopexit: ; preds = %30 - %41 = ptrtoint ptr %25 to i64 + %27 = uitofp i64 %0 to double + br label %28 + +28: ; preds = %.lr.ph, %28 + %.04476 = phi i64 [ 0, %.lr.ph ], [ %38, %28 ] + %29 = uitofp i64 %.04476 to double + %30 = fdiv double %29, %27 + %31 = fmul double %.0.i, %30 + %32 = tail call double @cos(double noundef %31) #11 + %33 = fmul double %2, %32 + %34 = getelementptr inbounds %"struct.std::array.5", ptr %22, i64 %.04476 + store double %33, ptr %34, align 8 + %35 = tail call double @sin(double noundef %31) #11 + %36 = fmul double %2, %35 + %37 = getelementptr inbounds nuw i8, ptr %34, i64 8 + store double %36, ptr %37, align 8 + %38 = add nuw i64 %.04476, 1 + %exitcond.not = icmp eq i64 %38, %19 + br i1 %exitcond.not, label %._crit_edge.loopexit, label %28, !llvm.loop !11 + +._crit_edge.loopexit: ; preds = %28 + %39 = ptrtoint ptr %23 to i64 br label %._crit_edge ._crit_edge: ; preds = %._crit_edge.loopexit, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i - %.sroa.10.092 = phi i64 [ 0, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %41, %._crit_edge.loopexit ] - %.sroa.0.091 = phi ptr [ null, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %24, %._crit_edge.loopexit ] - %42 = fneg double %2 - %43 = getelementptr inbounds nuw i8, ptr %6, i64 16 + %.sroa.10.092 = phi i64 [ 0, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %39, %._crit_edge.loopexit ] + %.sroa.0.091 = phi ptr [ null, %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EE17_S_check_init_lenEmRKS2_.exit.i ], [ %22, %._crit_edge.loopexit ] + %40 = fneg double %2 + %41 = getelementptr inbounds nuw i8, ptr %6, i64 16 call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %6, i8 0, i64 16, i1 false) - store double %42, ptr %43, align 8 + store double %40, ptr %41, align 8 %.unpack.i = load i64, ptr %4, align 8 %.elt2.i = getelementptr inbounds nuw i8, ptr %4, i64 8 %.unpack3.i = load i64, ptr %.elt2.i, align 8 - %44 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i - %45 = and i64 %.unpack.i, 1 - %.not.i = icmp eq i64 %45, 0 - br i1 %.not.i, label %51, label %46 - -46: ; preds = %._crit_edge - %47 = load ptr, ptr %44, align 8 - %48 = getelementptr i8, ptr %47, i64 %.unpack.i - %49 = getelementptr i8, ptr %48, i64 -1 - %50 = load ptr, ptr %49, align 8, !nosanitize !7 - br label %53 - -51: ; preds = %._crit_edge - %52 = inttoptr i64 %.unpack.i to ptr - br label %53 - -53: ; preds = %51, %46 - %54 = phi ptr [ %50, %46 ], [ %52, %51 ] - invoke void %54(ptr noundef nonnull align 8 dereferenceable(32) %44, ptr noundef nonnull align 8 dereferenceable(24) %6) - to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader unwind label %94 - -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader: ; preds = %53 - %55 = icmp ugt i64 %1, 1 - br i1 %55, label %.lr.ph82, label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit._crit_edge + %42 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i + %43 = and i64 %.unpack.i, 1 + %.not.i = icmp eq i64 %43, 0 + br i1 %.not.i, label %49, label %44 + +44: ; preds = %._crit_edge + %45 = load ptr, ptr %42, align 8 + %46 = getelementptr i8, ptr %45, i64 %.unpack.i + %47 = getelementptr i8, ptr %46, i64 -1 + %48 = load ptr, ptr %47, align 8, !nosanitize !7 + br label %51 + +49: ; preds = %._crit_edge + %50 = inttoptr i64 %.unpack.i to ptr + br label %51 + +51: ; preds = %49, %44 + %52 = phi ptr [ %48, %44 ], [ %50, %49 ] + invoke void %52(ptr noundef nonnull align 8 dereferenceable(32) %42, ptr noundef nonnull align 8 dereferenceable(24) %6) + to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader unwind label %92 + +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader: ; preds = %51 + %53 = icmp ugt i64 %1, 1 + br i1 %53, label %.lr.ph82, label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit._crit_edge .lr.ph82: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader - %56 = uitofp i64 %1 to double - %57 = getelementptr inbounds nuw i8, ptr %7, i64 8 - %58 = getelementptr inbounds nuw i8, ptr %7, i64 16 + %54 = uitofp i64 %1 to double + %55 = getelementptr inbounds nuw i8, ptr %7, i64 8 + %56 = getelementptr inbounds nuw i8, ptr %7, i64 16 br i1 %.not.i.i.i.i, label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit, label %.lr.ph79.us .lr.ph79.us: ; preds = %.lr.ph82, %._crit_edge80.us - %.04581.us = phi i64 [ %85, %._crit_edge80.us ], [ 1, %.lr.ph82 ] - %59 = uitofp i64 %.04581.us to double - %60 = fdiv double %59, %56 - %61 = fadd double %60, -5.000000e-01 - %62 = fmul double %61, 0x400921FB54442D18 - %63 = call double @cos(double noundef %62) #11 - %64 = call double @sin(double noundef %62) #11 - %65 = fmul double %2, %64 - br label %66 - -66: ; preds = %.lr.ph79.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit57.us - %.077.us = phi i64 [ 0, %.lr.ph79.us ], [ %84, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit57.us ] - %67 = getelementptr inbounds %"struct.std::array.5", ptr %.sroa.0.091, i64 %.077.us - %68 = load double, ptr %67, align 8 - %69 = fmul double %63, %68 - %70 = getelementptr inbounds nuw i8, ptr %67, i64 8 - %71 = load double, ptr %70, align 8 - %72 = fmul double %63, %71 - store double %69, ptr %7, align 8 - store double %72, ptr %57, align 8 - store double %65, ptr %58, align 8 + %.04581.us = phi i64 [ %83, %._crit_edge80.us ], [ 1, %.lr.ph82 ] + %57 = uitofp i64 %.04581.us to double + %58 = fdiv double %57, %54 + %59 = fadd double %58, -5.000000e-01 + %60 = fmul double %59, 0x400921FB54442D18 + %61 = call double @cos(double noundef %60) #11 + %62 = call double @sin(double noundef %60) #11 + %63 = fmul double %2, %62 + br label %64 + +64: ; preds = %.lr.ph79.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit57.us + %.077.us = phi i64 [ 0, %.lr.ph79.us ], [ %82, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit57.us ] + %65 = getelementptr inbounds %"struct.std::array.5", ptr %.sroa.0.091, i64 %.077.us + %66 = load double, ptr %65, align 8 + %67 = fmul double %61, %66 + %68 = getelementptr inbounds nuw i8, ptr %65, i64 8 + %69 = load double, ptr %68, align 8 + %70 = fmul double %61, %69 + store double %67, ptr %7, align 8 + store double %70, ptr %55, align 8 + store double %63, ptr %56, align 8 %.unpack.i52.us = load i64, ptr %4, align 8 %.unpack3.i54.us = load i64, ptr %.elt2.i, align 8 - %73 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i54.us - %74 = and i64 %.unpack.i52.us, 1 - %.not.i55.us = icmp eq i64 %74, 0 - br i1 %.not.i55.us, label %80, label %75 - -75: ; preds = %66 - %76 = load ptr, ptr %73, align 8 - %77 = getelementptr i8, ptr %76, i64 %.unpack.i52.us - %78 = getelementptr i8, ptr %77, i64 -1 - %79 = load ptr, ptr %78, align 8, !nosanitize !7 - br label %82 - -80: ; preds = %66 - %81 = inttoptr i64 %.unpack.i52.us to ptr - br label %82 - -82: ; preds = %80, %75 - %83 = phi ptr [ %79, %75 ], [ %81, %80 ] - invoke void %83(ptr noundef nonnull align 8 dereferenceable(32) %73, ptr noundef nonnull align 8 dereferenceable(24) %7) + %71 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i54.us + %72 = and i64 %.unpack.i52.us, 1 + %.not.i55.us = icmp eq i64 %72, 0 + br i1 %.not.i55.us, label %78, label %73 + +73: ; preds = %64 + %74 = load ptr, ptr %71, align 8 + %75 = getelementptr i8, ptr %74, i64 %.unpack.i52.us + %76 = getelementptr i8, ptr %75, i64 -1 + %77 = load ptr, ptr %76, align 8, !nosanitize !7 + br label %80 + +78: ; preds = %64 + %79 = inttoptr i64 %.unpack.i52.us to ptr + br label %80 + +80: ; preds = %78, %73 + %81 = phi ptr [ %77, %73 ], [ %79, %78 ] + invoke void %81(ptr noundef nonnull align 8 dereferenceable(32) %71, ptr noundef nonnull align 8 dereferenceable(24) %7) to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit57.us unwind label %.thread.split.us -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit57.us: ; preds = %82 - %84 = add nuw i64 %.077.us, 1 - %exitcond86.not = icmp eq i64 %84, %21 - br i1 %exitcond86.not, label %._crit_edge80.us, label %66, !llvm.loop !12 +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit57.us: ; preds = %80 + %82 = add nuw i64 %.077.us, 1 + %exitcond86.not = icmp eq i64 %82, %19 + br i1 %exitcond86.not, label %._crit_edge80.us, label %64, !llvm.loop !12 ._crit_edge80.us: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit57.us - %85 = add nuw i64 %.04581.us, 1 - %exitcond87.not = icmp eq i64 %85, %1 + %83 = add nuw i64 %.04581.us, 1 + %exitcond87.not = icmp eq i64 %83, %1 br i1 %exitcond87.not, label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit._crit_edge, label %.lr.ph79.us, !llvm.loop !13 -.thread.split.us: ; preds = %82 - %86 = landingpad { ptr, i32 } +.thread.split.us: ; preds = %80 + %84 = landingpad { ptr, i32 } cleanup - br label %96 + br label %94 _ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit: ; preds = %.lr.ph82, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit - %.04581 = phi i64 [ %93, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit ], [ 1, %.lr.ph82 ] - %87 = uitofp i64 %.04581 to double - %88 = fdiv double %87, %56 - %89 = fadd double %88, -5.000000e-01 - %90 = fmul double %89, 0x400921FB54442D18 - %91 = call double @cos(double noundef %90) #11 - %92 = call double @sin(double noundef %90) #11 - %93 = add nuw i64 %.04581, 1 - %exitcond88.not = icmp eq i64 %93, %1 + %.04581 = phi i64 [ %91, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit ], [ 1, %.lr.ph82 ] + %85 = uitofp i64 %.04581 to double + %86 = fdiv double %85, %54 + %87 = fadd double %86, -5.000000e-01 + %88 = fmul double %87, 0x400921FB54442D18 + %89 = call double @cos(double noundef %88) #11 + %90 = call double @sin(double noundef %88) #11 + %91 = add nuw i64 %.04581, 1 + %exitcond88.not = icmp eq i64 %91, %1 br i1 %exitcond88.not, label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit._crit_edge, label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit, !llvm.loop !13 -94: ; preds = %110, %53 - %95 = landingpad { ptr, i32 } +92: ; preds = %108, %51 + %93 = landingpad { ptr, i32 } cleanup %.not.i.i.i = icmp eq ptr %.sroa.0.091, null - br i1 %.not.i.i.i, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit, label %96 + br i1 %.not.i.i.i, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit, label %94 -96: ; preds = %.thread.split.us, %94 - %97 = phi { ptr, i32 } [ %86, %.thread.split.us ], [ %95, %94 ] - %98 = ptrtoint ptr %.sroa.0.091 to i64 - %99 = sub i64 %.sroa.10.092, %98 - call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.091, i64 noundef %99) #12 +94: ; preds = %.thread.split.us, %92 + %95 = phi { ptr, i32 } [ %84, %.thread.split.us ], [ %93, %92 ] + %96 = ptrtoint ptr %.sroa.0.091 to i64 + %97 = sub i64 %.sroa.10.092, %96 + call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.091, i64 noundef %97) #12 br label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit _ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit._crit_edge: ; preds = %._crit_edge80.us, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit.preheader - %100 = getelementptr inbounds nuw i8, ptr %8, i64 16 + %98 = getelementptr inbounds nuw i8, ptr %8, i64 16 call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(16) %8, i8 0, i64 16, i1 false) - store double %2, ptr %100, align 8 + store double %2, ptr %98, align 8 %.unpack.i58 = load i64, ptr %4, align 8 %.unpack3.i60 = load i64, ptr %.elt2.i, align 8 - %101 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i60 - %102 = and i64 %.unpack.i58, 1 - %.not.i61 = icmp eq i64 %102, 0 - br i1 %.not.i61, label %108, label %103 - -103: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit._crit_edge - %104 = load ptr, ptr %101, align 8 - %105 = getelementptr i8, ptr %104, i64 %.unpack.i58 - %106 = getelementptr i8, ptr %105, i64 -1 - %107 = load ptr, ptr %106, align 8, !nosanitize !7 - br label %110 - -108: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit._crit_edge - %109 = inttoptr i64 %.unpack.i58 to ptr - br label %110 - -110: ; preds = %108, %103 - %111 = phi ptr [ %107, %103 ], [ %109, %108 ] - invoke void %111(ptr noundef nonnull align 8 dereferenceable(32) %101, ptr noundef nonnull align 8 dereferenceable(24) %8) - to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit63 unwind label %94 - -_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit63: ; preds = %110 + %99 = getelementptr inbounds i8, ptr %4, i64 %.unpack3.i60 + %100 = and i64 %.unpack.i58, 1 + %.not.i61 = icmp eq i64 %100, 0 + br i1 %.not.i61, label %106, label %101 + +101: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit._crit_edge + %102 = load ptr, ptr %99, align 8 + %103 = getelementptr i8, ptr %102, i64 %.unpack.i58 + %104 = getelementptr i8, ptr %103, i64 -1 + %105 = load ptr, ptr %104, align 8, !nosanitize !7 + br label %108 + +106: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit._crit_edge + %107 = inttoptr i64 %.unpack.i58 to ptr + br label %108 + +108: ; preds = %106, %101 + %109 = phi ptr [ %105, %101 ], [ %107, %106 ] + invoke void %109(ptr noundef nonnull align 8 dereferenceable(32) %99, ptr noundef nonnull align 8 dereferenceable(24) %8) + to label %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit63 unwind label %92 + +_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit63: ; preds = %108 %.not.i.i.i64 = icmp eq ptr %.sroa.0.091, null - br i1 %.not.i.i.i64, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit65, label %112 + br i1 %.not.i.i.i64, label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit65, label %110 -112: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit63 - %113 = ptrtoint ptr %.sroa.0.091 to i64 - %114 = sub i64 %.sroa.10.092, %113 - call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.091, i64 noundef %114) #12 +110: ; preds = %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit63 + %111 = ptrtoint ptr %.sroa.0.091 to i64 + %112 = sub i64 %.sroa.10.092, %111 + call void @_ZdlPvm(ptr noundef nonnull %.sroa.0.091, i64 noundef %112) #12 br label %_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit65 -_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit65: ; preds = %112, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit63, %5 +_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit65: ; preds = %110, %_ZNK32pxrInternal_v0_24__pxrReserved__25GeomUtilMeshGeneratorBase12_PointWriterINS_7GfVec3dEE5WriteERKS2_.exit63, %5 ret void -_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit: ; preds = %96, %94 - %.pn = phi { ptr, i32 } [ %95, %94 ], [ %97, %96 ] +_ZNSt6vectorISt5arrayIdLm2EESaIS1_EED2Ev.exit: ; preds = %94, %92 + %.pn = phi { ptr, i32 } [ %93, %92 ], [ %95, %94 ] resume { ptr, i32 } %.pn } diff --git a/bench/quantlib/optimized/blackformula.ll b/bench/quantlib/optimized/blackformula.ll index da28cf65cfc..586ffc61223 100644 --- a/bench/quantlib/optimized/blackformula.ll +++ b/bench/quantlib/optimized/blackformula.ll @@ -10803,11 +10803,7 @@ ehcleanup77: ; preds = %_ZNKSt7__cxx1112bas do.body81: ; preds = %do.end, %_ZN8QuantLib12close_enoughEdd.exit %or.cond189 = fcmp ult double %div35, -1.000000e+00 - br i1 %or.cond189, label %_ZN8QuantLib12close_enoughEdd.exit86, label %do.body81.do.end127_crit_edge - -do.body81.do.end127_crit_edge: ; preds = %do.body81 - %.pre = tail call double @llvm.fabs.f64(double %div35) - br label %do.end127 + br i1 %or.cond189, label %_ZN8QuantLib12close_enoughEdd.exit86, label %do.end127 _ZN8QuantLib12close_enoughEdd.exit86: ; preds = %do.body81 %sub.i77 = fadd double %div35, 1.000000e+00 @@ -10983,24 +10979,22 @@ ehcleanup123: ; preds = %_ZNKSt7__cxx1112bas call void @llvm.lifetime.end.p0(i64 376, ptr nonnull %_ql_msg_stream86) #26 br label %common.resume -do.end127: ; preds = %do.body81.do.end127_crit_edge, %_ZN8QuantLib12close_enoughEdd.exit86 - %.pre-phi = phi double [ %.pre, %do.body81.do.end127_crit_edge ], [ %50, %_ZN8QuantLib12close_enoughEdd.exit86 ] +do.end127: ; preds = %_ZN8QuantLib12close_enoughEdd.exit86, %do.body81 %cmp.i118 = fcmp ogt double %div35, 0x3FEFFFFFFFFFFFFE %.sroa.speculated129 = select i1 %cmp.i118, double 0x3FEFFFFFFFFFFFFE, double %div35 %cmp.i119 = fcmp ogt double %.sroa.speculated129, 0xBFEFFFFFFFFFFFFE %.sroa.speculated = select i1 %cmp.i119, double %.sroa.speculated129, double 0xBFEFFFFFFFFFFFFE - %73 = select i1 %cmp.i118, double 0x3FEFFFFFFFFFFFFE, double %.pre-phi - %74 = select i1 %cmp.i119, double %73, double 0x3FEFFFFFFFFFFFFE - %75 = load double, ptr @_ZZN8QuantLib35bachelierBlackFormulaImpliedVolChoiENS_6Option4TypeEdddddE15SQRT_QL_EPSILON, align 8, !tbaa !71 - %cmp135 = fcmp olt double %74, %75 + %73 = tail call double @llvm.fabs.f64(double %.sroa.speculated) + %74 = load double, ptr @_ZZN8QuantLib35bachelierBlackFormulaImpliedVolChoiENS_6Option4TypeEdddddE15SQRT_QL_EPSILON, align 8, !tbaa !71 + %cmp135 = fcmp olt double %73, %74 br i1 %cmp135, label %_ZN8QuantLibL1hEd.exit, label %cond.false cond.false: ; preds = %do.end127 %conv.i.i = fpext double %.sroa.speculated to x86_fp80 call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %ref.tmp.i.i) #26 %call.i.i121 = call noundef x86_fp80 @_ZN5boost4math6detail9atanh_impIeNS0_8policies6policyINS3_13promote_floatILb0EEENS3_14promote_doubleILb0EEENS3_14default_policyES9_S9_S9_S9_S9_S9_S9_S9_S9_S9_EEEET_SB_RKT0_(x86_fp80 noundef %conv.i.i, ptr noundef nonnull align 1 dereferenceable(1) %ref.tmp.i.i) - %76 = call noundef x86_fp80 @llvm.fabs.f80(x86_fp80 %call.i.i121) - %cmp.i.i.i122 = fcmp ogt x86_fp80 %76, 0xK43FEFFFFFFFFFFFFF800 + %75 = call noundef x86_fp80 @llvm.fabs.f80(x86_fp80 %call.i.i121) + %cmp.i.i.i122 = fcmp ogt x86_fp80 %75, 0xK43FEFFFFFFFFFFFFF800 br i1 %cmp.i.i.i122, label %if.then.i.i.i, label %cond.end if.then.i.i.i: ; preds = %cond.false @@ -11055,114 +11049,114 @@ invoke.cont16.i: ; preds = %invoke.cont14.i to label %unreachable.i unwind label %lpad15.i lpad.i: ; preds = %invoke.cont1.i, %invoke.cont.i, %if.then.i - %77 = landingpad { ptr, i32 } + %76 = landingpad { ptr, i32 } cleanup br label %ehcleanup26.i ehcleanup22.thread.i: ; preds = %invoke.cont3.i - %78 = landingpad { ptr, i32 } + %77 = landingpad { ptr, i32 } cleanup br label %cleanup.action.sink.split.i lpad13.i: ; preds = %invoke.cont11.i - %79 = landingpad { ptr, i32 } + %78 = landingpad { ptr, i32 } cleanup br label %ehcleanup.i lpad15.i: ; preds = %invoke.cont16.i, %invoke.cont14.i %cleanup.isactive.0.i = phi i1 [ false, %invoke.cont16.i ], [ true, %invoke.cont14.i ] - %80 = landingpad { ptr, i32 } + %79 = landingpad { ptr, i32 } cleanup - %81 = load ptr, ptr %ref.tmp12.i, align 8, !tbaa !10 - %82 = getelementptr inbounds nuw i8, ptr %ref.tmp12.i, i64 16 - %cmp.i.i.i.i = icmp eq ptr %81, %82 + %80 = load ptr, ptr %ref.tmp12.i, align 8, !tbaa !10 + %81 = getelementptr inbounds nuw i8, ptr %ref.tmp12.i, i64 16 + %cmp.i.i.i.i = icmp eq ptr %80, %81 br i1 %cmp.i.i.i.i, label %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i.i, label %if.then.i.i.i125 _ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i.i: ; preds = %lpad15.i %_M_string_length.i.i.i.i = getelementptr inbounds nuw i8, ptr %ref.tmp12.i, i64 8 - %83 = load i64, ptr %_M_string_length.i.i.i.i, align 8, !tbaa !13 - %cmp3.i.i.i.i = icmp ult i64 %83, 16 + %82 = load i64, ptr %_M_string_length.i.i.i.i, align 8, !tbaa !13 + %cmp3.i.i.i.i = icmp ult i64 %82, 16 call void @llvm.assume(i1 %cmp3.i.i.i.i) br label %ehcleanup.i if.then.i.i.i125: ; preds = %lpad15.i - %84 = load i64, ptr %82, align 8, !tbaa !12 - %add.i.i.i.i = add i64 %84, 1 - call void @_ZdlPvm(ptr noundef %81, i64 noundef %add.i.i.i.i) #29 + %83 = load i64, ptr %81, align 8, !tbaa !12 + %add.i.i.i.i = add i64 %83, 1 + call void @_ZdlPvm(ptr noundef %80, i64 noundef %add.i.i.i.i) #29 br label %ehcleanup.i ehcleanup.i: ; preds = %if.then.i.i.i125, %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i.i, %lpad13.i %cleanup.isactive.3.i = phi i1 [ true, %lpad13.i ], [ %cleanup.isactive.0.i, %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i.i ], [ %cleanup.isactive.0.i, %if.then.i.i.i125 ] - %.pn.i = phi { ptr, i32 } [ %79, %lpad13.i ], [ %80, %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i.i ], [ %80, %if.then.i.i.i125 ] + %.pn.i = phi { ptr, i32 } [ %78, %lpad13.i ], [ %79, %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i.i ], [ %79, %if.then.i.i.i125 ] call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %ref.tmp12.i) #26 - %85 = load ptr, ptr %ref.tmp8.i, align 8, !tbaa !10 - %86 = getelementptr inbounds nuw i8, ptr %ref.tmp8.i, i64 16 - %cmp.i.i.i28.i = icmp eq ptr %85, %86 + %84 = load ptr, ptr %ref.tmp8.i, align 8, !tbaa !10 + %85 = getelementptr inbounds nuw i8, ptr %ref.tmp8.i, i64 16 + %cmp.i.i.i28.i = icmp eq ptr %84, %85 br i1 %cmp.i.i.i28.i, label %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i31.i, label %if.then.i.i29.i _ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i31.i: ; preds = %ehcleanup.i %_M_string_length.i.i.i32.i = getelementptr inbounds nuw i8, ptr %ref.tmp8.i, i64 8 - %87 = load i64, ptr %_M_string_length.i.i.i32.i, align 8, !tbaa !13 - %cmp3.i.i.i33.i = icmp ult i64 %87, 16 + %86 = load i64, ptr %_M_string_length.i.i.i32.i, align 8, !tbaa !13 + %cmp3.i.i.i33.i = icmp ult i64 %86, 16 call void @llvm.assume(i1 %cmp3.i.i.i33.i) br label %ehcleanup18.i if.then.i.i29.i: ; preds = %ehcleanup.i - %88 = load i64, ptr %86, align 8, !tbaa !12 - %add.i.i.i30.i = add i64 %88, 1 - call void @_ZdlPvm(ptr noundef %85, i64 noundef %add.i.i.i30.i) #29 + %87 = load i64, ptr %85, align 8, !tbaa !12 + %add.i.i.i30.i = add i64 %87, 1 + call void @_ZdlPvm(ptr noundef %84, i64 noundef %add.i.i.i30.i) #29 br label %ehcleanup18.i ehcleanup18.i: ; preds = %if.then.i.i29.i, %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i31.i call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %ref.tmp9.i) #26 call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %ref.tmp8.i) #26 - %89 = load ptr, ptr %ref.tmp.i, align 8, !tbaa !10 - %90 = getelementptr inbounds nuw i8, ptr %ref.tmp.i, i64 16 - %cmp.i.i.i35.i = icmp eq ptr %89, %90 + %88 = load ptr, ptr %ref.tmp.i, align 8, !tbaa !10 + %89 = getelementptr inbounds nuw i8, ptr %ref.tmp.i, i64 16 + %cmp.i.i.i35.i = icmp eq ptr %88, %89 br i1 %cmp.i.i.i35.i, label %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i38.i, label %ehcleanup22.i ehcleanup18.thread.i: ; preds = %invoke.cont7.i - %91 = landingpad { ptr, i32 } + %90 = landingpad { ptr, i32 } cleanup call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %ref.tmp9.i) #26 call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %ref.tmp8.i) #26 - %92 = load ptr, ptr %ref.tmp.i, align 8, !tbaa !10 - %93 = getelementptr inbounds nuw i8, ptr %ref.tmp.i, i64 16 - %cmp.i.i.i3547.i = icmp eq ptr %92, %93 + %91 = load ptr, ptr %ref.tmp.i, align 8, !tbaa !10 + %92 = getelementptr inbounds nuw i8, ptr %ref.tmp.i, i64 16 + %cmp.i.i.i3547.i = icmp eq ptr %91, %92 br i1 %cmp.i.i.i3547.i, label %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i38.thread.i, label %ehcleanup22.thread56.i ehcleanup22.thread56.i: ; preds = %ehcleanup18.thread.i - %94 = load i64, ptr %93, align 8, !tbaa !12 - %add.i.i.i3759.i = add i64 %94, 1 - call void @_ZdlPvm(ptr noundef %92, i64 noundef %add.i.i.i3759.i) #29 + %93 = load i64, ptr %92, align 8, !tbaa !12 + %add.i.i.i3759.i = add i64 %93, 1 + call void @_ZdlPvm(ptr noundef %91, i64 noundef %add.i.i.i3759.i) #29 br label %cleanup.action.sink.split.i _ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i38.thread.i: ; preds = %ehcleanup18.thread.i %_M_string_length.i.i.i3954.i = getelementptr inbounds nuw i8, ptr %ref.tmp.i, i64 8 - %95 = load i64, ptr %_M_string_length.i.i.i3954.i, align 8, !tbaa !13 - %cmp3.i.i.i4055.i = icmp ult i64 %95, 16 + %94 = load i64, ptr %_M_string_length.i.i.i3954.i, align 8, !tbaa !13 + %cmp3.i.i.i4055.i = icmp ult i64 %94, 16 call void @llvm.assume(i1 %cmp3.i.i.i4055.i) br label %cleanup.action.sink.split.i _ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i38.i: ; preds = %ehcleanup18.i %_M_string_length.i.i.i39.i = getelementptr inbounds nuw i8, ptr %ref.tmp.i, i64 8 - %96 = load i64, ptr %_M_string_length.i.i.i39.i, align 8, !tbaa !13 - %cmp3.i.i.i40.i = icmp ult i64 %96, 16 + %95 = load i64, ptr %_M_string_length.i.i.i39.i, align 8, !tbaa !13 + %cmp3.i.i.i40.i = icmp ult i64 %95, 16 call void @llvm.assume(i1 %cmp3.i.i.i40.i) call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %ref.tmp5.i) #26 call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %ref.tmp.i) #26 br i1 %cleanup.isactive.3.i, label %cleanup.action.i, label %ehcleanup26.i ehcleanup22.i: ; preds = %ehcleanup18.i - %97 = load i64, ptr %90, align 8, !tbaa !12 - %add.i.i.i37.i = add i64 %97, 1 - call void @_ZdlPvm(ptr noundef %89, i64 noundef %add.i.i.i37.i) #29 + %96 = load i64, ptr %89, align 8, !tbaa !12 + %add.i.i.i37.i = add i64 %96, 1 + call void @_ZdlPvm(ptr noundef %88, i64 noundef %add.i.i.i37.i) #29 call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %ref.tmp5.i) #26 call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %ref.tmp.i) #26 br i1 %cleanup.isactive.3.i, label %cleanup.action.i, label %ehcleanup26.i cleanup.action.sink.split.i: ; preds = %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i38.thread.i, %ehcleanup22.thread56.i, %ehcleanup22.thread.i - %.pn.pn.pn44.ph.i = phi { ptr, i32 } [ %91, %ehcleanup22.thread56.i ], [ %91, %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i38.thread.i ], [ %78, %ehcleanup22.thread.i ] + %.pn.pn.pn44.ph.i = phi { ptr, i32 } [ %90, %ehcleanup22.thread56.i ], [ %90, %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i38.thread.i ], [ %77, %ehcleanup22.thread.i ] call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %ref.tmp5.i) #26 call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %ref.tmp.i) #26 br label %cleanup.action.i @@ -11177,7 +11171,7 @@ common.resume: ; preds = %ehcleanup28, %ehcle resume { ptr, i32 } %common.resume.op ehcleanup26.i: ; preds = %cleanup.action.i, %ehcleanup22.i, %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i38.i, %lpad.i - %.pn.pn.pn.pn.i = phi { ptr, i32 } [ %.pn.pn.pn44.i, %cleanup.action.i ], [ %.pn.i, %ehcleanup22.i ], [ %77, %lpad.i ], [ %.pn.i, %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i38.i ] + %.pn.pn.pn.pn.i = phi { ptr, i32 } [ %.pn.pn.pn44.i, %cleanup.action.i ], [ %.pn.i, %ehcleanup22.i ], [ %76, %lpad.i ], [ %.pn.i, %_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE11_M_is_localEv.exit.thread.i.i38.i ] call void @_ZNSt7__cxx1119basic_ostringstreamIcSt11char_traitsIcESaIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(112) %_ql_msg_stream.i) #26 call void @llvm.lifetime.end.p0(i64 376, ptr nonnull %_ql_msg_stream.i) #26 br label %common.resume @@ -11187,24 +11181,24 @@ unreachable.i: ; preds = %invoke.cont16.i _ZN8QuantLibL1hEd.exit: ; preds = %do.end127, %cond.end %cond143 = phi double [ %div137, %cond.end ], [ 1.000000e+00, %do.end127 ] - %98 = call double @llvm.fmuladd.f64(double %cond143, double 0x40C8BC4A4E440B07, double 0x40D85989C85A0509) - %99 = call double @llvm.fmuladd.f64(double %cond143, double %98, double 0x40B7DA5289526CFE) - %100 = call double @llvm.fmuladd.f64(double %cond143, double %99, double 0x409CE1F572B87D47) - %101 = call double @llvm.fmuladd.f64(double %cond143, double %100, double 0x4082B7024619CBC3) - %102 = call double @llvm.fmuladd.f64(double %cond143, double %101, double 0x4048E6D5E1F1349C) - %103 = call double @llvm.fmuladd.f64(double %cond143, double %102, double 0x40350275AAA9F939) - %104 = call double @llvm.fmuladd.f64(double %cond143, double %103, double 0x3FD9915860E5E3DD) - %105 = call double @llvm.fmuladd.f64(double %cond143, double 0x40277C1CA3691867, double 0xC069D8B3CDA26C76) - %106 = call double @llvm.fmuladd.f64(double %cond143, double %105, double 0x40AC31A25C07681E) - %107 = call double @llvm.fmuladd.f64(double %cond143, double %106, double 0x40D75C05B0D1CCE9) - %108 = call double @llvm.fmuladd.f64(double %cond143, double %107, double 0x40CF3A993689238F) - %109 = call double @llvm.fmuladd.f64(double %cond143, double %108, double 0x4094AE75496C561C) - %110 = call double @llvm.fmuladd.f64(double %cond143, double %109, double 0x40975C6B874C7632) - %111 = call double @llvm.fmuladd.f64(double %cond143, double %110, double 0x403EEF8C9D7CB246) - %112 = call double @llvm.fmuladd.f64(double %cond143, double %111, double 0x4048F3E23B403024) - %113 = call double @llvm.fmuladd.f64(double %cond143, double %112, double 1.000000e+00) + %97 = call double @llvm.fmuladd.f64(double %cond143, double 0x40C8BC4A4E440B07, double 0x40D85989C85A0509) + %98 = call double @llvm.fmuladd.f64(double %cond143, double %97, double 0x40B7DA5289526CFE) + %99 = call double @llvm.fmuladd.f64(double %cond143, double %98, double 0x409CE1F572B87D47) + %100 = call double @llvm.fmuladd.f64(double %cond143, double %99, double 0x4082B7024619CBC3) + %101 = call double @llvm.fmuladd.f64(double %cond143, double %100, double 0x4048E6D5E1F1349C) + %102 = call double @llvm.fmuladd.f64(double %cond143, double %101, double 0x40350275AAA9F939) + %103 = call double @llvm.fmuladd.f64(double %cond143, double %102, double 0x3FD9915860E5E3DD) + %104 = call double @llvm.fmuladd.f64(double %cond143, double 0x40277C1CA3691867, double 0xC069D8B3CDA26C76) + %105 = call double @llvm.fmuladd.f64(double %cond143, double %104, double 0x40AC31A25C07681E) + %106 = call double @llvm.fmuladd.f64(double %cond143, double %105, double 0x40D75C05B0D1CCE9) + %107 = call double @llvm.fmuladd.f64(double %cond143, double %106, double 0x40CF3A993689238F) + %108 = call double @llvm.fmuladd.f64(double %cond143, double %107, double 0x4094AE75496C561C) + %109 = call double @llvm.fmuladd.f64(double %cond143, double %108, double 0x40975C6B874C7632) + %110 = call double @llvm.fmuladd.f64(double %cond143, double %109, double 0x403EEF8C9D7CB246) + %111 = call double @llvm.fmuladd.f64(double %cond143, double %110, double 0x4048F3E23B403024) + %112 = call double @llvm.fmuladd.f64(double %cond143, double %111, double 1.000000e+00) %call28.i = call double @sqrt(double noundef %cond143) #26, !tbaa !18 - %div.i = fdiv double %104, %113 + %div.i = fdiv double %103, %112 %mul.i124 = fmul double %call28.i, %div.i %mul = fmul double %tte, 2.000000e+00 %div139 = fdiv double 0x400921FB54442D18, %mul diff --git a/bench/quantlib/optimized/lmdif.ll b/bench/quantlib/optimized/lmdif.ll index c2a6e8a43e8..c90f69248c9 100644 --- a/bench/quantlib/optimized/lmdif.ll +++ b/bench/quantlib/optimized/lmdif.ll @@ -3559,9 +3559,8 @@ if.end332: ; preds = %_ZN8QuantLib7MINPAC %fnorm.2 = phi double [ %retval.0.i505, %_ZN8QuantLib7MINPACK5enormEiPd.exit711 ], [ %fnorm.1, %if.end300 ] %iter.2 = phi i32 [ %add331, %_ZN8QuantLib7MINPACK5enormEiPd.exit711 ], [ %iter.1, %if.end300 ] %xnorm.3 = phi double [ %retval.0.i649, %_ZN8QuantLib7MINPACK5enormEiPd.exit711 ], [ %xnorm.2, %if.end300 ] - %109 = call double @llvm.fabs.f64(double %78) - %110 = select i1 %cmp228, double %109, double 1.000000e+00 - %cmp333 = fcmp ugt double %110, %ftol + %109 = call double @llvm.fabs.f64(double %actred.0) + %cmp333 = fcmp ugt double %109, %ftol %cmp334 = fcmp ugt double %94, %ftol %or.cond308 = or i1 %cmp333, %cmp334 %mul336 = fmul double %ratio.0, 5.000000e-01 @@ -3570,26 +3569,26 @@ if.end332: ; preds = %_ZN8QuantLib7MINPAC %mul340 = fmul double %xtol, %xnorm.3 %cmp341 = fcmp ugt double %delta.4, %mul340 %.not = and i1 %or.cond309, %cmp341 - br i1 %.not, label %112, label %111 + br i1 %.not, label %111, label %110 -111: ; preds = %if.end332 +110: ; preds = %if.end332 %simplifycfg.merge = select i1 %cmp341, i32 1, i32 2 store i32 %simplifycfg.merge, ptr %info, align 4, !tbaa !9 - br label %112 + br label %111 -112: ; preds = %if.end332, %111 +111: ; preds = %if.end332, %110 %.pr724 = load i32, ptr %info, align 4, !tbaa !9 %cmp351 = icmp ne i32 %.pr724, 2 %or.cond.not = select i1 %or.cond309, i1 true, i1 %cmp351 br i1 %or.cond.not, label %if.end353, label %L300.sink.split -if.end353: ; preds = %112 +if.end353: ; preds = %111 %cmp354.not = icmp eq i32 %.pr724, 0 br i1 %cmp354.not, label %if.end356, label %L300 if.end356: ; preds = %if.end353 - %113 = load i32, ptr %nfev, align 4, !tbaa !9 - %cmp357.not = icmp slt i32 %113, %maxfev + %112 = load i32, ptr %nfev, align 4, !tbaa !9 + %cmp357.not = icmp slt i32 %112, %maxfev br i1 %cmp357.not, label %if.end359, label %if.then358 if.then358: ; preds = %if.end356 @@ -3597,35 +3596,35 @@ if.then358: ; preds = %if.end356 br label %if.end359 if.end359: ; preds = %if.then358, %if.end356 - %114 = load double, ptr @_ZN8QuantLib7MINPACK6MACHEPE, align 8, !tbaa !3 - %cmp360 = fcmp ugt double %110, %114 - %cmp362 = fcmp ugt double %94, %114 + %113 = load double, ptr @_ZN8QuantLib7MINPACK6MACHEPE, align 8, !tbaa !3 + %cmp360 = fcmp ugt double %109, %113 + %cmp362 = fcmp ugt double %94, %113 %or.cond313 = or i1 %cmp360, %cmp362 %or.cond314 = or i1 %cmp337, %or.cond313 - %mul368 = fmul double %xnorm.3, %114 + %mul368 = fmul double %xnorm.3, %113 %cmp369 = fcmp ugt double %delta.4, %mul368 %.not732 = and i1 %cmp369, %or.cond314 - br i1 %.not732, label %115, label %.thread + br i1 %.not732, label %114, label %.thread -115: ; preds = %if.end359 - %cmp372 = fcmp ugt double %gnorm.0, %114 +114: ; preds = %if.end359 + %cmp372 = fcmp ugt double %gnorm.0, %113 br i1 %cmp372, label %if.end374, label %L300.sink.split .thread: ; preds = %if.end359 %simplifycfg.merge730 = select i1 %cmp369, i32 6, i32 7 store i32 %simplifycfg.merge730, ptr %info, align 4, !tbaa !9 - %cmp372933 = fcmp ugt double %gnorm.0, %114 + %cmp372933 = fcmp ugt double %gnorm.0, %113 br i1 %cmp372933, label %L300, label %L300.sink.split -if.end374: ; preds = %115 +if.end374: ; preds = %114 br i1 %cmp357.not, label %if.end377, label %L300 if.end377: ; preds = %if.end374 %cmp378 = fcmp olt double %ratio.0, 1.000000e-04 br i1 %cmp378, label %L200, label %L30 -L300.sink.split: ; preds = %if.end168, %115, %112, %.thread - %.sink = phi i32 [ 8, %.thread ], [ 3, %112 ], [ 8, %115 ], [ 4, %if.end168 ] +L300.sink.split: ; preds = %if.end168, %114, %111, %.thread + %.sink = phi i32 [ 8, %.thread ], [ 3, %111 ], [ 8, %114 ], [ 4, %if.end168 ] store i32 %.sink, ptr %info, align 4, !tbaa !9 br label %L300 @@ -3635,8 +3634,8 @@ L300: ; preds = %for.body, %if.end17 br i1 %cmp381, label %if.then382, label %if.end383 if.then382: ; preds = %if.end26, %_ZNKSt8functionIFviiPdS0_PiEEclEiiS0_S0_S1_.exit339, %_ZNKSt8functionIFviiPdS0_PiEEclEiiS0_S0_S1_.exit496, %_ZNKSt8functionIFviiPdS0_PiEEclEiiS0_S0_S1_.exit, %L300 - %116 = phi i32 [ %.pr728, %L300 ], [ %3, %_ZNKSt8functionIFviiPdS0_PiEEclEiiS0_S0_S1_.exit ], [ %68, %_ZNKSt8functionIFviiPdS0_PiEEclEiiS0_S0_S1_.exit496 ], [ %21, %_ZNKSt8functionIFviiPdS0_PiEEclEiiS0_S0_S1_.exit339 ], [ %18, %if.end26 ] - store i32 %116, ptr %info, align 4, !tbaa !9 + %115 = phi i32 [ %.pr728, %L300 ], [ %3, %_ZNKSt8functionIFviiPdS0_PiEEclEiiS0_S0_S1_.exit ], [ %68, %_ZNKSt8functionIFviiPdS0_PiEEclEiiS0_S0_S1_.exit496 ], [ %21, %_ZNKSt8functionIFviiPdS0_PiEEclEiiS0_S0_S1_.exit339 ], [ %18, %if.end26 ] + store i32 %115, ptr %info, align 4, !tbaa !9 br label %if.end383 if.end383: ; preds = %if.then382, %L300 @@ -3656,8 +3655,8 @@ if.then385: ; preds = %if.end383 store ptr %fvec, ptr %__args.addr6.i715, align 8, !tbaa !11 store ptr %iflag, ptr %__args.addr8.i716, align 8, !tbaa !11 %_M_manager.i.i717 = getelementptr inbounds nuw i8, ptr %fcn, i64 16 - %117 = load ptr, ptr %_M_manager.i.i717, align 8, !tbaa !13 - %tobool.not.i.i718 = icmp eq ptr %117, null + %116 = load ptr, ptr %_M_manager.i.i717, align 8, !tbaa !13 + %tobool.not.i.i718 = icmp eq ptr %116, null br i1 %tobool.not.i.i718, label %if.then.i721, label %_ZNKSt8functionIFviiPdS0_PiEEclEiiS0_S0_S1_.exit722 if.then.i721: ; preds = %if.then385 @@ -3666,8 +3665,8 @@ if.then.i721: ; preds = %if.then385 _ZNKSt8functionIFviiPdS0_PiEEclEiiS0_S0_S1_.exit722: ; preds = %if.then385 %_M_invoker.i720 = getelementptr inbounds nuw i8, ptr %fcn, i64 24 - %118 = load ptr, ptr %_M_invoker.i720, align 8, !tbaa !15 - call void %118(ptr noundef nonnull align 8 dereferenceable(32) %fcn, ptr noundef nonnull align 4 dereferenceable(4) %__args.addr.i712, ptr noundef nonnull align 4 dereferenceable(4) %__args.addr2.i713, ptr noundef nonnull align 8 dereferenceable(8) %__args.addr4.i714, ptr noundef nonnull align 8 dereferenceable(8) %__args.addr6.i715, ptr noundef nonnull align 8 dereferenceable(8) %__args.addr8.i716) + %117 = load ptr, ptr %_M_invoker.i720, align 8, !tbaa !15 + call void %117(ptr noundef nonnull align 8 dereferenceable(32) %fcn, ptr noundef nonnull align 4 dereferenceable(4) %__args.addr.i712, ptr noundef nonnull align 4 dereferenceable(4) %__args.addr2.i713, ptr noundef nonnull align 8 dereferenceable(8) %__args.addr4.i714, ptr noundef nonnull align 8 dereferenceable(8) %__args.addr6.i715, ptr noundef nonnull align 8 dereferenceable(8) %__args.addr8.i716) call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %__args.addr.i712) call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %__args.addr2.i713) call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %__args.addr4.i714) diff --git a/bench/quantlib/optimized/noarbsabr.ll b/bench/quantlib/optimized/noarbsabr.ll index 09d04be9e99..4c0ac0df9b8 100644 --- a/bench/quantlib/optimized/noarbsabr.ll +++ b/bench/quantlib/optimized/noarbsabr.ll @@ -11076,12 +11076,12 @@ if.end: ; preds = %entry store i64 %1, ptr %count, align 8, !tbaa !43 %invert.i = getelementptr inbounds nuw i8, ptr %f, i64 16 %p.i = getelementptr inbounds nuw i8, ptr %f, i64 8 - %.pre152 = load double, ptr %f, align 8, !tbaa !147, !noalias !149 + %.pre151 = load double, ptr %f, align 8, !tbaa !147, !noalias !149 br label %do.body do.body: ; preds = %land.rhs, %if.end - %agg.tmp.sroa.0.0.copyload153 = phi double [ %.pre152, %if.end ], [ %agg.tmp.sroa.0.0.copyload154, %land.rhs ] - %2 = phi double [ %.pre152, %if.end ], [ %35, %land.rhs ] + %agg.tmp.sroa.0.0.copyload152 = phi double [ %.pre151, %if.end ], [ %agg.tmp.sroa.0.0.copyload153, %land.rhs ] + %2 = phi double [ %.pre151, %if.end ], [ %35, %land.rhs ] %delta.0 = phi double [ %.sroa.speculated, %if.end ], [ %delta.5135, %land.rhs ] %3 = phi double [ %guess, %if.end ], [ %result.5136, %land.rhs ] %max_range_f.0 = phi double [ 0.000000e+00, %if.end ], [ %max_range_f.1137, %land.rhs ] @@ -11168,7 +11168,7 @@ if.end11: ; preds = %try.cont if.then13: ; preds = %try.cont.thread, %if.end11 %17 = phi double [ %.pr, %try.cont.thread ], [ %sub24.i, %if.end11 ] - %agg.tmp.sroa.0.0.copyload = phi double [ %.pre, %try.cont.thread ], [ %agg.tmp.sroa.0.0.copyload153, %if.end11 ] + %agg.tmp.sroa.0.0.copyload = phi double [ %.pre, %try.cont.thread ], [ %agg.tmp.sroa.0.0.copyload152, %if.end11 ] %18 = phi double [ %.pre, %try.cont.thread ], [ %2, %if.end11 ] %cmp.i33 = fcmp oeq double %4, 0.000000e+00 br i1 %cmp.i33, label %if.then.i35, label %_ZN5boost4math5tools6detail22handle_zero_derivativeINS0_6detail20gamma_p_inverse_funcIdNS0_8policies6policyINS6_14default_policyES8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_EEEEdEEvT_RT0_RKSC_SD_SD_SD_SF_SF_.exit @@ -11192,11 +11192,11 @@ if.then.i35: ; preds = %if.then13 %sub24.i.i = fsub double %conv3.i.i, %agg.tmp.sroa.2.0.copyload call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %ft.i.i) #32, !noalias !154 %sub.i36 = fsub double %storemerge.i, %3 - %.pre156 = load double, ptr %f0, align 8, !tbaa !52 + %.pre155 = load double, ptr %f0, align 8, !tbaa !52 br label %_ZN5boost4math5tools6detail22handle_zero_derivativeINS0_6detail20gamma_p_inverse_funcIdNS0_8policies6policyINS6_14default_policyES8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_EEEEdEEvT_RT0_RKSC_SD_SD_SD_SF_SF_.exit _ZN5boost4math5tools6detail22handle_zero_derivativeINS0_6detail20gamma_p_inverse_funcIdNS0_8policies6policyINS6_14default_policyES8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_EEEEdEEvT_RT0_RKSC_SD_SD_SD_SF_SF_.exit: ; preds = %if.then13, %if.then.i35 - %21 = phi double [ %.pre156, %if.then.i35 ], [ %17, %if.then13 ] + %21 = phi double [ %.pre155, %if.then.i35 ], [ %17, %if.then13 ] %22 = phi double [ %agg.tmp.sroa.0.0.copyload, %if.then.i35 ], [ %18, %if.then13 ] %delta.8 = phi double [ %sub.i36, %if.then.i35 ], [ %delta.0, %if.then13 ] %23 = phi double [ %sub24.i.i, %if.then.i35 ], [ %4, %if.then13 ] @@ -11276,7 +11276,7 @@ if.else30: ; preds = %if.else br label %if.end33 if.end33: ; preds = %if.else30, %if.then19, %if.then23, %_ZN5boost4math5tools6detail11halley_step4stepIdEET_RKS5_S7_S7_S7_.exit, %_ZN5boost4math5tools6detail22handle_zero_derivativeINS0_6detail20gamma_p_inverse_funcIdNS0_8policies6policyINS6_14default_policyES8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_EEEEdEEvT_RT0_RKSC_SD_SD_SD_SF_SF_.exit - %agg.tmp.sroa.0.0.copyload154 = phi double [ %agg.tmp.sroa.0.0.copyload, %_ZN5boost4math5tools6detail22handle_zero_derivativeINS0_6detail20gamma_p_inverse_funcIdNS0_8policies6policyINS6_14default_policyES8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_EEEEdEEvT_RT0_RKSC_SD_SD_SD_SF_SF_.exit ], [ %agg.tmp.sroa.0.0.copyload153, %if.then23 ], [ %agg.tmp.sroa.0.0.copyload153, %if.then19 ], [ %agg.tmp.sroa.0.0.copyload153, %_ZN5boost4math5tools6detail11halley_step4stepIdEET_RKS5_S7_S7_S7_.exit ], [ %agg.tmp.sroa.0.0.copyload153, %if.else30 ] + %agg.tmp.sroa.0.0.copyload153 = phi double [ %agg.tmp.sroa.0.0.copyload, %_ZN5boost4math5tools6detail22handle_zero_derivativeINS0_6detail20gamma_p_inverse_funcIdNS0_8policies6policyINS6_14default_policyES8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_EEEEdEEvT_RT0_RKSC_SD_SD_SD_SF_SF_.exit ], [ %agg.tmp.sroa.0.0.copyload152, %if.then23 ], [ %agg.tmp.sroa.0.0.copyload152, %if.then19 ], [ %agg.tmp.sroa.0.0.copyload152, %_ZN5boost4math5tools6detail11halley_step4stepIdEET_RKS5_S7_S7_S7_.exit ], [ %agg.tmp.sroa.0.0.copyload152, %if.else30 ] %35 = phi double [ %22, %_ZN5boost4math5tools6detail22handle_zero_derivativeINS0_6detail20gamma_p_inverse_funcIdNS0_8policies6policyINS6_14default_policyES8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_EEEEdEEvT_RT0_RKSC_SD_SD_SD_SF_SF_.exit ], [ %2, %if.then23 ], [ %2, %if.then19 ], [ %2, %_ZN5boost4math5tools6detail11halley_step4stepIdEET_RKS5_S7_S7_S7_.exit ], [ %2, %if.else30 ] %delta.1 = phi double [ %div18.i, %_ZN5boost4math5tools6detail22handle_zero_derivativeINS0_6detail20gamma_p_inverse_funcIdNS0_8policies6policyINS6_14default_policyES8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_EEEEdEEvT_RT0_RKSC_SD_SD_SD_SF_SF_.exit ], [ %mul27, %if.then23 ], [ %div20, %if.then19 ], [ %delta.0.i, %_ZN5boost4math5tools6detail11halley_step4stepIdEET_RKS5_S7_S7_S7_.exit ], [ %div31, %if.else30 ] %36 = call double @llvm.fabs.f64(double %delta1.0) @@ -11487,20 +11487,19 @@ if.else146: ; preds = %if.end82 if.then148: ; preds = %if.else146 %66 = call double @llvm.fabs.f64(double %65) - %cmp150 = fcmp uge double %66, 1.000000e+00 + %cmp150 = fcmp olt double %66, 1.000000e+00 %67 = call double @llvm.fabs.f64(double %sub83) - %cmp152 = fcmp ule double %67, 1.000000e+00 - %or.cond29.not151 = or i1 %cmp152, %cmp150 + %cmp152 = fcmp ogt double %67, 1.000000e+00 + %or.cond29 = and i1 %cmp152, %cmp150 %div155 = fdiv double 0x7FEFFFFFFFFFFFFF, %67 - %cmp156 = fcmp uge double %div155, %66 - %or.cond150.not = or i1 %cmp156, %or.cond29.not151 + %cmp156 = fcmp olt double %div155, %66 + %or.cond150 = and i1 %cmp156, %or.cond29 %div159 = fdiv double %sub83, %65 - %68 = call double @llvm.fabs.f64(double %div159) - %69 = fcmp olt double %68, 1.000000e+00 - %70 = fdiv double 1.000000e+00, %div159 - %div164 = select i1 %or.cond150.not, double %70, double 1.000000e-03 - %cond161 = select i1 %69, double %div164, double %div159 - %diff149.0 = select i1 %or.cond150.not, double %cond161, double 1.000000e+03 + %cond161 = select i1 %or.cond150, double 1.000000e+03, double %div159 + %68 = call double @llvm.fabs.f64(double %cond161) + %cmp162 = fcmp olt double %68, 1.000000e+00 + %div164 = fdiv double 1.000000e+00, %cond161 + %diff149.0 = select i1 %cmp162, double %div164, double %cond161 %loadedv166 = trunc nuw i8 %out_of_bounds_sentry.0 to i1 %cmp168 = fcmp ule double %diff149.0, 0.000000e+00 %cmp170 = fcmp uge double %diff149.0, 3.000000e+00 @@ -11520,28 +11519,28 @@ if.else175: ; preds = %if.then148 call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %ref.tmp2.i.i52) #32 call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %ref.tmp.i.i51) #32 call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %ref.tmp.i54) #32 - %71 = call double @llvm.fabs.f64(double %call6.i.i55) - %cmp177 = fcmp olt double %71, 2.000000e+00 + %69 = call double @llvm.fabs.f64(double %call6.i.i55) + %cmp177 = fcmp olt double %69, 2.000000e+00 br i1 %cmp177, label %if.then178, label %if.end181 if.then178: ; preds = %if.else175 - %72 = load double, ptr %min.addr, align 8, !tbaa !52 - %73 = load double, ptr %max.addr, align 8, !tbaa !52 - %add179 = fadd double %72, %73 + %70 = load double, ptr %min.addr, align 8, !tbaa !52 + %71 = load double, ptr %max.addr, align 8, !tbaa !52 + %add179 = fadd double %70, %71 %div180 = fmul double %add179, 5.000000e-01 br label %do.end if.end181: ; preds = %if.else175 %call183 = call noundef double @_ZN5boost4math5tools6detail24bracket_root_towards_maxINS0_6detail20gamma_p_inverse_funcIdNS0_8policies6policyINS6_14default_policyES8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_S8_EEEEdEET0_T_SB_RKSB_RSB_SF_Rm(ptr noundef nonnull byval(%"struct.boost::math::detail::gamma_p_inverse_func") align 8 %f, double noundef %3, ptr noundef nonnull align 8 dereferenceable(8) %f0, ptr noundef nonnull align 8 dereferenceable(8) %min.addr, ptr noundef nonnull align 8 dereferenceable(8) %max.addr, ptr noundef nonnull align 8 dereferenceable(8) %count) %sub184 = fsub double %3, %call183 - %74 = load double, ptr %max.addr, align 8, !tbaa !52 - %cmp185 = fcmp ult double %sub184, %74 + %72 = load double, ptr %max.addr, align 8, !tbaa !52 + %cmp185 = fcmp ult double %sub184, %72 br i1 %cmp185, label %if.end188, label %if.then186 if.then186: ; preds = %if.end181 call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %ref.tmp.i58) #32 call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %ref.tmp.i.i56) #32 - store double %74, ptr %ref.tmp.i.i56, align 8, !tbaa !52 + store double %72, ptr %ref.tmp.i.i56, align 8, !tbaa !52 call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %ref.tmp2.i.i57) #32 %call3.i.i59 = call noundef double @_ZN5boost4math6detail15float_prior_impIdNS0_8policies6policyINS3_14default_policyES5_S5_S5_S5_S5_S5_S5_S5_S5_S5_S5_S5_EEEET_RKS7_RKSt17integral_constantIbLb1EERKT0_(ptr noundef nonnull align 8 dereferenceable(8) %ref.tmp.i.i56, ptr noundef nonnull align 1 dereferenceable(1) %ref.tmp2.i.i57, ptr noundef nonnull align 1 dereferenceable(1) %ref.tmp.i58) call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %ref.tmp2.i.i57) #32 @@ -11551,20 +11550,20 @@ if.then186: ; preds = %if.end181 if.end188: ; preds = %if.then186, %if.end181 %result.8 = phi double [ %sub184, %if.end181 ], [ %call3.i.i59, %if.then186 ] - %75 = load double, ptr %min.addr, align 8, !tbaa !52 - %cmp189 = fcmp ugt double %result.8, %75 + %73 = load double, ptr %min.addr, align 8, !tbaa !52 + %cmp189 = fcmp ugt double %result.8, %73 br i1 %cmp189, label %do.cond.sink.split, label %if.then190 if.then190: ; preds = %if.end188 call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %ref.tmp.i62) #32 call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %ref.tmp.i.i60) #32 - store double %75, ptr %ref.tmp.i.i60, align 8, !tbaa !52 + store double %73, ptr %ref.tmp.i.i60, align 8, !tbaa !52 call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %ref.tmp2.i.i61) #32 %call3.i.i63 = call noundef double @_ZN5boost4math6detail14float_next_impIdNS0_8policies6policyINS3_14default_policyES5_S5_S5_S5_S5_S5_S5_S5_S5_S5_S5_S5_EEEET_RKS7_RKSt17integral_constantIbLb1EERKT0_(ptr noundef nonnull align 8 dereferenceable(8) %ref.tmp.i.i60, ptr noundef nonnull align 1 dereferenceable(1) %ref.tmp2.i.i61, ptr noundef nonnull align 1 dereferenceable(1) %ref.tmp.i62) call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %ref.tmp2.i.i61) #32 call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %ref.tmp.i.i60) #32 call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %ref.tmp.i62) #32 - %.pre157 = load double, ptr %min.addr, align 8, !tbaa !52 + %.pre156 = load double, ptr %min.addr, align 8, !tbaa !52 br label %do.cond.sink.split cleanup194: ; preds = %if.then148 @@ -11582,28 +11581,28 @@ if.end198: ; preds = %cleanup194, %cleanu if.then200: ; preds = %if.end198 store double %3, ptr %max.addr, align 8, !tbaa !52 - %76 = load double, ptr %f0, align 8, !tbaa !52 + %74 = load double, ptr %f0, align 8, !tbaa !52 br label %if.end202 if.else201: ; preds = %if.end198 store double %3, ptr %min.addr, align 8, !tbaa !52 - %77 = load double, ptr %f0, align 8, !tbaa !52 + %75 = load double, ptr %f0, align 8, !tbaa !52 br label %if.end202 if.end202: ; preds = %if.else201, %if.then200 - %max_range_f.2 = phi double [ %76, %if.then200 ], [ %max_range_f.0, %if.else201 ] - %min_range_f.2 = phi double [ %min_range_f.0, %if.then200 ], [ %77, %if.else201 ] + %max_range_f.2 = phi double [ %74, %if.then200 ], [ %max_range_f.0, %if.else201 ] + %min_range_f.2 = phi double [ %min_range_f.0, %if.then200 ], [ %75, %if.else201 ] %mul203 = fmul double %max_range_f.2, %min_range_f.2 %cmp204 = fcmp ogt double %mul203, 0.000000e+00 br i1 %cmp204, label %cleanup209.thread, label %do.cond cleanup209.thread: ; preds = %if.end202 - %78 = load ptr, ptr @_ZZN5boost4math5tools6detail24second_order_root_finderINS2_11halley_stepENS0_6detail20gamma_p_inverse_funcIdNS0_8policies6policyINS7_14default_policyES9_S9_S9_S9_S9_S9_S9_S9_S9_S9_S9_S9_EEEEdEET1_T0_SC_SC_SC_iRmE8function, align 8, !tbaa !33 - call void @_ZN5boost4math8policies6detail11raise_errorINS0_16evaluation_errorEdEEvPKcS6_RKT0_(ptr noundef %78, ptr noundef nonnull @.str.83, ptr noundef nonnull align 8 dereferenceable(8) %guess.addr) + %76 = load ptr, ptr @_ZZN5boost4math5tools6detail24second_order_root_finderINS2_11halley_stepENS0_6detail20gamma_p_inverse_funcIdNS0_8policies6policyINS7_14default_policyES9_S9_S9_S9_S9_S9_S9_S9_S9_S9_S9_S9_EEEEdEET1_T0_SC_SC_SC_iRmE8function, align 8, !tbaa !33 + call void @_ZN5boost4math8policies6detail11raise_errorINS0_16evaluation_errorEdEEvPKcS6_RKT0_(ptr noundef %76, ptr noundef nonnull @.str.83, ptr noundef nonnull align 8 dereferenceable(8) %guess.addr) br label %cleanup215 do.cond.sink.split: ; preds = %if.end188, %if.then190, %if.end144 - %.sink = phi double [ %64, %if.end144 ], [ %75, %if.end188 ], [ %.pre157, %if.then190 ] + %.sink = phi double [ %64, %if.end144 ], [ %73, %if.end188 ], [ %.pre156, %if.then190 ] %result.5136.ph = phi double [ %result.4, %if.end144 ], [ %result.8, %if.end188 ], [ %call3.i.i63, %if.then190 ] %delta.5135.ph = phi double [ %call135, %if.end144 ], [ %call183, %if.end188 ], [ %call183, %if.then190 ] store double %.sink, ptr %guess.addr, align 8, !tbaa !52 @@ -11615,22 +11614,22 @@ do.cond: ; preds = %do.cond.sink.split, %max_range_f.1137 = phi double [ %max_range_f.2, %if.end202 ], [ %max_range_f.0, %do.cond.sink.split ] %result.5136 = phi double [ %result.6, %if.end202 ], [ %result.5136.ph, %do.cond.sink.split ] %delta.5135 = phi double [ %delta.6, %if.end202 ], [ %delta.5135.ph, %do.cond.sink.split ] - %79 = load i64, ptr %count, align 8, !tbaa !43 - %tobool.not = icmp eq i64 %79, 0 + %77 = load i64, ptr %count, align 8, !tbaa !43 + %tobool.not = icmp eq i64 %77, 0 br i1 %tobool.not, label %do.end, label %land.rhs land.rhs: ; preds = %do.cond %mul212 = fmul double %call1, %result.5136 - %80 = call double @llvm.fabs.f64(double %mul212) - %81 = call double @llvm.fabs.f64(double %delta.5135) - %cmp213 = fcmp olt double %80, %81 + %78 = call double @llvm.fabs.f64(double %mul212) + %79 = call double @llvm.fabs.f64(double %delta.5135) + %cmp213 = fcmp olt double %78, %79 br i1 %cmp213, label %do.body, label %do.end, !llvm.loop !157 do.end: ; preds = %try.cont.thread, %do.cond, %try.cont, %land.rhs, %if.then131, %if.then178 %result.1 = phi double [ %div132, %if.then131 ], [ %div180, %if.then178 ], [ %3, %try.cont.thread ], [ %result.5136, %land.rhs ], [ %result.5136, %do.cond ], [ %3, %try.cont ] - %82 = load i64, ptr %count, align 8, !tbaa !43 - %83 = load i64, ptr %max_iter, align 8, !tbaa !43 - %sub214 = sub i64 %83, %82 + %80 = load i64, ptr %count, align 8, !tbaa !43 + %81 = load i64, ptr %max_iter, align 8, !tbaa !43 + %sub214 = sub i64 %81, %80 store i64 %sub214, ptr %max_iter, align 8, !tbaa !43 br label %cleanup215 diff --git a/bench/recastnavigation/optimized/catch_amalgamated.cpp.ll b/bench/recastnavigation/optimized/catch_amalgamated.cpp.ll index 5ca81f621fd..26cee12ed54 100644 --- a/bench/recastnavigation/optimized/catch_amalgamated.cpp.ll +++ b/bench/recastnavigation/optimized/catch_amalgamated.cpp.ll @@ -107335,8 +107335,8 @@ define linkonce_odr dso_local noundef i64 @_ZN5Catch11ulpDistanceIfEEmT_S1_(floa .lr.ph: ; preds = %2, %tailrecurse %.tr2228 = phi float [ 0.000000e+00, %tailrecurse ], [ %1, %2 ] - %.tr27 = phi float [ %14, %tailrecurse ], [ %0, %2 ] - %accumulator.tr26 = phi i64 [ %15, %tailrecurse ], [ 0, %2 ] + %.tr27 = phi float [ %12, %tailrecurse ], [ %0, %2 ] + %accumulator.tr26 = phi i64 [ %13, %tailrecurse ], [ 0, %2 ] %4 = fcmp oeq float %.tr27, 0.000000e+00 %.010 = select i1 %4, float 0.000000e+00, float %.tr27 %5 = fcmp oeq float %.tr2228, 0.000000e+00 @@ -107345,29 +107345,26 @@ define linkonce_odr dso_local noundef i64 @_ZN5Catch11ulpDistanceIfEEmT_S1_(floa %7 = bitcast float %.0 to i32 %8 = xor i32 %7, %6 %9 = icmp slt i32 %8, 0 - br i1 %9, label %tailrecurse, label %17 + br i1 %9, label %tailrecurse, label %14 tailrecurse: ; preds = %.lr.ph - %10 = tail call float @llvm.fabs.f32(float %.tr27) - %11 = select i1 %4, float 0.000000e+00, float %10 - %12 = tail call noundef i64 @_ZN5Catch11ulpDistanceIfEEmT_S1_(float noundef %11, float noundef 0.000000e+00) - %13 = tail call float @llvm.fabs.f32(float %.tr2228) - %14 = select i1 %5, float 0.000000e+00, float %13 - %15 = add i64 %12, %accumulator.tr26 - %16 = fcmp oeq float %14, 0.000000e+00 - br i1 %16, label %.loopexit, label %.lr.ph + %10 = tail call noundef float @llvm.fabs.f32(float %.010) + %11 = tail call noundef i64 @_ZN5Catch11ulpDistanceIfEEmT_S1_(float noundef %10, float noundef 0.000000e+00) + %12 = tail call noundef float @llvm.fabs.f32(float %.0) + %13 = add i64 %11, %accumulator.tr26 + br i1 %5, label %.loopexit, label %.lr.ph -17: ; preds = %.lr.ph +14: ; preds = %.lr.ph %spec.select21 = tail call i32 @llvm.umax.i32(i32 %6, i32 %7) %spec.select = zext i32 %spec.select21 to i64 %spec.select20.v = tail call i32 @llvm.umin.i32(i32 %6, i32 %7) %spec.select20 = zext i32 %spec.select20.v to i64 - %18 = sub nsw i64 %spec.select, %spec.select20 + %15 = sub nsw i64 %spec.select, %spec.select20 br label %.loopexit -.loopexit: ; preds = %tailrecurse, %2, %17 - %accumulator.tr24 = phi i64 [ %accumulator.tr26, %17 ], [ 0, %2 ], [ %15, %tailrecurse ] - %.011 = phi i64 [ %18, %17 ], [ 0, %2 ], [ 0, %tailrecurse ] +.loopexit: ; preds = %tailrecurse, %2, %14 + %accumulator.tr24 = phi i64 [ %accumulator.tr26, %14 ], [ 0, %2 ], [ %13, %tailrecurse ] + %.011 = phi i64 [ %15, %14 ], [ 0, %2 ], [ 0, %tailrecurse ] %accumulator.ret.tr = add i64 %.011, %accumulator.tr24 ret i64 %accumulator.ret.tr } @@ -107382,8 +107379,8 @@ define linkonce_odr dso_local noundef i64 @_ZN5Catch11ulpDistanceIdEEmT_S1_(doub .lr.ph: ; preds = %2, %tailrecurse %.tr2127 = phi double [ 0.000000e+00, %tailrecurse ], [ %1, %2 ] - %.tr26 = phi double [ %14, %tailrecurse ], [ %0, %2 ] - %accumulator.tr25 = phi i64 [ %15, %tailrecurse ], [ 0, %2 ] + %.tr26 = phi double [ %12, %tailrecurse ], [ %0, %2 ] + %accumulator.tr25 = phi i64 [ %13, %tailrecurse ], [ 0, %2 ] %4 = fcmp oeq double %.tr26, 0.000000e+00 %.010 = select i1 %4, double 0.000000e+00, double %.tr26 %5 = fcmp oeq double %.tr2127, 0.000000e+00 @@ -107392,27 +107389,24 @@ define linkonce_odr dso_local noundef i64 @_ZN5Catch11ulpDistanceIdEEmT_S1_(doub %7 = bitcast double %.0 to i64 %8 = xor i64 %7, %6 %9 = icmp slt i64 %8, 0 - br i1 %9, label %tailrecurse, label %17 + br i1 %9, label %tailrecurse, label %14 tailrecurse: ; preds = %.lr.ph - %10 = tail call double @llvm.fabs.f64(double %.tr26) - %11 = select i1 %4, double 0.000000e+00, double %10 - %12 = tail call noundef i64 @_ZN5Catch11ulpDistanceIdEEmT_S1_(double noundef %11, double noundef 0.000000e+00) - %13 = tail call double @llvm.fabs.f64(double %.tr2127) - %14 = select i1 %5, double 0.000000e+00, double %13 - %15 = add i64 %12, %accumulator.tr25 - %16 = fcmp oeq double %14, 0.000000e+00 - br i1 %16, label %.loopexit, label %.lr.ph + %10 = tail call noundef double @llvm.fabs.f64(double %.010) + %11 = tail call noundef i64 @_ZN5Catch11ulpDistanceIdEEmT_S1_(double noundef %10, double noundef 0.000000e+00) + %12 = tail call noundef double @llvm.fabs.f64(double %.0) + %13 = add i64 %11, %accumulator.tr25 + br i1 %5, label %.loopexit, label %.lr.ph -17: ; preds = %.lr.ph +14: ; preds = %.lr.ph %spec.select = tail call i64 @llvm.umax.i64(i64 %6, i64 %7) %spec.select20 = tail call i64 @llvm.umin.i64(i64 %6, i64 %7) - %18 = sub i64 %spec.select, %spec.select20 + %15 = sub i64 %spec.select, %spec.select20 br label %.loopexit -.loopexit: ; preds = %tailrecurse, %2, %17 - %accumulator.tr23 = phi i64 [ %accumulator.tr25, %17 ], [ 0, %2 ], [ %15, %tailrecurse ] - %.011 = phi i64 [ %18, %17 ], [ 0, %2 ], [ 0, %tailrecurse ] +.loopexit: ; preds = %tailrecurse, %2, %14 + %accumulator.tr23 = phi i64 [ %accumulator.tr25, %14 ], [ 0, %2 ], [ %13, %tailrecurse ] + %.011 = phi i64 [ %15, %14 ], [ 0, %2 ], [ 0, %tailrecurse ] %accumulator.ret.tr = add i64 %.011, %accumulator.tr23 ret i64 %accumulator.ret.tr } diff --git a/bench/typst-rs/optimized/1ru1rhojhbz2vfey.ll b/bench/typst-rs/optimized/1ru1rhojhbz2vfey.ll index 9a2a21104aa..e1b6d06d48f 100644 --- a/bench/typst-rs/optimized/1ru1rhojhbz2vfey.ll +++ b/bench/typst-rs/optimized/1ru1rhojhbz2vfey.ll @@ -63977,11 +63977,11 @@ define hidden { i64, double } @"_ZN5typst11foundations4auto14Smart$LT$T$GT$3map1 %.0.i.inv.i.i.i.i.i.i.i.i = fcmp ord double %.sroa.3.0.copyload, 0.000000e+00 %.0.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double %.sroa.3.0.copyload, double 0.000000e+00 %10 = fmul double %.0.i.i.i.i.i.i.i.i, %9 - %.0.i.inv.i.i.i.i.i.i = fcmp uno double %10, 0.000000e+00 - %11 = tail call double @llvm.fabs.f64(double %10) + %.0.i.inv.i.i.i.i.i.i = fcmp ord double %10, 0.000000e+00 + %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %10, double 0.000000e+00 + %11 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i) %12 = fcmp one double %11, 0x7FF0000000000000 - %.0.i.i.i.i.i.i = select i1 %12, double %10, double 0.000000e+00 - %.0.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i + %.0.i.i.i = select i1 %12, double %.0.i.i.i.i.i.i, double 0.000000e+00 %13 = fadd double %8, %.0.i.i.i %.0.i.inv.i.i.i.i.i = fcmp ord double %13, 0.000000e+00 %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %13, double 0.000000e+00 @@ -64112,11 +64112,11 @@ define hidden { i64, double } @"_ZN5typst11foundations4auto14Smart$LT$T$GT$3map1 %.0.i.inv.i.i.i.i.i.i.i.i = fcmp ord double %6, 0.000000e+00 %.0.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double %6, double 0.000000e+00 %10 = fmul double %.0.i.i.i.i.i.i.i.i, %9 - %.0.i.inv.i.i.i.i.i.i = fcmp uno double %10, 0.000000e+00 - %11 = tail call double @llvm.fabs.f64(double %10) + %.0.i.inv.i.i.i.i.i.i = fcmp ord double %10, 0.000000e+00 + %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %10, double 0.000000e+00 + %11 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i) %12 = fcmp one double %11, 0x7FF0000000000000 - %.0.i.i.i.i.i.i = select i1 %12, double %10, double 0.000000e+00 - %.0.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i + %.0.i.i.i = select i1 %12, double %.0.i.i.i.i.i.i, double 0.000000e+00 %13 = fadd double %8, %.0.i.i.i %.0.i.inv.i.i.i.i.i = fcmp ord double %13, 0.000000e+00 %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %13, double 0.000000e+00 @@ -64244,11 +64244,11 @@ define hidden { i64, double } @"_ZN5typst11foundations4auto14Smart$LT$T$GT$3map1 %.0.i.inv.i.i.i.i.i.i.i.i = fcmp ord double %.sroa.3.0.copyload, 0.000000e+00 %.0.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double %.sroa.3.0.copyload, double 0.000000e+00 %10 = fmul double %.0.i.i.i.i.i.i.i.i, %9 - %.0.i.inv.i.i.i.i.i.i = fcmp uno double %10, 0.000000e+00 - %11 = tail call double @llvm.fabs.f64(double %10) + %.0.i.inv.i.i.i.i.i.i = fcmp ord double %10, 0.000000e+00 + %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %10, double 0.000000e+00 + %11 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i) %12 = fcmp one double %11, 0x7FF0000000000000 - %.0.i.i.i.i.i.i = select i1 %12, double %10, double 0.000000e+00 - %.0.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i + %.0.i.i.i = select i1 %12, double %.0.i.i.i.i.i.i, double 0.000000e+00 %13 = fadd double %8, %.0.i.i.i %.0.i.inv.i.i.i.i.i = fcmp ord double %13, 0.000000e+00 %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %13, double 0.000000e+00 @@ -64341,11 +64341,11 @@ define hidden { i64, double } @"_ZN5typst11foundations4auto14Smart$LT$T$GT$3map1 %.0.i.inv.i.i.i.i.i.i.i.i = fcmp ord double %6, 0.000000e+00 %.0.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double %6, double 0.000000e+00 %10 = fmul double %.0.i.i.i.i.i.i.i.i, %9 - %.0.i.inv.i.i.i.i.i.i = fcmp uno double %10, 0.000000e+00 - %11 = tail call double @llvm.fabs.f64(double %10) + %.0.i.inv.i.i.i.i.i.i = fcmp ord double %10, 0.000000e+00 + %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %10, double 0.000000e+00 + %11 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i) %12 = fcmp one double %11, 0x7FF0000000000000 - %.0.i.i.i.i.i.i = select i1 %12, double %10, double 0.000000e+00 - %.0.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i + %.0.i.i.i = select i1 %12, double %.0.i.i.i.i.i.i, double 0.000000e+00 %13 = fadd double %8, %.0.i.i.i %.0.i.inv.i.i.i.i.i = fcmp ord double %13, 0.000000e+00 %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %13, double 0.000000e+00 @@ -94357,11 +94357,11 @@ define hidden void @"_ZN5typst6layout7corners16Corners$LT$T$GT$3map17h050f5e290b %.0.i.inv.i.i.i.i.i.i.i.i = fcmp ord double %4, 0.000000e+00 %.0.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double %4, double 0.000000e+00 %9 = fmul double %.0.i.i.i.i.i.i.i.i, %.0.i.i.i.i - %.0.i.inv.i.i.i.i.i.i = fcmp uno double %9, 0.000000e+00 - %10 = tail call double @llvm.fabs.f64(double %9) + %.0.i.inv.i.i.i.i.i.i = fcmp ord double %9, 0.000000e+00 + %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %9, double 0.000000e+00 + %10 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i) %11 = fcmp one double %10, 0x7FF0000000000000 - %.0.i.i.i.i.i.i = select i1 %11, double %9, double 0.000000e+00 - %.0.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i + %.0.i.i.i = select i1 %11, double %.0.i.i.i.i.i.i, double 0.000000e+00 %12 = fadd double %6, %.0.i.i.i %.0.i.inv.i.i.i.i.i = fcmp ord double %12, 0.000000e+00 %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %12, double 0.000000e+00 @@ -94385,11 +94385,11 @@ define hidden void @"_ZN5typst6layout7corners16Corners$LT$T$GT$3map17h050f5e290b %.0.i.inv.i.i.i.i.i.i.i.i14 = fcmp ord double %18, 0.000000e+00 %.0.i.i.i.i.i.i.i.i15 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i14, double %18, double 0.000000e+00 %21 = fmul double %.0.i.i.i.i, %.0.i.i.i.i.i.i.i.i15 - %.0.i.inv.i.i.i.i.i.i16 = fcmp uno double %21, 0.000000e+00 - %22 = tail call double @llvm.fabs.f64(double %21) + %.0.i.inv.i.i.i.i.i.i16 = fcmp ord double %21, 0.000000e+00 + %.0.i.i.i.i.i.i17 = select i1 %.0.i.inv.i.i.i.i.i.i16, double %21, double 0.000000e+00 + %22 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i17) %23 = fcmp one double %22, 0x7FF0000000000000 - %.0.i.i.i.i.i.i17 = select i1 %23, double %21, double 0.000000e+00 - %.0.i.i.i18 = select i1 %.0.i.inv.i.i.i.i.i.i16, double 0.000000e+00, double %.0.i.i.i.i.i.i17 + %.0.i.i.i18 = select i1 %23, double %.0.i.i.i.i.i.i17, double 0.000000e+00 %24 = fadd double %20, %.0.i.i.i18 %.0.i.inv.i.i.i.i.i19 = fcmp ord double %24, 0.000000e+00 %.0.i.i.i.i.i20 = select i1 %.0.i.inv.i.i.i.i.i19, double %24, double 0.000000e+00 @@ -94413,11 +94413,11 @@ define hidden void @"_ZN5typst6layout7corners16Corners$LT$T$GT$3map17h050f5e290b %.0.i.inv.i.i.i.i.i.i.i.i25 = fcmp ord double %30, 0.000000e+00 %.0.i.i.i.i.i.i.i.i26 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i25, double %30, double 0.000000e+00 %33 = fmul double %.0.i.i.i.i, %.0.i.i.i.i.i.i.i.i26 - %.0.i.inv.i.i.i.i.i.i27 = fcmp uno double %33, 0.000000e+00 - %34 = tail call double @llvm.fabs.f64(double %33) + %.0.i.inv.i.i.i.i.i.i27 = fcmp ord double %33, 0.000000e+00 + %.0.i.i.i.i.i.i28 = select i1 %.0.i.inv.i.i.i.i.i.i27, double %33, double 0.000000e+00 + %34 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i28) %35 = fcmp one double %34, 0x7FF0000000000000 - %.0.i.i.i.i.i.i28 = select i1 %35, double %33, double 0.000000e+00 - %.0.i.i.i29 = select i1 %.0.i.inv.i.i.i.i.i.i27, double 0.000000e+00, double %.0.i.i.i.i.i.i28 + %.0.i.i.i29 = select i1 %35, double %.0.i.i.i.i.i.i28, double 0.000000e+00 %36 = fadd double %32, %.0.i.i.i29 %.0.i.inv.i.i.i.i.i30 = fcmp ord double %36, 0.000000e+00 %.0.i.i.i.i.i31 = select i1 %.0.i.inv.i.i.i.i.i30, double %36, double 0.000000e+00 @@ -94441,11 +94441,11 @@ define hidden void @"_ZN5typst6layout7corners16Corners$LT$T$GT$3map17h050f5e290b %.0.i.inv.i.i.i.i.i.i.i.i36 = fcmp ord double %42, 0.000000e+00 %.0.i.i.i.i.i.i.i.i37 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i36, double %42, double 0.000000e+00 %45 = fmul double %.0.i.i.i.i, %.0.i.i.i.i.i.i.i.i37 - %.0.i.inv.i.i.i.i.i.i38 = fcmp uno double %45, 0.000000e+00 - %46 = tail call double @llvm.fabs.f64(double %45) + %.0.i.inv.i.i.i.i.i.i38 = fcmp ord double %45, 0.000000e+00 + %.0.i.i.i.i.i.i39 = select i1 %.0.i.inv.i.i.i.i.i.i38, double %45, double 0.000000e+00 + %46 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i39) %47 = fcmp one double %46, 0x7FF0000000000000 - %.0.i.i.i.i.i.i39 = select i1 %47, double %45, double 0.000000e+00 - %.0.i.i.i40 = select i1 %.0.i.inv.i.i.i.i.i.i38, double 0.000000e+00, double %.0.i.i.i.i.i.i39 + %.0.i.i.i40 = select i1 %47, double %.0.i.i.i.i.i.i39, double 0.000000e+00 %48 = fadd double %44, %.0.i.i.i40 %.0.i.inv.i.i.i.i.i41 = fcmp ord double %48, 0.000000e+00 %.0.i.i.i.i.i42 = select i1 %.0.i.inv.i.i.i.i.i41, double %48, double 0.000000e+00 @@ -94781,11 +94781,11 @@ define hidden void @"_ZN5typst6layout7corners16Corners$LT$T$GT$3map17h85375aae49 %.0.i.inv.i.i.i.i.i.i.i.i = fcmp ord double %4, 0.000000e+00 %.0.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double %4, double 0.000000e+00 %9 = fmul double %.0.i.i.i.i.i.i.i.i, %.0.i.i.i.i - %.0.i.inv.i.i.i.i.i.i = fcmp uno double %9, 0.000000e+00 - %10 = tail call double @llvm.fabs.f64(double %9) + %.0.i.inv.i.i.i.i.i.i = fcmp ord double %9, 0.000000e+00 + %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %9, double 0.000000e+00 + %10 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i) %11 = fcmp one double %10, 0x7FF0000000000000 - %.0.i.i.i.i.i.i = select i1 %11, double %9, double 0.000000e+00 - %.0.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i + %.0.i.i.i = select i1 %11, double %.0.i.i.i.i.i.i, double 0.000000e+00 %12 = fadd double %6, %.0.i.i.i %.0.i.inv.i.i.i.i.i = fcmp ord double %12, 0.000000e+00 %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %12, double 0.000000e+00 @@ -94809,11 +94809,11 @@ define hidden void @"_ZN5typst6layout7corners16Corners$LT$T$GT$3map17h85375aae49 %.0.i.inv.i.i.i.i.i.i.i.i14 = fcmp ord double %18, 0.000000e+00 %.0.i.i.i.i.i.i.i.i15 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i14, double %18, double 0.000000e+00 %21 = fmul double %.0.i.i.i.i, %.0.i.i.i.i.i.i.i.i15 - %.0.i.inv.i.i.i.i.i.i16 = fcmp uno double %21, 0.000000e+00 - %22 = tail call double @llvm.fabs.f64(double %21) + %.0.i.inv.i.i.i.i.i.i16 = fcmp ord double %21, 0.000000e+00 + %.0.i.i.i.i.i.i17 = select i1 %.0.i.inv.i.i.i.i.i.i16, double %21, double 0.000000e+00 + %22 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i17) %23 = fcmp one double %22, 0x7FF0000000000000 - %.0.i.i.i.i.i.i17 = select i1 %23, double %21, double 0.000000e+00 - %.0.i.i.i18 = select i1 %.0.i.inv.i.i.i.i.i.i16, double 0.000000e+00, double %.0.i.i.i.i.i.i17 + %.0.i.i.i18 = select i1 %23, double %.0.i.i.i.i.i.i17, double 0.000000e+00 %24 = fadd double %20, %.0.i.i.i18 %.0.i.inv.i.i.i.i.i19 = fcmp ord double %24, 0.000000e+00 %.0.i.i.i.i.i20 = select i1 %.0.i.inv.i.i.i.i.i19, double %24, double 0.000000e+00 @@ -94837,11 +94837,11 @@ define hidden void @"_ZN5typst6layout7corners16Corners$LT$T$GT$3map17h85375aae49 %.0.i.inv.i.i.i.i.i.i.i.i25 = fcmp ord double %30, 0.000000e+00 %.0.i.i.i.i.i.i.i.i26 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i25, double %30, double 0.000000e+00 %33 = fmul double %.0.i.i.i.i, %.0.i.i.i.i.i.i.i.i26 - %.0.i.inv.i.i.i.i.i.i27 = fcmp uno double %33, 0.000000e+00 - %34 = tail call double @llvm.fabs.f64(double %33) + %.0.i.inv.i.i.i.i.i.i27 = fcmp ord double %33, 0.000000e+00 + %.0.i.i.i.i.i.i28 = select i1 %.0.i.inv.i.i.i.i.i.i27, double %33, double 0.000000e+00 + %34 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i28) %35 = fcmp one double %34, 0x7FF0000000000000 - %.0.i.i.i.i.i.i28 = select i1 %35, double %33, double 0.000000e+00 - %.0.i.i.i29 = select i1 %.0.i.inv.i.i.i.i.i.i27, double 0.000000e+00, double %.0.i.i.i.i.i.i28 + %.0.i.i.i29 = select i1 %35, double %.0.i.i.i.i.i.i28, double 0.000000e+00 %36 = fadd double %32, %.0.i.i.i29 %.0.i.inv.i.i.i.i.i30 = fcmp ord double %36, 0.000000e+00 %.0.i.i.i.i.i31 = select i1 %.0.i.inv.i.i.i.i.i30, double %36, double 0.000000e+00 @@ -94865,11 +94865,11 @@ define hidden void @"_ZN5typst6layout7corners16Corners$LT$T$GT$3map17h85375aae49 %.0.i.inv.i.i.i.i.i.i.i.i36 = fcmp ord double %42, 0.000000e+00 %.0.i.i.i.i.i.i.i.i37 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i36, double %42, double 0.000000e+00 %45 = fmul double %.0.i.i.i.i, %.0.i.i.i.i.i.i.i.i37 - %.0.i.inv.i.i.i.i.i.i38 = fcmp uno double %45, 0.000000e+00 - %46 = tail call double @llvm.fabs.f64(double %45) + %.0.i.inv.i.i.i.i.i.i38 = fcmp ord double %45, 0.000000e+00 + %.0.i.i.i.i.i.i39 = select i1 %.0.i.inv.i.i.i.i.i.i38, double %45, double 0.000000e+00 + %46 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i39) %47 = fcmp one double %46, 0x7FF0000000000000 - %.0.i.i.i.i.i.i39 = select i1 %47, double %45, double 0.000000e+00 - %.0.i.i.i40 = select i1 %.0.i.inv.i.i.i.i.i.i38, double 0.000000e+00, double %.0.i.i.i.i.i.i39 + %.0.i.i.i40 = select i1 %47, double %.0.i.i.i.i.i.i39, double 0.000000e+00 %48 = fadd double %44, %.0.i.i.i40 %.0.i.inv.i.i.i.i.i41 = fcmp ord double %48, 0.000000e+00 %.0.i.i.i.i.i42 = select i1 %.0.i.inv.i.i.i.i.i41, double %48, double 0.000000e+00 @@ -110695,11 +110695,11 @@ define hidden void @_ZN5typst4math6cancel16draw_cancel_line17h5e2a8bc925af4686E( %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %2, 0.000000e+00 %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %2, double 0.000000e+00 %164 = fmul double %.0.i.i.i.i.i.i.i, %.0.i.i.i - %.0.i.inv.i.i.i.i.i = fcmp uno double %164, 0.000000e+00 - %165 = call double @llvm.fabs.f64(double %164) + %.0.i.inv.i.i.i.i.i = fcmp ord double %164, 0.000000e+00 + %.0.i.i.i.i.i33 = select i1 %.0.i.inv.i.i.i.i.i, double %164, double 0.000000e+00 + %165 = call double @llvm.fabs.f64(double %.0.i.i.i.i.i33) %166 = fcmp one double %165, 0x7FF0000000000000 - %.0.i.i.i.i.i33 = select i1 %166, double %164, double 0.000000e+00 - %.0.i.i = select i1 %.0.i.inv.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i33 + %.0.i.i = select i1 %166, double %.0.i.i.i.i.i33, double 0.000000e+00 %167 = fadd double %3, %.0.i.i %.0.i.inv.i.i.i.i34 = fcmp ord double %167, 0.000000e+00 %.0.i.i.i.i35 = select i1 %.0.i.inv.i.i.i.i34, double %167, double 0.000000e+00 @@ -122418,11 +122418,11 @@ define hidden noundef double @"_ZN5typst9visualize5shape6layout28_$u7b$$u7b$clos %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %6, 0.000000e+00 %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %6, double 0.000000e+00 %12 = fmul double %.0.i.i.i.i.i.i.i, %11 - %.0.i.inv.i.i.i.i.i = fcmp uno double %12, 0.000000e+00 - %13 = tail call double @llvm.fabs.f64(double %12) + %.0.i.inv.i.i.i.i.i = fcmp ord double %12, 0.000000e+00 + %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %12, double 0.000000e+00 + %13 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i) %14 = fcmp one double %13, 0x7FF0000000000000 - %.0.i.i.i.i.i = select i1 %14, double %12, double 0.000000e+00 - %.0.i.i = select i1 %.0.i.inv.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i + %.0.i.i = select i1 %14, double %.0.i.i.i.i.i, double 0.000000e+00 %15 = fadd double %10, %.0.i.i %.0.i.inv.i.i.i.i = fcmp ord double %15, 0.000000e+00 %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i, double %15, double 0.000000e+00 @@ -128084,11 +128084,11 @@ define hidden noundef double @"_ZN5typst6layout9container94_$LT$impl$u20$typst.. %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %1, 0.000000e+00 %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %1, double 0.000000e+00 %5 = fmul double %.0.i.i.i.i.i.i.i, %4 - %.0.i.inv.i.i.i.i.i = fcmp uno double %5, 0.000000e+00 - %6 = tail call double @llvm.fabs.f64(double %5) + %.0.i.inv.i.i.i.i.i = fcmp ord double %5, 0.000000e+00 + %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %5, double 0.000000e+00 + %6 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i) %7 = fcmp one double %6, 0x7FF0000000000000 - %.0.i.i.i.i.i = select i1 %7, double %5, double 0.000000e+00 - %.0.i.i = select i1 %.0.i.inv.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i + %.0.i.i = select i1 %7, double %.0.i.i.i.i.i, double 0.000000e+00 %8 = fadd double %2, %.0.i.i %.0.i.inv.i.i.i.i = fcmp ord double %8, 0.000000e+00 %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i, double %8, double 0.000000e+00 @@ -128101,11 +128101,11 @@ define hidden noundef double @"_ZN5typst6layout9container138_$LT$impl$u20$typst. %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %1, 0.000000e+00 %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %1, double 0.000000e+00 %5 = fmul double %.0.i.i.i.i.i.i.i, %4 - %.0.i.inv.i.i.i.i.i = fcmp uno double %5, 0.000000e+00 - %6 = tail call double @llvm.fabs.f64(double %5) + %.0.i.inv.i.i.i.i.i = fcmp ord double %5, 0.000000e+00 + %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %5, double 0.000000e+00 + %6 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i) %7 = fcmp one double %6, 0x7FF0000000000000 - %.0.i.i.i.i.i = select i1 %7, double %5, double 0.000000e+00 - %.0.i.i = select i1 %.0.i.inv.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i + %.0.i.i = select i1 %7, double %.0.i.i.i.i.i, double 0.000000e+00 %8 = fadd double %2, %.0.i.i %.0.i.inv.i.i.i.i = fcmp ord double %8, 0.000000e+00 %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i, double %8, double 0.000000e+00 @@ -180159,11 +180159,11 @@ define hidden noundef double @"_ZN5typst9visualize5image135_$LT$impl$u20$typst.. %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %6, 0.000000e+00 %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %6, double 0.000000e+00 %12 = fmul double %.0.i.i.i.i.i.i.i, %11 - %.0.i.inv.i.i.i.i.i = fcmp uno double %12, 0.000000e+00 - %13 = tail call double @llvm.fabs.f64(double %12) + %.0.i.inv.i.i.i.i.i = fcmp ord double %12, 0.000000e+00 + %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %12, double 0.000000e+00 + %13 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i) %14 = fcmp one double %13, 0x7FF0000000000000 - %.0.i.i.i.i.i = select i1 %14, double %12, double 0.000000e+00 - %.0.i.i = select i1 %.0.i.inv.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i + %.0.i.i = select i1 %14, double %.0.i.i.i.i.i, double 0.000000e+00 %15 = fadd double %10, %.0.i.i %.0.i.inv.i.i.i.i = fcmp ord double %15, 0.000000e+00 %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i, double %15, double 0.000000e+00 diff --git a/bench/typst-rs/optimized/22a0ijn9jg8ilzgs.ll b/bench/typst-rs/optimized/22a0ijn9jg8ilzgs.ll index 68860f14b0b..67d99642400 100644 --- a/bench/typst-rs/optimized/22a0ijn9jg8ilzgs.ll +++ b/bench/typst-rs/optimized/22a0ijn9jg8ilzgs.ll @@ -199790,11 +199790,11 @@ define noundef double @_ZN5typst6layout2em2Em2at17h108a80ae3a8ce535E(double noun %.0.i.inv.i.i.i.i.i = fcmp ord double %0, 0.000000e+00 %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %0, double 0.000000e+00 %3 = fmul double %1, %.0.i.i.i.i.i - %.0.i.inv.i.i.i = fcmp uno double %3, 0.000000e+00 - %4 = tail call double @llvm.fabs.f64(double %3) + %.0.i.inv.i.i.i = fcmp ord double %3, 0.000000e+00 + %.0.i.i.i = select i1 %.0.i.inv.i.i.i, double %3, double 0.000000e+00 + %4 = tail call double @llvm.fabs.f64(double %.0.i.i.i) %5 = fcmp one double %4, 0x7FF0000000000000 - %.0.i.i.i = select i1 %5, double %3, double 0.000000e+00 - %.0 = select i1 %.0.i.inv.i.i.i, double 0.000000e+00, double %.0.i.i.i + %.0 = select i1 %5, double %.0.i.i.i, double 0.000000e+00 ret double %.0 } @@ -199942,11 +199942,11 @@ _ZN5typst4util7Numeric7is_zero17h8b8e138031b37f84E.exit: ; preds = %2 %.0.i.inv.i.i.i = fcmp ord double %19, 0.000000e+00 %.0.i.i.i = select i1 %.0.i.inv.i.i.i, double %19, double 0.000000e+00 %20 = fmul double %0, %.0.i.i.i - %.0.i.inv.i.i.i.i = fcmp uno double %20, 0.000000e+00 - %21 = call double @llvm.fabs.f64(double %20) + %.0.i.inv.i.i.i.i = fcmp ord double %20, 0.000000e+00 + %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i, double %20, double 0.000000e+00 + %21 = call double @llvm.fabs.f64(double %.0.i.i.i.i) %22 = fcmp one double %21, 0x7FF0000000000000 - %.0.i.i.i.i = select i1 %22, double %20, double 0.000000e+00 - %.0.i = select i1 %.0.i.inv.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i + %.0.i = select i1 %22, double %.0.i.i.i.i, double 0.000000e+00 br label %23 23: ; preds = %_ZN5typst4util7Numeric7is_zero17h8b8e138031b37f84E.exit, %14 @@ -199971,11 +199971,11 @@ define noundef double @"_ZN80_$LT$ttf_parser..tables..math..MathValue$u20$as$u20 %.0.i.inv.i.i.i.i = fcmp ord double %12, 0.000000e+00 %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i, double %12, double 0.000000e+00 %13 = fmul double %2, %.0.i.i.i.i - %.0.i.inv.i.i.i.i.i = fcmp uno double %13, 0.000000e+00 - %14 = tail call double @llvm.fabs.f64(double %13) + %.0.i.inv.i.i.i.i.i = fcmp ord double %13, 0.000000e+00 + %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %13, double 0.000000e+00 + %14 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i) %15 = fcmp one double %14, 0x7FF0000000000000 - %.0.i.i.i.i.i = select i1 %15, double %13, double 0.000000e+00 - %.0.i.i = select i1 %.0.i.inv.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i + %.0.i.i = select i1 %15, double %.0.i.i.i.i.i, double 0.000000e+00 ret double %.0.i.i } diff --git a/bench/typst-rs/optimized/2d3c2n5y91mtl0x0.ll b/bench/typst-rs/optimized/2d3c2n5y91mtl0x0.ll index 272959f5f90..35f731c82a3 100644 --- a/bench/typst-rs/optimized/2d3c2n5y91mtl0x0.ll +++ b/bench/typst-rs/optimized/2d3c2n5y91mtl0x0.ll @@ -141324,21 +141324,21 @@ define { double, double } @_ZN5typst6layout5point5Point9transform17h63f5747d152d %.0.i.inv.i.i.i.i.i.i = fcmp ord double %4, 0.000000e+00 %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %4, double 0.000000e+00 %5 = fmul double %0, %.0.i.i.i.i.i.i - %.0.i.inv.i.i.i.i = fcmp uno double %5, 0.000000e+00 - %6 = tail call double @llvm.fabs.f64(double %5) + %.0.i.inv.i.i.i.i = fcmp ord double %5, 0.000000e+00 + %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i, double %5, double 0.000000e+00 + %6 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i) %7 = fcmp one double %6, 0x7FF0000000000000 - %.0.i.i.i.i = select i1 %7, double %5, double 0.000000e+00 - %.0.i = select i1 %.0.i.inv.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i + %.0.i = select i1 %7, double %.0.i.i.i.i, double 0.000000e+00 %8 = getelementptr inbounds nuw i8, ptr %2, i64 16 %9 = load double, ptr %8, align 8, !noundef !7 %.0.i.inv.i.i.i.i.i.i1 = fcmp ord double %9, 0.000000e+00 %.0.i.i.i.i.i.i2 = select i1 %.0.i.inv.i.i.i.i.i.i1, double %9, double 0.000000e+00 %10 = fmul double %1, %.0.i.i.i.i.i.i2 - %.0.i.inv.i.i.i.i3 = fcmp uno double %10, 0.000000e+00 - %11 = tail call double @llvm.fabs.f64(double %10) + %.0.i.inv.i.i.i.i3 = fcmp ord double %10, 0.000000e+00 + %.0.i.i.i.i4 = select i1 %.0.i.inv.i.i.i.i3, double %10, double 0.000000e+00 + %11 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i4) %12 = fcmp one double %11, 0x7FF0000000000000 - %.0.i.i.i.i4 = select i1 %12, double %10, double 0.000000e+00 - %.0.i5 = select i1 %.0.i.inv.i.i.i.i3, double 0.000000e+00, double %.0.i.i.i.i4 + %.0.i5 = select i1 %12, double %.0.i.i.i.i4, double 0.000000e+00 %13 = fadd double %.0.i, %.0.i5 %14 = getelementptr inbounds nuw i8, ptr %2, i64 32 %15 = load double, ptr %14, align 8, !noundef !7 @@ -141350,21 +141350,21 @@ define { double, double } @_ZN5typst6layout5point5Point9transform17h63f5747d152d %.0.i.inv.i.i.i.i.i.i6 = fcmp ord double %18, 0.000000e+00 %.0.i.i.i.i.i.i7 = select i1 %.0.i.inv.i.i.i.i.i.i6, double %18, double 0.000000e+00 %19 = fmul double %0, %.0.i.i.i.i.i.i7 - %.0.i.inv.i.i.i.i8 = fcmp uno double %19, 0.000000e+00 - %20 = tail call double @llvm.fabs.f64(double %19) + %.0.i.inv.i.i.i.i8 = fcmp ord double %19, 0.000000e+00 + %.0.i.i.i.i9 = select i1 %.0.i.inv.i.i.i.i8, double %19, double 0.000000e+00 + %20 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i9) %21 = fcmp one double %20, 0x7FF0000000000000 - %.0.i.i.i.i9 = select i1 %21, double %19, double 0.000000e+00 - %.0.i10 = select i1 %.0.i.inv.i.i.i.i8, double 0.000000e+00, double %.0.i.i.i.i9 + %.0.i10 = select i1 %21, double %.0.i.i.i.i9, double 0.000000e+00 %22 = getelementptr inbounds nuw i8, ptr %2, i64 24 %23 = load double, ptr %22, align 8, !noundef !7 %.0.i.inv.i.i.i.i.i.i11 = fcmp ord double %23, 0.000000e+00 %.0.i.i.i.i.i.i12 = select i1 %.0.i.inv.i.i.i.i.i.i11, double %23, double 0.000000e+00 %24 = fmul double %1, %.0.i.i.i.i.i.i12 - %.0.i.inv.i.i.i.i13 = fcmp uno double %24, 0.000000e+00 - %25 = tail call double @llvm.fabs.f64(double %24) + %.0.i.inv.i.i.i.i13 = fcmp ord double %24, 0.000000e+00 + %.0.i.i.i.i14 = select i1 %.0.i.inv.i.i.i.i13, double %24, double 0.000000e+00 + %25 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i14) %26 = fcmp one double %25, 0x7FF0000000000000 - %.0.i.i.i.i14 = select i1 %26, double %24, double 0.000000e+00 - %.0.i15 = select i1 %.0.i.inv.i.i.i.i13, double 0.000000e+00, double %.0.i.i.i.i14 + %.0.i15 = select i1 %26, double %.0.i.i.i.i14, double 0.000000e+00 %27 = fadd double %.0.i10, %.0.i15 %28 = getelementptr inbounds nuw i8, ptr %2, i64 40 %29 = load double, ptr %28, align 8, !noundef !7 diff --git a/bench/typst-rs/optimized/3dimj4rf5dyrieyi.ll b/bench/typst-rs/optimized/3dimj4rf5dyrieyi.ll index cfd868b80bb..9b2877c94d9 100644 --- a/bench/typst-rs/optimized/3dimj4rf5dyrieyi.ll +++ b/bench/typst-rs/optimized/3dimj4rf5dyrieyi.ll @@ -11370,11 +11370,11 @@ define hidden noundef double @_ZN4core3ops8function5FnMut8call_mut17h1c095964dd4 %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %1, 0.000000e+00 %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %1, double 0.000000e+00 %5 = fmul double %3, %.0.i.i.i.i.i.i.i - %.0.i.inv.i.i.i.i.i = fcmp uno double %5, 0.000000e+00 - %6 = tail call double @llvm.fabs.f64(double %5) + %.0.i.inv.i.i.i.i.i = fcmp ord double %5, 0.000000e+00 + %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %5, double 0.000000e+00 + %6 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i) %7 = fcmp one double %6, 0x7FF0000000000000 - %.0.i.i.i.i.i = select i1 %7, double %5, double 0.000000e+00 - %.0.i.i = select i1 %.0.i.inv.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i + %.0.i.i = select i1 %7, double %.0.i.i.i.i.i, double 0.000000e+00 %8 = fadd double %2, %.0.i.i %.0.i.inv.i.i.i.i = fcmp ord double %8, 0.000000e+00 %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i, double %8, double 0.000000e+00 @@ -108846,11 +108846,11 @@ define hidden void @"_ZN5typst6layout4axes13Axes$LT$T$GT$7zip_map17h74476c29ed30 %.0.i.inv.i.i.i.i.i.i.i.i.i.i = fcmp ord double %.sroa.415.0.copyload, 0.000000e+00 %.0.i.i.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i.i.i, double %.sroa.415.0.copyload, double 0.000000e+00 %6 = fmul double %2, %.0.i.i.i.i.i.i.i.i.i.i - %.0.i.inv.i.i.i.i.i.i.i.i = fcmp uno double %6, 0.000000e+00 - %7 = tail call double @llvm.fabs.f64(double %6) + %.0.i.inv.i.i.i.i.i.i.i.i = fcmp ord double %6, 0.000000e+00 + %.0.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double %6, double 0.000000e+00 + %7 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i.i.i) %8 = fcmp one double %7, 0x7FF0000000000000 - %.0.i.i.i.i.i.i.i.i = select i1 %8, double %6, double 0.000000e+00 - %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i.i.i + %.0.i.i.i.i.i = select i1 %8, double %.0.i.i.i.i.i.i.i.i, double 0.000000e+00 %9 = fadd double %.sroa.516.0.copyload, %.0.i.i.i.i.i %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %9, 0.000000e+00 %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %9, double 0.000000e+00 @@ -108872,11 +108872,11 @@ define hidden void @"_ZN5typst6layout4axes13Axes$LT$T$GT$7zip_map17h74476c29ed30 %.0.i.inv.i.i.i.i.i.i.i.i.i.i6 = fcmp ord double %.sroa.422.0.copyload, 0.000000e+00 %.0.i.i.i.i.i.i.i.i.i.i7 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i.i.i6, double %.sroa.422.0.copyload, double 0.000000e+00 %12 = fmul double %3, %.0.i.i.i.i.i.i.i.i.i.i7 - %.0.i.inv.i.i.i.i.i.i.i.i8 = fcmp uno double %12, 0.000000e+00 - %13 = tail call double @llvm.fabs.f64(double %12) + %.0.i.inv.i.i.i.i.i.i.i.i8 = fcmp ord double %12, 0.000000e+00 + %.0.i.i.i.i.i.i.i.i9 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i8, double %12, double 0.000000e+00 + %13 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i.i.i9) %14 = fcmp one double %13, 0x7FF0000000000000 - %.0.i.i.i.i.i.i.i.i9 = select i1 %14, double %12, double 0.000000e+00 - %.0.i.i.i.i.i10 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i8, double 0.000000e+00, double %.0.i.i.i.i.i.i.i.i9 + %.0.i.i.i.i.i10 = select i1 %14, double %.0.i.i.i.i.i.i.i.i9, double 0.000000e+00 %15 = fadd double %.sroa.523.0.copyload, %.0.i.i.i.i.i10 %.0.i.inv.i.i.i.i.i.i.i11 = fcmp ord double %15, 0.000000e+00 %.0.i.i.i.i.i.i.i12 = select i1 %.0.i.inv.i.i.i.i.i.i.i11, double %15, double 0.000000e+00 @@ -108917,11 +108917,11 @@ define hidden void @"_ZN5typst6layout4axes13Axes$LT$T$GT$7zip_map17h7454decaf601 %.0.i.inv.i.i.i.i.i.i.i.i.i.i = fcmp ord double %.sroa.623.0.copyload, 0.000000e+00 %.0.i.i.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i.i.i, double %.sroa.623.0.copyload, double 0.000000e+00 %10 = fmul double %2, %.0.i.i.i.i.i.i.i.i.i.i - %.0.i.inv.i.i.i.i.i.i.i.i = fcmp uno double %10, 0.000000e+00 - %11 = tail call double @llvm.fabs.f64(double %10) + %.0.i.inv.i.i.i.i.i.i.i.i = fcmp ord double %10, 0.000000e+00 + %.0.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double %10, double 0.000000e+00 + %11 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i.i.i) %12 = fcmp one double %11, 0x7FF0000000000000 - %.0.i.i.i.i.i.i.i.i = select i1 %12, double %10, double 0.000000e+00 - %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i.i.i + %.0.i.i.i.i.i = select i1 %12, double %.0.i.i.i.i.i.i.i.i, double 0.000000e+00 %13 = fadd double %9, %.0.i.i.i.i.i %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %13, 0.000000e+00 %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %13, double 0.000000e+00 @@ -108949,11 +108949,11 @@ define hidden void @"_ZN5typst6layout4axes13Axes$LT$T$GT$7zip_map17h7454decaf601 %.0.i.inv.i.i.i.i.i.i.i.i.i.i11 = fcmp ord double %.sroa.632.0.copyload, 0.000000e+00 %.0.i.i.i.i.i.i.i.i.i.i12 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i.i.i11, double %.sroa.632.0.copyload, double 0.000000e+00 %17 = fmul double %3, %.0.i.i.i.i.i.i.i.i.i.i12 - %.0.i.inv.i.i.i.i.i.i.i.i13 = fcmp uno double %17, 0.000000e+00 - %18 = tail call double @llvm.fabs.f64(double %17) + %.0.i.inv.i.i.i.i.i.i.i.i13 = fcmp ord double %17, 0.000000e+00 + %.0.i.i.i.i.i.i.i.i14 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i13, double %17, double 0.000000e+00 + %18 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i.i.i14) %19 = fcmp one double %18, 0x7FF0000000000000 - %.0.i.i.i.i.i.i.i.i14 = select i1 %19, double %17, double 0.000000e+00 - %.0.i.i.i.i.i15 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i13, double 0.000000e+00, double %.0.i.i.i.i.i.i.i.i14 + %.0.i.i.i.i.i15 = select i1 %19, double %.0.i.i.i.i.i.i.i.i14, double 0.000000e+00 %20 = fadd double %16, %.0.i.i.i.i.i15 %.0.i.inv.i.i.i.i.i.i.i16 = fcmp ord double %20, 0.000000e+00 %.0.i.i.i.i.i.i.i17 = select i1 %.0.i.inv.i.i.i.i.i.i.i16, double %20, double 0.000000e+00 @@ -108980,11 +108980,11 @@ define hidden { double, double } @"_ZN5typst6layout4axes13Axes$LT$T$GT$7zip_map1 %.0.i.inv.i.i.i.i.i.i.i.i = fcmp ord double %4, 0.000000e+00 %.0.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double %4, double 0.000000e+00 %7 = fmul double %1, %.0.i.i.i.i.i.i.i.i - %.0.i.inv.i.i.i.i.i.i = fcmp uno double %7, 0.000000e+00 - %8 = tail call double @llvm.fabs.f64(double %7) + %.0.i.inv.i.i.i.i.i.i = fcmp ord double %7, 0.000000e+00 + %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %7, double 0.000000e+00 + %8 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i) %9 = fcmp one double %8, 0x7FF0000000000000 - %.0.i.i.i.i.i.i = select i1 %9, double %7, double 0.000000e+00 - %.0.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i + %.0.i.i.i = select i1 %9, double %.0.i.i.i.i.i.i, double 0.000000e+00 %10 = fadd double %6, %.0.i.i.i %.0.i.inv.i.i.i.i.i = fcmp ord double %10, 0.000000e+00 %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %10, double 0.000000e+00 @@ -108995,11 +108995,11 @@ define hidden { double, double } @"_ZN5typst6layout4axes13Axes$LT$T$GT$7zip_map1 %.0.i.inv.i.i.i.i.i.i.i.i10 = fcmp ord double %12, 0.000000e+00 %.0.i.i.i.i.i.i.i.i11 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i10, double %12, double 0.000000e+00 %15 = fmul double %2, %.0.i.i.i.i.i.i.i.i11 - %.0.i.inv.i.i.i.i.i.i12 = fcmp uno double %15, 0.000000e+00 - %16 = tail call double @llvm.fabs.f64(double %15) + %.0.i.inv.i.i.i.i.i.i12 = fcmp ord double %15, 0.000000e+00 + %.0.i.i.i.i.i.i13 = select i1 %.0.i.inv.i.i.i.i.i.i12, double %15, double 0.000000e+00 + %16 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i13) %17 = fcmp one double %16, 0x7FF0000000000000 - %.0.i.i.i.i.i.i13 = select i1 %17, double %15, double 0.000000e+00 - %.0.i.i.i14 = select i1 %.0.i.inv.i.i.i.i.i.i12, double 0.000000e+00, double %.0.i.i.i.i.i.i13 + %.0.i.i.i14 = select i1 %17, double %.0.i.i.i.i.i.i13, double 0.000000e+00 %18 = fadd double %14, %.0.i.i.i14 %.0.i.inv.i.i.i.i.i15 = fcmp ord double %18, 0.000000e+00 %.0.i.i.i.i.i16 = select i1 %.0.i.inv.i.i.i.i.i15, double %18, double 0.000000e+00 @@ -109030,11 +109030,11 @@ define hidden void @"_ZN5typst6layout4axes13Axes$LT$T$GT$7zip_map17h9b5eb248ca21 %.0.i.inv.i.i.i.i.i.i.i.i.i.i = fcmp ord double %.sroa.623.0.copyload, 0.000000e+00 %.0.i.i.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i.i.i, double %.sroa.623.0.copyload, double 0.000000e+00 %10 = fmul double %2, %.0.i.i.i.i.i.i.i.i.i.i - %.0.i.inv.i.i.i.i.i.i.i.i = fcmp uno double %10, 0.000000e+00 - %11 = tail call double @llvm.fabs.f64(double %10) + %.0.i.inv.i.i.i.i.i.i.i.i = fcmp ord double %10, 0.000000e+00 + %.0.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double %10, double 0.000000e+00 + %11 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i.i.i) %12 = fcmp one double %11, 0x7FF0000000000000 - %.0.i.i.i.i.i.i.i.i = select i1 %12, double %10, double 0.000000e+00 - %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i.i.i + %.0.i.i.i.i.i = select i1 %12, double %.0.i.i.i.i.i.i.i.i, double 0.000000e+00 %13 = fadd double %9, %.0.i.i.i.i.i %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %13, 0.000000e+00 %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %13, double 0.000000e+00 @@ -109062,11 +109062,11 @@ define hidden void @"_ZN5typst6layout4axes13Axes$LT$T$GT$7zip_map17h9b5eb248ca21 %.0.i.inv.i.i.i.i.i.i.i.i.i.i11 = fcmp ord double %.sroa.632.0.copyload, 0.000000e+00 %.0.i.i.i.i.i.i.i.i.i.i12 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i.i.i11, double %.sroa.632.0.copyload, double 0.000000e+00 %17 = fmul double %3, %.0.i.i.i.i.i.i.i.i.i.i12 - %.0.i.inv.i.i.i.i.i.i.i.i13 = fcmp uno double %17, 0.000000e+00 - %18 = tail call double @llvm.fabs.f64(double %17) + %.0.i.inv.i.i.i.i.i.i.i.i13 = fcmp ord double %17, 0.000000e+00 + %.0.i.i.i.i.i.i.i.i14 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i13, double %17, double 0.000000e+00 + %18 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i.i.i14) %19 = fcmp one double %18, 0x7FF0000000000000 - %.0.i.i.i.i.i.i.i.i14 = select i1 %19, double %17, double 0.000000e+00 - %.0.i.i.i.i.i15 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i13, double 0.000000e+00, double %.0.i.i.i.i.i.i.i.i14 + %.0.i.i.i.i.i15 = select i1 %19, double %.0.i.i.i.i.i.i.i.i14, double 0.000000e+00 %20 = fadd double %16, %.0.i.i.i.i.i15 %.0.i.inv.i.i.i.i.i.i.i16 = fcmp ord double %20, 0.000000e+00 %.0.i.i.i.i.i.i.i17 = select i1 %.0.i.inv.i.i.i.i.i.i.i16, double %20, double 0.000000e+00 @@ -109090,19 +109090,19 @@ define hidden { double, double } @"_ZN5typst6layout4axes13Axes$LT$T$GT$7zip_map1 %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %2, 0.000000e+00 %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %2, double 0.000000e+00 %5 = fmul double %0, %.0.i.i.i.i.i.i.i - %.0.i.inv.i.i.i.i.i = fcmp uno double %5, 0.000000e+00 - %6 = tail call double @llvm.fabs.f64(double %5) + %.0.i.inv.i.i.i.i.i = fcmp ord double %5, 0.000000e+00 + %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %5, double 0.000000e+00 + %6 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i) %7 = fcmp one double %6, 0x7FF0000000000000 - %.0.i.i.i.i.i = select i1 %7, double %5, double 0.000000e+00 - %.0.i.i = select i1 %.0.i.inv.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i + %.0.i.i = select i1 %7, double %.0.i.i.i.i.i, double 0.000000e+00 %.0.i.inv.i.i.i.i.i.i.i10 = fcmp ord double %3, 0.000000e+00 %.0.i.i.i.i.i.i.i11 = select i1 %.0.i.inv.i.i.i.i.i.i.i10, double %3, double 0.000000e+00 %8 = fmul double %1, %.0.i.i.i.i.i.i.i11 - %.0.i.inv.i.i.i.i.i12 = fcmp uno double %8, 0.000000e+00 - %9 = tail call double @llvm.fabs.f64(double %8) + %.0.i.inv.i.i.i.i.i12 = fcmp ord double %8, 0.000000e+00 + %.0.i.i.i.i.i13 = select i1 %.0.i.inv.i.i.i.i.i12, double %8, double 0.000000e+00 + %9 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i13) %10 = fcmp one double %9, 0x7FF0000000000000 - %.0.i.i.i.i.i13 = select i1 %10, double %8, double 0.000000e+00 - %.0.i.i14 = select i1 %.0.i.inv.i.i.i.i.i12, double 0.000000e+00, double %.0.i.i.i.i.i13 + %.0.i.i14 = select i1 %10, double %.0.i.i.i.i.i13, double 0.000000e+00 %11 = insertvalue { double, double } poison, double %.0.i.i, 0 %12 = insertvalue { double, double } %11, double %.0.i.i14, 1 ret { double, double } %12 @@ -109201,11 +109201,11 @@ define hidden void @"_ZN5typst6layout4axes13Axes$LT$T$GT$7zip_map17he0ef55b9c613 %.0.i.inv.i.i.i.i.i.i.i.i.i.i = fcmp ord double %.sroa.415.0.copyload, 0.000000e+00 %.0.i.i.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i.i.i, double %.sroa.415.0.copyload, double 0.000000e+00 %6 = fmul double %2, %.0.i.i.i.i.i.i.i.i.i.i - %.0.i.inv.i.i.i.i.i.i.i.i = fcmp uno double %6, 0.000000e+00 - %7 = tail call double @llvm.fabs.f64(double %6) + %.0.i.inv.i.i.i.i.i.i.i.i = fcmp ord double %6, 0.000000e+00 + %.0.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double %6, double 0.000000e+00 + %7 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i.i.i) %8 = fcmp one double %7, 0x7FF0000000000000 - %.0.i.i.i.i.i.i.i.i = select i1 %8, double %6, double 0.000000e+00 - %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i.i.i + %.0.i.i.i.i.i = select i1 %8, double %.0.i.i.i.i.i.i.i.i, double 0.000000e+00 %9 = fadd double %.sroa.516.0.copyload, %.0.i.i.i.i.i %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %9, 0.000000e+00 %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %9, double 0.000000e+00 @@ -109227,11 +109227,11 @@ define hidden void @"_ZN5typst6layout4axes13Axes$LT$T$GT$7zip_map17he0ef55b9c613 %.0.i.inv.i.i.i.i.i.i.i.i.i.i6 = fcmp ord double %.sroa.422.0.copyload, 0.000000e+00 %.0.i.i.i.i.i.i.i.i.i.i7 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i.i.i6, double %.sroa.422.0.copyload, double 0.000000e+00 %12 = fmul double %3, %.0.i.i.i.i.i.i.i.i.i.i7 - %.0.i.inv.i.i.i.i.i.i.i.i8 = fcmp uno double %12, 0.000000e+00 - %13 = tail call double @llvm.fabs.f64(double %12) + %.0.i.inv.i.i.i.i.i.i.i.i8 = fcmp ord double %12, 0.000000e+00 + %.0.i.i.i.i.i.i.i.i9 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i8, double %12, double 0.000000e+00 + %13 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i.i.i9) %14 = fcmp one double %13, 0x7FF0000000000000 - %.0.i.i.i.i.i.i.i.i9 = select i1 %14, double %12, double 0.000000e+00 - %.0.i.i.i.i.i10 = select i1 %.0.i.inv.i.i.i.i.i.i.i.i8, double 0.000000e+00, double %.0.i.i.i.i.i.i.i.i9 + %.0.i.i.i.i.i10 = select i1 %14, double %.0.i.i.i.i.i.i.i.i9, double 0.000000e+00 %15 = fadd double %.sroa.523.0.copyload, %.0.i.i.i.i.i10 %.0.i.inv.i.i.i.i.i.i.i11 = fcmp ord double %15, 0.000000e+00 %.0.i.i.i.i.i.i.i12 = select i1 %.0.i.inv.i.i.i.i.i.i.i11, double %15, double 0.000000e+00 @@ -109711,11 +109711,11 @@ define hidden noundef double @_ZN5typst6layout5ratio5Ratio2of17h01563bd6c24e0ab7 %.0.i.inv.i.i.i.i.i = fcmp ord double %0, 0.000000e+00 %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %0, double 0.000000e+00 %3 = fmul double %1, %.0.i.i.i.i.i - %.0.i.inv.i.i.i = fcmp uno double %3, 0.000000e+00 - %4 = tail call double @llvm.fabs.f64(double %3) + %.0.i.inv.i.i.i = fcmp ord double %3, 0.000000e+00 + %.0.i.i.i = select i1 %.0.i.inv.i.i.i, double %3, double 0.000000e+00 + %4 = tail call double @llvm.fabs.f64(double %.0.i.i.i) %5 = fcmp one double %4, 0x7FF0000000000000 - %.0.i.i.i = select i1 %5, double %3, double 0.000000e+00 - %.0 = select i1 %.0.i.inv.i.i.i, double 0.000000e+00, double %.0.i.i.i + %.0 = select i1 %5, double %.0.i.i.i, double 0.000000e+00 ret double %.0 } @@ -109724,11 +109724,11 @@ define hidden noundef double @_ZN5typst6layout5ratio5Ratio2of17h09b8bba204c60514 %.0.i.inv.i.i.i.i.i = fcmp ord double %0, 0.000000e+00 %.0.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i, double %0, double 0.000000e+00 %3 = fmul double %1, %.0.i.i.i.i.i - %.0.i.inv.i.i.i = fcmp uno double %3, 0.000000e+00 - %4 = tail call double @llvm.fabs.f64(double %3) + %.0.i.inv.i.i.i = fcmp ord double %3, 0.000000e+00 + %.0.i.i.i = select i1 %.0.i.inv.i.i.i, double %3, double 0.000000e+00 + %4 = tail call double @llvm.fabs.f64(double %.0.i.i.i) %5 = fcmp one double %4, 0x7FF0000000000000 - %.0.i.i.i = select i1 %5, double %3, double 0.000000e+00 - %.0 = select i1 %.0.i.inv.i.i.i, double 0.000000e+00, double %.0.i.i.i + %.0 = select i1 %5, double %.0.i.i.i, double 0.000000e+00 ret double %.0 } @@ -112361,11 +112361,11 @@ define hidden { i64, double } @"_ZN5typst9visualize5shape6layout28_$u7b$$u7b$clo %.0.i.inv.i.i.i.i.i.i.i.i.i = fcmp ord double %.sroa.3.0.copyload.i, 0.000000e+00 %.0.i.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i.i, double %.sroa.3.0.copyload.i, double 0.000000e+00 %10 = fmul double %2, %.0.i.i.i.i.i.i.i.i.i - %.0.i.inv.i.i.i.i.i.i.i = fcmp uno double %10, 0.000000e+00 - %11 = tail call double @llvm.fabs.f64(double %10) + %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %10, 0.000000e+00 + %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %10, double 0.000000e+00 + %11 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i.i) %12 = fcmp one double %11, 0x7FF0000000000000 - %.0.i.i.i.i.i.i.i = select i1 %12, double %10, double 0.000000e+00 - %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i.i + %.0.i.i.i.i = select i1 %12, double %.0.i.i.i.i.i.i.i, double 0.000000e+00 %13 = fadd double %9, %.0.i.i.i.i %.0.i.inv.i.i.i.i.i.i = fcmp ord double %13, 0.000000e+00 %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %13, double 0.000000e+00 @@ -124991,11 +124991,11 @@ define hidden { i64, double } @"_ZN5typst6layout9container94_$LT$impl$u20$typst. %.0.i.inv.i.i.i.i.i.i.i.i.i = fcmp ord double %7, 0.000000e+00 %.0.i.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i.i, double %7, double 0.000000e+00 %10 = fmul double %2, %.0.i.i.i.i.i.i.i.i.i - %.0.i.inv.i.i.i.i.i.i.i = fcmp uno double %10, 0.000000e+00 - %11 = tail call double @llvm.fabs.f64(double %10) + %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %10, 0.000000e+00 + %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %10, double 0.000000e+00 + %11 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i.i) %12 = fcmp one double %11, 0x7FF0000000000000 - %.0.i.i.i.i.i.i.i = select i1 %12, double %10, double 0.000000e+00 - %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i.i + %.0.i.i.i.i = select i1 %12, double %.0.i.i.i.i.i.i.i, double 0.000000e+00 %13 = fadd double %9, %.0.i.i.i.i %.0.i.inv.i.i.i.i.i.i = fcmp ord double %13, 0.000000e+00 %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %13, double 0.000000e+00 @@ -133643,11 +133643,11 @@ define hidden { i64, double } @"_ZN5typst6layout9container138_$LT$impl$u20$typst %.0.i.inv.i.i.i.i.i.i.i.i.i = fcmp ord double %7, 0.000000e+00 %.0.i.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i.i, double %7, double 0.000000e+00 %10 = fmul double %2, %.0.i.i.i.i.i.i.i.i.i - %.0.i.inv.i.i.i.i.i.i.i = fcmp uno double %10, 0.000000e+00 - %11 = tail call double @llvm.fabs.f64(double %10) + %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %10, 0.000000e+00 + %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %10, double 0.000000e+00 + %11 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i.i) %12 = fcmp one double %11, 0x7FF0000000000000 - %.0.i.i.i.i.i.i.i = select i1 %12, double %10, double 0.000000e+00 - %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i.i + %.0.i.i.i.i = select i1 %12, double %.0.i.i.i.i.i.i.i, double 0.000000e+00 %13 = fadd double %9, %.0.i.i.i.i %.0.i.inv.i.i.i.i.i.i = fcmp ord double %13, 0.000000e+00 %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %13, double 0.000000e+00 @@ -141709,11 +141709,11 @@ define hidden noundef double @"_ZN5typst6layout9transform136_$LT$impl$u20$typst. %.0.i.inv.i.i.i.i.i.i = fcmp ord double %2, 0.000000e+00 %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %2, double 0.000000e+00 %4 = fmul double %1, %.0.i.i.i.i.i.i - %.0.i.inv.i.i.i.i = fcmp uno double %4, 0.000000e+00 - %5 = tail call double @llvm.fabs.f64(double %4) + %.0.i.inv.i.i.i.i = fcmp ord double %4, 0.000000e+00 + %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i, double %4, double 0.000000e+00 + %5 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i) %6 = fcmp one double %5, 0x7FF0000000000000 - %.0.i.i.i.i = select i1 %6, double %4, double 0.000000e+00 - %.0.i = select i1 %.0.i.inv.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i + %.0.i = select i1 %6, double %.0.i.i.i.i, double 0.000000e+00 ret double %.0.i } @@ -148500,11 +148500,11 @@ define hidden { i64, double } @"_ZN5typst9visualize5image135_$LT$impl$u20$typst. %.0.i.inv.i.i.i.i.i.i.i.i.i = fcmp ord double %.sroa.3.0.copyload.i, 0.000000e+00 %.0.i.i.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i.i.i, double %.sroa.3.0.copyload.i, double 0.000000e+00 %10 = fmul double %2, %.0.i.i.i.i.i.i.i.i.i - %.0.i.inv.i.i.i.i.i.i.i = fcmp uno double %10, 0.000000e+00 - %11 = tail call double @llvm.fabs.f64(double %10) + %.0.i.inv.i.i.i.i.i.i.i = fcmp ord double %10, 0.000000e+00 + %.0.i.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double %10, double 0.000000e+00 + %11 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i.i) %12 = fcmp one double %11, 0x7FF0000000000000 - %.0.i.i.i.i.i.i.i = select i1 %12, double %10, double 0.000000e+00 - %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i.i.i.i + %.0.i.i.i.i = select i1 %12, double %.0.i.i.i.i.i.i.i, double 0.000000e+00 %13 = fadd double %9, %.0.i.i.i.i %.0.i.inv.i.i.i.i.i.i = fcmp ord double %13, 0.000000e+00 %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %13, double 0.000000e+00 diff --git a/bench/typst-rs/optimized/40w6rezair915kkd.ll b/bench/typst-rs/optimized/40w6rezair915kkd.ll index d10b61486a3..5b69b2e75af 100644 --- a/bench/typst-rs/optimized/40w6rezair915kkd.ll +++ b/bench/typst-rs/optimized/40w6rezair915kkd.ll @@ -91161,11 +91161,11 @@ _ZN5typst4math8fragment19script_alternatives17h3f13278ce2573cd8E.llvm.5857379167 %.0.i.inv.i.i.i.i = fcmp ord double %255, 0.000000e+00 %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i, double %255, double 0.000000e+00 %256 = fmul double %.0.i.i.i.i.i, %.0.i.i.i.i - %.0.i.inv.i.i.i.i.i148 = fcmp uno double %256, 0.000000e+00 - %257 = call double @llvm.fabs.f64(double %256) + %.0.i.inv.i.i.i.i.i148 = fcmp ord double %256, 0.000000e+00 + %.0.i.i.i.i.i149 = select i1 %.0.i.inv.i.i.i.i.i148, double %256, double 0.000000e+00 + %257 = call double @llvm.fabs.f64(double %.0.i.i.i.i.i149) %258 = fcmp one double %257, 0x7FF0000000000000 - %.0.i.i.i.i.i149 = select i1 %258, double %256, double 0.000000e+00 - %.0.i.i150 = select i1 %.0.i.inv.i.i.i.i.i148, double 0.000000e+00, double %.0.i.i.i.i.i149 + %.0.i.i150 = select i1 %258, double %.0.i.i.i.i.i149, double 0.000000e+00 %259 = getelementptr inbounds nuw i8, ptr %57, i64 80 %260 = load double, ptr %259, align 16, !alias.scope !24037, !noundef !4 %261 = getelementptr inbounds nuw i8, ptr %57, i64 88 @@ -91251,11 +91251,11 @@ _ZN5typst4math8fragment19script_alternatives17h3f13278ce2573cd8E.llvm.5857379167 %.0.i.inv.i.i.i.i.i.i = fcmp ord double %293, 0.000000e+00 %.0.i.i.i.i.i.i = select i1 %.0.i.inv.i.i.i.i.i.i, double %293, double 0.000000e+00 %294 = fmul double %287, %.0.i.i.i.i.i.i - %.0.i.inv.i.i.i.i.i.i.i157 = fcmp uno double %294, 0.000000e+00 - %295 = call double @llvm.fabs.f64(double %294) + %.0.i.inv.i.i.i.i.i.i.i157 = fcmp ord double %294, 0.000000e+00 + %.0.i.i.i.i.i.i.i158 = select i1 %.0.i.inv.i.i.i.i.i.i.i157, double %294, double 0.000000e+00 + %295 = call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i.i158) %296 = fcmp one double %295, 0x7FF0000000000000 - %.0.i.i.i.i.i.i.i158 = select i1 %296, double %294, double 0.000000e+00 - %.0.i.i.i.i159 = select i1 %.0.i.inv.i.i.i.i.i.i.i157, double 0.000000e+00, double %.0.i.i.i.i.i.i.i158 + %.0.i.i.i.i159 = select i1 %296, double %.0.i.i.i.i.i.i.i158, double 0.000000e+00 %297 = fmul double %271, 5.000000e-01 %.0.i.inv.i.i.i.i160 = fcmp ord double %297, 0.000000e+00 %.0.i.i.i1.i = select i1 %.0.i.inv.i.i.i.i160, double %297, double 0.000000e+00 @@ -92048,11 +92048,11 @@ _ZN5typst4math8fragment19script_alternatives17h3f13278ce2573cd8E.llvm.5857379167 %.0.i.inv.i.i.i.i.i210 = fcmp ord double %615, 0.000000e+00 %.0.i.i.i.i.i211 = select i1 %.0.i.inv.i.i.i.i.i210, double %615, double 0.000000e+00 %616 = fmul double %.0.i.i.i.i.i203, %.0.i.i.i.i.i211 - %.0.i.inv.i.i.i.i.i.i212 = fcmp uno double %616, 0.000000e+00 - %617 = call double @llvm.fabs.f64(double %616) + %.0.i.inv.i.i.i.i.i.i212 = fcmp ord double %616, 0.000000e+00 + %.0.i.i.i.i.i.i213 = select i1 %.0.i.inv.i.i.i.i.i.i212, double %616, double 0.000000e+00 + %617 = call double @llvm.fabs.f64(double %.0.i.i.i.i.i.i213) %618 = fcmp one double %617, 0x7FF0000000000000 - %.0.i.i.i.i.i.i213 = select i1 %618, double %616, double 0.000000e+00 - %.0.i.i.i214 = select i1 %.0.i.inv.i.i.i.i.i.i212, double 0.000000e+00, double %.0.i.i.i.i.i.i213 + %.0.i.i.i214 = select i1 %618, double %.0.i.i.i.i.i.i213, double 0.000000e+00 %619 = getelementptr inbounds nuw i8, ptr %31, i64 32 %620 = load double, ptr %619, align 8, !alias.scope !24265, !noundef !4 %621 = fmul double %620, 5.000000e-01 @@ -92946,11 +92946,11 @@ define noundef double @"_ZN48_$LT$i16$u20$as$u20$typst..math..ctx..Scaled$GT$6sc %.0.i.inv.i.i.i = fcmp ord double %10, 0.000000e+00 %.0.i.i.i = select i1 %.0.i.inv.i.i.i, double %10, double 0.000000e+00 %11 = fmul double %2, %.0.i.i.i - %.0.i.inv.i.i.i.i = fcmp uno double %11, 0.000000e+00 - %12 = tail call double @llvm.fabs.f64(double %11) + %.0.i.inv.i.i.i.i = fcmp ord double %11, 0.000000e+00 + %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i, double %11, double 0.000000e+00 + %12 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i) %13 = fcmp one double %12, 0x7FF0000000000000 - %.0.i.i.i.i = select i1 %13, double %11, double 0.000000e+00 - %.0.i = select i1 %.0.i.inv.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i + %.0.i = select i1 %13, double %.0.i.i.i.i, double 0.000000e+00 ret double %.0.i } @@ -92968,11 +92968,11 @@ define noundef double @"_ZN48_$LT$u16$u20$as$u20$typst..math..ctx..Scaled$GT$6sc %.0.i.inv.i.i.i = fcmp ord double %10, 0.000000e+00 %.0.i.i.i = select i1 %.0.i.inv.i.i.i, double %10, double 0.000000e+00 %11 = fmul double %2, %.0.i.i.i - %.0.i.inv.i.i.i.i = fcmp uno double %11, 0.000000e+00 - %12 = tail call double @llvm.fabs.f64(double %11) + %.0.i.inv.i.i.i.i = fcmp ord double %11, 0.000000e+00 + %.0.i.i.i.i = select i1 %.0.i.inv.i.i.i.i, double %11, double 0.000000e+00 + %12 = tail call double @llvm.fabs.f64(double %.0.i.i.i.i) %13 = fcmp one double %12, 0x7FF0000000000000 - %.0.i.i.i.i = select i1 %13, double %11, double 0.000000e+00 - %.0.i = select i1 %.0.i.inv.i.i.i.i, double 0.000000e+00, double %.0.i.i.i.i + %.0.i = select i1 %13, double %.0.i.i.i.i, double 0.000000e+00 ret double %.0.i } diff --git a/scripts/setup_pre_commit_patch.sh b/scripts/setup_pre_commit_patch.sh index c5409e09ef4..afe0f275df0 100755 --- a/scripts/setup_pre_commit_patch.sh +++ b/scripts/setup_pre_commit_patch.sh @@ -2,7 +2,7 @@ set -euo pipefail shopt -s inherit_errexit -export GITHUB_PATCH_ID="/llvm-project/commit/" +export GITHUB_PATCH_ID=llvm/llvm-project/pull/122270 export COMPTIME_MODE=0 # Please rebase manually