; LLVM IR from jingweizhanghuai/Morn :: src/wave (morn_wave)

; 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.MWave = type { i32, i32, [32 x ptr] }
%struct.HandleList = type { %struct.MList, i32, i32, i32, i32 }
%struct.MList = type { i32, ptr }
%struct.MHandle = type { i32, i32, ptr, ptr }
%struct.HandleWaveCreate = type { ptr, ptr, i32, i32, [32 x ptr], ptr }

@.str = external hidden unnamed_addr constant [76 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [14 x i8], align 1
@__FUNCTION__.mWaveRedefine = external hidden unnamed_addr constant [14 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [17 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

declare void @m_Exception(i32 noundef, i32 noundef, ptr noundef, i32 noundef, ptr noundef, ptr noundef, ...) #1

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

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #2

declare ptr @mMemoryCreate(i32 noundef, i32 noundef, i32 noundef) #1

declare void @mMemoryIndex(ptr noundef, i32 noundef, i32 noundef, ptr noundef, i32 noundef) #1

; 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) #3

; Function Attrs: nounwind uwtable
define dso_local void @mWaveRedefine(ptr noundef %0, i32 noundef %1, i32 noundef %2, ptr noundef %3) #4 {
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca [32 x ptr], align 16
  %19 = alloca i32, align 4
  %20 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store i32 %1, ptr %6, align 4, !tbaa !9
  store i32 %2, ptr %7, align 4, !tbaa !9
  store ptr %3, ptr %8, align 8, !tbaa !5
  br label %21

21:                                               ; preds = %4
  call void @llvm.lifetime.start.p0(i64 4, ptr %9) #5
  %22 = load ptr, ptr %5, align 8, !tbaa !5
  %23 = icmp eq ptr %22, null
  br i1 %23, label %28, label %24

24:                                               ; preds = %21
  %25 = load ptr, ptr %5, align 8, !tbaa !5
  %26 = ptrtoint ptr %25 to i64
  %27 = icmp eq i64 %26, -1
  br label %28

28:                                               ; preds = %24, %21
  %29 = phi i1 [ true, %21 ], [ %27, %24 ]
  %30 = zext i1 %29 to i32
  store i32 %30, ptr %9, align 4, !tbaa !9
  %31 = load i32, ptr %9, align 4, !tbaa !9
  %32 = icmp ne i32 %31, 0
  br i1 %32, label %33, label %35

33:                                               ; preds = %28
  %34 = load i32, ptr %9, align 4, !tbaa !9
  call void (i32, i32, ptr, i32, ptr, ptr, ...) @m_Exception(i32 noundef %34, i32 noundef -1, ptr noundef @.str, i32 noundef 70, ptr noundef @__FUNCTION__.mWaveRedefine, ptr noundef @.str.2)
  br label %35

35:                                               ; preds = %33, %28
  call void @llvm.lifetime.end.p0(i64 4, ptr %9) #5
  br label %36

36:                                               ; preds = %35
  %37 = load i32, ptr %7, align 4, !tbaa !9
  %38 = icmp sle i32 %37, 0
  br i1 %38, label %39, label %43

39:                                               ; preds = %36
  %40 = load ptr, ptr %5, align 8, !tbaa !5
  %41 = getelementptr inbounds %struct.MWave, ptr %40, i32 0, i32 1
  %42 = load i32, ptr %41, align 4, !tbaa !11
  store i32 %42, ptr %7, align 4, !tbaa !9
  br label %43

43:                                               ; preds = %39, %36
  %44 = load i32, ptr %6, align 4, !tbaa !9
  %45 = icmp sle i32 %44, 0
  br i1 %45, label %46, label %50

46:                                               ; preds = %43
  %47 = load ptr, ptr %5, align 8, !tbaa !5
  %48 = getelementptr inbounds %struct.MWave, ptr %47, i32 0, i32 0
  %49 = load i32, ptr %48, align 8, !tbaa !13
  store i32 %49, ptr %6, align 4, !tbaa !9
  br label %50

50:                                               ; preds = %46, %43
  %51 = load i32, ptr %6, align 4, !tbaa !9
  %52 = load ptr, ptr %5, align 8, !tbaa !5
  %53 = getelementptr inbounds %struct.MWave, ptr %52, i32 0, i32 0
  %54 = load i32, ptr %53, align 8, !tbaa !13
  %55 = icmp ne i32 %51, %54
  br i1 %55, label %62, label %56

56:                                               ; preds = %50
  %57 = load i32, ptr %7, align 4, !tbaa !9
  %58 = load ptr, ptr %5, align 8, !tbaa !5
  %59 = getelementptr inbounds %struct.MWave, ptr %58, i32 0, i32 1
  %60 = load i32, ptr %59, align 4, !tbaa !11
  %61 = icmp ne i32 %57, %60
  br i1 %61, label %62, label %64

62:                                               ; preds = %56, %50
  %63 = load ptr, ptr %5, align 8, !tbaa !5
  call void @mHandleReset(ptr noundef %63)
  br label %64

64:                                               ; preds = %62, %56
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #5
  %65 = load i32, ptr %7, align 4, !tbaa !9
  %66 = load ptr, ptr %5, align 8, !tbaa !5
  %67 = getelementptr inbounds %struct.MWave, ptr %66, i32 0, i32 1
  %68 = load i32, ptr %67, align 4, !tbaa !11
  %69 = icmp sle i32 %65, %68
  br i1 %69, label %70, label %76

70:                                               ; preds = %64
  %71 = load i32, ptr %6, align 4, !tbaa !9
  %72 = load ptr, ptr %5, align 8, !tbaa !5
  %73 = getelementptr inbounds %struct.MWave, ptr %72, i32 0, i32 0
  %74 = load i32, ptr %73, align 8, !tbaa !13
  %75 = icmp sle i32 %71, %74
  br label %76

76:                                               ; preds = %70, %64
  %77 = phi i1 [ false, %64 ], [ %75, %70 ]
  %78 = zext i1 %77 to i32
  store i32 %78, ptr %10, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #5
  %79 = load ptr, ptr %8, align 8, !tbaa !5
  %80 = load ptr, ptr %5, align 8, !tbaa !5
  %81 = getelementptr inbounds %struct.MWave, ptr %80, i32 0, i32 2
  %82 = getelementptr inbounds [32 x ptr], ptr %81, i64 0, i64 0
  %83 = icmp eq ptr %79, %82
  %84 = zext i1 %83 to i32
  store i32 %84, ptr %11, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  %85 = load ptr, ptr %5, align 8, !tbaa !5
  %86 = getelementptr inbounds %struct.MWave, ptr %85, i32 0, i32 1
  %87 = load i32, ptr %86, align 4, !tbaa !11
  %88 = icmp ne i32 %87, 0
  br i1 %88, label %89, label %94

89:                                               ; preds = %76
  %90 = load ptr, ptr %5, align 8, !tbaa !5
  %91 = getelementptr inbounds %struct.MWave, ptr %90, i32 0, i32 0
  %92 = load i32, ptr %91, align 8, !tbaa !13
  %93 = icmp ne i32 %92, 0
  br label %94

94:                                               ; preds = %89, %76
  %95 = phi i1 [ false, %76 ], [ %93, %89 ]
  %96 = zext i1 %95 to i32
  store i32 %96, ptr %12, align 4, !tbaa !9
  %97 = load i32, ptr %7, align 4, !tbaa !9
  %98 = load ptr, ptr %5, align 8, !tbaa !5
  %99 = getelementptr inbounds %struct.MWave, ptr %98, i32 0, i32 1
  store i32 %97, ptr %99, align 4, !tbaa !11
  %100 = load i32, ptr %6, align 4, !tbaa !9
  %101 = load ptr, ptr %5, align 8, !tbaa !5
  %102 = getelementptr inbounds %struct.MWave, ptr %101, i32 0, i32 0
  store i32 %100, ptr %102, align 8, !tbaa !13
  %103 = load i32, ptr %10, align 4, !tbaa !9
  %104 = icmp ne i32 %103, 0
  br i1 %104, label %105, label %109

105:                                              ; preds = %94
  %106 = load i32, ptr %11, align 4, !tbaa !9
  %107 = icmp ne i32 %106, 0
  br i1 %107, label %108, label %109

108:                                              ; preds = %105
  store i32 1, ptr %13, align 4
  br label %301

109:                                              ; preds = %105, %94
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #5
  %110 = load ptr, ptr %5, align 8, !tbaa !5
  %111 = getelementptr inbounds %struct.HandleList, ptr %110, i64 -1
  %112 = getelementptr inbounds %struct.HandleList, ptr %111, i32 0, i32 0
  %113 = getelementptr inbounds %struct.MList, ptr %112, i32 0, i32 1
  %114 = load ptr, ptr %113, align 8, !tbaa !14
  %115 = getelementptr inbounds ptr, ptr %114, i64 0
  %116 = load ptr, ptr %115, align 8, !tbaa !5
  %117 = getelementptr inbounds %struct.MHandle, ptr %116, i32 0, i32 3
  %118 = load ptr, ptr %117, align 8, !tbaa !17
  store ptr %118, ptr %14, align 8, !tbaa !5
  %119 = load i32, ptr %10, align 4, !tbaa !9
  %120 = icmp ne i32 %119, 0
  br i1 %120, label %121, label %130

121:                                              ; preds = %109
  %122 = load ptr, ptr %8, align 8, !tbaa !5
  %123 = icmp eq ptr %122, null
  br i1 %123, label %124, label %130

124:                                              ; preds = %121
  %125 = load ptr, ptr %14, align 8, !tbaa !5
  %126 = getelementptr inbounds %struct.HandleWaveCreate, ptr %125, i32 0, i32 3
  %127 = load i32, ptr %126, align 4, !tbaa !19
  %128 = icmp sgt i32 %127, 0
  br i1 %128, label %129, label %130

129:                                              ; preds = %124
  store i32 1, ptr %13, align 4
  br label %300

130:                                              ; preds = %124, %121, %109
  br label %131

131:                                              ; preds = %130
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #5
  %132 = load i32, ptr %11, align 4, !tbaa !9
  %133 = icmp ne i32 %132, 0
  br i1 %133, label %134, label %142

134:                                              ; preds = %131
  %135 = load i32, ptr %12, align 4, !tbaa !9
  %136 = icmp ne i32 %135, 0
  br i1 %136, label %137, label %142

137:                                              ; preds = %134
  %138 = load ptr, ptr %14, align 8, !tbaa !5
  %139 = getelementptr inbounds %struct.HandleWaveCreate, ptr %138, i32 0, i32 3
  %140 = load i32, ptr %139, align 4, !tbaa !19
  %141 = icmp eq i32 %140, 0
  br label %142

142:                                              ; preds = %137, %134, %131
  %143 = phi i1 [ false, %134 ], [ false, %131 ], [ %141, %137 ]
  %144 = zext i1 %143 to i32
  store i32 %144, ptr %15, align 4, !tbaa !9
  %145 = load i32, ptr %15, align 4, !tbaa !9
  %146 = icmp ne i32 %145, 0
  br i1 %146, label %147, label %149

147:                                              ; preds = %142
  %148 = load i32, ptr %15, align 4, !tbaa !9
  call void (i32, i32, ptr, i32, ptr, ptr, ...) @m_Exception(i32 noundef %148, i32 noundef -1, ptr noundef @.str, i32 noundef 86, ptr noundef @__FUNCTION__.mWaveRedefine, ptr noundef @.str.3)
  br label %149

149:                                              ; preds = %147, %142
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #5
  br label %150

150:                                              ; preds = %149
  br label %151

151:                                              ; preds = %150
  br label %152

152:                                              ; preds = %151
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #5
  %153 = load i32, ptr %6, align 4, !tbaa !9
  %154 = icmp sgt i32 %153, 32
  %155 = zext i1 %154 to i32
  store i32 %155, ptr %16, align 4, !tbaa !9
  %156 = load i32, ptr %16, align 4, !tbaa !9
  %157 = icmp ne i32 %156, 0
  br i1 %157, label %158, label %160

158:                                              ; preds = %152
  %159 = load i32, ptr %16, align 4, !tbaa !9
  call void (i32, i32, ptr, i32, ptr, ptr, ...) @m_Exception(i32 noundef %159, i32 noundef -1, ptr noundef @.str, i32 noundef 88, ptr noundef @__FUNCTION__.mWaveRedefine, ptr noundef @.str.2)
  br label %160

160:                                              ; preds = %158, %152
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #5
  br label %161

161:                                              ; preds = %160
  br label %162

162:                                              ; preds = %161
  %163 = load ptr, ptr %14, align 8, !tbaa !5
  %164 = getelementptr inbounds %struct.HandleWaveCreate, ptr %163, i32 0, i32 3
  store i32 0, ptr %164, align 4, !tbaa !19
  %165 = load i32, ptr %6, align 4, !tbaa !9
  %166 = icmp sle i32 %165, 0
  br i1 %166, label %170, label %167

167:                                              ; preds = %162
  %168 = load i32, ptr %7, align 4, !tbaa !9
  %169 = icmp sle i32 %168, 0
  br i1 %169, label %170, label %191

170:                                              ; preds = %167, %162
  br label %171

171:                                              ; preds = %170
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #5
  %172 = load ptr, ptr %8, align 8, !tbaa !5
  %173 = icmp ne ptr %172, null
  br i1 %173, label %174, label %178

174:                                              ; preds = %171
  %175 = load i32, ptr %11, align 4, !tbaa !9
  %176 = icmp ne i32 %175, 0
  %177 = xor i1 %176, true
  br label %178

178:                                              ; preds = %174, %171
  %179 = phi i1 [ false, %171 ], [ %177, %174 ]
  %180 = zext i1 %179 to i32
  store i32 %180, ptr %17, align 4, !tbaa !9
  %181 = load i32, ptr %17, align 4, !tbaa !9
  %182 = icmp ne i32 %181, 0
  br i1 %182, label %183, label %185

183:                                              ; preds = %178
  %184 = load i32, ptr %17, align 4, !tbaa !9
  call void (i32, i32, ptr, i32, ptr, ptr, ...) @m_Exception(i32 noundef %184, i32 noundef -1, ptr noundef @.str, i32 noundef 93, ptr noundef @__FUNCTION__.mWaveRedefine, ptr noundef @.str.2)
  br label %185

185:                                              ; preds = %183, %178
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #5
  br label %186

186:                                              ; preds = %185
  br label %187

187:                                              ; preds = %186
  %188 = load ptr, ptr %5, align 8, !tbaa !5
  %189 = getelementptr inbounds %struct.MWave, ptr %188, i32 0, i32 2
  %190 = getelementptr inbounds [32 x ptr], ptr %189, i64 0, i64 0
  call void @llvm.memset.p0.i64(ptr align 8 %190, i8 0, i64 256, i1 false)
  store i32 1, ptr %13, align 4
  br label %300

191:                                              ; preds = %167
  %192 = load i32, ptr %11, align 4, !tbaa !9
  %193 = icmp ne i32 %192, 0
  br i1 %193, label %194, label %195

194:                                              ; preds = %191
  store ptr null, ptr %8, align 8, !tbaa !5
  br label %195

195:                                              ; preds = %194, %191
  %196 = load ptr, ptr %8, align 8, !tbaa !5
  %197 = icmp ne ptr %196, null
  br i1 %197, label %198, label %206

198:                                              ; preds = %195
  %199 = load ptr, ptr %5, align 8, !tbaa !5
  %200 = getelementptr inbounds %struct.MWave, ptr %199, i32 0, i32 2
  %201 = getelementptr inbounds [32 x ptr], ptr %200, i64 0, i64 0
  %202 = load ptr, ptr %8, align 8, !tbaa !5
  %203 = load i32, ptr %6, align 4, !tbaa !9
  %204 = sext i32 %203 to i64
  %205 = mul i64 %204, 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %201, ptr align 8 %202, i64 %205, i1 false)
  store i32 1, ptr %13, align 4
  br label %300

206:                                              ; preds = %195
  %207 = load i32, ptr %7, align 4, !tbaa !9
  %208 = load ptr, ptr %14, align 8, !tbaa !5
  %209 = getelementptr inbounds %struct.HandleWaveCreate, ptr %208, i32 0, i32 3
  %210 = load i32, ptr %209, align 4, !tbaa !19
  %211 = icmp sgt i32 %207, %210
  br i1 %211, label %218, label %212

212:                                              ; preds = %206
  %213 = load i32, ptr %6, align 4, !tbaa !9
  %214 = load ptr, ptr %14, align 8, !tbaa !5
  %215 = getelementptr inbounds %struct.HandleWaveCreate, ptr %214, i32 0, i32 2
  %216 = load i32, ptr %215, align 8, !tbaa !21
  %217 = icmp sgt i32 %213, %216
  br i1 %217, label %218, label %277

218:                                              ; preds = %212, %206
  %219 = load i32, ptr %7, align 4, !tbaa !9
  %220 = add nsw i32 %219, 32
  store i32 %220, ptr %7, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 256, ptr %18) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #5
  store i32 0, ptr %19, align 4, !tbaa !9
  br label %221

221:                                              ; preds = %235, %218
  %222 = load i32, ptr %19, align 4, !tbaa !9
  %223 = load i32, ptr %6, align 4, !tbaa !9
  %224 = icmp slt i32 %222, %223
  br i1 %224, label %226, label %225

225:                                              ; preds = %221
  store i32 10, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #5
  br label %238

226:                                              ; preds = %221
  %227 = load ptr, ptr %14, align 8, !tbaa !5
  %228 = getelementptr inbounds %struct.HandleWaveCreate, ptr %227, i32 0, i32 4
  %229 = load i32, ptr %19, align 4, !tbaa !9
  %230 = sext i32 %229 to i64
  %231 = getelementptr inbounds [32 x ptr], ptr %228, i64 0, i64 %230
  %232 = load i32, ptr %19, align 4, !tbaa !9
  %233 = sext i32 %232 to i64
  %234 = getelementptr inbounds [32 x ptr], ptr %18, i64 0, i64 %233
  store ptr %231, ptr %234, align 8, !tbaa !5
  br label %235

235:                                              ; preds = %226
  %236 = load i32, ptr %19, align 4, !tbaa !9
  %237 = add nsw i32 %236, 1
  store i32 %237, ptr %19, align 4, !tbaa !9
  br label %221, !llvm.loop !22

