; LLVM IR from kala13x/libxutils :: tools (xtop)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%struct.xcli_bar_ = type { %struct.xcli_size_, i64, i64, i32, i32, i8, i8, i8, i8, double, i32, i8, i8, i8, i8, i8, i8, [256 x i8], [256 x i8], [256 x i8] }
%struct.xcli_size_ = type { i64, i64 }
%struct.XMemInfo = type { i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64 }

@.str.6 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.61 = external hidden unnamed_addr constant [25 x i8], align 1

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #0

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #0

declare i64 @xstrncpyf(ptr noundef, i64 noundef, ptr noundef, ...) #1

declare i64 @xstrnfill(ptr noundef, i64 noundef, i64 noundef, i8 noundef signext) #1

; Function Attrs: nounwind uwtable
define dso_local i32 @XTOPApp_FillMemoryBar(ptr noundef %0, ptr noundef %1, ptr noundef %2, i64 noundef %3) #2 {
  %5 = alloca i32, align 4
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i64, align 8
  %10 = alloca [2048 x i8], align 16
  %11 = alloca [2048 x i8], align 16
  %12 = alloca [2048 x i8], align 16
  %13 = alloca [2048 x i8], align 16
  %14 = alloca i64, align 8
  %15 = alloca i64, align 8
  %16 = alloca i64, align 8
  %17 = alloca i64, align 8
  %18 = alloca i64, align 8
  %19 = alloca double, align 8
  %20 = alloca double, align 8
  %21 = alloca double, align 8
  %22 = alloca double, align 8
  %23 = alloca i64, align 8
  %24 = alloca i64, align 8
  %25 = alloca i64, align 8
  %26 = alloca i64, align 8
  %27 = alloca i64, align 8
  store ptr %0, ptr %6, align 8, !tbaa !5
  store ptr %1, ptr %7, align 8, !tbaa !5
  store ptr %2, ptr %8, align 8, !tbaa !5
  store i64 %3, ptr %9, align 8, !tbaa !9
  %28 = load ptr, ptr %8, align 8, !tbaa !5
  %29 = icmp eq ptr %28, null
  br i1 %29, label %33, label %30

30:                                               ; preds = %4
  %31 = load i64, ptr %9, align 8, !tbaa !9
  %32 = icmp ne i64 %31, 0
  br i1 %32, label %34, label %33

33:                                               ; preds = %30, %4
  store i32 0, ptr %5, align 4
  br label %237

34:                                               ; preds = %30
  call void @llvm.lifetime.start.p0(i64 2048, ptr %10) #4
  call void @llvm.lifetime.start.p0(i64 2048, ptr %11) #4
  call void @llvm.lifetime.start.p0(i64 2048, ptr %12) #4
  call void @llvm.lifetime.start.p0(i64 2048, ptr %13) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #4
  %35 = load ptr, ptr %6, align 8, !tbaa !5
  %36 = getelementptr inbounds %struct.xcli_bar_, ptr %35, i32 0, i32 1
  %37 = load i64, ptr %36, align 8, !tbaa !11
  store i64 %37, ptr %14, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #4
  %38 = load ptr, ptr %6, align 8, !tbaa !5
  %39 = getelementptr inbounds %struct.xcli_bar_, ptr %38, i32 0, i32 2
  %40 = load i64, ptr %39, align 8, !tbaa !16
  store i64 %40, ptr %15, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #4
  %41 = load ptr, ptr %7, align 8, !tbaa !5
  %42 = getelementptr inbounds %struct.XMemInfo, ptr %41, i32 0, i32 5
  %43 = load i64, ptr %42, align 8, !tbaa !17
  %44 = load ptr, ptr %7, align 8, !tbaa !5
  %45 = getelementptr inbounds %struct.XMemInfo, ptr %44, i32 0, i32 6
  %46 = load i64, ptr %45, align 8, !tbaa !19
  %47 = sub i64 %43, %46
  store i64 %47, ptr %16, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #4
  %48 = load ptr, ptr %7, align 8, !tbaa !5
  %49 = getelementptr inbounds %struct.XMemInfo, ptr %48, i32 0, i32 2
  %50 = load i64, ptr %49, align 8, !tbaa !20
  %51 = load ptr, ptr %7, align 8, !tbaa !5
  %52 = getelementptr inbounds %struct.XMemInfo, ptr %51, i32 0, i32 3
  %53 = load i64, ptr %52, align 8, !tbaa !21
  %54 = sub i64 %50, %53
  store i64 %54, ptr %17, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #4
  %55 = load i64, ptr %16, align 8, !tbaa !9
  %56 = load ptr, ptr %7, align 8, !tbaa !5
  %57 = getelementptr inbounds %struct.XMemInfo, ptr %56, i32 0, i32 11
  %58 = load i64, ptr %57, align 8, !tbaa !22
  %59 = load ptr, ptr %7, align 8, !tbaa !5
  %60 = getelementptr inbounds %struct.XMemInfo, ptr %59, i32 0, i32 2
  %61 = load i64, ptr %60, align 8, !tbaa !20
  %62 = add i64 %58, %61
  %63 = sub i64 %55, %62
  store i64 %63, ptr %18, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #4
  %64 = load i64, ptr %16, align 8, !tbaa !9
  %65 = icmp ne i64 %64, 0
  br i1 %65, label %66, label %75

