; LLVM IR from libxsmm/libxsmm :: src (generator_mateltwise_unary_binary_rv64)

; 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.libxsmm_meltw_descriptor = type <{ i32, i32, i32, i32, i32, i32, i8, i8, i8, i16, i16, i8 }>

@.str = external hidden unnamed_addr constant [94 x i8], align 1
@libxsmm_ninit = external global i32, align 4
@libxsmm_verbosity = external global i32, align 4
@__func__.libxsmm_generator_configure_rv64_M_N_blocking = external hidden unnamed_addr constant [46 x i8], align 1

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

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

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

; Function Attrs: nounwind uwtable
define dso_local void @libxsmm_generator_configure_rv64_M_N_blocking(ptr noundef %0, ptr noundef %1, i32 noundef %2, i32 noundef %3, i32 noundef %4, ptr noundef %5, ptr noundef %6, i32 noundef %7) #2 {
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  %19 = alloca i32, align 4
  %20 = alloca i32, align 4
  %21 = alloca i32, align 4
  %22 = alloca i32, align 4
  %23 = alloca i32, align 4
  %24 = alloca i32, align 4
  %25 = alloca i32, align 4
  %26 = alloca i32, align 4
  %27 = alloca i32, align 4
  %28 = alloca i32, align 4
  %29 = alloca i32, align 4
  %30 = alloca i32, align 4
  %31 = alloca i32, align 4
  %32 = alloca i32, align 4
  store ptr %0, ptr %9, align 8, !tbaa !5
  store ptr %1, ptr %10, align 8, !tbaa !5
  store i32 %2, ptr %11, align 4, !tbaa !9
  store i32 %3, ptr %12, align 4, !tbaa !9
  store i32 %4, ptr %13, align 4, !tbaa !9
  store ptr %5, ptr %14, align 8, !tbaa !5
  store ptr %6, ptr %15, align 8, !tbaa !5
  store i32 %7, ptr %16, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #3
  store i32 0, ptr %17, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #3
  store i32 4, ptr %18, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #3
  store i32 32, ptr %19, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #3
  %33 = load ptr, ptr %10, align 8, !tbaa !5
  %34 = getelementptr inbounds %struct.libxsmm_meltw_descriptor, ptr %33, i32 0, i32 9
  %35 = load i16, ptr %34, align 1, !tbaa !11
  %36 = zext i16 %35 to i32
  %37 = and i32 %36, 1
  %38 = icmp sgt i32 %37, 0
  br i1 %38, label %39, label %61

39:                                               ; preds = %8
  %40 = load i32, ptr %13, align 4, !tbaa !9
  %41 = icmp eq i32 %40, 4
  br i1 %41, label %42, label %61

42:                                               ; preds = %39
  %43 = load i32, ptr %13, align 4, !tbaa !9
  %44 = mul i32 %43, 2
  store i32 %44, ptr %13, align 4, !tbaa !9
  %45 = load i32, ptr %16, align 4, !tbaa !9
  %46 = icmp ult i32 %45, 3
  br i1 %46, label %47, label %56

47:                                               ; preds = %42
  %48 = load ptr, ptr %9, align 8, !tbaa !5
  %49 = load i32, ptr @libxsmm_ninit, align 4, !tbaa !9
  %50 = icmp ult i32 1, %49
  br i1 %50, label %51, label %53

51:                                               ; preds = %47
  %52 = load i32, ptr @libxsmm_verbosity, align 4, !tbaa !9
  br label %54

53:                                               ; preds = %47
  br label %54

54:                                               ; preds = %53, %51
  %55 = phi i32 [ %52, %51 ], [ 1, %53 ]
  call void @libxsmm_handle_error(ptr noundef %48, i32 noundef 90045, ptr noundef @__func__.libxsmm_generator_configure_rv64_M_N_blocking, ptr noundef @.str, i32 noundef 265, i32 noundef %55)
  store i32 1, ptr %24, align 4
  br label %233

56:                                               ; preds = %42
  %57 = load i32, ptr %16, align 4, !tbaa !9
  %58 = udiv i32 %57, 2
  store i32 %58, ptr %16, align 4, !tbaa !9
  %59 = load i32, ptr %19, align 4, !tbaa !9
  %60 = udiv i32 %59, 2
  store i32 %60, ptr %19, align 4, !tbaa !9
  br label %61