238:                                              ; preds = %225
  %239 = load ptr, ptr %14, align 8, !tbaa !5
  %240 = getelementptr inbounds %struct.HandleWaveCreate, ptr %239, i32 0, i32 5
  %241 = load ptr, ptr %240, align 8, !tbaa !24
  %242 = icmp eq ptr %241, null
  br i1 %242, label %243, label %252

243:                                              ; preds = %238
  %244 = load i32, ptr %6, align 4, !tbaa !9
  %245 = load i32, ptr %7, align 4, !tbaa !9
  %246 = sext i32 %245 to i64
  %247 = mul i64 %246, 4
  %248 = trunc i64 %247 to i32
  %249 = call ptr @mMemoryCreate(i32 noundef %244, i32 noundef %248, i32 noundef 0)
  %250 = load ptr, ptr %14, align 8, !tbaa !5
  %251 = getelementptr inbounds %struct.HandleWaveCreate, ptr %250, i32 0, i32 5
  store ptr %249, ptr %251, align 8, !tbaa !24
  br label %261

252:                                              ; preds = %238
  %253 = load ptr, ptr %14, align 8, !tbaa !5
  %254 = getelementptr inbounds %struct.HandleWaveCreate, ptr %253, i32 0, i32 5
  %255 = load ptr, ptr %254, align 8, !tbaa !24
  %256 = load i32, ptr %6, align 4, !tbaa !9
  %257 = load i32, ptr %7, align 4, !tbaa !9
  %258 = sext i32 %257 to i64
  %259 = mul i64 %258, 4
  %260 = trunc i64 %259 to i32
  call void @mMemoryRedefine(ptr noundef %255, i32 noundef %256, i32 noundef %260, i32 noundef 0)
  br label %261