66:                                               ; preds = %34
  %67 = load i64, ptr %16, align 8, !tbaa !9
  %68 = uitofp i64 %67 to double
  %69 = fdiv double 1.000000e+02, %68
  %70 = load ptr, ptr %7, align 8, !tbaa !5
  %71 = getelementptr inbounds %struct.XMemInfo, ptr %70, i32 0, i32 11
  %72 = load i64, ptr %71, align 8, !tbaa !22
  %73 = uitofp i64 %72 to double
  %74 = fmul double %69, %73
  br label %76

75:                                               ; preds = %34
  br label %76

76:                                               ; preds = %75, %66
  %77 = phi double [ %74, %66 ], [ 0.000000e+00, %75 ]
  store double %77, ptr %19, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #4
  %78 = load i64, ptr %16, align 8, !tbaa !9
  %79 = icmp ne i64 %78, 0
  br i1 %79, label %80, label %89

80:                                               ; preds = %76
  %81 = load i64, ptr %16, align 8, !tbaa !9
  %82 = uitofp i64 %81 to double
  %83 = fdiv double 1.000000e+02, %82
  %84 = load ptr, ptr %7, align 8, !tbaa !5
  %85 = getelementptr inbounds %struct.XMemInfo, ptr %84, i32 0, i32 3
  %86 = load i64, ptr %85, align 8, !tbaa !21
  %87 = uitofp i64 %86 to double
  %88 = fmul double %83, %87
  br label %90

89:                                               ; preds = %76
  br label %90

90:                                               ; preds = %89, %80
  %91 = phi double [ %88, %80 ], [ 0.000000e+00, %89 ]
  store double %91, ptr %20, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #4
  %92 = load i64, ptr %16, align 8, !tbaa !9
  %93 = icmp ne i64 %92, 0
  br i1 %93, label %94, label %101

94:                                               ; preds = %90
  %95 = load i64, ptr %16, align 8, !tbaa !9
  %96 = uitofp i64 %95 to double
  %97 = fdiv double 1.000000e+02, %96
  %98 = load i64, ptr %17, align 8, !tbaa !9
  %99 = uitofp i64 %98 to double
  %100 = fmul double %97, %99
  br label %102

101:                                              ; preds = %90
  br label %102

102:                                              ; preds = %101, %94
  %103 = phi double [ %100, %94 ], [ 0.000000e+00, %101 ]
  store double %103, ptr %21, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #4
  %104 = load i64, ptr %16, align 8, !tbaa !9
  %105 = icmp ne i64 %104, 0
  br i1 %105, label %106, label %113

106:                                              ; preds = %102
  %107 = load i64, ptr %16, align 8, !tbaa !9
  %108 = uitofp i64 %107 to double
  %109 = fdiv double 1.000000e+02, %108
  %110 = load i64, ptr %18, align 8, !tbaa !9
  %111 = uitofp i64 %110 to double
  %112 = fmul double %109, %111
  br label %114