61:                                               ; preds = %56, %39, %8
  %62 = load i32, ptr %11, align 4, !tbaa !9
  %63 = load i32, ptr %13, align 4, !tbaa !9
  %64 = sub i32 %63, 1
  %65 = add i32 %62, %64
  %66 = load i32, ptr %13, align 4, !tbaa !9
  %67 = udiv i32 %65, %66
  store i32 %67, ptr %17, align 4, !tbaa !9
  %68 = load i32, ptr %17, align 4, !tbaa !9
  %69 = and i32 %68, -2
  store i32 %69, ptr %17, align 4, !tbaa !9
  %70 = load i32, ptr %11, align 4, !tbaa !9
  %71 = load i32, ptr %13, align 4, !tbaa !9
  %72 = urem i32 %70, %71
  %73 = icmp eq i32 %72, 0
  br i1 %73, label %74, label %92

74:                                               ; preds = %61
  %75 = load i32, ptr %17, align 4, !tbaa !9
  %76 = load i32, ptr %19, align 4, !tbaa !9
  %77 = icmp ugt i32 %75, %76
  br i1 %77, label %78, label %88

78:                                               ; preds = %74
  %79 = load i32, ptr %17, align 4, !tbaa !9
  %80 = load i32, ptr %17, align 4, !tbaa !9
  %81 = add i32 %80, 1
  %82 = udiv i32 %81, 2
  %83 = call i32 @libxsmm_compute_equalized_blocking(i32 noundef %79, i32 noundef %82, ptr noundef %20, ptr noundef %21, ptr noundef %22, ptr noundef %23)
  %84 = load i32, ptr %20, align 4, !tbaa !9
  %85 = load i32, ptr %13, align 4, !tbaa !9
  %86 = mul i32 %84, %85
  %87 = load ptr, ptr %14, align 8, !tbaa !5
  store i32 %86, ptr %87, align 4, !tbaa !9
  br label %91

88:                                               ; preds = %74
  %89 = load i32, ptr %11, align 4, !tbaa !9
  %90 = load ptr, ptr %14, align 8, !tbaa !5
  store i32 %89, ptr %90, align 4, !tbaa !9
  br label %91

91:                                               ; preds = %88, %78
  br label %230

92:                                               ; preds = %61
  %93 = load i32, ptr %17, align 4, !tbaa !9
  %94 = load i32, ptr %19, align 4, !tbaa !9
  %95 = udiv i32 %94, 2
  %96 = icmp ugt i32 %93, %95
  br i1 %96, label %97, label %159

97:                                               ; preds = %92
  %98 = load ptr, ptr %10, align 8, !tbaa !5
  %99 = getelementptr inbounds %struct.libxsmm_meltw_descriptor, ptr %98, i32 0, i32 9
  %100 = load i16, ptr %99, align 1, !tbaa !11
  %101 = zext i16 %100 to i32
  %102 = and i32 %101, 1
  %103 = icmp sgt i32 %102, 0
  br i1 %103, label %104, label %114

104:                                              ; preds = %97
  %105 = load i32, ptr %13, align 4, !tbaa !9
  %106 = icmp eq i32 %105, 4
  br i1 %106, label %107, label %114

107:                                              ; preds = %104
  %108 = load i32, ptr %17, align 4, !tbaa !9
  %109 = load i32, ptr %18, align 4, !tbaa !9
  %110 = sub i32 %108, %109
  %111 = load i32, ptr %13, align 4, !tbaa !9
  %112 = mul i32 %110, %111
  %113 = load ptr, ptr %14, align 8, !tbaa !5
  store i32 %112, ptr %113, align 4, !tbaa !9
  br label %158

114:                                              ; preds = %104, %97
  call void @llvm.lifetime.start.p0(i64 4, ptr %25) #3
  store i32 0, ptr %25, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %26) #3
  store i32 0, ptr %26, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %27) #3
  store i32 0, ptr %27, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %28) #3
  store i32 0, ptr %28, align 4, !tbaa !9
  %115 = load i32, ptr %18, align 4, !tbaa !9
  store i32 %115, ptr %28, align 4, !tbaa !9
  br label %116

116:                                              ; preds = %152, %114
  %117 = load i32, ptr %28, align 4, !tbaa !9
  %118 = load i32, ptr %17, align 4, !tbaa !9
  %119 = load i32, ptr %16, align 4, !tbaa !9
  %120 = icmp ult i32 %118, %119
  br i1 %120, label %121, label %123

121:                                              ; preds = %116
  %122 = load i32, ptr %17, align 4, !tbaa !9
  br label %125

123:                                              ; preds = %116
  %124 = load i32, ptr %16, align 4, !tbaa !9
  br label %125

125:                                              ; preds = %123, %121
  %126 = phi i32 [ %122, %121 ], [ %124, %123 ]
  %127 = icmp ult i32 %117, %126
  br i1 %127, label %128, label %155

128:                                              ; preds = %125
  %129 = load i32, ptr %16, align 4, !tbaa !9
  store i32 %129, ptr %26, align 4, !tbaa !9
  br label %130

130:                                              ; preds = %137, %128
  %131 = load i32, ptr %17, align 4, !tbaa !9
  %132 = load i32, ptr %28, align 4, !tbaa !9
  %133 = sub i32 %131, %132
  %134 = load i32, ptr %26, align 4, !tbaa !9
  %135 = urem i32 %133, %134
  %136 = icmp ne i32 %135, 0
  br i1 %136, label %137, label %140

137:                                              ; preds = %130
  %138 = load i32, ptr %26, align 4, !tbaa !9
  %139 = add i32 %138, -1
  store i32 %139, ptr %26, align 4, !tbaa !9
  br label %130, !llvm.loop !14

140:                                              ; preds = %130
  %141 = load i32, ptr %26, align 4, !tbaa !9
  %142 = load i32, ptr %27, align 4, !tbaa !9
  %143 = icmp ugt i32 %141, %142
  br i1 %143, label %144, label %151

144:                                              ; preds = %140
  %145 = load i32, ptr %26, align 4, !tbaa !9
  store i32 %145, ptr %27, align 4, !tbaa !9
  %146 = load i32, ptr %17, align 4, !tbaa !9
  %147 = load i32, ptr %28, align 4, !tbaa !9
  %148 = sub i32 %146, %147
  %149 = load i32, ptr %13, align 4, !tbaa !9
  %150 = mul i32 %148, %149
  store i32 %150, ptr %25, align 4, !tbaa !9
  br label %151

151:                                              ; preds = %144, %140
  br label %152

152:                                              ; preds = %151
  %153 = load i32, ptr %28, align 4, !tbaa !9
  %154 = add i32 %153, 1
  store i32 %154, ptr %28, align 4, !tbaa !9
  br label %116, !llvm.loop !16

155:                                              ; preds = %125
  %156 = load i32, ptr %25, align 4, !tbaa !9
  %157 = load ptr, ptr %14, align 8, !tbaa !5
  store i32 %156, ptr %157, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 4, ptr %28) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %27) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %26) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %25) #3
  br label %158

158:                                              ; preds = %155, %107
  br label %229

159:                                              ; preds = %92
  %160 = load i32, ptr %16, align 4, !tbaa !9
  %161 = load i32, ptr %13, align 4, !tbaa !9
  %162 = mul i32 %160, %161
  %163 = load i32, ptr %11, align 4, !tbaa !9
  %164 = icmp uge i32 %162, %163
  br i1 %164, label %165, label %168

165:                                              ; preds = %159
  %166 = load i32, ptr %11, align 4, !tbaa !9
  %167 = load ptr, ptr %14, align 8, !tbaa !5
  store i32 %166, ptr %167, align 4, !tbaa !9
  br label %228

168:                                              ; preds = %159
  %169 = load ptr, ptr %10, align 8, !tbaa !5
  %170 = getelementptr inbounds %struct.libxsmm_meltw_descriptor, ptr %169, i32 0, i32 9
  %171 = load i16, ptr %170, align 1, !tbaa !11
  %172 = zext i16 %171 to i32
  %173 = and i32 %172, 1
  %174 = icmp sgt i32 %173, 0
  br i1 %174, label %175, label %184

175:                                              ; preds = %168
  %176 = load i32, ptr %13, align 4, !tbaa !9
  %177 = icmp eq i32 %176, 4
  br i1 %177, label %178, label %184

178:                                              ; preds = %175
  %179 = load i32, ptr %17, align 4, !tbaa !9
  %180 = sub i32 %179, 1
  %181 = load i32, ptr %13, align 4, !tbaa !9
  %182 = mul i32 %180, %181
  %183 = load ptr, ptr %14, align 8, !tbaa !5
  store i32 %182, ptr %183, align 4, !tbaa !9
  br label %227

184:                                              ; preds = %175, %168
  call void @llvm.lifetime.start.p0(i64 4, ptr %29) #3
  store i32 0, ptr %29, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %30) #3
  store i32 0, ptr %30, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %31) #3
  store i32 0, ptr %31, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %32) #3
  store i32 0, ptr %32, align 4, !tbaa !9
  store i32 1, ptr %32, align 4, !tbaa !9
  br label %185

185:                                              ; preds = %221, %184
  %186 = load i32, ptr %32, align 4, !tbaa !9
  %187 = load i32, ptr %17, align 4, !tbaa !9
  %188 = load i32, ptr %16, align 4, !tbaa !9
  %189 = icmp ult i32 %187, %188
  br i1 %189, label %190, label %192

190:                                              ; preds = %185
  %191 = load i32, ptr %17, align 4, !tbaa !9
  br label %194

192:                                              ; preds = %185
  %193 = load i32, ptr %16, align 4, !tbaa !9
  br label %194

194:                                              ; preds = %192, %190
  %195 = phi i32 [ %191, %190 ], [ %193, %192 ]
  %196 = icmp ult i32 %186, %195
  br i1 %196, label %197, label %224

197:                                              ; preds = %194
  %198 = load i32, ptr %16, align 4, !tbaa !9
  store i32 %198, ptr %30, align 4, !tbaa !9
  br label %199

199:                                              ; preds = %206, %197
  %200 = load i32, ptr %17, align 4, !tbaa !9
  %201 = load i32, ptr %32, align 4, !tbaa !9
  %202 = sub i32 %200, %201
  %203 = load i32, ptr %30, align 4, !tbaa !9
  %204 = urem i32 %202, %203
  %205 = icmp ne i32 %204, 0
  br i1 %205, label %206, label %209

206:                                              ; preds = %199
  %207 = load i32, ptr %30, align 4, !tbaa !9
  %208 = add i32 %207, -1
  store i32 %208, ptr %30, align 4, !tbaa !9
  br label %199, !llvm.loop !17

209:                                              ; preds = %199
  %210 = load i32, ptr %30, align 4, !tbaa !9
  %211 = load i32, ptr %31, align 4, !tbaa !9
  %212 = icmp ugt i32 %210, %211
  br i1 %212, label %213, label %220

213:                                              ; preds = %209
  %214 = load i32, ptr %30, align 4, !tbaa !9
  store i32 %214, ptr %31, align 4, !tbaa !9
  %215 = load i32, ptr %17, align 4, !tbaa !9
  %216 = load i32, ptr %32, align 4, !tbaa !9
  %217 = sub i32 %215, %216
  %218 = load i32, ptr %13, align 4, !tbaa !9
  %219 = mul i32 %217, %218
  store i32 %219, ptr %29, align 4, !tbaa !9
  br label %220

220:                                              ; preds = %213, %209
  br label %221

221:                                              ; preds = %220
  %222 = load i32, ptr %32, align 4, !tbaa !9
  %223 = add i32 %222, 1
  store i32 %223, ptr %32, align 4, !tbaa !9
  br label %185, !llvm.loop !18

224:                                              ; preds = %194
  %225 = load i32, ptr %29, align 4, !tbaa !9
  %226 = load ptr, ptr %14, align 8, !tbaa !5
  store i32 %225, ptr %226, align 4, !tbaa !9
  call void @llvm.lifetime.end.p0(i64 4, ptr %32) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %31) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %30) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %29) #3
  br label %227

227:                                              ; preds = %224, %178
  br label %228

228:                                              ; preds = %227, %165
  br label %229

229:                                              ; preds = %228, %158
  br label %230

230:                                              ; preds = %229, %91
  %231 = load i32, ptr %12, align 4, !tbaa !9
  %232 = load ptr, ptr %15, align 8, !tbaa !5
  store i32 %231, ptr %232, align 4, !tbaa !9
  store i32 0, ptr %24, align 4
  br label %233

233:                                              ; preds = %230, %54
  call void @llvm.lifetime.end.p0(i64 4, ptr %23) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %22) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %21) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %20) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %19) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #3
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #3
  %234 = load i32, ptr %24, align 4
  switch i32 %234, label %236 [
    i32 0, label %235
    i32 1, label %235
  ]

235:                                              ; preds = %233, %233
  ret void

236:                                              ; preds = %233
  unreachable
}

declare i32 @libxsmm_compute_equalized_blocking(i32 noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, ptr 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 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { 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, !13, i64 27}
!12 = !{!"libxsmm_meltw_descriptor", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !7, i64 24, !7, i64 25, !7, i64 26, !13, i64 27, !13, i64 29, !7, i64 31}
!13 = !{!"short", !7, i64 0}
!14 = distinct !{!14, !15}
!15 = !{!"llvm.loop.mustprogress"}
!16 = distinct !{!16, !15}
!17 = distinct !{!17, !15}
!18 = distinct !{!18, !15}


; 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 [94 x i8], align 1
@libxsmm_ninit = external local_unnamed_addr global i32, align 4
@libxsmm_verbosity = external local_unnamed_addr global i32, align 4
@__func__.libxsmm_generator_configure_rv64_M_N_blocking = external hidden unnamed_addr constant [46 x i8], align 1

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

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

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

; Function Attrs: nounwind uwtable
define dso_local void @libxsmm_generator_configure_rv64_M_N_blocking(ptr noundef %0, ptr nocapture noundef readonly %1, i32 noundef %2, i32 noundef %3, i32 noundef %4, ptr nocapture noundef writeonly %5, ptr nocapture noundef writeonly %6, i32 noundef %7) local_unnamed_addr #2 {
  %9 = alloca i32, align 4
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %9) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %10) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %11) #4
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %12) #4
  %13 = getelementptr inbounds i8, ptr %1, i64 27
  %14 = load i16, ptr %13, align 1, !tbaa !5
  %15 = and i16 %14, 1
  %16 = icmp ne i16 %15, 0
  %17 = icmp eq i32 %4, 4
  %or.cond = and i1 %17, %16
  br i1 %or.cond, label %18, label %27

18:                                               ; preds = %8
  %19 = icmp ult i32 %7, 3
  br i1 %19, label %20, label %25

20:                                               ; preds = %18
  %21 = load i32, ptr @libxsmm_ninit, align 4, !tbaa !11
  %22 = icmp ugt i32 %21, 1
  %23 = load i32, ptr @libxsmm_verbosity, align 4
  %24 = select i1 %22, i32 %23, i32 1
  tail call void @libxsmm_handle_error(ptr noundef %0, i32 noundef 90045, ptr noundef nonnull @__func__.libxsmm_generator_configure_rv64_M_N_blocking, ptr noundef nonnull @.str, i32 noundef 265, i32 noundef %24) #4
  br label %78

25:                                               ; preds = %18
  %26 = lshr i32 %7, 1
  br label %27

27:                                               ; preds = %25, %8
  %.096 = phi i32 [ %26, %25 ], [ %7, %8 ]
  %.095 = phi i32 [ 8, %25 ], [ %4, %8 ]
  %.094 = phi i32 [ 16, %25 ], [ 32, %8 ]
  %28 = add i32 %2, -1
  %29 = add i32 %28, %.095
  %30 = udiv i32 %29, %.095
  %31 = and i32 %30, -2
  %32 = urem i32 %2, %.095
  %33 = icmp eq i32 %32, 0
  br i1 %33, label %34, label %41

34:                                               ; preds = %27
  %35 = icmp ugt i32 %31, %.094
  br i1 %35, label %36, label %._crit_edge117

36:                                               ; preds = %34
  %37 = lshr i32 %30, 1
  %38 = call i32 @libxsmm_compute_equalized_blocking(i32 noundef %31, i32 noundef %37, ptr noundef nonnull %9, ptr noundef nonnull %10, ptr noundef nonnull %11, ptr noundef nonnull %12) #4
  %39 = load i32, ptr %9, align 4, !tbaa !11
  %40 = mul i32 %39, %.095
  br label %._crit_edge117

41:                                               ; preds = %27
  %42 = lshr exact i32 %.094, 1
  %43 = icmp ugt i32 %31, %42
  br i1 %43, label %44, label %60

44:                                               ; preds = %41
  %45 = icmp eq i32 %.095, 4
  %or.cond3 = and i1 %16, %45
  br i1 %or.cond3, label %48, label %.preheader107

.preheader107:                                    ; preds = %44
  %46 = tail call i32 @llvm.umin.i32(i32 %31, i32 %.096)
  %47 = icmp ugt i32 %46, 4
  br i1 %47, label %.preheader, label %._crit_edge117

48:                                               ; preds = %44
  %49 = shl nuw i32 %31, 2
  %50 = add i32 %49, -16
  br label %._crit_edge117

.preheader:                                       ; preds = %.preheader107, %55
  %.088116 = phi i32 [ %58, %55 ], [ 4, %.preheader107 ]
  %.089115 = phi i32 [ %spec.select104, %55 ], [ 0, %.preheader107 ]
  %.092114 = phi i32 [ %spec.select, %55 ], [ 0, %.preheader107 ]
  %51 = sub i32 %31, %.088116
  br label %52

52:                                               ; preds = %52, %.preheader
  %.091 = phi i32 [ %54, %52 ], [ %.096, %.preheader ]
  %53 = urem i32 %51, %.091
  %.not103 = icmp eq i32 %53, 0
  %54 = add i32 %.091, -1
  br i1 %.not103, label %55, label %52, !llvm.loop !12

55:                                               ; preds = %52
  %56 = icmp ugt i32 %.091, %.089115
  %57 = mul i32 %51, %.095
  %spec.select = select i1 %56, i32 %57, i32 %.092114
  %spec.select104 = tail call i32 @llvm.umax.i32(i32 %.091, i32 %.089115)
  %58 = add nuw i32 %.088116, 1
  %59 = icmp ult i32 %58, %46
  br i1 %59, label %.preheader, label %._crit_edge117, !llvm.loop !14

60:                                               ; preds = %41
  %61 = mul i32 %.095, %.096
  %.not = icmp ult i32 %61, %2
  br i1 %.not, label %62, label %._crit_edge117

62:                                               ; preds = %60
  %63 = icmp eq i32 %.095, 4
  %or.cond5 = and i1 %16, %63
  br i1 %or.cond5, label %66, label %.preheader109

.preheader109:                                    ; preds = %62
  %64 = tail call i32 @llvm.umin.i32(i32 %31, i32 %.096)
  %65 = icmp ugt i32 %64, 1
  br i1 %65, label %.preheader108, label %._crit_edge117

66:                                               ; preds = %62
  %67 = shl nuw nsw i32 %31, 2
  %68 = add nsw i32 %67, -4
  br label %._crit_edge117

.preheader108:                                    ; preds = %.preheader109, %73
  %.0113 = phi i32 [ %76, %73 ], [ 1, %.preheader109 ]
  %.084112 = phi i32 [ %spec.select106, %73 ], [ 0, %.preheader109 ]
  %.086111 = phi i32 [ %spec.select105, %73 ], [ 0, %.preheader109 ]
  %69 = sub i32 %31, %.0113
  br label %70

70:                                               ; preds = %70, %.preheader108
  %.085 = phi i32 [ %72, %70 ], [ %.096, %.preheader108 ]
  %71 = urem i32 %69, %.085
  %.not102 = icmp eq i32 %71, 0
  %72 = add i32 %.085, -1
  br i1 %.not102, label %73, label %70, !llvm.loop !15

73:                                               ; preds = %70
  %74 = icmp ugt i32 %.085, %.084112
  %75 = mul i32 %69, %.095
  %spec.select105 = select i1 %74, i32 %75, i32 %.086111
  %spec.select106 = tail call i32 @llvm.umax.i32(i32 %.085, i32 %.084112)
  %76 = add nuw i32 %.0113, 1
  %77 = icmp ult i32 %76, %64
  br i1 %77, label %.preheader108, label %._crit_edge117, !llvm.loop !16

._crit_edge117:                                   ; preds = %73, %55, %.preheader109, %60, %.preheader107, %34, %48, %66, %36
  %.092.lcssa.sink = phi i32 [ %50, %48 ], [ %68, %66 ], [ %40, %36 ], [ %2, %34 ], [ 0, %.preheader107 ], [ %2, %60 ], [ 0, %.preheader109 ], [ %spec.select, %55 ], [ %spec.select105, %73 ]
  store i32 %.092.lcssa.sink, ptr %5, align 4, !tbaa !11
  store i32 %3, ptr %6, align 4, !tbaa !11
  br label %78

78:                                               ; preds = %._crit_edge117, %20
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %12) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %11) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %10) #4
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %9) #4
  ret void
}

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

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.umin.i32(i32, i32) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i32 @llvm.umax.i32(i32, i32) #3

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !10, i64 27}
!6 = !{!"libxsmm_meltw_descriptor", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !7, i64 16, !7, i64 20, !8, i64 24, !8, i64 25, !8, i64 26, !10, i64 27, !10, i64 29, !8, i64 31}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"short", !8, i64 0}
!11 = !{!7, !7, i64 0}
!12 = distinct !{!12, !13}
!13 = !{!"llvm.loop.mustprogress"}
!14 = distinct !{!14, !13}
!15 = distinct !{!15, !13}
!16 = distinct !{!16, !13}


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