261:                                              ; preds = %252, %243
  %262 = load ptr, ptr %14, align 8, !tbaa !5
  %263 = getelementptr inbounds %struct.HandleWaveCreate, ptr %262, i32 0, i32 5
  %264 = load ptr, ptr %263, align 8, !tbaa !24
  %265 = load i32, ptr %7, align 4, !tbaa !9
  %266 = sext i32 %265 to i64
  %267 = mul i64 %266, 4
  %268 = trunc i64 %267 to i32
  %269 = getelementptr inbounds [32 x ptr], ptr %18, i64 0, i64 0
  %270 = load i32, ptr %6, align 4, !tbaa !9
  call void @mMemoryIndex(ptr noundef %264, i32 noundef 1, i32 noundef %268, ptr noundef %269, i32 noundef %270)
  %271 = load i32, ptr %7, align 4, !tbaa !9
  %272 = load ptr, ptr %14, align 8, !tbaa !5
  %273 = getelementptr inbounds %struct.HandleWaveCreate, ptr %272, i32 0, i32 3
  store i32 %271, ptr %273, align 4, !tbaa !19
  %274 = load i32, ptr %6, align 4, !tbaa !9
  %275 = load ptr, ptr %14, align 8, !tbaa !5
  %276 = getelementptr inbounds %struct.HandleWaveCreate, ptr %275, i32 0, i32 2
  store i32 %274, ptr %276, align 8, !tbaa !21
  call void @llvm.lifetime.end.p0(i64 256, ptr %18) #5
  br label %277

277:                                              ; preds = %261, %212
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #5
  store i32 0, ptr %20, align 4, !tbaa !9
  br label %278

278:                                              ; preds = %296, %277
  %279 = load i32, ptr %20, align 4, !tbaa !9
  %280 = load i32, ptr %6, align 4, !tbaa !9
  %281 = icmp slt i32 %279, %280
  br i1 %281, label %283, label %282

282:                                              ; preds = %278
  store i32 13, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #5
  br label %299

283:                                              ; preds = %278
  %284 = load ptr, ptr %14, align 8, !tbaa !5
  %285 = getelementptr inbounds %struct.HandleWaveCreate, ptr %284, i32 0, i32 4
  %286 = load i32, ptr %20, align 4, !tbaa !9
  %287 = sext i32 %286 to i64
  %288 = getelementptr inbounds [32 x ptr], ptr %285, i64 0, i64 %287
  %289 = load ptr, ptr %288, align 8, !tbaa !5
  %290 = getelementptr inbounds float, ptr %289, i64 16
  %291 = load ptr, ptr %5, align 8, !tbaa !5
  %292 = getelementptr inbounds %struct.MWave, ptr %291, i32 0, i32 2
  %293 = load i32, ptr %20, align 4, !tbaa !9
  %294 = sext i32 %293 to i64
  %295 = getelementptr inbounds [32 x ptr], ptr %292, i64 0, i64 %294
  store ptr %290, ptr %295, align 8, !tbaa !5
  br label %296

296:                                              ; preds = %283
  %297 = load i32, ptr %20, align 4, !tbaa !9
  %298 = add nsw i32 %297, 1
  store i32 %298, ptr %20, align 4, !tbaa !9
  br label %278, !llvm.loop !25

299:                                              ; preds = %282
  store i32 0, ptr %13, align 4
  br label %300

300:                                              ; preds = %299, %198, %187, %129
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  br label %301

301:                                              ; preds = %300, %108
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #5
  %302 = load i32, ptr %13, align 4
  switch i32 %302, label %304 [
    i32 0, label %303
    i32 1, label %303
  ]

303:                                              ; preds = %301, %301
  ret void

304:                                              ; preds = %301
  unreachable
}

declare void @mHandleReset(ptr noundef) #1

declare void @mMemoryRedefine(ptr noundef, i32 noundef, i32 noundef, i32 noundef) #1

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 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #3 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { 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 #5 = { 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 = !{!"int", !7, i64 0}
!11 = !{!12, !10, i64 4}
!12 = !{!"MWave", !10, i64 0, !10, i64 4, !7, i64 8}
!13 = !{!12, !10, i64 0}
!14 = !{!15, !6, i64 8}
!15 = !{!"HandleList", !16, i64 0, !10, i64 16, !10, i64 20, !10, i64 24, !10, i64 28}
!16 = !{!"MList", !10, i64 0, !6, i64 8}
!17 = !{!18, !6, i64 16}
!18 = !{!"MHandle", !10, i64 0, !10, i64 4, !6, i64 8, !6, i64 16}
!19 = !{!20, !10, i64 20}
!20 = !{!"HandleWaveCreate", !6, i64 0, !6, i64 8, !10, i64 16, !10, i64 20, !7, i64 24, !6, i64 280}
!21 = !{!20, !10, i64 16}
!22 = distinct !{!22, !23}
!23 = !{!"llvm.loop.mustprogress"}
!24 = !{!20, !6, i64 280}
!25 = distinct !{!25, !23}


; 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 [76 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [14 x i8], align 1
@__FUNCTION__.mWaveRedefine = external hidden unnamed_addr constant [14 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [17 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

declare void @m_Exception(i32 noundef, i32 noundef, ptr noundef, i32 noundef, ptr noundef, ptr noundef, ...) local_unnamed_addr #1

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

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #2

declare ptr @mMemoryCreate(i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #1

declare void @mMemoryIndex(ptr noundef, i32 noundef, i32 noundef, ptr noundef, i32 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress 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) #3

; Function Attrs: nounwind uwtable
define dso_local void @mWaveRedefine(ptr noundef %0, i32 noundef %1, i32 noundef %2, ptr noundef readonly %3) local_unnamed_addr #4 {
  %5 = ptrtoint ptr %0 to i64
  %6 = alloca [32 x ptr], align 16
  %magicptr = ptrtoint ptr %0 to i64
  switch i64 %magicptr, label %12 [
    i64 -1, label %7
    i64 0, label %7
  ]

7:                                                ; preds = %4, %4
  %8 = icmp eq ptr %0, null
  %9 = icmp eq ptr %0, inttoptr (i64 -1 to ptr)
  %10 = or i1 %8, %9
  %11 = zext i1 %10 to i32
  tail call void (i32, i32, ptr, i32, ptr, ptr, ...) @m_Exception(i32 noundef %11, i32 noundef -1, ptr noundef nonnull @.str, i32 noundef 70, ptr noundef nonnull @__FUNCTION__.mWaveRedefine, ptr noundef nonnull @.str.2) #5
  br label %12

12:                                               ; preds = %4, %7
  %13 = icmp slt i32 %2, 1
  br i1 %13, label %14, label %17

14:                                               ; preds = %12
  %15 = getelementptr inbounds i8, ptr %0, i64 4
  %16 = load i32, ptr %15, align 4, !tbaa !5
  br label %17

17:                                               ; preds = %14, %12
  %.092 = phi i32 [ %16, %14 ], [ %2, %12 ]
  %18 = icmp slt i32 %1, 1
  %.pre = load i32, ptr %0, align 8, !tbaa !10
  br i1 %18, label %.thread117, label %19

19:                                               ; preds = %17
  %.not = icmp eq i32 %.pre, %1
  br i1 %.not, label %.thread117, label %22

.thread117:                                       ; preds = %17, %19
  %.091122 = phi i32 [ %1, %19 ], [ %.pre, %17 ]
  %20 = getelementptr inbounds i8, ptr %0, i64 4
  %21 = load i32, ptr %20, align 4, !tbaa !5
  %.not98 = icmp eq i32 %.092, %21
  br i1 %.not98, label %23, label %22

22:                                               ; preds = %.thread117, %19
  %.091120 = phi i32 [ %.091122, %.thread117 ], [ %1, %19 ]
  tail call void @mHandleReset(ptr noundef nonnull %0) #5
  %.phi.trans.insert = getelementptr inbounds i8, ptr %0, i64 4
  %.pre115 = load i32, ptr %.phi.trans.insert, align 4, !tbaa !5
  br label %23

23:                                               ; preds = %22, %.thread117
  %.091121 = phi i32 [ %.091120, %22 ], [ %.091122, %.thread117 ]
  %24 = phi i32 [ %.pre115, %22 ], [ %.092, %.thread117 ]
  %25 = getelementptr inbounds i8, ptr %0, i64 4
  %.not99 = icmp sgt i32 %.092, %24
  br i1 %.not99, label %29, label %26

26:                                               ; preds = %23
  %27 = load i32, ptr %0, align 8, !tbaa !10
  %28 = icmp sle i32 %.091121, %27
  br label %29

29:                                               ; preds = %26, %23
  %30 = phi i1 [ false, %23 ], [ %28, %26 ]
  %31 = getelementptr inbounds i8, ptr %0, i64 8
  %32 = icmp eq ptr %31, %3
  %.not100 = icmp eq i32 %24, 0
  br i1 %.not100, label %36, label %33

33:                                               ; preds = %29
  %34 = load i32, ptr %0, align 8, !tbaa !10
  %35 = icmp ne i32 %34, 0
  br label %36

36:                                               ; preds = %33, %29
  %37 = phi i1 [ false, %29 ], [ %35, %33 ]
  store i32 %.092, ptr %25, align 4, !tbaa !5
  store i32 %.091121, ptr %0, align 8, !tbaa !10
  %or.cond = select i1 %30, i1 %32, i1 false
  br i1 %or.cond, label %.loopexit, label %38

38:                                               ; preds = %36
  %39 = getelementptr inbounds i8, ptr %0, i64 -24
  %40 = load ptr, ptr %39, align 8, !tbaa !11
  %41 = load ptr, ptr %40, align 8, !tbaa !15
  %42 = getelementptr inbounds i8, ptr %41, i64 16
  %43 = load ptr, ptr %42, align 8, !tbaa !16
  %44 = ptrtoint ptr %43 to i64
  %45 = icmp eq ptr %3, null
  %or.cond3 = and i1 %45, %30
  br i1 %or.cond3, label %46, label %50

46:                                               ; preds = %38
  %47 = getelementptr inbounds i8, ptr %43, i64 20
  %48 = load i32, ptr %47, align 4, !tbaa !18
  %49 = icmp sgt i32 %48, 0
  br i1 %49, label %.loopexit, label %50

50:                                               ; preds = %38, %46
  %or.cond5 = select i1 %32, i1 %37, i1 false
  br i1 %or.cond5, label %51, label %.thread

51:                                               ; preds = %50
  %52 = getelementptr inbounds i8, ptr %43, i64 20
  %53 = load i32, ptr %52, align 4, !tbaa !18
  %54 = icmp eq i32 %53, 0
  br i1 %54, label %55, label %.thread

55:                                               ; preds = %51
  tail call void (i32, i32, ptr, i32, ptr, ptr, ...) @m_Exception(i32 noundef 1, i32 noundef -1, ptr noundef nonnull @.str, i32 noundef 86, ptr noundef nonnull @__FUNCTION__.mWaveRedefine, ptr noundef nonnull @.str.3) #5
  br label %.thread

.thread:                                          ; preds = %50, %55, %51
  %56 = icmp sgt i32 %.091121, 32
  br i1 %56, label %57, label %58

57:                                               ; preds = %.thread
  tail call void (i32, i32, ptr, i32, ptr, ptr, ...) @m_Exception(i32 noundef 1, i32 noundef -1, ptr noundef nonnull @.str, i32 noundef 88, ptr noundef nonnull @__FUNCTION__.mWaveRedefine, ptr noundef nonnull @.str.2) #5
  br label %58

58:                                               ; preds = %57, %.thread
  %59 = getelementptr inbounds i8, ptr %43, i64 20
  store i32 0, ptr %59, align 4, !tbaa !18
  %60 = icmp slt i32 %.091121, 1
  %61 = icmp slt i32 %.092, 1
  %or.cond7 = select i1 %60, i1 true, i1 %61
  br i1 %or.cond7, label %62, label %65

62:                                               ; preds = %58
  %.not104 = select i1 %45, i1 true, i1 %32
  br i1 %.not104, label %64, label %63

63:                                               ; preds = %62
  tail call void (i32, i32, ptr, i32, ptr, ptr, ...) @m_Exception(i32 noundef 1, i32 noundef -1, ptr noundef nonnull @.str, i32 noundef 93, ptr noundef nonnull @__FUNCTION__.mWaveRedefine, ptr noundef nonnull @.str.2) #5
  br label %64

64:                                               ; preds = %63, %62
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(256) %31, i8 0, i64 256, i1 false)
  br label %.loopexit

65:                                               ; preds = %58
  %.not101 = or i1 %32, %45
  br i1 %.not101, label %.lr.ph, label %66

66:                                               ; preds = %65
  %67 = zext nneg i32 %.091121 to i64
  %68 = shl nuw nsw i64 %67, 3
  tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 8 %31, ptr nonnull align 8 %3, i64 %68, i1 false)
  br label %.loopexit

.lr.ph:                                           ; preds = %65
  %69 = add nuw nsw i32 %.092, 32
  call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %6) #5
  %70 = getelementptr inbounds i8, ptr %43, i64 24
  %wide.trip.count = zext nneg i32 %.091121 to i64
  %min.iters.check = icmp ult i32 %.091121, 4
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.ph

scalar.ph.preheader:                              ; preds = %middle.block, %.lr.ph
  %indvars.iv.ph = phi i64 [ 0, %.lr.ph ], [ %n.vec, %middle.block ]
  br label %scalar.ph

vector.ph:                                        ; preds = %.lr.ph
  %n.vec = and i64 %wide.trip.count, 2147483644
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %vec.ind = phi <2 x i64> [ <i64 0, i64 1>, %vector.ph ], [ %vec.ind.next, %vector.body ]
  %step.add = add <2 x i64> %vec.ind, <i64 2, i64 2>
  %71 = getelementptr inbounds [32 x ptr], ptr %70, i64 0, <2 x i64> %vec.ind
  %72 = getelementptr inbounds [32 x ptr], ptr %70, i64 0, <2 x i64> %step.add
  %73 = getelementptr inbounds [32 x ptr], ptr %6, i64 0, i64 %index
  %74 = getelementptr inbounds i8, ptr %73, i64 16
  store <2 x ptr> %71, ptr %73, align 16, !tbaa !15
  store <2 x ptr> %72, ptr %74, align 16, !tbaa !15
  %index.next = add nuw i64 %index, 4
  %vec.ind.next = add <2 x i64> %vec.ind, <i64 4, i64 4>
  %75 = icmp eq i64 %index.next, %n.vec
  br i1 %75, label %middle.block, label %vector.body, !llvm.loop !20

middle.block:                                     ; preds = %vector.body
  %cmp.n = icmp eq i64 %n.vec, %wide.trip.count
  br i1 %cmp.n, label %._crit_edge, label %scalar.ph.preheader

._crit_edge:                                      ; preds = %scalar.ph, %middle.block
  %76 = getelementptr inbounds i8, ptr %43, i64 280
  %77 = load ptr, ptr %76, align 8, !tbaa !24
  %78 = icmp eq ptr %77, null
  %79 = shl i32 %69, 2
  br i1 %78, label %82, label %84

scalar.ph:                                        ; preds = %scalar.ph.preheader, %scalar.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %scalar.ph ], [ %indvars.iv.ph, %scalar.ph.preheader ]
  %80 = getelementptr inbounds [32 x ptr], ptr %70, i64 0, i64 %indvars.iv
  %81 = getelementptr inbounds [32 x ptr], ptr %6, i64 0, i64 %indvars.iv
  store ptr %80, ptr %81, align 8, !tbaa !15
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %._crit_edge, label %scalar.ph, !llvm.loop !25

82:                                               ; preds = %._crit_edge
  %83 = tail call ptr @mMemoryCreate(i32 noundef %.091121, i32 noundef %79, i32 noundef 0) #5
  store ptr %83, ptr %76, align 8, !tbaa !24
  br label %.lr.ph108

84:                                               ; preds = %._crit_edge
  tail call void @mMemoryRedefine(ptr noundef nonnull %77, i32 noundef %.091121, i32 noundef %79, i32 noundef 0) #5
  %.pre116 = load ptr, ptr %76, align 8, !tbaa !24
  br label %.lr.ph108

.lr.ph108:                                        ; preds = %84, %82
  %85 = phi ptr [ %83, %82 ], [ %.pre116, %84 ]
  call void @mMemoryIndex(ptr noundef %85, i32 noundef 1, i32 noundef %79, ptr noundef nonnull %6, i32 noundef %.091121) #5
  store i32 %69, ptr %59, align 4, !tbaa !18
  %86 = getelementptr inbounds i8, ptr %43, i64 16
  store i32 %.091121, ptr %86, align 8, !tbaa !26
  call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %6) #5
  %87 = getelementptr inbounds i8, ptr %43, i64 24
  %wide.trip.count113 = zext nneg i32 %.091121 to i64
  %min.iters.check126 = icmp ult i32 %.091121, 8
  br i1 %min.iters.check126, label %scalar.ph125.preheader, label %vector.memcheck

vector.memcheck:                                  ; preds = %.lr.ph108
  %88 = add i64 %5, -16
  %89 = sub i64 %88, %44
  %diff.check = icmp ult i64 %89, 32
  br i1 %diff.check, label %scalar.ph125.preheader, label %vector.ph127

vector.ph127:                                     ; preds = %vector.memcheck
  %n.vec129 = and i64 %wide.trip.count, 2147483644
  br label %vector.body131

vector.body131:                                   ; preds = %vector.body131, %vector.ph127
  %index132 = phi i64 [ 0, %vector.ph127 ], [ %index.next134, %vector.body131 ]
  %90 = getelementptr inbounds [32 x ptr], ptr %87, i64 0, i64 %index132
  %91 = getelementptr inbounds i8, ptr %90, i64 16
  %wide.load = load <2 x ptr>, ptr %90, align 8, !tbaa !15
  %wide.load133 = load <2 x ptr>, ptr %91, align 8, !tbaa !15
  %92 = getelementptr inbounds i8, <2 x ptr> %wide.load, i64 64
  %93 = getelementptr inbounds i8, <2 x ptr> %wide.load133, i64 64
  %94 = getelementptr inbounds [32 x ptr], ptr %31, i64 0, i64 %index132
  %95 = getelementptr inbounds i8, ptr %94, i64 16
  store <2 x ptr> %92, ptr %94, align 8, !tbaa !15
  store <2 x ptr> %93, ptr %95, align 8, !tbaa !15
  %index.next134 = add nuw i64 %index132, 4
  %96 = icmp eq i64 %index.next134, %n.vec129
  br i1 %96, label %middle.block124, label %vector.body131, !llvm.loop !27

middle.block124:                                  ; preds = %vector.body131
  %cmp.n135 = icmp eq i64 %n.vec129, %wide.trip.count
  br i1 %cmp.n135, label %.loopexit, label %scalar.ph125.preheader

scalar.ph125.preheader:                           ; preds = %middle.block124, %vector.memcheck, %.lr.ph108
  %indvars.iv110.ph = phi i64 [ 0, %vector.memcheck ], [ 0, %.lr.ph108 ], [ %n.vec129, %middle.block124 ]
  %xtraiter = and i64 %wide.trip.count, 3
  %lcmp.mod.not = icmp eq i64 %xtraiter, 0
  br i1 %lcmp.mod.not, label %scalar.ph125.prol.loopexit, label %scalar.ph125.prol

scalar.ph125.prol:                                ; preds = %scalar.ph125.preheader, %scalar.ph125.prol
  %indvars.iv110.prol = phi i64 [ %indvars.iv.next111.prol, %scalar.ph125.prol ], [ %indvars.iv110.ph, %scalar.ph125.preheader ]
  %prol.iter = phi i64 [ %prol.iter.next, %scalar.ph125.prol ], [ 0, %scalar.ph125.preheader ]
  %97 = getelementptr inbounds [32 x ptr], ptr %87, i64 0, i64 %indvars.iv110.prol
  %98 = load ptr, ptr %97, align 8, !tbaa !15
  %99 = getelementptr inbounds i8, ptr %98, i64 64
  %100 = getelementptr inbounds [32 x ptr], ptr %31, i64 0, i64 %indvars.iv110.prol
  store ptr %99, ptr %100, align 8, !tbaa !15
  %indvars.iv.next111.prol = add nuw nsw i64 %indvars.iv110.prol, 1
  %prol.iter.next = add i64 %prol.iter, 1
  %prol.iter.cmp.not = icmp eq i64 %prol.iter.next, %xtraiter
  br i1 %prol.iter.cmp.not, label %scalar.ph125.prol.loopexit, label %scalar.ph125.prol, !llvm.loop !28

scalar.ph125.prol.loopexit:                       ; preds = %scalar.ph125.prol, %scalar.ph125.preheader
  %indvars.iv110.unr = phi i64 [ %indvars.iv110.ph, %scalar.ph125.preheader ], [ %indvars.iv.next111.prol, %scalar.ph125.prol ]
  %101 = sub nsw i64 %indvars.iv110.ph, %wide.trip.count
  %102 = icmp ugt i64 %101, -4
  br i1 %102, label %.loopexit, label %scalar.ph125

scalar.ph125:                                     ; preds = %scalar.ph125.prol.loopexit, %scalar.ph125
  %indvars.iv110 = phi i64 [ %indvars.iv.next111.3, %scalar.ph125 ], [ %indvars.iv110.unr, %scalar.ph125.prol.loopexit ]
  %103 = getelementptr inbounds [32 x ptr], ptr %87, i64 0, i64 %indvars.iv110
  %104 = load ptr, ptr %103, align 8, !tbaa !15
  %105 = getelementptr inbounds i8, ptr %104, i64 64
  %106 = getelementptr inbounds [32 x ptr], ptr %31, i64 0, i64 %indvars.iv110
  store ptr %105, ptr %106, align 8, !tbaa !15
  %indvars.iv.next111 = add nuw nsw i64 %indvars.iv110, 1
  %107 = getelementptr inbounds [32 x ptr], ptr %87, i64 0, i64 %indvars.iv.next111
  %108 = load ptr, ptr %107, align 8, !tbaa !15
  %109 = getelementptr inbounds i8, ptr %108, i64 64
  %110 = getelementptr inbounds [32 x ptr], ptr %31, i64 0, i64 %indvars.iv.next111
  store ptr %109, ptr %110, align 8, !tbaa !15
  %indvars.iv.next111.1 = add nuw nsw i64 %indvars.iv110, 2
  %111 = getelementptr inbounds [32 x ptr], ptr %87, i64 0, i64 %indvars.iv.next111.1
  %112 = load ptr, ptr %111, align 8, !tbaa !15
  %113 = getelementptr inbounds i8, ptr %112, i64 64
  %114 = getelementptr inbounds [32 x ptr], ptr %31, i64 0, i64 %indvars.iv.next111.1
  store ptr %113, ptr %114, align 8, !tbaa !15
  %indvars.iv.next111.2 = add nuw nsw i64 %indvars.iv110, 3
  %115 = getelementptr inbounds [32 x ptr], ptr %87, i64 0, i64 %indvars.iv.next111.2
  %116 = load ptr, ptr %115, align 8, !tbaa !15
  %117 = getelementptr inbounds i8, ptr %116, i64 64
  %118 = getelementptr inbounds [32 x ptr], ptr %31, i64 0, i64 %indvars.iv.next111.2
  store ptr %117, ptr %118, align 8, !tbaa !15
  %indvars.iv.next111.3 = add nuw nsw i64 %indvars.iv110, 4
  %exitcond114.not.3 = icmp eq i64 %indvars.iv.next111.3, %wide.trip.count113
  br i1 %exitcond114.not.3, label %.loopexit, label %scalar.ph125, !llvm.loop !30

.loopexit:                                        ; preds = %scalar.ph125.prol.loopexit, %scalar.ph125, %middle.block124, %64, %66, %46, %36
  ret void
}

declare void @mHandleReset(ptr noundef) local_unnamed_addr #1

declare void @mMemoryRedefine(ptr noundef, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #1

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 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #3 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { 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 #5 = { 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, !7, i64 4}
!6 = !{!"MWave", !7, i64 0, !7, i64 4, !8, i64 8}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!6, !7, i64 0}
!11 = !{!12, !14, i64 8}
!12 = !{!"HandleList", !13, i64 0, !7, i64 16, !7, i64 20, !7, i64 24, !7, i64 28}
!13 = !{!"MList", !7, i64 0, !14, i64 8}
!14 = !{!"any pointer", !8, i64 0}
!15 = !{!14, !14, i64 0}
!16 = !{!17, !14, i64 16}
!17 = !{!"MHandle", !7, i64 0, !7, i64 4, !14, i64 8, !14, i64 16}
!18 = !{!19, !7, i64 20}
!19 = !{!"HandleWaveCreate", !14, i64 0, !14, i64 8, !7, i64 16, !7, i64 20, !8, i64 24, !14, i64 280}
!20 = distinct !{!20, !21, !22, !23}
!21 = !{!"llvm.loop.mustprogress"}
!22 = !{!"llvm.loop.isvectorized", i32 1}
!23 = !{!"llvm.loop.unroll.runtime.disable"}
!24 = !{!19, !14, i64 280}
!25 = distinct !{!25, !21, !23, !22}
!26 = !{!19, !7, i64 16}
!27 = distinct !{!27, !21, !22, !23}
!28 = distinct !{!28, !29}
!29 = !{!"llvm.loop.unroll.disable"}
!30 = distinct !{!30, !21, !22}


; Effective O3 passes: ConstraintEliminationPass,CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,IndVarSimplifyPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass