; LLVM IR from mlcommons/tiny :: benchmark/interface/Application/Audio/WaveSource.ll (ZN5Audio10WaveSource4OpenEv)

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

%"class.Audio::WaveSource" = type <{ %class.IDataSource, ptr, i8, i8, i8, i8, i16, i16, i32, i32, i16, i16, i32, i32, [4 x i8] }>
%class.IDataSource = type { ptr }

@.str = external hidden unnamed_addr constant [5 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [5 x i8], align 1

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i8 @_ZN5Audio10WaveSource4OpenEv(ptr noundef nonnull align 8 dereferenceable(44) %0) unnamed_addr #0 align 2 {
  %2 = alloca ptr, align 8
  %3 = alloca i8, align 1
  %4 = alloca [8 x i8], align 1
  %5 = alloca i32, align 4
  %6 = alloca i16, align 2
  %7 = alloca i16, align 2
  %8 = alloca i32, align 4
  %9 = alloca i32, align 4
  %10 = alloca i16, align 2
  %11 = alloca i16, align 2
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  store ptr %0, ptr %2, align 8, !tbaa !5
  %14 = load ptr, ptr %2, align 8
  call void @llvm.lifetime.start.p0(i64 1, ptr %3) #3
  store i8 1, ptr %3, align 1, !tbaa !9
  %15 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 2
  %16 = load i8, ptr %15, align 8, !tbaa !10
  %17 = zext i8 %16 to i32
  %18 = icmp ne i32 %17, 1
  br i1 %18, label %19, label %264

19:                                               ; preds = %1
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #3
  call void @llvm.lifetime.start.p0(i64 2, ptr %6) #3
  call void @llvm.lifetime.start.p0(i64 2, ptr %7) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #3
  call void @llvm.lifetime.start.p0(i64 2, ptr %10) #3
  call void @llvm.lifetime.start.p0(i64 2, ptr %11) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #3
  %20 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %21 = load ptr, ptr %20, align 8, !tbaa !15
  %22 = load ptr, ptr %21, align 8, !tbaa !16
  %23 = getelementptr inbounds ptr, ptr %22, i64 3
  %24 = load ptr, ptr %23, align 8
  %25 = call noundef zeroext i8 %24(ptr noundef nonnull align 8 dereferenceable(8) %21)
  store i8 %25, ptr %3, align 1, !tbaa !9
  %26 = load i8, ptr %3, align 1, !tbaa !9
  %27 = icmp ne i8 %26, 0
  br i1 %27, label %28, label %36

28:                                               ; preds = %19
  %29 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 3
  store i8 1, ptr %29, align 1, !tbaa !18
  %30 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %31 = load ptr, ptr %30, align 8, !tbaa !15
  %32 = load ptr, ptr %31, align 8, !tbaa !16
  %33 = getelementptr inbounds ptr, ptr %32, i64 5
  %34 = load ptr, ptr %33, align 8
  %35 = call noundef zeroext i8 %34(ptr noundef nonnull align 8 dereferenceable(8) %31, i64 noundef 0)
  store i8 %35, ptr %3, align 1, !tbaa !9
  br label %36

36:                                               ; preds = %28, %19
  %37 = load i8, ptr %3, align 1, !tbaa !9
  %38 = icmp ne i8 %37, 0
  br i1 %38, label %39, label %57

39:                                               ; preds = %36
  %40 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %41 = load ptr, ptr %40, align 8, !tbaa !15
  %42 = getelementptr inbounds [8 x i8], ptr %4, i64 0, i64 0
  %43 = load ptr, ptr %41, align 8, !tbaa !16
  %44 = getelementptr inbounds ptr, ptr %43, i64 6
  %45 = load ptr, ptr %44, align 8
  %46 = call noundef i64 %45(ptr noundef nonnull align 8 dereferenceable(8) %41, ptr noundef %42, i64 noundef 4)
  %47 = icmp eq i64 %46, 4
  br i1 %47, label %48, label %52

48:                                               ; preds = %39
  %49 = getelementptr inbounds [8 x i8], ptr %4, i64 0, i64 0
  %50 = call i32 @strncmp(ptr noundef @.str, ptr noundef %49, i64 noundef 4) #4
  %51 = icmp eq i32 %50, 0
  br label %52

52:                                               ; preds = %48, %39
  %53 = phi i1 [ false, %39 ], [ %51, %48 ]
  %54 = zext i1 %53 to i64
  %55 = select i1 %53, i32 1, i32 0
  %56 = trunc i32 %55 to i8
  store i8 %56, ptr %3, align 1, !tbaa !9
  br label %57

57:                                               ; preds = %52, %36
  %58 = load i8, ptr %3, align 1, !tbaa !9
  %59 = icmp ne i8 %58, 0
  br i1 %59, label %60, label %71

60:                                               ; preds = %57
  %61 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %62 = load ptr, ptr %61, align 8, !tbaa !15
  %63 = load ptr, ptr %62, align 8, !tbaa !16
  %64 = getelementptr inbounds ptr, ptr %63, i64 6
  %65 = load ptr, ptr %64, align 8
  %66 = call noundef i64 %65(ptr noundef nonnull align 8 dereferenceable(8) %62, ptr noundef %5, i64 noundef 4)
  %67 = icmp eq i64 %66, 4
  %68 = zext i1 %67 to i64
  %69 = select i1 %67, i32 1, i32 0
  %70 = trunc i32 %69 to i8
  store i8 %70, ptr %3, align 1, !tbaa !9
  br label %71

71:                                               ; preds = %60, %57
  %72 = load i8, ptr %3, align 1, !tbaa !9
  %73 = icmp ne i8 %72, 0
  br i1 %73, label %74, label %92

74:                                               ; preds = %71
  %75 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %76 = load ptr, ptr %75, align 8, !tbaa !15
  %77 = getelementptr inbounds [8 x i8], ptr %4, i64 0, i64 0
  %78 = load ptr, ptr %76, align 8, !tbaa !16
  %79 = getelementptr inbounds ptr, ptr %78, i64 6
  %80 = load ptr, ptr %79, align 8
  %81 = call noundef i64 %80(ptr noundef nonnull align 8 dereferenceable(8) %76, ptr noundef %77, i64 noundef 8)
  %82 = icmp eq i64 %81, 8
  br i1 %82, label %83, label %87

83:                                               ; preds = %74
  %84 = getelementptr inbounds [8 x i8], ptr %4, i64 0, i64 0
  %85 = call i32 @strncmp(ptr noundef @.str.1, ptr noundef %84, i64 noundef 8) #4
  %86 = icmp eq i32 %85, 0
  br label %87

87:                                               ; preds = %83, %74
  %88 = phi i1 [ false, %74 ], [ %86, %83 ]
  %89 = zext i1 %88 to i64
  %90 = select i1 %88, i32 1, i32 0
  %91 = trunc i32 %90 to i8
  store i8 %91, ptr %3, align 1, !tbaa !9
  br label %92

92:                                               ; preds = %87, %71
  %93 = load i8, ptr %3, align 1, !tbaa !9
  %94 = icmp ne i8 %93, 0
  br i1 %94, label %95, label %106

95:                                               ; preds = %92
  %96 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %97 = load ptr, ptr %96, align 8, !tbaa !15
  %98 = load ptr, ptr %97, align 8, !tbaa !16
  %99 = getelementptr inbounds ptr, ptr %98, i64 6
  %100 = load ptr, ptr %99, align 8
  %101 = call noundef i64 %100(ptr noundef nonnull align 8 dereferenceable(8) %97, ptr noundef %13, i64 noundef 4)
  %102 = icmp eq i64 %101, 4
  %103 = zext i1 %102 to i64
  %104 = select i1 %102, i32 1, i32 0
  %105 = trunc i32 %104 to i8
  store i8 %105, ptr %3, align 1, !tbaa !9
  br label %106

106:                                              ; preds = %95, %92
  %107 = load i8, ptr %3, align 1, !tbaa !9
  %108 = icmp ne i8 %107, 0
  br i1 %108, label %109, label %120

109:                                              ; preds = %106
  %110 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %111 = load ptr, ptr %110, align 8, !tbaa !15
  %112 = load ptr, ptr %111, align 8, !tbaa !16
  %113 = getelementptr inbounds ptr, ptr %112, i64 6
  %114 = load ptr, ptr %113, align 8
  %115 = call noundef i64 %114(ptr noundef nonnull align 8 dereferenceable(8) %111, ptr noundef %6, i64 noundef 2)
  %116 = icmp eq i64 %115, 2
  %117 = zext i1 %116 to i64
  %118 = select i1 %116, i32 1, i32 0
  %119 = trunc i32 %118 to i8
  store i8 %119, ptr %3, align 1, !tbaa !9
  br label %120

120:                                              ; preds = %109, %106
  %121 = load i8, ptr %3, align 1, !tbaa !9
  %122 = icmp ne i8 %121, 0
  br i1 %122, label %123, label %134

123:                                              ; preds = %120
  %124 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %125 = load ptr, ptr %124, align 8, !tbaa !15
  %126 = load ptr, ptr %125, align 8, !tbaa !16
  %127 = getelementptr inbounds ptr, ptr %126, i64 6
  %128 = load ptr, ptr %127, align 8
  %129 = call noundef i64 %128(ptr noundef nonnull align 8 dereferenceable(8) %125, ptr noundef %7, i64 noundef 2)
  %130 = icmp eq i64 %129, 2
  %131 = zext i1 %130 to i64
  %132 = select i1 %130, i32 1, i32 0
  %133 = trunc i32 %132 to i8
  store i8 %133, ptr %3, align 1, !tbaa !9
  br label %134

134:                                              ; preds = %123, %120
  %135 = load i8, ptr %3, align 1, !tbaa !9
  %136 = icmp ne i8 %135, 0
  br i1 %136, label %137, label %148

137:                                              ; preds = %134
  %138 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %139 = load ptr, ptr %138, align 8, !tbaa !15
  %140 = load ptr, ptr %139, align 8, !tbaa !16
  %141 = getelementptr inbounds ptr, ptr %140, i64 6
  %142 = load ptr, ptr %141, align 8
  %143 = call noundef i64 %142(ptr noundef nonnull align 8 dereferenceable(8) %139, ptr noundef %8, i64 noundef 4)
  %144 = icmp eq i64 %143, 4
  %145 = zext i1 %144 to i64
  %146 = select i1 %144, i32 1, i32 0
  %147 = trunc i32 %146 to i8
  store i8 %147, ptr %3, align 1, !tbaa !9
  br label %148

148:                                              ; preds = %137, %134
  %149 = load i8, ptr %3, align 1, !tbaa !9
  %150 = icmp ne i8 %149, 0
  br i1 %150, label %151, label %162

151:                                              ; preds = %148
  %152 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %153 = load ptr, ptr %152, align 8, !tbaa !15
  %154 = load ptr, ptr %153, align 8, !tbaa !16
  %155 = getelementptr inbounds ptr, ptr %154, i64 6
  %156 = load ptr, ptr %155, align 8
  %157 = call noundef i64 %156(ptr noundef nonnull align 8 dereferenceable(8) %153, ptr noundef %9, i64 noundef 4)
  %158 = icmp eq i64 %157, 4
  %159 = zext i1 %158 to i64
  %160 = select i1 %158, i32 1, i32 0
  %161 = trunc i32 %160 to i8
  store i8 %161, ptr %3, align 1, !tbaa !9
  br label %162

162:                                              ; preds = %151, %148
  %163 = load i8, ptr %3, align 1, !tbaa !9
  %164 = icmp ne i8 %163, 0
  br i1 %164, label %165, label %176

165:                                              ; preds = %162
  %166 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %167 = load ptr, ptr %166, align 8, !tbaa !15
  %168 = load ptr, ptr %167, align 8, !tbaa !16
  %169 = getelementptr inbounds ptr, ptr %168, i64 6
  %170 = load ptr, ptr %169, align 8
  %171 = call noundef i64 %170(ptr noundef nonnull align 8 dereferenceable(8) %167, ptr noundef %10, i64 noundef 2)
  %172 = icmp eq i64 %171, 2
  %173 = zext i1 %172 to i64
  %174 = select i1 %172, i32 1, i32 0
  %175 = trunc i32 %174 to i8
  store i8 %175, ptr %3, align 1, !tbaa !9
  br label %176

176:                                              ; preds = %165, %162
  %177 = load i8, ptr %3, align 1, !tbaa !9
  %178 = icmp ne i8 %177, 0
  br i1 %178, label %179, label %190

179:                                              ; preds = %176
  %180 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %181 = load ptr, ptr %180, align 8, !tbaa !15
  %182 = load ptr, ptr %181, align 8, !tbaa !16
  %183 = getelementptr inbounds ptr, ptr %182, i64 6
  %184 = load ptr, ptr %183, align 8
  %185 = call noundef i64 %184(ptr noundef nonnull align 8 dereferenceable(8) %181, ptr noundef %11, i64 noundef 2)
  %186 = icmp eq i64 %185, 2
  %187 = zext i1 %186 to i64
  %188 = select i1 %186, i32 1, i32 0
  %189 = trunc i32 %188 to i8
  store i8 %189, ptr %3, align 1, !tbaa !9
  br label %190

190:                                              ; preds = %179, %176
  %191 = load i8, ptr %3, align 1, !tbaa !9
  %192 = icmp ne i8 %191, 0
  br i1 %192, label %193, label %211

193:                                              ; preds = %190
  %194 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %195 = load ptr, ptr %194, align 8, !tbaa !15
  %196 = getelementptr inbounds [8 x i8], ptr %4, i64 0, i64 0
  %197 = load ptr, ptr %195, align 8, !tbaa !16
  %198 = getelementptr inbounds ptr, ptr %197, i64 6
  %199 = load ptr, ptr %198, align 8
  %200 = call noundef i64 %199(ptr noundef nonnull align 8 dereferenceable(8) %195, ptr noundef %196, i64 noundef 4)
  %201 = icmp eq i64 %200, 4
  br i1 %201, label %202, label %206

202:                                              ; preds = %193
  %203 = getelementptr inbounds [8 x i8], ptr %4, i64 0, i64 0
  %204 = call i32 @strncmp(ptr noundef @.str.2, ptr noundef %203, i64 noundef 4) #4
  %205 = icmp eq i32 %204, 0
  br label %206

206:                                              ; preds = %202, %193
  %207 = phi i1 [ false, %193 ], [ %205, %202 ]
  %208 = zext i1 %207 to i64
  %209 = select i1 %207, i32 1, i32 0
  %210 = trunc i32 %209 to i8
  store i8 %210, ptr %3, align 1, !tbaa !9
  br label %211

211:                                              ; preds = %206, %190
  %212 = load i8, ptr %3, align 1, !tbaa !9
  %213 = icmp ne i8 %212, 0
  br i1 %213, label %214, label %225

214:                                              ; preds = %211
  %215 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %216 = load ptr, ptr %215, align 8, !tbaa !15
  %217 = load ptr, ptr %216, align 8, !tbaa !16
  %218 = getelementptr inbounds ptr, ptr %217, i64 6
  %219 = load ptr, ptr %218, align 8
  %220 = call noundef i64 %219(ptr noundef nonnull align 8 dereferenceable(8) %216, ptr noundef %12, i64 noundef 4)
  %221 = icmp eq i64 %220, 4
  %222 = zext i1 %221 to i64
  %223 = select i1 %221, i32 1, i32 0
  %224 = trunc i32 %223 to i8
  store i8 %224, ptr %3, align 1, !tbaa !9
  br label %225

225:                                              ; preds = %214, %211
  %226 = load i8, ptr %3, align 1, !tbaa !9
  %227 = icmp ne i8 %226, 0
  br i1 %227, label %228, label %252

228:                                              ; preds = %225
  %229 = load i16, ptr %6, align 2, !tbaa !19
  %230 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 6
  store i16 %229, ptr %230, align 4, !tbaa !20
  %231 = load i16, ptr %7, align 2, !tbaa !19
  %232 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 7
  store i16 %231, ptr %232, align 2, !tbaa !21
  %233 = load i32, ptr %8, align 4, !tbaa !22
  %234 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 8
  store i32 %233, ptr %234, align 8, !tbaa !23
  %235 = load i32, ptr %9, align 4, !tbaa !22
  %236 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 9
  store i32 %235, ptr %236, align 4, !tbaa !24
  %237 = load i16, ptr %10, align 2, !tbaa !19
  %238 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 10
  store i16 %237, ptr %238, align 8, !tbaa !25
  %239 = load i16, ptr %11, align 2, !tbaa !19
  %240 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 11
  store i16 %239, ptr %240, align 2, !tbaa !26
  %241 = load i32, ptr %12, align 4, !tbaa !22
  %242 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 12
  store i32 %241, ptr %242, align 4, !tbaa !27
  %243 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 1
  %244 = load ptr, ptr %243, align 8, !tbaa !15
  %245 = load ptr, ptr %244, align 8, !tbaa !16
  %246 = getelementptr inbounds ptr, ptr %245, i64 7
  %247 = load ptr, ptr %246, align 8
  %248 = call noundef i64 %247(ptr noundef nonnull align 8 dereferenceable(8) %244)
  %249 = trunc i64 %248 to i32
  %250 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 13
  store i32 %249, ptr %250, align 8, !tbaa !28
  %251 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 4
  store i8 1, ptr %251, align 2, !tbaa !29
  br label %262

252:                                              ; preds = %225
  %253 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 3
  %254 = load i8, ptr %253, align 1, !tbaa !18
  %255 = icmp ne i8 %254, 0
  br i1 %255, label %256, label %261

256:                                              ; preds = %252
  %257 = load ptr, ptr %14, align 8, !tbaa !16
  %258 = getelementptr inbounds ptr, ptr %257, i64 4
  %259 = load ptr, ptr %258, align 8
  %260 = call noundef zeroext i8 %259(ptr noundef nonnull align 8 dereferenceable(44) %14)
  br label %261

261:                                              ; preds = %256, %252
  br label %262

262:                                              ; preds = %261, %228
  %263 = getelementptr inbounds %"class.Audio::WaveSource", ptr %14, i32 0, i32 2
  store i8 1, ptr %263, align 8, !tbaa !10
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #3
  call void @llvm.lifetime.end.p0(i64 2, ptr %11) #3
  call void @llvm.lifetime.end.p0(i64 2, ptr %10) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #3
  call void @llvm.lifetime.end.p0(i64 2, ptr %7) #3
  call void @llvm.lifetime.end.p0(i64 2, ptr %6) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #3
  br label %264

264:                                              ; preds = %262, %1
  %265 = load i8, ptr %3, align 1, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 1, ptr %3) #3
  ret i8 %265
}

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

; Function Attrs: nounwind willreturn memory(read)
declare i32 @strncmp(ptr noundef, ptr noundef, i64 noundef) #2

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

attributes #0 = { mustprogress 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 = { nounwind willreturn memory(read) "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 = { nounwind }
attributes #4 = { nounwind willreturn memory(read) }

!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++ TBAA"}
!9 = !{!7, !7, i64 0}
!10 = !{!11, !7, i64 16}
!11 = !{!"_ZTSN5Audio10WaveSourceE", !12, i64 0, !6, i64 8, !7, i64 16, !7, i64 17, !7, i64 18, !13, i64 20, !13, i64 22, !14, i64 24, !14, i64 28, !13, i64 32, !13, i64 34, !14, i64 36, !14, i64 40}
!12 = !{!"_ZTS11IDataSource"}
!13 = !{!"short", !7, i64 0}
!14 = !{!"int", !7, i64 0}
!15 = !{!11, !6, i64 8}
!16 = !{!17, !17, i64 0}
!17 = !{!"vtable pointer", !8, i64 0}
!18 = !{!11, !7, i64 17}
!19 = !{!13, !13, i64 0}
!20 = !{!11, !13, i64 20}
!21 = !{!11, !13, i64 22}
!22 = !{!14, !14, i64 0}
!23 = !{!11, !14, i64 24}
!24 = !{!11, !14, i64 28}
!25 = !{!11, !13, i64 32}
!26 = !{!11, !13, i64 34}
!27 = !{!11, !14, i64 36}
!28 = !{!11, !14, i64 40}
!29 = !{!11, !7, i64 18}


; 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 = external hidden unnamed_addr constant [5 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [5 x i8], align 1

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext range(i8 0, 2) i8 @_ZN5Audio10WaveSource4OpenEv(ptr noundef nonnull align 8 dereferenceable(44) %0) unnamed_addr #0 align 2 {
  %2 = alloca [8 x i8], align 1
  %3 = alloca i32, align 4
  %4 = alloca i16, align 2
  %5 = alloca i16, align 2
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i16, align 2
  %9 = alloca i16, align 2
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = getelementptr inbounds i8, ptr %0, i64 16
  %13 = load i8, ptr %12, align 8, !tbaa !5
  %.not = icmp eq i8 %13, 1
  br i1 %.not, label %130, label %14

14:                                               ; preds = %1
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #3
  call void @llvm.lifetime.start.p0(i64 2, ptr nonnull %4) #3
  call void @llvm.lifetime.start.p0(i64 2, ptr nonnull %5) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %6) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %7) #3
  call void @llvm.lifetime.start.p0(i64 2, ptr nonnull %8) #3
  call void @llvm.lifetime.start.p0(i64 2, ptr nonnull %9) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %10) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %11) #3
  %15 = getelementptr inbounds i8, ptr %0, i64 8
  %16 = load ptr, ptr %15, align 8, !tbaa !13
  %17 = load ptr, ptr %16, align 8, !tbaa !14
  %18 = getelementptr inbounds i8, ptr %17, i64 24
  %19 = load ptr, ptr %18, align 8
  %20 = tail call noundef zeroext i8 %19(ptr noundef nonnull align 8 dereferenceable(8) %16)
  %.not16 = icmp eq i8 %20, 0
  br i1 %.not16, label %.critedge39.thread, label %21

21:                                               ; preds = %14
  %22 = getelementptr inbounds i8, ptr %0, i64 17
  store i8 1, ptr %22, align 1, !tbaa !16
  %23 = load ptr, ptr %15, align 8, !tbaa !13
  %24 = load ptr, ptr %23, align 8, !tbaa !14
  %25 = getelementptr inbounds i8, ptr %24, i64 40
  %26 = load ptr, ptr %25, align 8
  %27 = tail call noundef zeroext i8 %26(ptr noundef nonnull align 8 dereferenceable(8) %23, i64 noundef 0)
  %.not17 = icmp eq i8 %27, 0
  br i1 %.not17, label %.critedge39.thread, label %28

28:                                               ; preds = %21
  %29 = load ptr, ptr %15, align 8, !tbaa !13
  %30 = load ptr, ptr %29, align 8, !tbaa !14
  %31 = getelementptr inbounds i8, ptr %30, i64 48
  %32 = load ptr, ptr %31, align 8
  %33 = call noundef i64 %32(ptr noundef nonnull align 8 dereferenceable(8) %29, ptr noundef nonnull %2, i64 noundef 4)
  %34 = icmp eq i64 %33, 4
  br i1 %34, label %35, label %.critedge39.thread

35:                                               ; preds = %28
  %36 = call i32 @strncmp(ptr noundef nonnull dereferenceable(1) @.str, ptr noundef nonnull dereferenceable(1) %2, i64 noundef 4) #4
  %.not51 = icmp eq i32 %36, 0
  br i1 %.not51, label %37, label %.critedge39.thread

37:                                               ; preds = %35
  %38 = load ptr, ptr %15, align 8, !tbaa !13
  %39 = load ptr, ptr %38, align 8, !tbaa !14
  %40 = getelementptr inbounds i8, ptr %39, i64 48
  %41 = load ptr, ptr %40, align 8
  %42 = call noundef i64 %41(ptr noundef nonnull align 8 dereferenceable(8) %38, ptr noundef nonnull %3, i64 noundef 4)
  %.not52 = icmp eq i64 %42, 4
  br i1 %.not52, label %43, label %.critedge39.thread

43:                                               ; preds = %37
  %44 = load ptr, ptr %15, align 8, !tbaa !13
  %45 = load ptr, ptr %44, align 8, !tbaa !14
  %46 = getelementptr inbounds i8, ptr %45, i64 48
  %47 = load ptr, ptr %46, align 8
  %48 = call noundef i64 %47(ptr noundef nonnull align 8 dereferenceable(8) %44, ptr noundef nonnull %2, i64 noundef 8)
  %49 = icmp eq i64 %48, 8
  br i1 %49, label %.critedge, label %.critedge39.thread

.critedge:                                        ; preds = %43
  %50 = call i32 @strncmp(ptr noundef nonnull dereferenceable(1) @.str.1, ptr noundef nonnull dereferenceable(1) %2, i64 noundef 8) #4
  %.not53 = icmp eq i32 %50, 0
  br i1 %.not53, label %.critedge31, label %.critedge39.thread

.critedge31:                                      ; preds = %.critedge
  %51 = load ptr, ptr %15, align 8, !tbaa !13
  %52 = load ptr, ptr %51, align 8, !tbaa !14
  %53 = getelementptr inbounds i8, ptr %52, i64 48
  %54 = load ptr, ptr %53, align 8
  %55 = call noundef i64 %54(ptr noundef nonnull align 8 dereferenceable(8) %51, ptr noundef nonnull %11, i64 noundef 4)
  %.not54 = icmp eq i64 %55, 4
  br i1 %.not54, label %.critedge32, label %.critedge39.thread

.critedge32:                                      ; preds = %.critedge31
  %56 = load ptr, ptr %15, align 8, !tbaa !13
  %57 = load ptr, ptr %56, align 8, !tbaa !14
  %58 = getelementptr inbounds i8, ptr %57, i64 48
  %59 = load ptr, ptr %58, align 8
  %60 = call noundef i64 %59(ptr noundef nonnull align 8 dereferenceable(8) %56, ptr noundef nonnull %4, i64 noundef 2)
  %.not55 = icmp eq i64 %60, 2
  br i1 %.not55, label %.critedge33, label %.critedge39.thread

.critedge33:                                      ; preds = %.critedge32
  %61 = load ptr, ptr %15, align 8, !tbaa !13
  %62 = load ptr, ptr %61, align 8, !tbaa !14
  %63 = getelementptr inbounds i8, ptr %62, i64 48
  %64 = load ptr, ptr %63, align 8
  %65 = call noundef i64 %64(ptr noundef nonnull align 8 dereferenceable(8) %61, ptr noundef nonnull %5, i64 noundef 2)
  %.not56 = icmp eq i64 %65, 2
  br i1 %.not56, label %.critedge34, label %.critedge39.thread

.critedge34:                                      ; preds = %.critedge33
  %66 = load ptr, ptr %15, align 8, !tbaa !13
  %67 = load ptr, ptr %66, align 8, !tbaa !14
  %68 = getelementptr inbounds i8, ptr %67, i64 48
  %69 = load ptr, ptr %68, align 8
  %70 = call noundef i64 %69(ptr noundef nonnull align 8 dereferenceable(8) %66, ptr noundef nonnull %6, i64 noundef 4)
  %.not57 = icmp eq i64 %70, 4
  br i1 %.not57, label %.critedge35, label %.critedge39.thread

.critedge35:                                      ; preds = %.critedge34
  %71 = load ptr, ptr %15, align 8, !tbaa !13
  %72 = load ptr, ptr %71, align 8, !tbaa !14
  %73 = getelementptr inbounds i8, ptr %72, i64 48
  %74 = load ptr, ptr %73, align 8
  %75 = call noundef i64 %74(ptr noundef nonnull align 8 dereferenceable(8) %71, ptr noundef nonnull %7, i64 noundef 4)
  %.not58 = icmp eq i64 %75, 4
  br i1 %.not58, label %.critedge36, label %.critedge39.thread

.critedge36:                                      ; preds = %.critedge35
  %76 = load ptr, ptr %15, align 8, !tbaa !13
  %77 = load ptr, ptr %76, align 8, !tbaa !14
  %78 = getelementptr inbounds i8, ptr %77, i64 48
  %79 = load ptr, ptr %78, align 8
  %80 = call noundef i64 %79(ptr noundef nonnull align 8 dereferenceable(8) %76, ptr noundef nonnull %8, i64 noundef 2)
  %.not59 = icmp eq i64 %80, 2
  br i1 %.not59, label %.critedge37, label %.critedge39.thread

.critedge37:                                      ; preds = %.critedge36
  %81 = load ptr, ptr %15, align 8, !tbaa !13
  %82 = load ptr, ptr %81, align 8, !tbaa !14
  %83 = getelementptr inbounds i8, ptr %82, i64 48
  %84 = load ptr, ptr %83, align 8
  %85 = call noundef i64 %84(ptr noundef nonnull align 8 dereferenceable(8) %81, ptr noundef nonnull %9, i64 noundef 2)
  %.not60 = icmp eq i64 %85, 2
  br i1 %.not60, label %86, label %.critedge39.thread

86:                                               ; preds = %.critedge37
  %87 = load ptr, ptr %15, align 8, !tbaa !13
  %88 = load ptr, ptr %87, align 8, !tbaa !14
  %89 = getelementptr inbounds i8, ptr %88, i64 48
  %90 = load ptr, ptr %89, align 8
  %91 = call noundef i64 %90(ptr noundef nonnull align 8 dereferenceable(8) %87, ptr noundef nonnull %2, i64 noundef 4)
  %92 = icmp eq i64 %91, 4
  br i1 %92, label %.critedge38, label %.critedge39.thread

.critedge38:                                      ; preds = %86
  %93 = call i32 @strncmp(ptr noundef nonnull dereferenceable(1) @.str.2, ptr noundef nonnull dereferenceable(1) %2, i64 noundef 4) #4
  %.not61 = icmp eq i32 %93, 0
  br i1 %.not61, label %.critedge39, label %.critedge39.thread

.critedge39:                                      ; preds = %.critedge38
  %94 = load ptr, ptr %15, align 8, !tbaa !13
  %95 = load ptr, ptr %94, align 8, !tbaa !14
  %96 = getelementptr inbounds i8, ptr %95, i64 48
  %97 = load ptr, ptr %96, align 8
  %98 = call noundef i64 %97(ptr noundef nonnull align 8 dereferenceable(8) %94, ptr noundef nonnull %10, i64 noundef 4)
  %.not62 = icmp eq i64 %98, 4
  br i1 %.not62, label %99, label %.critedge39.thread

99:                                               ; preds = %.critedge39
  %100 = load i16, ptr %4, align 2, !tbaa !17
  %101 = getelementptr inbounds i8, ptr %0, i64 20
  store i16 %100, ptr %101, align 4, !tbaa !18
  %102 = load i16, ptr %5, align 2, !tbaa !17
  %103 = getelementptr inbounds i8, ptr %0, i64 22
  store i16 %102, ptr %103, align 2, !tbaa !19
  %104 = load i32, ptr %6, align 4, !tbaa !20
  %105 = getelementptr inbounds i8, ptr %0, i64 24
  store i32 %104, ptr %105, align 8, !tbaa !21
  %106 = load i32, ptr %7, align 4, !tbaa !20
  %107 = getelementptr inbounds i8, ptr %0, i64 28
  store i32 %106, ptr %107, align 4, !tbaa !22
  %108 = load i16, ptr %8, align 2, !tbaa !17
  %109 = getelementptr inbounds i8, ptr %0, i64 32
  store i16 %108, ptr %109, align 8, !tbaa !23
  %110 = load i16, ptr %9, align 2, !tbaa !17
  %111 = getelementptr inbounds i8, ptr %0, i64 34
  store i16 %110, ptr %111, align 2, !tbaa !24
  %112 = load i32, ptr %10, align 4, !tbaa !20
  %113 = getelementptr inbounds i8, ptr %0, i64 36
  store i32 %112, ptr %113, align 4, !tbaa !25
  %114 = load ptr, ptr %15, align 8, !tbaa !13
  %115 = load ptr, ptr %114, align 8, !tbaa !14
  %116 = getelementptr inbounds i8, ptr %115, i64 56
  %117 = load ptr, ptr %116, align 8
  %118 = call noundef i64 %117(ptr noundef nonnull align 8 dereferenceable(8) %114)
  %119 = trunc i64 %118 to i32
  %120 = getelementptr inbounds i8, ptr %0, i64 40
  store i32 %119, ptr %120, align 8, !tbaa !26
  %121 = getelementptr inbounds i8, ptr %0, i64 18
  store i8 1, ptr %121, align 2, !tbaa !27
  br label %129

.critedge39.thread:                               ; preds = %14, %21, %28, %.critedge37, %86, %.critedge35, %.critedge33, %.critedge31, %37, %43, %35, %.critedge, %.critedge32, %.critedge34, %.critedge36, %.critedge38, %.critedge39
  %122 = getelementptr inbounds i8, ptr %0, i64 17
  %123 = load i8, ptr %122, align 1, !tbaa !16
  %.not30 = icmp eq i8 %123, 0
  br i1 %.not30, label %129, label %124

124:                                              ; preds = %.critedge39.thread
  %125 = load ptr, ptr %0, align 8, !tbaa !14
  %126 = getelementptr inbounds i8, ptr %125, i64 32
  %127 = load ptr, ptr %126, align 8
  %128 = call noundef zeroext i8 %127(ptr noundef nonnull align 8 dereferenceable(44) %0)
  br label %129

129:                                              ; preds = %.critedge39.thread, %124, %99
  %.1249 = phi i8 [ 0, %.critedge39.thread ], [ 0, %124 ], [ 1, %99 ]
  store i8 1, ptr %12, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %11) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %10) #3
  call void @llvm.lifetime.end.p0(i64 2, ptr nonnull %9) #3
  call void @llvm.lifetime.end.p0(i64 2, ptr nonnull %8) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %7) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %6) #3
  call void @llvm.lifetime.end.p0(i64 2, ptr nonnull %5) #3
  call void @llvm.lifetime.end.p0(i64 2, ptr nonnull %4) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #3
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #3
  br label %130

130:                                              ; preds = %129, %1
  %.13 = phi i8 [ %.1249, %129 ], [ 1, %1 ]
  ret i8 %.13
}

; 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 nofree nounwind willreturn memory(argmem: read)
declare i32 @strncmp(ptr nocapture noundef, ptr nocapture noundef, i64 noundef) local_unnamed_addr #2

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

attributes #0 = { mustprogress 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 = { mustprogress nofree nounwind willreturn memory(argmem: read) "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 = { nounwind }
attributes #4 = { nounwind willreturn memory(read) }

!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, !9, i64 16}
!6 = !{!"_ZTSN5Audio10WaveSourceE", !7, i64 0, !8, i64 8, !9, i64 16, !9, i64 17, !9, i64 18, !11, i64 20, !11, i64 22, !12, i64 24, !12, i64 28, !11, i64 32, !11, i64 34, !12, i64 36, !12, i64 40}
!7 = !{!"_ZTS11IDataSource"}
!8 = !{!"any pointer", !9, i64 0}
!9 = !{!"omnipotent char", !10, i64 0}
!10 = !{!"Simple C++ TBAA"}
!11 = !{!"short", !9, i64 0}
!12 = !{!"int", !9, i64 0}
!13 = !{!6, !8, i64 8}
!14 = !{!15, !15, i64 0}
!15 = !{!"vtable pointer", !10, i64 0}
!16 = !{!6, !9, i64 17}
!17 = !{!11, !11, i64 0}
!18 = !{!6, !11, i64 20}
!19 = !{!6, !11, i64 22}
!20 = !{!12, !12, i64 0}
!21 = !{!6, !12, i64 24}
!22 = !{!6, !12, i64 28}
!23 = !{!6, !11, i64 32}
!24 = !{!6, !11, i64 34}
!25 = !{!6, !12, i64 36}
!26 = !{!6, !12, i64 40}
!27 = !{!6, !9, i64 18}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,SROAPass,SimplifyCFGPass,TailCallElimPass