113:                                              ; preds = %102
  br label %114

114:                                              ; preds = %113, %106
  %115 = phi double [ %112, %106 ], [ 0.000000e+00, %113 ]
  store double %115, ptr %22, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #4
  %116 = load i64, ptr %15, align 8, !tbaa !9
  %117 = load double, ptr %19, align 8, !tbaa !23
  %118 = call double @llvm.floor.f64(double %117)
  %119 = fptoui double %118 to i64
  %120 = mul i64 %116, %119
  %121 = udiv i64 %120, 100
  store i64 %121, ptr %23, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #4
  %122 = load i64, ptr %15, align 8, !tbaa !9
  %123 = load double, ptr %20, align 8, !tbaa !23
  %124 = call double @llvm.floor.f64(double %123)
  %125 = fptoui double %124 to i64
  %126 = mul i64 %122, %125
  %127 = udiv i64 %126, 100
  store i64 %127, ptr %24, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #4
  %128 = load i64, ptr %15, align 8, !tbaa !9
  %129 = load double, ptr %21, align 8, !tbaa !23
  %130 = call double @llvm.floor.f64(double %129)
  %131 = fptoui double %130 to i64
  %132 = mul i64 %128, %131
  %133 = udiv i64 %132, 100
  store i64 %133, ptr %25, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #4
  %134 = load i64, ptr %15, align 8, !tbaa !9
  %135 = load double, ptr %22, align 8, !tbaa !23
  %136 = call double @llvm.floor.f64(double %135)
  %137 = fptoui double %136 to i64
  %138 = mul i64 %134, %137
  %139 = udiv i64 %138, 100
  store i64 %139, ptr %26, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #4
  %140 = load i64, ptr %26, align 8, !tbaa !9
  %141 = load i64, ptr %24, align 8, !tbaa !9
  %142 = add i64 %140, %141
  %143 = load i64, ptr %23, align 8, !tbaa !9
  %144 = add i64 %142, %143
  %145 = load i64, ptr %25, align 8, !tbaa !9
  %146 = add i64 %144, %145
  store i64 %146, ptr %27, align 8, !tbaa !9
  %147 = load double, ptr %19, align 8, !tbaa !23
  %148 = fcmp ogt double %147, 0.000000e+00
  br i1 %148, label %149, label %161

149:                                              ; preds = %114
  %150 = load i64, ptr %23, align 8, !tbaa !9
  %151 = icmp ne i64 %150, 0
  br i1 %151, label %161, label %152

152:                                              ; preds = %149
  %153 = load i64, ptr %27, align 8, !tbaa !9
  %154 = load i64, ptr %14, align 8, !tbaa !9
  %155 = icmp ult i64 %153, %154
  br i1 %155, label %156, label %161

156:                                              ; preds = %152
  %157 = load i64, ptr %23, align 8, !tbaa !9
  %158 = add i64 %157, 1
  store i64 %158, ptr %23, align 8, !tbaa !9
  %159 = load i64, ptr %27, align 8, !tbaa !9
  %160 = add i64 %159, 1
  store i64 %160, ptr %27, align 8, !tbaa !9
  br label %161

161:                                              ; preds = %156, %152, %149, %114
  %162 = load double, ptr %20, align 8, !tbaa !23
  %163 = fcmp ogt double %162, 0.000000e+00
  br i1 %163, label %164, label %176

164:                                              ; preds = %161
  %165 = load i64, ptr %24, align 8, !tbaa !9
  %166 = icmp ne i64 %165, 0
  br i1 %166, label %176, label %167

167:                                              ; preds = %164
  %168 = load i64, ptr %27, align 8, !tbaa !9
  %169 = load i64, ptr %14, align 8, !tbaa !9
  %170 = icmp ult i64 %168, %169
  br i1 %170, label %171, label %176

171:                                              ; preds = %167
  %172 = load i64, ptr %24, align 8, !tbaa !9
  %173 = add i64 %172, 1
  store i64 %173, ptr %24, align 8, !tbaa !9
  %174 = load i64, ptr %27, align 8, !tbaa !9
  %175 = add i64 %174, 1
  store i64 %175, ptr %27, align 8, !tbaa !9
  br label %176

176:                                              ; preds = %171, %167, %164, %161
  %177 = load double, ptr %21, align 8, !tbaa !23
  %178 = fcmp ogt double %177, 0.000000e+00
  br i1 %178, label %179, label %191

179:                                              ; preds = %176
  %180 = load i64, ptr %25, align 8, !tbaa !9
  %181 = icmp ne i64 %180, 0
  br i1 %181, label %191, label %182

182:                                              ; preds = %179
  %183 = load i64, ptr %27, align 8, !tbaa !9
  %184 = load i64, ptr %14, align 8, !tbaa !9
  %185 = icmp ult i64 %183, %184
  br i1 %185, label %186, label %191

186:                                              ; preds = %182
  %187 = load i64, ptr %25, align 8, !tbaa !9
  %188 = add i64 %187, 1
  store i64 %188, ptr %25, align 8, !tbaa !9
  %189 = load i64, ptr %27, align 8, !tbaa !9
  %190 = add i64 %189, 1
  store i64 %190, ptr %27, align 8, !tbaa !9
  br label %191

191:                                              ; preds = %186, %182, %179, %176
  %192 = load double, ptr %22, align 8, !tbaa !23
  %193 = fcmp ogt double %192, 0.000000e+00
  br i1 %193, label %194, label %204

194:                                              ; preds = %191
  %195 = load i64, ptr %26, align 8, !tbaa !9
  %196 = icmp ne i64 %195, 0
  br i1 %196, label %204, label %197

197:                                              ; preds = %194
  %198 = load i64, ptr %27, align 8, !tbaa !9
  %199 = load i64, ptr %14, align 8, !tbaa !9
  %200 = icmp ult i64 %198, %199
  br i1 %200, label %201, label %204

201:                                              ; preds = %197
  %202 = load i64, ptr %26, align 8, !tbaa !9
  %203 = add i64 %202, 1
  store i64 %203, ptr %26, align 8, !tbaa !9
  br label %204

204:                                              ; preds = %201, %197, %194, %191
  %205 = getelementptr inbounds [2048 x i8], ptr %10, i64 0, i64 0
  %206 = load i64, ptr %23, align 8, !tbaa !9
  %207 = load ptr, ptr %6, align 8, !tbaa !5
  %208 = getelementptr inbounds %struct.xcli_bar_, ptr %207, i32 0, i32 13
  %209 = load i8, ptr %208, align 2, !tbaa !24
  %210 = call i64 @xstrnfill(ptr noundef %205, i64 noundef 2048, i64 noundef %206, i8 noundef signext %209)
  %211 = getelementptr inbounds [2048 x i8], ptr %12, i64 0, i64 0
  %212 = load i64, ptr %24, align 8, !tbaa !9
  %213 = load ptr, ptr %6, align 8, !tbaa !5
  %214 = getelementptr inbounds %struct.xcli_bar_, ptr %213, i32 0, i32 13
  %215 = load i8, ptr %214, align 2, !tbaa !24
  %216 = call i64 @xstrnfill(ptr noundef %211, i64 noundef 2048, i64 noundef %212, i8 noundef signext %215)
  %217 = getelementptr inbounds [2048 x i8], ptr %13, i64 0, i64 0
  %218 = load i64, ptr %25, align 8, !tbaa !9
  %219 = load ptr, ptr %6, align 8, !tbaa !5
  %220 = getelementptr inbounds %struct.xcli_bar_, ptr %219, i32 0, i32 13
  %221 = load i8, ptr %220, align 2, !tbaa !24
  %222 = call i64 @xstrnfill(ptr noundef %217, i64 noundef 2048, i64 noundef %218, i8 noundef signext %221)
  %223 = getelementptr inbounds [2048 x i8], ptr %11, i64 0, i64 0
  %224 = load i64, ptr %26, align 8, !tbaa !9
  %225 = load ptr, ptr %6, align 8, !tbaa !5
  %226 = getelementptr inbounds %struct.xcli_bar_, ptr %225, i32 0, i32 13
  %227 = load i8, ptr %226, align 2, !tbaa !24
  %228 = call i64 @xstrnfill(ptr noundef %223, i64 noundef 2048, i64 noundef %224, i8 noundef signext %227)
  %229 = load ptr, ptr %8, align 8, !tbaa !5
  %230 = load i64, ptr %9, align 8, !tbaa !9
  %231 = getelementptr inbounds [2048 x i8], ptr %11, i64 0, i64 0
  %232 = getelementptr inbounds [2048 x i8], ptr %10, i64 0, i64 0
  %233 = getelementptr inbounds [2048 x i8], ptr %12, i64 0, i64 0
  %234 = getelementptr inbounds [2048 x i8], ptr %13, i64 0, i64 0
  %235 = call i64 (ptr, i64, ptr, ...) @xstrncpyf(ptr noundef %229, i64 noundef %230, ptr noundef @.str.61, ptr noundef @.str.8, ptr noundef %231, ptr noundef @.str.6, ptr noundef @.str.7, ptr noundef %232, ptr noundef @.str.6, ptr noundef @.str.13, ptr noundef %233, ptr noundef @.str.6, ptr noundef @.str.14, ptr noundef %234, ptr noundef @.str.6)
  %236 = trunc i64 %235 to i32
  store i32 %236, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #4
  call void @llvm.lifetime.end.p0(i64 2048, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 2048, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 2048, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 2048, ptr %10) #4
  br label %237

237:                                              ; preds = %204, %33
  %238 = load i32, ptr %5, align 4
  ret i32 %238
}

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.floor.f64(double) #3

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #4 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !10, i64 16}
!12 = !{!"xcli_bar_", !13, i64 0, !10, i64 16, !10, i64 24, !14, i64 32, !14, i64 36, !7, i64 40, !7, i64 41, !7, i64 42, !7, i64 43, !15, i64 48, !14, i64 56, !7, i64 60, !7, i64 61, !7, i64 62, !7, i64 63, !7, i64 64, !7, i64 65, !7, i64 66, !7, i64 322, !7, i64 578}
!13 = !{!"xcli_size_", !10, i64 0, !10, i64 8}
!14 = !{!"int", !7, i64 0}
!15 = !{!"double", !7, i64 0}
!16 = !{!12, !10, i64 24}
!17 = !{!18, !10, i64 40}
!18 = !{!"XMemInfo", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !10, i64 72, !10, i64 80, !10, i64 88}
!19 = !{!18, !10, i64 48}
!20 = !{!18, !10, i64 16}
!21 = !{!18, !10, i64 24}
!22 = !{!18, !10, i64 88}
!23 = !{!15, !15, i64 0}
!24 = !{!12, !7, i64 62}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

@.str.6 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [6 x i8], align 1
@.str.61 = external hidden unnamed_addr constant [25 x i8], align 1

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #0

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #0

declare i64 @xstrncpyf(ptr noundef, i64 noundef, ptr noundef, ...) local_unnamed_addr #1

declare i64 @xstrnfill(ptr noundef, i64 noundef, i64 noundef, i8 noundef signext) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
define dso_local i32 @XTOPApp_FillMemoryBar(ptr nocapture noundef readonly %0, ptr nocapture noundef readonly %1, ptr noundef %2, i64 noundef %3) local_unnamed_addr #2 {
  %5 = alloca [2048 x i8], align 16
  %6 = alloca [2048 x i8], align 16
  %7 = alloca [2048 x i8], align 16
  %8 = alloca [2048 x i8], align 16
  %9 = icmp ne ptr %2, null
  %10 = icmp ne i64 %3, 0
  %or.cond = and i1 %9, %10
  br i1 %or.cond, label %11, label %86

11:                                               ; preds = %4
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %5) #4
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %6) #4
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %7) #4
  call void @llvm.lifetime.start.p0(i64 2048, ptr nonnull %8) #4
  %12 = getelementptr inbounds i8, ptr %0, i64 16
  %13 = load i64, ptr %12, align 8, !tbaa !5
  %14 = getelementptr inbounds i8, ptr %0, i64 24
  %15 = load i64, ptr %14, align 8, !tbaa !13
  %16 = getelementptr inbounds i8, ptr %1, i64 40
  %17 = load i64, ptr %16, align 8, !tbaa !14
  %18 = getelementptr inbounds i8, ptr %1, i64 48
  %19 = load i64, ptr %18, align 8, !tbaa !16
  %20 = sub i64 %17, %19
  %21 = getelementptr inbounds i8, ptr %1, i64 16
  %22 = load i64, ptr %21, align 8, !tbaa !17
  %23 = getelementptr inbounds i8, ptr %1, i64 24
  %24 = load i64, ptr %23, align 8, !tbaa !18
  %25 = sub i64 %22, %24
  %26 = getelementptr inbounds i8, ptr %1, i64 88
  %27 = load i64, ptr %26, align 8, !tbaa !19
  %28 = add i64 %22, %27
  %29 = sub i64 %20, %28
  %.not = icmp eq i64 %17, %19
  %30 = uitofp i64 %20 to double
  %31 = fdiv double 1.000000e+02, %30
  %32 = uitofp i64 %27 to double
  %33 = fmul double %31, %32
  %34 = select i1 %.not, double 0.000000e+00, double %33
  %35 = uitofp i64 %24 to double
  %36 = fmul double %31, %35
  %37 = select i1 %.not, double 0.000000e+00, double %36
  %38 = uitofp i64 %25 to double
  %39 = fmul double %31, %38
  %40 = select i1 %.not, double 0.000000e+00, double %39
  %41 = uitofp i64 %29 to double
  %42 = fmul double %31, %41
  %43 = select i1 %.not, double 0.000000e+00, double %42
  %44 = tail call double @llvm.floor.f64(double %34)
  %45 = fptoui double %44 to i64
  %46 = mul i64 %15, %45
  %47 = udiv i64 %46, 100
  %48 = tail call double @llvm.floor.f64(double %37)
  %49 = fptoui double %48 to i64
  %50 = mul i64 %15, %49
  %51 = udiv i64 %50, 100
  %52 = tail call double @llvm.floor.f64(double %40)
  %53 = fptoui double %52 to i64
  %54 = mul i64 %15, %53
  %55 = udiv i64 %54, 100
  %56 = tail call double @llvm.floor.f64(double %43)
  %57 = fptoui double %56 to i64
  %58 = mul i64 %15, %57
  %59 = udiv i64 %58, 100
  %60 = add nuw nsw i64 %47, %51
  %61 = add nuw nsw i64 %60, %55
  %62 = add nuw nsw i64 %61, %59
  %63 = fcmp ogt double %34, 0.000000e+00
  %64 = icmp ult i64 %46, 100
  %or.cond3.not = select i1 %63, i1 %64, i1 false
  %65 = icmp ult i64 %62, %13
  %spec.select = zext i1 %65 to i64
  %.080 = select i1 %or.cond3.not, i64 %spec.select, i64 %47
  %narrow = select i1 %or.cond3.not, i1 %65, i1 false
  %spec.select93 = zext i1 %narrow to i64
  %.0 = add nuw nsw i64 %62, %spec.select93
  %66 = fcmp ogt double %37, 0.000000e+00
  %67 = icmp ult i64 %50, 100
  %or.cond5.not = select i1 %66, i1 %67, i1 false
  %68 = icmp ult i64 %.0, %13
  %spec.select94 = zext i1 %68 to i64
  %.079 = select i1 %or.cond5.not, i64 %spec.select94, i64 %51
  %narrow101 = select i1 %or.cond5.not, i1 %68, i1 false
  %spec.select95 = zext i1 %narrow101 to i64
  %.1 = add nuw nsw i64 %.0, %spec.select95
  %69 = fcmp ogt double %40, 0.000000e+00
  %70 = icmp ult i64 %54, 100
  %or.cond7.not = select i1 %69, i1 %70, i1 false
  %71 = icmp ult i64 %.1, %13
  %spec.select96 = zext i1 %71 to i64
  %.078 = select i1 %or.cond7.not, i64 %spec.select96, i64 %55
  %narrow104 = select i1 %or.cond7.not, i1 %71, i1 false
  %spec.select97 = zext i1 %narrow104 to i64
  %.2 = add nuw nsw i64 %.1, %spec.select97
  %72 = fcmp ule double %43, 0.000000e+00
  %73 = icmp ugt i64 %58, 99
  %or.cond9 = select i1 %72, i1 true, i1 %73
  %74 = icmp ult i64 %.2, %13
  %spec.select98 = zext i1 %74 to i64
  %.077 = select i1 %or.cond9, i64 %59, i64 %spec.select98
  %75 = getelementptr inbounds i8, ptr %0, i64 62
  %76 = load i8, ptr %75, align 2, !tbaa !20
  %77 = call i64 @xstrnfill(ptr noundef nonnull %5, i64 noundef 2048, i64 noundef %.080, i8 noundef signext %76) #4
  %78 = load i8, ptr %75, align 2, !tbaa !20
  %79 = call i64 @xstrnfill(ptr noundef nonnull %7, i64 noundef 2048, i64 noundef %.079, i8 noundef signext %78) #4
  %80 = load i8, ptr %75, align 2, !tbaa !20
  %81 = call i64 @xstrnfill(ptr noundef nonnull %8, i64 noundef 2048, i64 noundef %.078, i8 noundef signext %80) #4
  %82 = load i8, ptr %75, align 2, !tbaa !20
  %83 = call i64 @xstrnfill(ptr noundef nonnull %6, i64 noundef 2048, i64 noundef %.077, i8 noundef signext %82) #4
  %84 = call i64 (ptr, i64, ptr, ...) @xstrncpyf(ptr noundef nonnull %2, i64 noundef %3, ptr noundef nonnull @.str.61, ptr noundef nonnull @.str.8, ptr noundef nonnull %6, ptr noundef nonnull @.str.6, ptr noundef nonnull @.str.7, ptr noundef nonnull %5, ptr noundef nonnull @.str.6, ptr noundef nonnull @.str.13, ptr noundef nonnull %7, ptr noundef nonnull @.str.6, ptr noundef nonnull @.str.14, ptr noundef nonnull %8, ptr noundef nonnull @.str.6) #4
  %85 = trunc i64 %84 to i32
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %8) #4
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %6) #4
  call void @llvm.lifetime.end.p0(i64 2048, ptr nonnull %5) #4
  br label %86

86:                                               ; preds = %4, %11
  %.081 = phi i32 [ %85, %11 ], [ 0, %4 ]
  ret i32 %.081
}

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.floor.f64(double) #3

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #4 = { nounwind }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !8, i64 16}
!6 = !{!"xcli_bar_", !7, i64 0, !8, i64 16, !8, i64 24, !11, i64 32, !11, i64 36, !9, i64 40, !9, i64 41, !9, i64 42, !9, i64 43, !12, i64 48, !11, i64 56, !9, i64 60, !9, i64 61, !9, i64 62, !9, i64 63, !9, i64 64, !9, i64 65, !9, i64 66, !9, i64 322, !9, i64 578}
!7 = !{!"xcli_size_", !8, i64 0, !8, i64 8}
!8 = !{!"long", !9, i64 0}
!9 = !{!"omnipotent char", !10, i64 0}
!10 = !{!"Simple C/C++ TBAA"}
!11 = !{!"int", !9, i64 0}
!12 = !{!"double", !9, i64 0}
!13 = !{!6, !8, i64 24}
!14 = !{!15, !8, i64 40}
!15 = !{!"XMemInfo", !8, i64 0, !8, i64 8, !8, i64 16, !8, i64 24, !8, i64 32, !8, i64 40, !8, i64 48, !8, i64 56, !8, i64 64, !8, i64 72, !8, i64 80, !8, i64 88}
!16 = !{!15, !8, i64 48}
!17 = !{!15, !8, i64 16}
!18 = !{!15, !8, i64 24}
!19 = !{!15, !8, i64 88}
!20 = !{!6, !9, i64 62}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass