; LLVM IR from jermp/2i_bench :: external/CRoaring/benchmarks (contains)

; 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.stat = type { i64, i64, i64, i32, i32, i32, i32, i64, i64, i64, i64, %struct.timespec, %struct.timespec, %struct.timespec, [3 x i64] }
%struct.timespec = type { i64, i64 }
%struct.query = type { i32, i32 }

@.str = external hidden unnamed_addr constant [56 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [51 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [54 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [53 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [14 x i8], align 1

; Function Attrs: nounwind uwtable
declare dso_local ptr @read_padding(ptr noundef) #0

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

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

; Function Attrs: nounwind uwtable
define dso_local i32 @main(i32 noundef %0, ptr noundef %1) #0 {
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca %struct.stat, align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca ptr, align 8
  %20 = alloca i32, align 4
  %21 = alloca i32, align 4
  %22 = alloca i32, align 4
  %23 = alloca double, align 8
  %24 = alloca i64, align 8
  %25 = alloca i32, align 4
  %26 = alloca double, align 8
  %27 = alloca i32, align 4
  %28 = alloca double, align 8
  %29 = alloca double, align 8
  %30 = alloca i32, align 4
  store i32 0, ptr %3, align 4
  store i32 %0, ptr %4, align 4, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !9
  %31 = load i32, ptr %4, align 4, !tbaa !5
  %32 = icmp slt i32 %31, 3
  br i1 %32, label %33, label %38

33:                                               ; preds = %2
  %34 = load ptr, ptr %5, align 8, !tbaa !9
  %35 = getelementptr inbounds ptr, ptr %34, i64 0
  %36 = load ptr, ptr %35, align 8, !tbaa !9
  %37 = call i32 (ptr, ...) @printf(ptr noundef @.str, ptr noundef %36)
  store i32 1, ptr %3, align 4
  br label %291

38:                                               ; preds = %2
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #8
  %39 = load ptr, ptr %5, align 8, !tbaa !9
  %40 = getelementptr inbounds ptr, ptr %39, i64 1
  %41 = load ptr, ptr %40, align 8, !tbaa !9
  store ptr %41, ptr %6, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #8
  %42 = load ptr, ptr %5, align 8, !tbaa !9
  %43 = getelementptr inbounds ptr, ptr %42, i64 2
  %44 = load ptr, ptr %43, align 8, !tbaa !9
  %45 = call i32 @atoi(ptr noundef %44) #9
  store i32 %45, ptr %7, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #8
  %46 = load ptr, ptr %6, align 8, !tbaa !9
  %47 = call i32 (ptr, i32, ...) @open(ptr noundef %46, i32 noundef 0)
  store i32 %47, ptr %8, align 4, !tbaa !5
  %48 = load i32, ptr %8, align 4, !tbaa !5
  %49 = icmp eq i32 %48, -1
  br i1 %49, label %50, label %53

50:                                               ; preds = %38
  %51 = load ptr, ptr %6, align 8, !tbaa !9
  %52 = call i32 (ptr, ...) @printf(ptr noundef @.str.1, ptr noundef %51)
  call void @exit(i32 noundef 1) #10
  unreachable

53:                                               ; preds = %38
  call void @llvm.lifetime.start.p0(i64 144, ptr %9) #8
  %54 = load i32, ptr %8, align 4, !tbaa !5
  %55 = call i32 @fstat(i32 noundef %54, ptr noundef %9) #8
  %56 = icmp eq i32 %55, -1
  br i1 %56, label %57, label %60

57:                                               ; preds = %53
  %58 = load ptr, ptr %6, align 8, !tbaa !9
  %59 = call i32 (ptr, ...) @printf(ptr noundef @.str.2, ptr noundef %58)
  call void @exit(i32 noundef 1) #10
  unreachable

60:                                               ; preds = %53
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #8
  store i32 0, ptr %10, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #8
  store i32 0, ptr %11, align 4, !tbaa !5
  %61 = load i32, ptr %8, align 4, !tbaa !5
  %62 = call i64 @read(i32 noundef %61, ptr noundef %10, i64 noundef 4)
  %63 = load i32, ptr %8, align 4, !tbaa !5
  %64 = call i64 @read(i32 noundef %63, ptr noundef %11, i64 noundef 4)
  %65 = load i32, ptr %10, align 4, !tbaa !5
  %66 = call i32 (ptr, ...) @printf(ptr noundef @.str.3, i32 noundef %65)
  %67 = load i32, ptr %11, align 4, !tbaa !5
  %68 = call i32 (ptr, ...) @printf(ptr noundef @.str.4, i32 noundef %67)
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #8
  %69 = load i32, ptr %10, align 4, !tbaa !5
  %70 = zext i32 %69 to i64
  %71 = mul i64 %70, 4
  %72 = call noalias ptr @malloc(i64 noundef %71) #11
  store ptr %72, ptr %12, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #8
  %73 = load i32, ptr %10, align 4, !tbaa !5
  %74 = zext i32 %73 to i64
  %75 = mul i64 %74, 8
  %76 = call noalias ptr @malloc(i64 noundef %75) #11
  store ptr %76, ptr %13, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #8
  %77 = getelementptr inbounds %struct.stat, ptr %9, i32 0, i32 8
  %78 = load i64, ptr %77, align 8, !tbaa !11
  %79 = load i32, ptr %8, align 4, !tbaa !5
  %80 = call ptr @mmap(ptr noundef null, i64 noundef %78, i32 noundef 1, i32 noundef 1, i32 noundef %79, i64 noundef 0) #8
  store ptr %80, ptr %14, align 8, !tbaa !9
  %81 = load ptr, ptr %14, align 8, !tbaa !9
  %82 = icmp ne ptr %81, null
  br i1 %82, label %85, label %83

83:                                               ; preds = %60
  %84 = call i32 (ptr, ...) @printf(ptr noundef @.str.5)
  call void @exit(i32 noundef 1) #10
  unreachable

85:                                               ; preds = %60
  %86 = load ptr, ptr %14, align 8, !tbaa !9
  %87 = getelementptr inbounds i8, ptr %86, i64 8
  store ptr %87, ptr %14, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #8
  store i32 0, ptr %15, align 4, !tbaa !5
  br label %88

88:                                               ; preds = %102, %85
  %89 = load i32, ptr %15, align 4, !tbaa !5
  %90 = load i32, ptr %10, align 4, !tbaa !5
  %91 = icmp ne i32 %89, %90
  br i1 %91, label %93, label %92

92:                                               ; preds = %88
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #8
  br label %105

93:                                               ; preds = %88
  %94 = load ptr, ptr %14, align 8, !tbaa !9
  %95 = load i32, ptr %94, align 4, !tbaa !5
  %96 = load ptr, ptr %12, align 8, !tbaa !9
  %97 = load i32, ptr %15, align 4, !tbaa !5
  %98 = zext i32 %97 to i64
  %99 = getelementptr inbounds i32, ptr %96, i64 %98
  store i32 %95, ptr %99, align 4, !tbaa !5
  %100 = load ptr, ptr %14, align 8, !tbaa !9
  %101 = getelementptr inbounds i8, ptr %100, i64 4
  store ptr %101, ptr %14, align 8, !tbaa !9
  br label %102

102:                                              ; preds = %93
  %103 = load i32, ptr %15, align 4, !tbaa !5
  %104 = add i32 %103, 1
  store i32 %104, ptr %15, align 4, !tbaa !5
  br label %88, !llvm.loop !15

105:                                              ; preds = %92
  %106 = call i32 (ptr, ...) @printf(ptr noundef @.str.6)
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #8
  store i32 0, ptr %16, align 4, !tbaa !5
  br label %107

107:                                              ; preds = %141, %105
  %108 = load i32, ptr %16, align 4, !tbaa !5
  %109 = load i32, ptr %10, align 4, !tbaa !5
  %110 = icmp ne i32 %108, %109
  br i1 %110, label %112, label %111

111:                                              ; preds = %107
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #8
  br label %144

112:                                              ; preds = %107
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #8
  %113 = load ptr, ptr %12, align 8, !tbaa !9
  %114 = load i32, ptr %16, align 4, !tbaa !5
  %115 = zext i32 %114 to i64
  %116 = getelementptr inbounds i32, ptr %113, i64 %115
  %117 = load i32, ptr %116, align 4, !tbaa !5
  store i32 %117, ptr %17, align 4, !tbaa !5
  %118 = load ptr, ptr %14, align 8, !tbaa !9
  %119 = call ptr @read_padding(ptr noundef %118)
  store ptr %119, ptr %14, align 8, !tbaa !9
  %120 = load ptr, ptr %14, align 8, !tbaa !9
  %121 = load i32, ptr %17, align 4, !tbaa !5
  %122 = zext i32 %121 to i64
  %123 = call ptr @roaring_bitmap_frozen_view(ptr noundef %120, i64 noundef %122)
  %124 = load ptr, ptr %13, align 8, !tbaa !9
  %125 = load i32, ptr %16, align 4, !tbaa !5
  %126 = zext i32 %125 to i64
  %127 = getelementptr inbounds ptr, ptr %124, i64 %126
  store ptr %123, ptr %127, align 8, !tbaa !9
  %128 = load ptr, ptr %13, align 8, !tbaa !9
  %129 = load i32, ptr %16, align 4, !tbaa !5
  %130 = zext i32 %129 to i64
  %131 = getelementptr inbounds ptr, ptr %128, i64 %130
  %132 = load ptr, ptr %131, align 8, !tbaa !9
  %133 = icmp eq ptr %132, null
  br i1 %133, label %134, label %136

134:                                              ; preds = %112
  %135 = call i32 (ptr, ...) @printf(ptr noundef @.str.7)
  call void @exit(i32 noundef 1) #10
  unreachable

136:                                              ; preds = %112
  %137 = load i32, ptr %17, align 4, !tbaa !5
  %138 = load ptr, ptr %14, align 8, !tbaa !9
  %139 = zext i32 %137 to i64
  %140 = getelementptr inbounds i8, ptr %138, i64 %139
  store ptr %140, ptr %14, align 8, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #8
  br label %141

141:                                              ; preds = %136
  %142 = load i32, ptr %16, align 4, !tbaa !5
  %143 = add i32 %142, 1
  store i32 %143, ptr %16, align 4, !tbaa !5
  br label %107, !llvm.loop !17

144:                                              ; preds = %111
  %145 = load ptr, ptr %12, align 8, !tbaa !9
  call void @free(ptr noundef %145) #8
  %146 = load i32, ptr %10, align 4, !tbaa !5
  %147 = icmp eq i32 %146, 1
  br i1 %147, label %148, label %150

148:                                              ; preds = %144
  %149 = call i32 (ptr, ...) @printf(ptr noundef @.str.8)
  store i32 1, ptr %3, align 4
  store i32 1, ptr %18, align 4
  br label %290

150:                                              ; preds = %144
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #8
  %151 = load i32, ptr %7, align 4, !tbaa !5
  %152 = zext i32 %151 to i64
  %153 = mul i64 %152, 8
  %154 = call noalias ptr @malloc(i64 noundef %153) #11
  store ptr %154, ptr %19, align 8, !tbaa !9
  %155 = call i32 (ptr, ...) @printf(ptr noundef @.str.9)
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #8
  store i32 0, ptr %20, align 4, !tbaa !5
  br label %156

156:                                              ; preds = %185, %150
  %157 = load i32, ptr %20, align 4, !tbaa !5
  %158 = load i32, ptr %7, align 4, !tbaa !5
  %159 = icmp ne i32 %157, %158
  br i1 %159, label %161, label %160

160:                                              ; preds = %156
  store i32 8, ptr %18, align 4
  br label %188

161:                                              ; preds = %156
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #8
  %162 = load ptr, ptr %19, align 8, !tbaa !9
  %163 = load i32, ptr %20, align 4, !tbaa !5
  %164 = zext i32 %163 to i64
  %165 = getelementptr inbounds %struct.query, ptr %162, i64 %164
  %166 = getelementptr inbounds %struct.query, ptr %165, i32 0, i32 0
  %167 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.10, ptr noundef %166)
  store i32 %167, ptr %21, align 4, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #8
  %168 = load ptr, ptr %19, align 8, !tbaa !9
  %169 = load i32, ptr %20, align 4, !tbaa !5
  %170 = zext i32 %169 to i64
  %171 = getelementptr inbounds %struct.query, ptr %168, i64 %170
  %172 = getelementptr inbounds %struct.query, ptr %171, i32 0, i32 1
  %173 = call i32 (ptr, ...) @__isoc99_scanf(ptr noundef @.str.10, ptr noundef %172)
  store i32 %173, ptr %22, align 4, !tbaa !5
  %174 = load i32, ptr %21, align 4, !tbaa !5
  %175 = icmp eq i32 %174, -1
  br i1 %175, label %179, label %176

176:                                              ; preds = %161
  %177 = load i32, ptr %22, align 4, !tbaa !5
  %178 = icmp eq i32 %177, -1
  br i1 %178, label %179, label %181

179:                                              ; preds = %176, %161
  %180 = load i32, ptr %20, align 4, !tbaa !5
  store i32 %180, ptr %7, align 4, !tbaa !5
  store i32 8, ptr %18, align 4
  br label %182

181:                                              ; preds = %176
  store i32 0, ptr %18, align 4
  br label %182

182:                                              ; preds = %181, %179
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #8
  %183 = load i32, ptr %18, align 4
  switch i32 %183, label %188 [
    i32 0, label %184
  ]

184:                                              ; preds = %182
  br label %185

185:                                              ; preds = %184
  %186 = load i32, ptr %20, align 4, !tbaa !5
  %187 = add i32 %186, 1
  store i32 %187, ptr %20, align 4, !tbaa !5
  br label %156, !llvm.loop !18

188:                                              ; preds = %182, %160
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #8
  br label %189

189:                                              ; preds = %188
  %190 = load i32, ptr %7, align 4, !tbaa !5
  %191 = call i32 (ptr, ...) @printf(ptr noundef @.str.11, i32 noundef %190)
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #8
  store double 0.000000e+00, ptr %23, align 8, !tbaa !19
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #8
  store i64 0, ptr %24, align 8, !tbaa !21
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #8
  store i32 0, ptr %25, align 4, !tbaa !5
  br label %192

192:                                              ; preds = %239, %189
  %193 = load i32, ptr %25, align 4, !tbaa !5
  %194 = icmp ne i32 %193, 4
  br i1 %194, label %196, label %195

195:                                              ; preds = %192
  store i32 11, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #8
  br label %242

196:                                              ; preds = %192
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #8
  %197 = call double @get_time_usecs()
  store double %197, ptr %26, align 8, !tbaa !19
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #8
  store i32 0, ptr %27, align 4, !tbaa !5
  br label %198

198:                                              ; preds = %224, %196
  %199 = load i32, ptr %27, align 4, !tbaa !5
  %200 = load i32, ptr %7, align 4, !tbaa !5
  %201 = icmp ne i32 %199, %200
  br i1 %201, label %203, label %202

202:                                              ; preds = %198
  store i32 14, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #8
  br label %227

203:                                              ; preds = %198
  %204 = load ptr, ptr %13, align 8, !tbaa !9
  %205 = load ptr, ptr %19, align 8, !tbaa !9
  %206 = load i32, ptr %27, align 4, !tbaa !5
  %207 = zext i32 %206 to i64
  %208 = getelementptr inbounds %struct.query, ptr %205, i64 %207
  %209 = getelementptr inbounds %struct.query, ptr %208, i32 0, i32 0
  %210 = load i32, ptr %209, align 4, !tbaa !22
  %211 = zext i32 %210 to i64
  %212 = getelementptr inbounds ptr, ptr %204, i64 %211
  %213 = load ptr, ptr %212, align 8, !tbaa !9
  %214 = load ptr, ptr %19, align 8, !tbaa !9
  %215 = load i32, ptr %27, align 4, !tbaa !5
  %216 = zext i32 %215 to i64
  %217 = getelementptr inbounds %struct.query, ptr %214, i64 %216
  %218 = getelementptr inbounds %struct.query, ptr %217, i32 0, i32 1
  %219 = load i32, ptr %218, align 4, !tbaa !24
  %220 = call zeroext i1 @roaring_bitmap_contains(ptr noundef %213, i32 noundef %219)
  %221 = zext i1 %220 to i64
  %222 = load i64, ptr %24, align 8, !tbaa !21
  %223 = add i64 %222, %221
  store i64 %223, ptr %24, align 8, !tbaa !21
  br label %224

224:                                              ; preds = %203
  %225 = load i32, ptr %27, align 4, !tbaa !5
  %226 = add i32 %225, 1
  store i32 %226, ptr %27, align 4, !tbaa !5
  br label %198, !llvm.loop !25

227:                                              ; preds = %202
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #8
  %228 = call double @get_time_usecs()
  store double %228, ptr %28, align 8, !tbaa !19
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #8
  %229 = load double, ptr %28, align 8, !tbaa !19
  %230 = load double, ptr %26, align 8, !tbaa !19
  %231 = fsub double %229, %230
  store double %231, ptr %29, align 8, !tbaa !19
  %232 = load i32, ptr %25, align 4, !tbaa !5
  %233 = icmp ne i32 %232, 0
  br i1 %233, label %234, label %238

234:                                              ; preds = %227
  %235 = load double, ptr %29, align 8, !tbaa !19
  %236 = load double, ptr %23, align 8, !tbaa !19
  %237 = fadd double %236, %235
  store double %237, ptr %23, align 8, !tbaa !19
  br label %238

238:                                              ; preds = %234, %227
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #8
  br label %239

239:                                              ; preds = %238
  %240 = load i32, ptr %25, align 4, !tbaa !5
  %241 = add nsw i32 %240, 1
  store i32 %241, ptr %25, align 4, !tbaa !5
  br label %192, !llvm.loop !26

242:                                              ; preds = %195
  %243 = load i64, ptr %24, align 8, !tbaa !21
  %244 = call i32 (ptr, ...) @printf(ptr noundef @.str.12, i64 noundef %243)
  %245 = load i32, ptr %7, align 4, !tbaa !5
  %246 = load double, ptr %23, align 8, !tbaa !19
  %247 = fdiv double %246, 3.000000e+00
  %248 = call i32 (ptr, ...) @printf(ptr noundef @.str.13, i32 noundef %245, double noundef %247, i32 noundef 3)
  %249 = load double, ptr %23, align 8, !tbaa !19
  %250 = fdiv double %249, 3.000000e+00
  %251 = load i32, ptr %7, align 4, !tbaa !5
  %252 = uitofp i32 %251 to double
  %253 = fdiv double %250, %252
  %254 = load i32, ptr %7, align 4, !tbaa !5
  %255 = call i32 (ptr, ...) @printf(ptr noundef @.str.14, double noundef %253, i32 noundef %254)
  call void @llvm.lifetime.start.p0(i64 4, ptr %30) #8
  store i32 0, ptr %30, align 4, !tbaa !5
  br label %256

256:                                              ; preds = %271, %242
  %257 = load i32, ptr %30, align 4, !tbaa !5
  %258 = load i32, ptr %10, align 4, !tbaa !5
  %259 = icmp ne i32 %257, %258
  br i1 %259, label %261, label %260

260:                                              ; preds = %256
  store i32 17, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %30) #8
  br label %274

261:                                              ; preds = %256
  %262 = load ptr, ptr %13, align 8, !tbaa !9
  %263 = load i32, ptr %30, align 4, !tbaa !5
  %264 = zext i32 %263 to i64
  %265 = getelementptr inbounds ptr, ptr %262, i64 %264
  %266 = load ptr, ptr %265, align 8, !tbaa !9
  call void @roaring_bitmap_free(ptr noundef %266)
  %267 = load ptr, ptr %13, align 8, !tbaa !9
  %268 = load i32, ptr %30, align 4, !tbaa !5
  %269 = zext i32 %268 to i64
  %270 = getelementptr inbounds ptr, ptr %267, i64 %269
  store ptr null, ptr %270, align 8, !tbaa !9
  br label %271

271:                                              ; preds = %261
  %272 = load i32, ptr %30, align 4, !tbaa !5
  %273 = add i32 %272, 1
  store i32 %273, ptr %30, align 4, !tbaa !5
  br label %256, !llvm.loop !27

274:                                              ; preds = %260
  %275 = load ptr, ptr %13, align 8, !tbaa !9
  call void @free(ptr noundef %275) #8
  %276 = load ptr, ptr %14, align 8, !tbaa !9
  %277 = getelementptr inbounds %struct.stat, ptr %9, i32 0, i32 8
  %278 = load i64, ptr %277, align 8, !tbaa !11
  %279 = sub i64 0, %278
  %280 = getelementptr inbounds i8, ptr %276, i64 %279
  %281 = getelementptr inbounds %struct.stat, ptr %9, i32 0, i32 8
  %282 = load i64, ptr %281, align 8, !tbaa !11
  %283 = call i32 @munmap(ptr noundef %280, i64 noundef %282) #8
  %284 = icmp eq i32 %283, -1
  br i1 %284, label %285, label %287

285:                                              ; preds = %274
  %286 = call i32 (ptr, ...) @printf(ptr noundef @.str.15)
  call void @exit(i32 noundef 1) #10
  unreachable

287:                                              ; preds = %274
  %288 = load i32, ptr %8, align 4, !tbaa !5
  %289 = call i32 @close(i32 noundef %288)
  store i32 0, ptr %3, align 4
  store i32 1, ptr %18, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #8
  br label %290

290:                                              ; preds = %287, %148
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #8
  call void @llvm.lifetime.end.p0(i64 144, ptr %9) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #8
  br label %291

291:                                              ; preds = %290, %33
  %292 = load i32, ptr %3, align 4
  ret i32 %292
}

declare i32 @printf(ptr noundef, ...) #2

; Function Attrs: inlinehint nounwind willreturn memory(read) uwtable
declare i32 @atoi(ptr noundef nonnull) #3

declare i32 @open(ptr noundef, i32 noundef, ...) #2

; Function Attrs: noreturn nounwind
declare void @exit(i32 noundef) #4

; Function Attrs: nounwind
declare i32 @fstat(i32 noundef, ptr noundef) #5

declare i64 @read(i32 noundef, ptr noundef, i64 noundef) #2

; Function Attrs: nounwind allocsize(0)
declare noalias ptr @malloc(i64 noundef) #6

; Function Attrs: nounwind
declare ptr @mmap(ptr noundef, i64 noundef, i32 noundef, i32 noundef, i32 noundef, i64 noundef) #5

declare ptr @roaring_bitmap_frozen_view(ptr noundef, i64 noundef) #2

; Function Attrs: nounwind
declare void @free(ptr noundef) #5

declare i32 @__isoc99_scanf(ptr noundef, ...) #2

; Function Attrs: inlinehint nounwind uwtable
declare zeroext i1 @roaring_bitmap_contains(ptr noundef, i32 noundef) #7

declare void @roaring_bitmap_free(ptr noundef) #2

; Function Attrs: nounwind
declare i32 @munmap(ptr noundef, i64 noundef) #5

declare i32 @close(i32 noundef) #2

; Function Attrs: inlinehint nounwind uwtable
declare double @get_time_usecs() #7

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "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 = { inlinehint nounwind willreturn memory(read) 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 #4 = { noreturn nounwind "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 #5 = { nounwind "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 #6 = { nounwind allocsize(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 #7 = { inlinehint 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 #8 = { nounwind }
attributes #9 = { nounwind willreturn memory(read) }
attributes #10 = { noreturn nounwind }
attributes #11 = { nounwind allocsize(0) }

!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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = !{!12, !13, i64 48}
!12 = !{!"stat", !13, i64 0, !13, i64 8, !13, i64 16, !6, i64 24, !6, i64 28, !6, i64 32, !6, i64 36, !13, i64 40, !13, i64 48, !13, i64 56, !13, i64 64, !14, i64 72, !14, i64 88, !14, i64 104, !7, i64 120}
!13 = !{!"long", !7, i64 0}
!14 = !{!"timespec", !13, i64 0, !13, i64 8}
!15 = distinct !{!15, !16}
!16 = !{!"llvm.loop.mustprogress"}
!17 = distinct !{!17, !16}
!18 = distinct !{!18, !16}
!19 = !{!20, !20, i64 0}
!20 = !{!"double", !7, i64 0}
!21 = !{!13, !13, i64 0}
!22 = !{!23, !6, i64 0}
!23 = !{!"", !6, i64 0, !6, i64 4}
!24 = !{!23, !6, i64 4}
!25 = distinct !{!25, !16}
!26 = distinct !{!26, !16}
!27 = distinct !{!27, !16}


; 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"

%struct.stat = type { i64, i64, i64, i32, i32, i32, i32, i64, i64, i64, i64, %struct.timespec, %struct.timespec, %struct.timespec, [3 x i64] }
%struct.timespec = type { i64, i64 }
%struct.query = type { i32, i32 }

@.str = external hidden unnamed_addr constant [56 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [13 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [51 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [54 x i8], align 1
@.str.14 = external hidden unnamed_addr constant [53 x i8], align 1
@.str.15 = external hidden unnamed_addr constant [14 x i8], align 1

; Function Attrs: nounwind uwtable
declare dso_local ptr @read_padding(ptr noundef) local_unnamed_addr #0

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

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

; Function Attrs: nounwind uwtable
define dso_local range(i32 0, 2) i32 @main(i32 noundef %0, ptr nocapture noundef readonly %1) local_unnamed_addr #0 {
  %3 = alloca %struct.stat, align 8
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  %6 = icmp slt i32 %0, 3
  br i1 %6, label %7, label %10

7:                                                ; preds = %2
  %8 = load ptr, ptr %1, align 8, !tbaa !5
  %9 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str, ptr noundef %8)
  br label %166

10:                                               ; preds = %2
  %11 = getelementptr inbounds i8, ptr %1, i64 8
  %12 = load ptr, ptr %11, align 8, !tbaa !5
  %13 = getelementptr inbounds i8, ptr %1, i64 16
  %14 = load ptr, ptr %13, align 8, !tbaa !5
  %15 = tail call i32 @atoi(ptr nocapture noundef %14) #12
  %16 = tail call i32 (ptr, i32, ...) @open(ptr noundef %12, i32 noundef 0) #13
  %17 = icmp eq i32 %16, -1
  br i1 %17, label %18, label %20

18:                                               ; preds = %10
  %19 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.1, ptr noundef %12)
  tail call void @exit(i32 noundef 1) #14
  unreachable

20:                                               ; preds = %10
  call void @llvm.lifetime.start.p0(i64 144, ptr nonnull %3) #13
  %21 = call i32 @fstat(i32 noundef %16, ptr noundef nonnull %3) #13
  %22 = icmp eq i32 %21, -1
  br i1 %22, label %23, label %25

23:                                               ; preds = %20
  %24 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.2, ptr noundef %12)
  tail call void @exit(i32 noundef 1) #14
  unreachable

25:                                               ; preds = %20
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #13
  store i32 0, ptr %4, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #13
  store i32 0, ptr %5, align 4, !tbaa !9
  %26 = call i64 @read(i32 noundef %16, ptr noundef nonnull %4, i64 noundef 4) #13
  %27 = call i64 @read(i32 noundef %16, ptr noundef nonnull %5, i64 noundef 4) #13
  %28 = load i32, ptr %4, align 4, !tbaa !9
  %29 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.3, i32 noundef %28)
  %30 = load i32, ptr %5, align 4, !tbaa !9
  %31 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.4, i32 noundef %30)
  %32 = zext i32 %28 to i64
  %33 = shl nuw nsw i64 %32, 2
  %34 = tail call noalias ptr @malloc(i64 noundef %33) #15
  %35 = shl nuw nsw i64 %32, 3
  %36 = tail call noalias ptr @malloc(i64 noundef %35) #15
  %37 = getelementptr inbounds i8, ptr %3, i64 48
  %38 = load i64, ptr %37, align 8, !tbaa !11
  %39 = tail call ptr @mmap(ptr noundef null, i64 noundef %38, i32 noundef 1, i32 noundef 1, i32 noundef %16, i64 noundef 0) #13
  %.not = icmp eq ptr %39, null
  br i1 %.not, label %40, label %42

40:                                               ; preds = %25
  %41 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.5)
  tail call void @exit(i32 noundef 1) #14
  unreachable

42:                                               ; preds = %25
  %43 = getelementptr i8, ptr %39, i64 8
  %.not96107 = icmp eq i32 %28, 0
  br i1 %.not96107, label %._crit_edge115.thread, label %.lr.ph114.preheader

._crit_edge115.thread:                            ; preds = %42
  %44 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.6)
  tail call void @free(ptr noundef %34) #13
  br label %64

.lr.ph114.preheader:                              ; preds = %42
  tail call void @llvm.memcpy.p0.p0.i64(ptr align 4 %34, ptr align 4 %43, i64 %33, i1 false), !tbaa !9
  %45 = add i32 %28, -1
  %46 = zext i32 %45 to i64
  %47 = shl nuw nsw i64 %46, 2
  %48 = getelementptr i8, ptr %39, i64 %47
  %scevgep = getelementptr i8, ptr %48, i64 12
  %49 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.6)
  br label %.lr.ph114

._crit_edge115:                                   ; preds = %60
  tail call void @free(ptr noundef nonnull %34) #13
  %50 = icmp eq i32 %28, 1
  br i1 %50, label %62, label %64

.lr.ph114:                                        ; preds = %.lr.ph114.preheader, %60
  %indvars.iv = phi i64 [ 0, %.lr.ph114.preheader ], [ %indvars.iv.next, %60 ]
  %.184112 = phi ptr [ %scevgep, %.lr.ph114.preheader ], [ %61, %60 ]
  %51 = getelementptr inbounds i32, ptr %34, i64 %indvars.iv
  %52 = load i32, ptr %51, align 4, !tbaa !9
  %53 = tail call ptr @read_padding(ptr noundef %.184112)
  %54 = zext i32 %52 to i64
  %55 = tail call ptr @roaring_bitmap_frozen_view(ptr noundef %53, i64 noundef %54) #13
  %56 = getelementptr inbounds ptr, ptr %36, i64 %indvars.iv
  store ptr %55, ptr %56, align 8, !tbaa !5
  %57 = icmp eq ptr %55, null
  br i1 %57, label %58, label %60

58:                                               ; preds = %.lr.ph114
  %59 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.7)
  tail call void @exit(i32 noundef 1) #14
  unreachable

60:                                               ; preds = %.lr.ph114
  %61 = getelementptr inbounds i8, ptr %53, i64 %54
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %.not97 = icmp eq i64 %indvars.iv.next, %32
  br i1 %.not97, label %._crit_edge115, label %.lr.ph114, !llvm.loop !15

62:                                               ; preds = %._crit_edge115
  %63 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.8)
  br label %165

64:                                               ; preds = %._crit_edge115.thread, %._crit_edge115
  %.184.lcssa160 = phi ptr [ %43, %._crit_edge115.thread ], [ %61, %._crit_edge115 ]
  %65 = zext i32 %15 to i64
  %66 = shl nuw nsw i64 %65, 3
  %67 = tail call noalias ptr @malloc(i64 noundef %66) #15
  %68 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.9)
  %.not98118 = icmp eq i32 %15, 0
  br i1 %.not98118, label %._crit_edge122.thread, label %.lr.ph121

._crit_edge122.thread:                            ; preds = %64
  %69 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.11, i32 noundef 0)
  br label %.split.us.preheader

.lr.ph121:                                        ; preds = %64, %76
  %indvars.iv149 = phi i64 [ %indvars.iv.next150, %76 ], [ 0, %64 ]
  %70 = getelementptr inbounds %struct.query, ptr %67, i64 %indvars.iv149
  %71 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.10, ptr noundef %70)
  %72 = getelementptr inbounds i8, ptr %70, i64 4
  %73 = tail call i32 (ptr, ...) @__isoc99_scanf(ptr noundef nonnull @.str.10, ptr noundef nonnull %72)
  %74 = icmp ne i32 %71, -1
  %75 = icmp ne i32 %73, -1
  %or.cond.not = and i1 %74, %75
  br i1 %or.cond.not, label %76, label %._crit_edge122.split.loop.exit

76:                                               ; preds = %.lr.ph121
  %indvars.iv.next150 = add nuw nsw i64 %indvars.iv149, 1
  %.not98 = icmp eq i64 %indvars.iv.next150, %65
  br i1 %.not98, label %._crit_edge122, label %.lr.ph121, !llvm.loop !17

._crit_edge122.split.loop.exit:                   ; preds = %.lr.ph121
  %77 = trunc nuw i64 %indvars.iv149 to i32
  br label %._crit_edge122

._crit_edge122:                                   ; preds = %76, %._crit_edge122.split.loop.exit
  %.2 = phi i32 [ %77, %._crit_edge122.split.loop.exit ], [ %15, %76 ]
  %78 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.11, i32 noundef %.2)
  %.not103126 = icmp eq i32 %.2, 0
  br i1 %.not103126, label %.split.us.preheader, label %.lr.ph130.preheader

.lr.ph130.preheader:                              ; preds = %._crit_edge122
  %79 = zext i32 %.2 to i64
  %80 = tail call double @get_time_usecs()
  br label %144

.split.us.preheader:                              ; preds = %._crit_edge122.thread, %._crit_edge122
  %81 = tail call double @get_time_usecs()
  %82 = tail call double @get_time_usecs()
  %83 = tail call double @get_time_usecs()
  %84 = tail call double @get_time_usecs()
  %85 = fsub double %84, %83
  %86 = fadd double %85, 0.000000e+00
  %87 = tail call double @get_time_usecs()
  %88 = tail call double @get_time_usecs()
  %89 = fsub double %88, %87
  %90 = fadd double %86, %89
  %91 = tail call double @get_time_usecs()
  br label %.split137.us

.split137.us:                                     ; preds = %._crit_edge131.3, %.split.us.preheader
  %.sink173 = phi double [ %131, %._crit_edge131.3 ], [ %91, %.split.us.preheader ]
  %.sink = phi double [ %143, %._crit_edge131.3 ], [ %90, %.split.us.preheader ]
  %.2163 = phi i32 [ %.2, %._crit_edge131.3 ], [ 0, %.split.us.preheader ]
  %.us-phi138 = phi i64 [ %142, %._crit_edge131.3 ], [ 0, %.split.us.preheader ]
  %92 = tail call double @get_time_usecs()
  %93 = fsub double %92, %.sink173
  %94 = fadd double %.sink, %93
  %95 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.12, i64 noundef %.us-phi138)
  %96 = fdiv double %94, 3.000000e+00
  %97 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.13, i32 noundef %.2163, double noundef %96, i32 noundef 3)
  %98 = uitofp i32 %.2163 to double
  %99 = fdiv double %96, %98
  %100 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.14, double noundef %99, i32 noundef %.2163)
  br i1 %.not96107, label %._crit_edge143, label %.lr.ph142

._crit_edge131:                                   ; preds = %144
  %101 = tail call double @get_time_usecs()
  %102 = tail call double @get_time_usecs()
  br label %103

103:                                              ; preds = %103, %._crit_edge131
  %indvars.iv152.1 = phi i64 [ 0, %._crit_edge131 ], [ %indvars.iv.next153.1, %103 ]
  %.187127.1 = phi i64 [ %154, %._crit_edge131 ], [ %113, %103 ]
  %104 = getelementptr inbounds %struct.query, ptr %67, i64 %indvars.iv152.1
  %105 = load i32, ptr %104, align 4, !tbaa !18
  %106 = zext i32 %105 to i64
  %107 = getelementptr inbounds ptr, ptr %36, i64 %106
  %108 = load ptr, ptr %107, align 8, !tbaa !5
  %109 = getelementptr inbounds i8, ptr %104, i64 4
  %110 = load i32, ptr %109, align 4, !tbaa !20
  %111 = tail call zeroext i1 @roaring_bitmap_contains(ptr noundef %108, i32 noundef %110)
  %112 = zext i1 %111 to i64
  %113 = add i64 %.187127.1, %112
  %indvars.iv.next153.1 = add nuw nsw i64 %indvars.iv152.1, 1
  %.not103.1 = icmp eq i64 %indvars.iv.next153.1, %79
  br i1 %.not103.1, label %._crit_edge131.1, label %103, !llvm.loop !21

._crit_edge131.1:                                 ; preds = %103
  %114 = tail call double @get_time_usecs()
  %115 = fsub double %114, %102
  %116 = tail call double @get_time_usecs()
  br label %117

117:                                              ; preds = %117, %._crit_edge131.1
  %indvars.iv152.2 = phi i64 [ 0, %._crit_edge131.1 ], [ %indvars.iv.next153.2, %117 ]
  %.187127.2 = phi i64 [ %113, %._crit_edge131.1 ], [ %127, %117 ]
  %118 = getelementptr inbounds %struct.query, ptr %67, i64 %indvars.iv152.2
  %119 = load i32, ptr %118, align 4, !tbaa !18
  %120 = zext i32 %119 to i64
  %121 = getelementptr inbounds ptr, ptr %36, i64 %120
  %122 = load ptr, ptr %121, align 8, !tbaa !5
  %123 = getelementptr inbounds i8, ptr %118, i64 4
  %124 = load i32, ptr %123, align 4, !tbaa !20
  %125 = tail call zeroext i1 @roaring_bitmap_contains(ptr noundef %122, i32 noundef %124)
  %126 = zext i1 %125 to i64
  %127 = add i64 %.187127.2, %126
  %indvars.iv.next153.2 = add nuw nsw i64 %indvars.iv152.2, 1
  %.not103.2 = icmp eq i64 %indvars.iv.next153.2, %79
  br i1 %.not103.2, label %._crit_edge131.2, label %117, !llvm.loop !21

._crit_edge131.2:                                 ; preds = %117
  %128 = fadd double %115, 0.000000e+00
  %129 = tail call double @get_time_usecs()
  %130 = fsub double %129, %116
  %131 = tail call double @get_time_usecs()
  br label %132

132:                                              ; preds = %132, %._crit_edge131.2
  %indvars.iv152.3 = phi i64 [ 0, %._crit_edge131.2 ], [ %indvars.iv.next153.3, %132 ]
  %.187127.3 = phi i64 [ %127, %._crit_edge131.2 ], [ %142, %132 ]
  %133 = getelementptr inbounds %struct.query, ptr %67, i64 %indvars.iv152.3
  %134 = load i32, ptr %133, align 4, !tbaa !18
  %135 = zext i32 %134 to i64
  %136 = getelementptr inbounds ptr, ptr %36, i64 %135
  %137 = load ptr, ptr %136, align 8, !tbaa !5
  %138 = getelementptr inbounds i8, ptr %133, i64 4
  %139 = load i32, ptr %138, align 4, !tbaa !20
  %140 = tail call zeroext i1 @roaring_bitmap_contains(ptr noundef %137, i32 noundef %139)
  %141 = zext i1 %140 to i64
  %142 = add i64 %.187127.3, %141
  %indvars.iv.next153.3 = add nuw nsw i64 %indvars.iv152.3, 1
  %.not103.3 = icmp eq i64 %indvars.iv.next153.3, %79
  br i1 %.not103.3, label %._crit_edge131.3, label %132, !llvm.loop !21

._crit_edge131.3:                                 ; preds = %132
  %143 = fadd double %128, %130
  br label %.split137.us

144:                                              ; preds = %.lr.ph130.preheader, %144
  %indvars.iv152 = phi i64 [ 0, %.lr.ph130.preheader ], [ %indvars.iv.next153, %144 ]
  %.187127 = phi i64 [ 0, %.lr.ph130.preheader ], [ %154, %144 ]
  %145 = getelementptr inbounds %struct.query, ptr %67, i64 %indvars.iv152
  %146 = load i32, ptr %145, align 4, !tbaa !18
  %147 = zext i32 %146 to i64
  %148 = getelementptr inbounds ptr, ptr %36, i64 %147
  %149 = load ptr, ptr %148, align 8, !tbaa !5
  %150 = getelementptr inbounds i8, ptr %145, i64 4
  %151 = load i32, ptr %150, align 4, !tbaa !20
  %152 = tail call zeroext i1 @roaring_bitmap_contains(ptr noundef %149, i32 noundef %151)
  %153 = zext i1 %152 to i64
  %154 = add i64 %.187127, %153
  %indvars.iv.next153 = add nuw nsw i64 %indvars.iv152, 1
  %.not103 = icmp eq i64 %indvars.iv.next153, %79
  br i1 %.not103, label %._crit_edge131, label %144, !llvm.loop !21

._crit_edge143:                                   ; preds = %.lr.ph142, %.split137.us
  tail call void @free(ptr noundef %36) #13
  %155 = sub i64 0, %38
  %156 = getelementptr inbounds i8, ptr %.184.lcssa160, i64 %155
  %157 = tail call i32 @munmap(ptr noundef %156, i64 noundef %38) #13
  %158 = icmp eq i32 %157, -1
  br i1 %158, label %161, label %163

.lr.ph142:                                        ; preds = %.split137.us, %.lr.ph142
  %indvars.iv155 = phi i64 [ %indvars.iv.next156, %.lr.ph142 ], [ 0, %.split137.us ]
  %159 = getelementptr inbounds ptr, ptr %36, i64 %indvars.iv155
  %160 = load ptr, ptr %159, align 8, !tbaa !5
  tail call void @roaring_bitmap_free(ptr noundef %160) #13
  store ptr null, ptr %159, align 8, !tbaa !5
  %indvars.iv.next156 = add nuw nsw i64 %indvars.iv155, 1
  %.not102 = icmp eq i64 %indvars.iv.next156, %32
  br i1 %.not102, label %._crit_edge143, label %.lr.ph142, !llvm.loop !22

161:                                              ; preds = %._crit_edge143
  %162 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.15)
  tail call void @exit(i32 noundef 1) #14
  unreachable

163:                                              ; preds = %._crit_edge143
  %164 = tail call i32 @close(i32 noundef %16) #13
  br label %165

165:                                              ; preds = %163, %62
  %.079 = phi i32 [ 1, %62 ], [ 0, %163 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #13
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #13
  call void @llvm.lifetime.end.p0(i64 144, ptr nonnull %3) #13
  br label %166

166:                                              ; preds = %165, %7
  %.1 = phi i32 [ 1, %7 ], [ %.079, %165 ]
  ret i32 %.1
}

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #2

; Function Attrs: inlinehint mustprogress nofree nounwind willreturn memory(read) uwtable
declare i32 @atoi(ptr nocapture noundef nonnull) local_unnamed_addr #3

; Function Attrs: nofree
declare noundef i32 @open(ptr nocapture noundef readonly, i32 noundef, ...) local_unnamed_addr #4

; Function Attrs: noreturn nounwind
declare void @exit(i32 noundef) local_unnamed_addr #5

; Function Attrs: nofree nounwind
declare noundef i32 @fstat(i32 noundef, ptr nocapture noundef) local_unnamed_addr #2

; Function Attrs: nofree
declare noundef i64 @read(i32 noundef, ptr nocapture noundef, i64 noundef) local_unnamed_addr #4

; Function Attrs: mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @malloc(i64 noundef) local_unnamed_addr #6

; Function Attrs: nounwind
declare ptr @mmap(ptr noundef, i64 noundef, i32 noundef, i32 noundef, i32 noundef, i64 noundef) local_unnamed_addr #7

declare ptr @roaring_bitmap_frozen_view(ptr noundef, i64 noundef) local_unnamed_addr #8

; Function Attrs: mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite)
declare void @free(ptr allocptr nocapture noundef) local_unnamed_addr #9

; Function Attrs: nofree nounwind
declare noundef i32 @__isoc99_scanf(ptr nocapture noundef readonly, ...) local_unnamed_addr #2

; Function Attrs: inlinehint nounwind uwtable
declare zeroext i1 @roaring_bitmap_contains(ptr noundef, i32 noundef) local_unnamed_addr #10

declare void @roaring_bitmap_free(ptr noundef) local_unnamed_addr #8

; Function Attrs: nounwind
declare i32 @munmap(ptr noundef, i64 noundef) local_unnamed_addr #7

declare i32 @close(i32 noundef) local_unnamed_addr #8

; Function Attrs: inlinehint nounwind uwtable
declare double @get_time_usecs() local_unnamed_addr #10

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #11

attributes #0 = { 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 #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { nofree nounwind "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 = { inlinehint mustprogress nofree nounwind willreturn memory(read) 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 #4 = { nofree "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 #5 = { noreturn nounwind "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 #6 = { mustprogress nofree nounwind willreturn allockind("alloc,uninitialized") allocsize(0) memory(inaccessiblemem: readwrite) "alloc-family"="malloc" "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 #7 = { nounwind "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 #8 = { "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 #9 = { mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite) "alloc-family"="malloc" "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 #10 = { inlinehint 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 #11 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #12 = { nounwind willreturn memory(read) }
attributes #13 = { nounwind }
attributes #14 = { noreturn nounwind }
attributes #15 = { nounwind allocsize(0) }

!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 = !{!"int", !7, i64 0}
!11 = !{!12, !13, i64 48}
!12 = !{!"stat", !13, i64 0, !13, i64 8, !13, i64 16, !10, i64 24, !10, i64 28, !10, i64 32, !10, i64 36, !13, i64 40, !13, i64 48, !13, i64 56, !13, i64 64, !14, i64 72, !14, i64 88, !14, i64 104, !7, i64 120}
!13 = !{!"long", !7, i64 0}
!14 = !{!"timespec", !13, i64 0, !13, i64 8}
!15 = distinct !{!15, !16}
!16 = !{!"llvm.loop.mustprogress"}
!17 = distinct !{!17, !16}
!18 = !{!19, !10, i64 0}
!19 = !{!"", !10, i64 0, !10, i64 4}
!20 = !{!19, !10, i64 4}
!21 = distinct !{!21, !16}
!22 = distinct !{!22, !16}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopIdiomRecognizePass,LoopInstSimplifyPass,LoopRotatePass,LoopSimplifyCFGPass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass