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

; 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_matdiff_info = type { double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, i32, i32, i32, i32 }

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

; Function Attrs: nounwind uwtable
declare dso_local void @libxsmm_matdiff_clear(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: nounwind uwtable
declare dso_local double @libxsmm_matdiff_epsilon(ptr noundef) #1

; Function Attrs: nounwind uwtable
define dso_local void @libxsmm_matdiff_reduce(ptr noundef %0, ptr noundef %1) #1 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca double, align 8
  %6 = alloca double, align 8
  store ptr %0, ptr %3, align 8, !tbaa !5
  store ptr %1, ptr %4, align 8, !tbaa !5
  %7 = load ptr, ptr %3, align 8, !tbaa !5
  %8 = icmp ne ptr null, %7
  br i1 %8, label %9, label %264

9:                                                ; preds = %2
  %10 = load ptr, ptr %4, align 8, !tbaa !5
  %11 = icmp ne ptr null, %10
  br i1 %11, label %12, label %264

12:                                               ; preds = %9
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #2
  %13 = load ptr, ptr %4, align 8, !tbaa !5
  %14 = call double @libxsmm_matdiff_epsilon(ptr noundef %13)
  store double %14, ptr %5, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #2
  %15 = load ptr, ptr %3, align 8, !tbaa !5
  %16 = call double @libxsmm_matdiff_epsilon(ptr noundef %15)
  store double %16, ptr %6, align 8, !tbaa !9
  %17 = load ptr, ptr %3, align 8, !tbaa !5
  %18 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %17, i32 0, i32 5
  %19 = load double, ptr %18, align 8, !tbaa !11
  %20 = load ptr, ptr %4, align 8, !tbaa !5
  %21 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %20, i32 0, i32 5
  %22 = load double, ptr %21, align 8, !tbaa !11
  %23 = fcmp ole double %19, %22
  br i1 %23, label %24, label %35

24:                                               ; preds = %12
  %25 = load ptr, ptr %4, align 8, !tbaa !5
  %26 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %25, i32 0, i32 5
  %27 = load double, ptr %26, align 8, !tbaa !11
  %28 = load ptr, ptr %3, align 8, !tbaa !5
  %29 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %28, i32 0, i32 5
  store double %27, ptr %29, align 8, !tbaa !11
  %30 = load ptr, ptr %4, align 8, !tbaa !5
  %31 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %30, i32 0, i32 6
  %32 = load double, ptr %31, align 8, !tbaa !14
  %33 = load ptr, ptr %3, align 8, !tbaa !5
  %34 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %33, i32 0, i32 6
  store double %32, ptr %34, align 8, !tbaa !14
  br label %35

35:                                               ; preds = %24, %12
  %36 = load ptr, ptr %3, align 8, !tbaa !5
  %37 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %36, i32 0, i32 0
  %38 = load double, ptr %37, align 8, !tbaa !15
  %39 = load ptr, ptr %4, align 8, !tbaa !5
  %40 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %39, i32 0, i32 0
  %41 = load double, ptr %40, align 8, !tbaa !15
  %42 = fcmp ole double %38, %41
  br i1 %42, label %43, label %54

43:                                               ; preds = %35
  %44 = load ptr, ptr %4, align 8, !tbaa !5
  %45 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %44, i32 0, i32 0
  %46 = load double, ptr %45, align 8, !tbaa !15
  %47 = load ptr, ptr %3, align 8, !tbaa !5
  %48 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %47, i32 0, i32 0
  store double %46, ptr %48, align 8, !tbaa !15
  %49 = load ptr, ptr %4, align 8, !tbaa !5
  %50 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %49, i32 0, i32 1
  %51 = load double, ptr %50, align 8, !tbaa !16
  %52 = load ptr, ptr %3, align 8, !tbaa !5
  %53 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %52, i32 0, i32 1
  store double %51, ptr %53, align 8, !tbaa !16
  br label %54

54:                                               ; preds = %43, %35
  %55 = load ptr, ptr %3, align 8, !tbaa !5
  %56 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %55, i32 0, i32 2
  %57 = load double, ptr %56, align 8, !tbaa !17
  %58 = load ptr, ptr %4, align 8, !tbaa !5
  %59 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %58, i32 0, i32 2
  %60 = load double, ptr %59, align 8, !tbaa !17
  %61 = fcmp ole double %57, %60
  br i1 %61, label %62, label %73

62:                                               ; preds = %54
  %63 = load ptr, ptr %4, align 8, !tbaa !5
  %64 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %63, i32 0, i32 2
  %65 = load double, ptr %64, align 8, !tbaa !17
  %66 = load ptr, ptr %3, align 8, !tbaa !5
  %67 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %66, i32 0, i32 2
  store double %65, ptr %67, align 8, !tbaa !17
  %68 = load ptr, ptr %4, align 8, !tbaa !5
  %69 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %68, i32 0, i32 3
  %70 = load double, ptr %69, align 8, !tbaa !18
  %71 = load ptr, ptr %3, align 8, !tbaa !5
  %72 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %71, i32 0, i32 3
  store double %70, ptr %72, align 8, !tbaa !18
  br label %73

73:                                               ; preds = %62, %54
  %74 = load ptr, ptr %3, align 8, !tbaa !5
  %75 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %74, i32 0, i32 7
  %76 = load double, ptr %75, align 8, !tbaa !19
  %77 = load ptr, ptr %4, align 8, !tbaa !5
  %78 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %77, i32 0, i32 7
  %79 = load double, ptr %78, align 8, !tbaa !19
  %80 = fcmp ole double %76, %79
  br i1 %80, label %81, label %92

81:                                               ; preds = %73
  %82 = load ptr, ptr %4, align 8, !tbaa !5
  %83 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %82, i32 0, i32 7
  %84 = load double, ptr %83, align 8, !tbaa !19
  %85 = load ptr, ptr %3, align 8, !tbaa !5
  %86 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %85, i32 0, i32 7
  store double %84, ptr %86, align 8, !tbaa !19
  %87 = load ptr, ptr %4, align 8, !tbaa !5
  %88 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %87, i32 0, i32 8
  %89 = load double, ptr %88, align 8, !tbaa !20
  %90 = load ptr, ptr %3, align 8, !tbaa !5
  %91 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %90, i32 0, i32 8
  store double %89, ptr %91, align 8, !tbaa !20
  br label %92

92:                                               ; preds = %81, %73
  %93 = load ptr, ptr %3, align 8, !tbaa !5
  %94 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %93, i32 0, i32 4
  %95 = load double, ptr %94, align 8, !tbaa !21
  %96 = load ptr, ptr %4, align 8, !tbaa !5
  %97 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %96, i32 0, i32 4
  %98 = load double, ptr %97, align 8, !tbaa !21
  %99 = fcmp ole double %95, %98
  br i1 %99, label %100, label %106

100:                                              ; preds = %92
  %101 = load ptr, ptr %4, align 8, !tbaa !5
  %102 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %101, i32 0, i32 4
  %103 = load double, ptr %102, align 8, !tbaa !21
  %104 = load ptr, ptr %3, align 8, !tbaa !5
  %105 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %104, i32 0, i32 4
  store double %103, ptr %105, align 8, !tbaa !21
  br label %106

106:                                              ; preds = %100, %92
  %107 = load ptr, ptr %3, align 8, !tbaa !5
  %108 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %107, i32 0, i32 14
  %109 = load double, ptr %108, align 8, !tbaa !22
  %110 = load ptr, ptr %4, align 8, !tbaa !5
  %111 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %110, i32 0, i32 14
  %112 = load double, ptr %111, align 8, !tbaa !22
  %113 = fcmp ole double %109, %112
  br i1 %113, label %114, label %120

114:                                              ; preds = %106
  %115 = load ptr, ptr %4, align 8, !tbaa !5
  %116 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %115, i32 0, i32 14
  %117 = load double, ptr %116, align 8, !tbaa !22
  %118 = load ptr, ptr %3, align 8, !tbaa !5
  %119 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %118, i32 0, i32 14
  store double %117, ptr %119, align 8, !tbaa !22
  br label %120

120:                                              ; preds = %114, %106
  %121 = load ptr, ptr %3, align 8, !tbaa !5
  %122 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %121, i32 0, i32 19
  %123 = load double, ptr %122, align 8, !tbaa !23
  %124 = load ptr, ptr %4, align 8, !tbaa !5
  %125 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %124, i32 0, i32 19
  %126 = load double, ptr %125, align 8, !tbaa !23
  %127 = fcmp ole double %123, %126
  br i1 %127, label %128, label %134

128:                                              ; preds = %120
  %129 = load ptr, ptr %4, align 8, !tbaa !5
  %130 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %129, i32 0, i32 19
  %131 = load double, ptr %130, align 8, !tbaa !23
  %132 = load ptr, ptr %3, align 8, !tbaa !5
  %133 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %132, i32 0, i32 19
  store double %131, ptr %133, align 8, !tbaa !23
  br label %134

134:                                              ; preds = %128, %120
  %135 = load ptr, ptr %3, align 8, !tbaa !5
  %136 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %135, i32 0, i32 12
  %137 = load double, ptr %136, align 8, !tbaa !24
  %138 = load ptr, ptr %4, align 8, !tbaa !5
  %139 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %138, i32 0, i32 12
  %140 = load double, ptr %139, align 8, !tbaa !24
  %141 = fcmp ole double %137, %140
  br i1 %141, label %142, label %148

142:                                              ; preds = %134
  %143 = load ptr, ptr %4, align 8, !tbaa !5
  %144 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %143, i32 0, i32 12
  %145 = load double, ptr %144, align 8, !tbaa !24
  %146 = load ptr, ptr %3, align 8, !tbaa !5
  %147 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %146, i32 0, i32 12
  store double %145, ptr %147, align 8, !tbaa !24
  br label %148

148:                                              ; preds = %142, %134
  %149 = load ptr, ptr %3, align 8, !tbaa !5
  %150 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %149, i32 0, i32 17
  %151 = load double, ptr %150, align 8, !tbaa !25
  %152 = load ptr, ptr %4, align 8, !tbaa !5
  %153 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %152, i32 0, i32 17
  %154 = load double, ptr %153, align 8, !tbaa !25
  %155 = fcmp ole double %151, %154
  br i1 %155, label %156, label %162

156:                                              ; preds = %148
  %157 = load ptr, ptr %4, align 8, !tbaa !5
  %158 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %157, i32 0, i32 17
  %159 = load double, ptr %158, align 8, !tbaa !25
  %160 = load ptr, ptr %3, align 8, !tbaa !5
  %161 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %160, i32 0, i32 17
  store double %159, ptr %161, align 8, !tbaa !25
  br label %162

162:                                              ; preds = %156, %148
  %163 = load ptr, ptr %3, align 8, !tbaa !5
  %164 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %163, i32 0, i32 11
  %165 = load double, ptr %164, align 8, !tbaa !26
  %166 = load ptr, ptr %4, align 8, !tbaa !5
  %167 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %166, i32 0, i32 11
  %168 = load double, ptr %167, align 8, !tbaa !26
  %169 = fcmp oge double %165, %168
  br i1 %169, label %170, label %176

170:                                              ; preds = %162
  %171 = load ptr, ptr %4, align 8, !tbaa !5
  %172 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %171, i32 0, i32 11
  %173 = load double, ptr %172, align 8, !tbaa !26
  %174 = load ptr, ptr %3, align 8, !tbaa !5
  %175 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %174, i32 0, i32 11
  store double %173, ptr %175, align 8, !tbaa !26
  br label %176

176:                                              ; preds = %170, %162
  %177 = load ptr, ptr %3, align 8, !tbaa !5
  %178 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %177, i32 0, i32 16
  %179 = load double, ptr %178, align 8, !tbaa !27
  %180 = load ptr, ptr %4, align 8, !tbaa !5
  %181 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %180, i32 0, i32 16
  %182 = load double, ptr %181, align 8, !tbaa !27
  %183 = fcmp oge double %179, %182
  br i1 %183, label %184, label %190

184:                                              ; preds = %176
  %185 = load ptr, ptr %4, align 8, !tbaa !5
  %186 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %185, i32 0, i32 16
  %187 = load double, ptr %186, align 8, !tbaa !27
  %188 = load ptr, ptr %3, align 8, !tbaa !5
  %189 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %188, i32 0, i32 16
  store double %187, ptr %189, align 8, !tbaa !27
  br label %190

190:                                              ; preds = %184, %176
  %191 = load double, ptr %6, align 8, !tbaa !9
  %192 = load double, ptr %5, align 8, !tbaa !9
  %193 = fcmp olt double %191, %192
  br i1 %193, label %194, label %225

194:                                              ; preds = %190
  %195 = load ptr, ptr %4, align 8, !tbaa !5
  %196 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %195, i32 0, i32 9
  %197 = load double, ptr %196, align 8, !tbaa !28
  %198 = load ptr, ptr %3, align 8, !tbaa !5
  %199 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %198, i32 0, i32 9
  store double %197, ptr %199, align 8, !tbaa !28
  %200 = load ptr, ptr %4, align 8, !tbaa !5
  %201 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %200, i32 0, i32 20
  %202 = load double, ptr %201, align 8, !tbaa !29
  %203 = load ptr, ptr %3, align 8, !tbaa !5
  %204 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %203, i32 0, i32 20
  store double %202, ptr %204, align 8, !tbaa !29
  %205 = load ptr, ptr %4, align 8, !tbaa !5
  %206 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %205, i32 0, i32 21
  %207 = load double, ptr %206, align 8, !tbaa !30
  %208 = load ptr, ptr %3, align 8, !tbaa !5
  %209 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %208, i32 0, i32 21
  store double %207, ptr %209, align 8, !tbaa !30
  %210 = load ptr, ptr %4, align 8, !tbaa !5
  %211 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %210, i32 0, i32 22
  %212 = load i32, ptr %211, align 8, !tbaa !31
  %213 = load ptr, ptr %3, align 8, !tbaa !5
  %214 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %213, i32 0, i32 22
  store i32 %212, ptr %214, align 8, !tbaa !31
  %215 = load ptr, ptr %4, align 8, !tbaa !5
  %216 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %215, i32 0, i32 23
  %217 = load i32, ptr %216, align 4, !tbaa !32
  %218 = load ptr, ptr %3, align 8, !tbaa !5
  %219 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %218, i32 0, i32 23
  store i32 %217, ptr %219, align 4, !tbaa !32
  %220 = load ptr, ptr %4, align 8, !tbaa !5
  %221 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %220, i32 0, i32 25
  %222 = load i32, ptr %221, align 4, !tbaa !33
  %223 = load ptr, ptr %3, align 8, !tbaa !5
  %224 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %223, i32 0, i32 24
  store i32 %222, ptr %224, align 8, !tbaa !34
  br label %225

225:                                              ; preds = %194, %190
  %226 = load ptr, ptr %3, align 8, !tbaa !5
  %227 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %226, i32 0, i32 13
  %228 = load double, ptr %227, align 8, !tbaa !35
  %229 = load ptr, ptr %4, align 8, !tbaa !5
  %230 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %229, i32 0, i32 13
  %231 = load double, ptr %230, align 8, !tbaa !35
  %232 = fadd double %228, %231
  %233 = fmul double 5.000000e-01, %232
  %234 = load ptr, ptr %3, align 8, !tbaa !5
  %235 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %234, i32 0, i32 13
  store double %233, ptr %235, align 8, !tbaa !35
  %236 = load ptr, ptr %3, align 8, !tbaa !5
  %237 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %236, i32 0, i32 18
  %238 = load double, ptr %237, align 8, !tbaa !36
  %239 = load ptr, ptr %4, align 8, !tbaa !5
  %240 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %239, i32 0, i32 18
  %241 = load double, ptr %240, align 8, !tbaa !36
  %242 = fadd double %238, %241
  %243 = fmul double 5.000000e-01, %242
  %244 = load ptr, ptr %3, align 8, !tbaa !5
  %245 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %244, i32 0, i32 18
  store double %243, ptr %245, align 8, !tbaa !36
  %246 = load ptr, ptr %4, align 8, !tbaa !5
  %247 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %246, i32 0, i32 10
  %248 = load double, ptr %247, align 8, !tbaa !37
  %249 = load ptr, ptr %3, align 8, !tbaa !5
  %250 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %249, i32 0, i32 10
  %251 = load double, ptr %250, align 8, !tbaa !37
  %252 = fadd double %251, %248
  store double %252, ptr %250, align 8, !tbaa !37
  %253 = load ptr, ptr %4, align 8, !tbaa !5
  %254 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %253, i32 0, i32 15
  %255 = load double, ptr %254, align 8, !tbaa !38
  %256 = load ptr, ptr %3, align 8, !tbaa !5
  %257 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %256, i32 0, i32 15
  %258 = load double, ptr %257, align 8, !tbaa !38
  %259 = fadd double %258, %255
  store double %259, ptr %257, align 8, !tbaa !38
  %260 = load ptr, ptr %3, align 8, !tbaa !5
  %261 = getelementptr inbounds %struct.libxsmm_matdiff_info, ptr %260, i32 0, i32 25
  %262 = load i32, ptr %261, align 4, !tbaa !33
  %263 = add nsw i32 %262, 1
  store i32 %263, ptr %261, align 4, !tbaa !33
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #2
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #2
  br label %266

264:                                              ; preds = %9, %2
  %265 = load ptr, ptr %3, align 8, !tbaa !5
  call void @libxsmm_matdiff_clear(ptr noundef %265)
  br label %266

266:                                              ; preds = %264, %225
  ret void
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { 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 = !{!"double", !7, i64 0}
!11 = !{!12, !10, i64 40}
!12 = !{!"libxsmm_matdiff_info", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !10, i64 72, !10, i64 80, !10, i64 88, !10, i64 96, !10, i64 104, !10, i64 112, !10, i64 120, !10, i64 128, !10, i64 136, !10, i64 144, !10, i64 152, !10, i64 160, !10, i64 168, !13, i64 176, !13, i64 180, !13, i64 184, !13, i64 188}
!13 = !{!"int", !7, i64 0}
!14 = !{!12, !10, i64 48}
!15 = !{!12, !10, i64 0}
!16 = !{!12, !10, i64 8}
!17 = !{!12, !10, i64 16}
!18 = !{!12, !10, i64 24}
!19 = !{!12, !10, i64 56}
!20 = !{!12, !10, i64 64}
!21 = !{!12, !10, i64 32}
!22 = !{!12, !10, i64 112}
!23 = !{!12, !10, i64 152}
!24 = !{!12, !10, i64 96}
!25 = !{!12, !10, i64 136}
!26 = !{!12, !10, i64 88}
!27 = !{!12, !10, i64 128}
!28 = !{!12, !10, i64 72}
!29 = !{!12, !10, i64 160}
!30 = !{!12, !10, i64 168}
!31 = !{!12, !13, i64 176}
!32 = !{!12, !13, i64 180}
!33 = !{!12, !13, i64 188}
!34 = !{!12, !13, i64 184}
!35 = !{!12, !10, i64 104}
!36 = !{!12, !10, i64 144}
!37 = !{!12, !10, i64 80}
!38 = !{!12, !10, i64 120}


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

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

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

; Function Attrs: nounwind uwtable
define dso_local void @libxsmm_matdiff_reduce(ptr noundef %0, ptr noundef %1) local_unnamed_addr #0 {
  %3 = icmp ne ptr %0, null
  %4 = icmp ne ptr %1, null
  %or.cond = and i1 %3, %4
  br i1 %or.cond, label %5, label %135

5:                                                ; preds = %2
  %6 = tail call double @libxsmm_matdiff_epsilon(ptr noundef nonnull %1)
  %7 = tail call double @libxsmm_matdiff_epsilon(ptr noundef nonnull %0)
  %8 = getelementptr inbounds i8, ptr %0, i64 40
  %9 = load double, ptr %8, align 8, !tbaa !5
  %10 = getelementptr inbounds i8, ptr %1, i64 40
  %11 = load double, ptr %10, align 8, !tbaa !5
  %12 = fcmp ugt double %9, %11
  br i1 %12, label %17, label %13

13:                                               ; preds = %5
  store double %11, ptr %8, align 8, !tbaa !5
  %14 = getelementptr inbounds i8, ptr %1, i64 48
  %15 = load double, ptr %14, align 8, !tbaa !11
  %16 = getelementptr inbounds i8, ptr %0, i64 48
  store double %15, ptr %16, align 8, !tbaa !11
  br label %17

17:                                               ; preds = %13, %5
  %18 = load double, ptr %0, align 8, !tbaa !12
  %19 = load double, ptr %1, align 8, !tbaa !12
  %20 = fcmp ugt double %18, %19
  br i1 %20, label %25, label %21

21:                                               ; preds = %17
  store double %19, ptr %0, align 8, !tbaa !12
  %22 = getelementptr inbounds i8, ptr %1, i64 8
  %23 = load double, ptr %22, align 8, !tbaa !13
  %24 = getelementptr inbounds i8, ptr %0, i64 8
  store double %23, ptr %24, align 8, !tbaa !13
  br label %25

25:                                               ; preds = %21, %17
  %26 = getelementptr inbounds i8, ptr %0, i64 16
  %27 = load double, ptr %26, align 8, !tbaa !14
  %28 = getelementptr inbounds i8, ptr %1, i64 16
  %29 = load double, ptr %28, align 8, !tbaa !14
  %30 = fcmp ugt double %27, %29
  br i1 %30, label %35, label %31

31:                                               ; preds = %25
  store double %29, ptr %26, align 8, !tbaa !14
  %32 = getelementptr inbounds i8, ptr %1, i64 24
  %33 = load double, ptr %32, align 8, !tbaa !15
  %34 = getelementptr inbounds i8, ptr %0, i64 24
  store double %33, ptr %34, align 8, !tbaa !15
  br label %35

35:                                               ; preds = %31, %25
  %36 = getelementptr inbounds i8, ptr %0, i64 56
  %37 = load double, ptr %36, align 8, !tbaa !16
  %38 = getelementptr inbounds i8, ptr %1, i64 56
  %39 = load double, ptr %38, align 8, !tbaa !16
  %40 = fcmp ugt double %37, %39
  br i1 %40, label %45, label %41

41:                                               ; preds = %35
  store double %39, ptr %36, align 8, !tbaa !16
  %42 = getelementptr inbounds i8, ptr %1, i64 64
  %43 = load double, ptr %42, align 8, !tbaa !17
  %44 = getelementptr inbounds i8, ptr %0, i64 64
  store double %43, ptr %44, align 8, !tbaa !17
  br label %45

45:                                               ; preds = %41, %35
  %46 = getelementptr inbounds i8, ptr %0, i64 32
  %47 = load double, ptr %46, align 8, !tbaa !18
  %48 = getelementptr inbounds i8, ptr %1, i64 32
  %49 = load double, ptr %48, align 8, !tbaa !18
  %50 = fcmp ugt double %47, %49
  br i1 %50, label %52, label %51

51:                                               ; preds = %45
  store double %49, ptr %46, align 8, !tbaa !18
  br label %52

52:                                               ; preds = %51, %45
  %53 = getelementptr inbounds i8, ptr %0, i64 112
  %54 = load double, ptr %53, align 8, !tbaa !19
  %55 = getelementptr inbounds i8, ptr %1, i64 112
  %56 = load double, ptr %55, align 8, !tbaa !19
  %57 = fcmp ugt double %54, %56
  br i1 %57, label %59, label %58

58:                                               ; preds = %52
  store double %56, ptr %53, align 8, !tbaa !19
  br label %59

59:                                               ; preds = %58, %52
  %60 = getelementptr inbounds i8, ptr %0, i64 152
  %61 = load double, ptr %60, align 8, !tbaa !20
  %62 = getelementptr inbounds i8, ptr %1, i64 152
  %63 = load double, ptr %62, align 8, !tbaa !20
  %64 = fcmp ugt double %61, %63
  br i1 %64, label %66, label %65

65:                                               ; preds = %59
  store double %63, ptr %60, align 8, !tbaa !20
  br label %66

66:                                               ; preds = %65, %59
  %67 = getelementptr inbounds i8, ptr %0, i64 96
  %68 = load double, ptr %67, align 8, !tbaa !21
  %69 = getelementptr inbounds i8, ptr %1, i64 96
  %70 = load double, ptr %69, align 8, !tbaa !21
  %71 = fcmp ugt double %68, %70
  br i1 %71, label %73, label %72

72:                                               ; preds = %66
  store double %70, ptr %67, align 8, !tbaa !21
  br label %73

73:                                               ; preds = %72, %66
  %74 = getelementptr inbounds i8, ptr %0, i64 136
  %75 = load double, ptr %74, align 8, !tbaa !22
  %76 = getelementptr inbounds i8, ptr %1, i64 136
  %77 = load double, ptr %76, align 8, !tbaa !22
  %78 = fcmp ugt double %75, %77
  br i1 %78, label %80, label %79

79:                                               ; preds = %73
  store double %77, ptr %74, align 8, !tbaa !22
  br label %80

80:                                               ; preds = %79, %73
  %81 = getelementptr inbounds i8, ptr %0, i64 88
  %82 = load double, ptr %81, align 8, !tbaa !23
  %83 = getelementptr inbounds i8, ptr %1, i64 88
  %84 = load double, ptr %83, align 8, !tbaa !23
  %85 = fcmp ult double %82, %84
  br i1 %85, label %87, label %86

86:                                               ; preds = %80
  store double %84, ptr %81, align 8, !tbaa !23
  br label %87

87:                                               ; preds = %86, %80
  %88 = getelementptr inbounds i8, ptr %0, i64 128
  %89 = load double, ptr %88, align 8, !tbaa !24
  %90 = getelementptr inbounds i8, ptr %1, i64 128
  %91 = load double, ptr %90, align 8, !tbaa !24
  %92 = fcmp ult double %89, %91
  br i1 %92, label %94, label %93

93:                                               ; preds = %87
  store double %91, ptr %88, align 8, !tbaa !24
  br label %94

94:                                               ; preds = %93, %87
  %95 = fcmp olt double %7, %6
  br i1 %95, label %96, label %109

96:                                               ; preds = %94
  %97 = getelementptr inbounds i8, ptr %1, i64 72
  %98 = load double, ptr %97, align 8, !tbaa !25
  %99 = getelementptr inbounds i8, ptr %0, i64 72
  store double %98, ptr %99, align 8, !tbaa !25
  %100 = getelementptr inbounds i8, ptr %1, i64 160
  %101 = getelementptr inbounds i8, ptr %0, i64 160
  %102 = load <2 x double>, ptr %100, align 8, !tbaa !26
  store <2 x double> %102, ptr %101, align 8, !tbaa !26
  %103 = getelementptr inbounds i8, ptr %1, i64 176
  %104 = getelementptr inbounds i8, ptr %0, i64 176
  %105 = load <2 x i32>, ptr %103, align 8, !tbaa !27
  store <2 x i32> %105, ptr %104, align 8, !tbaa !27
  %106 = getelementptr inbounds i8, ptr %1, i64 188
  %107 = load i32, ptr %106, align 4, !tbaa !28
  %108 = getelementptr inbounds i8, ptr %0, i64 184
  store i32 %107, ptr %108, align 8, !tbaa !29
  br label %109

109:                                              ; preds = %96, %94
  %110 = getelementptr inbounds i8, ptr %0, i64 104
  %111 = load double, ptr %110, align 8, !tbaa !30
  %112 = getelementptr inbounds i8, ptr %1, i64 104
  %113 = load double, ptr %112, align 8, !tbaa !30
  %114 = fadd double %111, %113
  %115 = fmul double %114, 5.000000e-01
  store double %115, ptr %110, align 8, !tbaa !30
  %116 = getelementptr inbounds i8, ptr %0, i64 144
  %117 = load double, ptr %116, align 8, !tbaa !31
  %118 = getelementptr inbounds i8, ptr %1, i64 144
  %119 = load double, ptr %118, align 8, !tbaa !31
  %120 = fadd double %117, %119
  %121 = fmul double %120, 5.000000e-01
  store double %121, ptr %116, align 8, !tbaa !31
  %122 = getelementptr inbounds i8, ptr %1, i64 80
  %123 = load double, ptr %122, align 8, !tbaa !32
  %124 = getelementptr inbounds i8, ptr %0, i64 80
  %125 = load double, ptr %124, align 8, !tbaa !32
  %126 = fadd double %123, %125
  store double %126, ptr %124, align 8, !tbaa !32
  %127 = getelementptr inbounds i8, ptr %1, i64 120
  %128 = load double, ptr %127, align 8, !tbaa !33
  %129 = getelementptr inbounds i8, ptr %0, i64 120
  %130 = load double, ptr %129, align 8, !tbaa !33
  %131 = fadd double %128, %130
  store double %131, ptr %129, align 8, !tbaa !33
  %132 = getelementptr inbounds i8, ptr %0, i64 188
  %133 = load i32, ptr %132, align 4, !tbaa !28
  %134 = add nsw i32 %133, 1
  store i32 %134, ptr %132, align 4, !tbaa !28
  br label %136

135:                                              ; preds = %2
  tail call void @libxsmm_matdiff_clear(ptr noundef %0)
  br label %136

136:                                              ; preds = %135, %109
  ret void
}

attributes #0 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }

!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 40}
!6 = !{!"libxsmm_matdiff_info", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !7, i64 48, !7, i64 56, !7, i64 64, !7, i64 72, !7, i64 80, !7, i64 88, !7, i64 96, !7, i64 104, !7, i64 112, !7, i64 120, !7, i64 128, !7, i64 136, !7, i64 144, !7, i64 152, !7, i64 160, !7, i64 168, !10, i64 176, !10, i64 180, !10, i64 184, !10, i64 188}
!7 = !{!"double", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"int", !8, i64 0}
!11 = !{!6, !7, i64 48}
!12 = !{!6, !7, i64 0}
!13 = !{!6, !7, i64 8}
!14 = !{!6, !7, i64 16}
!15 = !{!6, !7, i64 24}
!16 = !{!6, !7, i64 56}
!17 = !{!6, !7, i64 64}
!18 = !{!6, !7, i64 32}
!19 = !{!6, !7, i64 112}
!20 = !{!6, !7, i64 152}
!21 = !{!6, !7, i64 96}
!22 = !{!6, !7, i64 136}
!23 = !{!6, !7, i64 88}
!24 = !{!6, !7, i64 128}
!25 = !{!6, !7, i64 72}
!26 = !{!7, !7, i64 0}
!27 = !{!10, !10, i64 0}
!28 = !{!6, !10, i64 188}
!29 = !{!6, !10, i64 184}
!30 = !{!6, !7, i64 104}
!31 = !{!6, !7, i64 144}
!32 = !{!6, !7, i64 80}
!33 = !{!6, !7, i64 120}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,ReassociatePass,SLPVectorizerPass,SROAPass,SimplifyCFGPass,TailCallElimPass