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

; 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_generated_code = type { ptr, i32, i32, i32, i32, i32, i32 }

; Function Attrs: nounwind uwtable
declare dso_local void @libxsmm_generator_transform_norm_to_normt_32bit_avx512_spr_microkernel(ptr noundef, ptr noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local void @libxsmm_generator_transform_norm_to_normt_32bit_avx512_pre_spr_microkernel(ptr noundef, ptr noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
define dso_local void @libxsmm_generator_transform_norm_to_normt_32bit_avx512_microkernel(ptr noundef %0, ptr noundef %1, i32 noundef %2, i32 noundef %3, i32 noundef %4, i32 noundef %5, i32 noundef %6, i32 noundef %7, i32 noundef %8, i32 noundef %9, i32 noundef %10, i32 noundef %11, i32 noundef %12, i32 noundef %13, i32 noundef %14, ptr noundef %15, ptr noundef %16) #0 {
  %18 = alloca ptr, align 8
  %19 = alloca ptr, align 8
  %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
  %33 = alloca ptr, align 8
  %34 = alloca ptr, align 8
  store ptr %0, ptr %18, align 8, !tbaa !5
  store ptr %1, ptr %19, align 8, !tbaa !5
  store i32 %2, ptr %20, align 4, !tbaa !9
  store i32 %3, ptr %21, align 4, !tbaa !9
  store i32 %4, ptr %22, align 4, !tbaa !9
  store i32 %5, ptr %23, align 4, !tbaa !9
  store i32 %6, ptr %24, align 4, !tbaa !9
  store i32 %7, ptr %25, align 4, !tbaa !9
  store i32 %8, ptr %26, align 4, !tbaa !9
  store i32 %9, ptr %27, align 4, !tbaa !9
  store i32 %10, ptr %28, align 4, !tbaa !9
  store i32 %11, ptr %29, align 4, !tbaa !9
  store i32 %12, ptr %30, align 4, !tbaa !9
  store i32 %13, ptr %31, align 4, !tbaa !9
  store i32 %14, ptr %32, align 4, !tbaa !9
  store ptr %15, ptr %33, align 8, !tbaa !5
  store ptr %16, ptr %34, align 8, !tbaa !5
  %35 = load ptr, ptr %18, align 8, !tbaa !5
  %36 = getelementptr inbounds %struct.libxsmm_generated_code, ptr %35, i32 0, i32 6
  %37 = load i32, ptr %36, align 4, !tbaa !11
  %38 = icmp uge i32 %37, 1104
  br i1 %38, label %39, label %62

39:                                               ; preds = %17
  %40 = load ptr, ptr %18, align 8, !tbaa !5
  %41 = getelementptr inbounds %struct.libxsmm_generated_code, ptr %40, i32 0, i32 6
  %42 = load i32, ptr %41, align 4, !tbaa !11
  %43 = icmp ult i32 %42, 1999
  br i1 %43, label %44, label %62

44:                                               ; preds = %39
  %45 = load ptr, ptr %18, align 8, !tbaa !5
  %46 = load ptr, ptr %19, align 8, !tbaa !5
  %47 = load i32, ptr %20, align 4, !tbaa !9
  %48 = load i32, ptr %21, align 4, !tbaa !9
  %49 = load i32, ptr %22, align 4, !tbaa !9
  %50 = load i32, ptr %23, align 4, !tbaa !9
  %51 = load i32, ptr %24, align 4, !tbaa !9
  %52 = load i32, ptr %25, align 4, !tbaa !9
  %53 = load i32, ptr %26, align 4, !tbaa !9
  %54 = load i32, ptr %27, align 4, !tbaa !9
  %55 = load i32, ptr %28, align 4, !tbaa !9
  %56 = load i32, ptr %29, align 4, !tbaa !9
  %57 = load i32, ptr %30, align 4, !tbaa !9
  %58 = load i32, ptr %31, align 4, !tbaa !9
  %59 = load i32, ptr %32, align 4, !tbaa !9
  %60 = load ptr, ptr %33, align 8, !tbaa !5
  %61 = load ptr, ptr %34, align 8, !tbaa !5
  call void @libxsmm_generator_transform_norm_to_normt_32bit_avx512_spr_microkernel(ptr noundef %45, ptr noundef %46, i32 noundef %47, i32 noundef %48, i32 noundef %49, i32 noundef %50, i32 noundef %51, i32 noundef %52, i32 noundef %53, i32 noundef %54, i32 noundef %55, i32 noundef %56, i32 noundef %57, i32 noundef %58, i32 noundef %59, ptr noundef %60, ptr noundef %61)
  br label %78

62:                                               ; preds = %39, %17
  %63 = load ptr, ptr %18, align 8, !tbaa !5
  %64 = load ptr, ptr %19, align 8, !tbaa !5
  %65 = load i32, ptr %20, align 4, !tbaa !9
  %66 = load i32, ptr %21, align 4, !tbaa !9
  %67 = load i32, ptr %22, align 4, !tbaa !9
  %68 = load i32, ptr %23, align 4, !tbaa !9
  %69 = load i32, ptr %24, align 4, !tbaa !9
  %70 = load i32, ptr %26, align 4, !tbaa !9
  %71 = load i32, ptr %27, align 4, !tbaa !9
  %72 = load i32, ptr %28, align 4, !tbaa !9
  %73 = load i32, ptr %29, align 4, !tbaa !9
  %74 = load i32, ptr %30, align 4, !tbaa !9
  %75 = load i32, ptr %31, align 4, !tbaa !9
  %76 = load ptr, ptr %33, align 8, !tbaa !5
  %77 = load ptr, ptr %34, align 8, !tbaa !5
  call void @libxsmm_generator_transform_norm_to_normt_32bit_avx512_pre_spr_microkernel(ptr noundef %63, ptr noundef %64, i32 noundef %65, i32 noundef %66, i32 noundef %67, i32 noundef %68, i32 noundef %69, i32 noundef %70, i32 noundef %71, i32 noundef %72, i32 noundef %73, i32 noundef %74, i32 noundef %75, ptr noundef %76, ptr noundef %77)
  br label %78

78:                                               ; preds = %62, %44
  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, !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 28}
!12 = !{!"libxsmm_generated_code", !6, i64 0, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !10, i64 24, !10, i64 28}


; 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_generator_transform_norm_to_normt_32bit_avx512_spr_microkernel(ptr noundef, ptr noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, ptr noundef, ptr noundef) local_unnamed_addr #0

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

; Function Attrs: nounwind uwtable
define dso_local void @libxsmm_generator_transform_norm_to_normt_32bit_avx512_microkernel(ptr noundef %0, ptr noundef %1, i32 noundef %2, i32 noundef %3, i32 noundef %4, i32 noundef %5, i32 noundef %6, i32 noundef %7, i32 noundef %8, i32 noundef %9, i32 noundef %10, i32 noundef %11, i32 noundef %12, i32 noundef %13, i32 noundef %14, ptr noundef %15, ptr noundef %16) local_unnamed_addr #0 {
  %18 = getelementptr inbounds i8, ptr %0, i64 28
  %19 = load i32, ptr %18, align 4, !tbaa !5
  %20 = add i32 %19, -1104
  %or.cond = icmp ult i32 %20, 895
  br i1 %or.cond, label %21, label %22

21:                                               ; preds = %17
  tail call void @libxsmm_generator_transform_norm_to_normt_32bit_avx512_spr_microkernel(ptr noundef nonnull %0, ptr noundef %1, i32 noundef %2, i32 noundef %3, i32 noundef %4, i32 noundef %5, i32 noundef %6, i32 noundef %7, i32 noundef %8, i32 noundef %9, i32 noundef %10, i32 noundef %11, i32 noundef %12, i32 noundef %13, i32 noundef %14, ptr noundef %15, ptr noundef %16)
  br label %23

22:                                               ; preds = %17
  tail call void @libxsmm_generator_transform_norm_to_normt_32bit_avx512_pre_spr_microkernel(ptr noundef nonnull %0, ptr noundef %1, i32 noundef %2, i32 noundef %3, i32 noundef %4, i32 noundef %5, i32 noundef %6, i32 noundef %8, i32 noundef %9, i32 noundef %10, i32 noundef %11, i32 noundef %12, i32 noundef %13, ptr noundef %15, ptr noundef %16)
  br label %23

23:                                               ; preds = %22, %21
  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, !10, i64 28}
!6 = !{!"libxsmm_generated_code", !7, i64 0, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !10, i64 24, !10, i64 28}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"int", !8, i64 0}


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