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

; 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_micro_kernel_config = type { i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i8, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, [4 x i32], [4 x i32], [4 x i32], [4 x i32], [4 x i32], [4 x i32], i32, [2 x %struct.libxsmm_blocking_info_t], %struct.libxsmm_tile_config, i32, i32, i32, i32, i32, i32, i32, i32, ptr, i32, i32, i32, i32, ptr, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32 }
%struct.libxsmm_blocking_info_t = type { i32, [4 x i32], i32, i32 }
%struct.libxsmm_tile_config = type { i8, i16, i8, i16, i8, i16, i8, i16, i8, i16, i8, i16, i8, i16, i8, i16, i8 }
%struct.libxsmm_gemm_descriptor = type <{ i32, i32, i32, i32, i32, i32, i32, i8, [3 x i8], i8, i64, i64, i8, i32, i32, i32, i16, i16, i8, i8, i8, i8, i16, i16, i16, i16, i16, i16, i32, i32, i32, i8 }>
%struct.libxsmm_gp_reg_mapping_struct = type { i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, 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: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.end.p0(i64 immarg, ptr nocapture) #0

; Function Attrs: nounwind uwtable
define dso_local void @libxsmm_generator_gemm_avx512_microkernel_loadNinterleave_A_pair_k_i8_to_bf16(ptr noundef %0, ptr noundef %1, ptr noundef %2, ptr noundef %3, i32 noundef %4, i32 noundef %5, i32 noundef %6, i32 noundef %7, i32 noundef %8) #1 {
  %10 = alloca ptr, align 8
  %11 = alloca ptr, align 8
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %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
  store ptr %0, ptr %10, align 8, !tbaa !5
  store ptr %1, ptr %11, align 8, !tbaa !5
  store ptr %2, ptr %12, align 8, !tbaa !5
  store ptr %3, ptr %13, align 8, !tbaa !5
  store i32 %4, ptr %14, align 4, !tbaa !9
  store i32 %5, ptr %15, align 4, !tbaa !9
  store i32 %6, ptr %16, align 4, !tbaa !9
  store i32 %7, ptr %17, align 4, !tbaa !9
  store i32 %8, ptr %18, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %19) #3
  call void @llvm.lifetime.start.p0(i64 4, ptr %20) #3
  %24 = load ptr, ptr %12, align 8, !tbaa !5
  %25 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %24, i32 0, i32 14
  %26 = load i32, ptr %25, align 8, !tbaa !11
  %27 = icmp eq i32 %26, -268032430
  %28 = zext i1 %27 to i64
  %29 = select i1 %27, i32 1, i32 0
  store i32 %29, ptr %20, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %21) #3
  %30 = load ptr, ptr %13, align 8, !tbaa !5
  %31 = getelementptr inbounds %struct.libxsmm_gemm_descriptor, ptr %30, i32 0, i32 6
  %32 = load i32, ptr %31, align 1, !tbaa !15
  %33 = and i32 %32, 256
  %34 = icmp ugt i32 %33, 0
  %35 = zext i1 %34 to i64
  %36 = select i1 %34, i32 537207857, i32 537207841
  store i32 %36, ptr %21, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %22) #3
  %37 = load ptr, ptr %13, align 8, !tbaa !5
  %38 = getelementptr inbounds %struct.libxsmm_gemm_descriptor, ptr %37, i32 0, i32 6
  %39 = load i32, ptr %38, align 1, !tbaa !15
  %40 = and i32 %39, 256
  %41 = icmp ugt i32 %40, 0
  %42 = zext i1 %41 to i64
  %43 = select i1 %41, i32 537208115, i32 537208099
  store i32 %43, ptr %22, align 4, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %23) #3
  %44 = load i32, ptr %18, align 4, !tbaa !9
  %45 = load i32, ptr %17, align 4, !tbaa !9
  %46 = sub i32 %45, 1
  %47 = icmp eq i32 %44, %46
  br i1 %47, label %48, label %54

48:                                               ; preds = %9
  %49 = load ptr, ptr %12, align 8, !tbaa !5
  %50 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %49, i32 0, i32 11
  %51 = load i32, ptr %50, align 4, !tbaa !18
  %52 = icmp ugt i32 %51, 0
  br i1 %52, label %53, label %54

53:                                               ; preds = %48
  br label %56

54:                                               ; preds = %48, %9
  %55 = load i32, ptr %21, align 4, !tbaa !9
  br label %56

56:                                               ; preds = %54, %53
  %57 = phi i32 [ -536406417, %53 ], [ %55, %54 ]
  store i32 %57, ptr %23, align 4, !tbaa !9
  %58 = load ptr, ptr %13, align 8, !tbaa !5
  %59 = getelementptr inbounds %struct.libxsmm_gemm_descriptor, ptr %58, i32 0, i32 6
  %60 = load i32, ptr %59, align 1, !tbaa !15
  %61 = and i32 %60, 524288
  %62 = icmp ugt i32 %61, 0
  br i1 %62, label %63, label %66

63:                                               ; preds = %56
  %64 = load i32, ptr %18, align 4, !tbaa !9
  %65 = add i32 1, %64
  store i32 %65, ptr %19, align 4, !tbaa !9
  br label %67

66:                                               ; preds = %56
  store i32 1, ptr %19, align 4, !tbaa !9
  br label %67

67:                                               ; preds = %66, %63
  %68 = load ptr, ptr %10, align 8, !tbaa !5
  %69 = load ptr, ptr %12, align 8, !tbaa !5
  %70 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %69, i32 0, i32 0
  %71 = load i32, ptr %70, align 8, !tbaa !19
  %72 = load i32, ptr %23, align 4, !tbaa !9
  %73 = load ptr, ptr %11, align 8, !tbaa !5
  %74 = getelementptr inbounds %struct.libxsmm_gp_reg_mapping_struct, ptr %73, i32 0, i32 1
  %75 = load i32, ptr %74, align 4, !tbaa !20
  %76 = load ptr, ptr %12, align 8, !tbaa !5
  %77 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %76, i32 0, i32 3
  %78 = load i32, ptr %77, align 4, !tbaa !22
  %79 = load ptr, ptr %12, align 8, !tbaa !5
  %80 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %79, i32 0, i32 2
  %81 = load i32, ptr %80, align 8, !tbaa !23
  %82 = mul i32 %78, %81
  %83 = load i32, ptr %18, align 4, !tbaa !9
  %84 = mul i32 %82, %83
  %85 = load ptr, ptr %12, align 8, !tbaa !5
  %86 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %85, i32 0, i32 21
  %87 = load i8, ptr %86, align 4, !tbaa !24
  %88 = load i32, ptr %14, align 4, !tbaa !9
  %89 = load i32, ptr %18, align 4, !tbaa !9
  %90 = load i32, ptr %17, align 4, !tbaa !9
  %91 = sub i32 %90, 1
  %92 = icmp eq i32 %89, %91
  br i1 %92, label %93, label %97

93:                                               ; preds = %67
  %94 = load ptr, ptr %12, align 8, !tbaa !5
  %95 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %94, i32 0, i32 11
  %96 = load i32, ptr %95, align 4, !tbaa !18
  br label %98

97:                                               ; preds = %67
  br label %98

98:                                               ; preds = %97, %93
  %99 = phi i32 [ %96, %93 ], [ 0, %97 ]
  call void @libxsmm_x86_instruction_vec_move(ptr noundef %68, i32 noundef %71, i32 noundef %72, i32 noundef %75, i32 noundef 127, i32 noundef 0, i32 noundef %84, i8 noundef signext %87, i32 noundef %88, i32 noundef %99, i32 noundef 1, i32 noundef 0)
  %100 = load i32, ptr %23, align 4, !tbaa !9
  %101 = icmp eq i32 %100, -536406417
  br i1 %101, label %102, label %110

102:                                              ; preds = %98
  %103 = load ptr, ptr %10, align 8, !tbaa !5
  %104 = load i32, ptr %21, align 4, !tbaa !9
  %105 = load ptr, ptr %12, align 8, !tbaa !5
  %106 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %105, i32 0, i32 21
  %107 = load i8, ptr %106, align 4, !tbaa !24
  %108 = load i32, ptr %14, align 4, !tbaa !9
  %109 = load i32, ptr %14, align 4, !tbaa !9
  call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %103, i32 noundef %104, i8 noundef signext %107, i32 noundef %108, i32 noundef %109)
  br label %110

110:                                              ; preds = %102, %98
  %111 = load i32, ptr %20, align 4, !tbaa !9
  %112 = icmp ugt i32 %111, 0
  br i1 %112, label %113, label %165

113:                                              ; preds = %110
  %114 = load ptr, ptr %10, align 8, !tbaa !5
  %115 = load ptr, ptr %12, align 8, !tbaa !5
  %116 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %115, i32 0, i32 0
  %117 = load i32, ptr %116, align 8, !tbaa !19
  %118 = load i32, ptr %23, align 4, !tbaa !9
  %119 = load ptr, ptr %11, align 8, !tbaa !5
  %120 = getelementptr inbounds %struct.libxsmm_gp_reg_mapping_struct, ptr %119, i32 0, i32 1
  %121 = load i32, ptr %120, align 4, !tbaa !20
  %122 = load ptr, ptr %12, align 8, !tbaa !5
  %123 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %122, i32 0, i32 3
  %124 = load i32, ptr %123, align 4, !tbaa !22
  %125 = load ptr, ptr %12, align 8, !tbaa !5
  %126 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %125, i32 0, i32 2
  %127 = load i32, ptr %126, align 8, !tbaa !23
  %128 = mul i32 %124, %127
  %129 = load i32, ptr %18, align 4, !tbaa !9
  %130 = mul i32 %128, %129
  %131 = load ptr, ptr %13, align 8, !tbaa !5
  %132 = getelementptr inbounds %struct.libxsmm_gemm_descriptor, ptr %131, i32 0, i32 3
  %133 = load i32, ptr %132, align 1, !tbaa !25
  %134 = load ptr, ptr %12, align 8, !tbaa !5
  %135 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %134, i32 0, i32 3
  %136 = load i32, ptr %135, align 4, !tbaa !22
  %137 = mul i32 %133, %136
  %138 = add i32 %130, %137
  %139 = load ptr, ptr %12, align 8, !tbaa !5
  %140 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %139, i32 0, i32 21
  %141 = load i8, ptr %140, align 4, !tbaa !24
  %142 = load i32, ptr %15, align 4, !tbaa !9
  %143 = load i32, ptr %18, align 4, !tbaa !9
  %144 = load i32, ptr %17, align 4, !tbaa !9
  %145 = sub i32 %144, 1
  %146 = icmp eq i32 %143, %145
  br i1 %146, label %147, label %151

147:                                              ; preds = %113
  %148 = load ptr, ptr %12, align 8, !tbaa !5
  %149 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %148, i32 0, i32 11
  %150 = load i32, ptr %149, align 4, !tbaa !18
  br label %152

151:                                              ; preds = %113
  br label %152

152:                                              ; preds = %151, %147
  %153 = phi i32 [ %150, %147 ], [ 0, %151 ]
  call void @libxsmm_x86_instruction_vec_move(ptr noundef %114, i32 noundef %117, i32 noundef %118, i32 noundef %121, i32 noundef 127, i32 noundef 0, i32 noundef %138, i8 noundef signext %141, i32 noundef %142, i32 noundef %153, i32 noundef 1, i32 noundef 0)
  %154 = load i32, ptr %23, align 4, !tbaa !9
  %155 = icmp eq i32 %154, -536406417
  br i1 %155, label %156, label %164

156:                                              ; preds = %152
  %157 = load ptr, ptr %10, align 8, !tbaa !5
  %158 = load i32, ptr %21, align 4, !tbaa !9
  %159 = load ptr, ptr %12, align 8, !tbaa !5
  %160 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %159, i32 0, i32 21
  %161 = load i8, ptr %160, align 4, !tbaa !24
  %162 = load i32, ptr %15, align 4, !tbaa !9
  %163 = load i32, ptr %15, align 4, !tbaa !9
  call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %157, i32 noundef %158, i8 noundef signext %161, i32 noundef %162, i32 noundef %163)
  br label %164

164:                                              ; preds = %156, %152
  br label %165

165:                                              ; preds = %164, %110
  %166 = load ptr, ptr %10, align 8, !tbaa !5
  %167 = load ptr, ptr %12, align 8, !tbaa !5
  %168 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %167, i32 0, i32 21
  %169 = load i8, ptr %168, align 4, !tbaa !24
  %170 = load i32, ptr %14, align 4, !tbaa !9
  %171 = load i32, ptr %14, align 4, !tbaa !9
  call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %166, i32 noundef 537138779, i8 noundef signext %169, i32 noundef %170, i32 noundef %171)
  %172 = load ptr, ptr %10, align 8, !tbaa !5
  %173 = load ptr, ptr %12, align 8, !tbaa !5
  %174 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %173, i32 0, i32 21
  %175 = load i8, ptr %174, align 4, !tbaa !24
  %176 = load i32, ptr %14, align 4, !tbaa !9
  %177 = load i32, ptr %19, align 4, !tbaa !9
  %178 = load i32, ptr %14, align 4, !tbaa !9
  call void @libxsmm_x86_instruction_vec_compute_3reg(ptr noundef %172, i32 noundef 805574233, i8 noundef signext %175, i32 noundef %176, i32 noundef %177, i32 noundef %178)
  %179 = load i32, ptr %20, align 4, !tbaa !9
  %180 = icmp ugt i32 %179, 0
  br i1 %180, label %181, label %188

181:                                              ; preds = %165
  %182 = load ptr, ptr %10, align 8, !tbaa !5
  %183 = load ptr, ptr %12, align 8, !tbaa !5
  %184 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %183, i32 0, i32 21
  %185 = load i8, ptr %184, align 4, !tbaa !24
  %186 = load i32, ptr %14, align 4, !tbaa !9
  %187 = load i32, ptr %14, align 4, !tbaa !9
  call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %182, i32 noundef 537273970, i8 noundef signext %185, i32 noundef %186, i32 noundef %187)
  br label %197

188:                                              ; preds = %165
  %189 = load ptr, ptr %10, align 8, !tbaa !5
  %190 = load ptr, ptr %12, align 8, !tbaa !5
  %191 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %190, i32 0, i32 21
  %192 = load i8, ptr %191, align 4, !tbaa !24
  %193 = load i32, ptr %14, align 4, !tbaa !9
  %194 = load i32, ptr %14, align 4, !tbaa !9
  %195 = load i32, ptr %15, align 4, !tbaa !9
  %196 = load i32, ptr %16, align 4, !tbaa !9
  call void @libxsmm_generator_vcvtneps2bf16_avx512_preppedstack(ptr noundef %189, i8 noundef signext %192, i32 noundef %193, i32 noundef %194, i32 noundef %195, i32 noundef %196, i32 noundef 6, i32 noundef 7, i32 noundef 0)
  br label %197

197:                                              ; preds = %188, %181
  %198 = load i32, ptr %20, align 4, !tbaa !9
  %199 = icmp ugt i32 %198, 0
  br i1 %199, label %200, label %227

200:                                              ; preds = %197
  %201 = load ptr, ptr %10, align 8, !tbaa !5
  %202 = load ptr, ptr %12, align 8, !tbaa !5
  %203 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %202, i32 0, i32 21
  %204 = load i8, ptr %203, align 4, !tbaa !24
  %205 = load i32, ptr %15, align 4, !tbaa !9
  %206 = load i32, ptr %15, align 4, !tbaa !9
  call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %201, i32 noundef 537138779, i8 noundef signext %204, i32 noundef %205, i32 noundef %206)
  %207 = load ptr, ptr %10, align 8, !tbaa !5
  %208 = load ptr, ptr %12, align 8, !tbaa !5
  %209 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %208, i32 0, i32 21
  %210 = load i8, ptr %209, align 4, !tbaa !24
  %211 = load i32, ptr %15, align 4, !tbaa !9
  %212 = load i32, ptr %19, align 4, !tbaa !9
  %213 = load i32, ptr %15, align 4, !tbaa !9
  call void @libxsmm_x86_instruction_vec_compute_3reg(ptr noundef %207, i32 noundef 805574233, i8 noundef signext %210, i32 noundef %211, i32 noundef %212, i32 noundef %213)
  %214 = load ptr, ptr %10, align 8, !tbaa !5
  %215 = load ptr, ptr %12, align 8, !tbaa !5
  %216 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %215, i32 0, i32 21
  %217 = load i8, ptr %216, align 4, !tbaa !24
  %218 = load i32, ptr %15, align 4, !tbaa !9
  %219 = load i32, ptr %15, align 4, !tbaa !9
  call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %214, i32 noundef 537273970, i8 noundef signext %217, i32 noundef %218, i32 noundef %219)
  %220 = load ptr, ptr %10, align 8, !tbaa !5
  %221 = load ptr, ptr %12, align 8, !tbaa !5
  %222 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %221, i32 0, i32 21
  %223 = load i8, ptr %222, align 4, !tbaa !24
  %224 = load i32, ptr %15, align 4, !tbaa !9
  %225 = load i32, ptr %16, align 4, !tbaa !9
  %226 = load i32, ptr %14, align 4, !tbaa !9
  call void @libxsmm_x86_instruction_vec_compute_3reg(ptr noundef %220, i32 noundef -259709315, i8 noundef signext %223, i32 noundef %224, i32 noundef %225, i32 noundef %226)
  br label %241

227:                                              ; preds = %197
  %228 = load ptr, ptr %10, align 8, !tbaa !5
  %229 = load i32, ptr %22, align 4, !tbaa !9
  %230 = load ptr, ptr %12, align 8, !tbaa !5
  %231 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %230, i32 0, i32 21
  %232 = load i8, ptr %231, align 4, !tbaa !24
  %233 = load i32, ptr %14, align 4, !tbaa !9
  %234 = load i32, ptr %14, align 4, !tbaa !9
  call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %228, i32 noundef %229, i8 noundef signext %232, i32 noundef %233, i32 noundef %234)
  %235 = load ptr, ptr %10, align 8, !tbaa !5
  %236 = load ptr, ptr %12, align 8, !tbaa !5
  %237 = getelementptr inbounds %struct.libxsmm_micro_kernel_config, ptr %236, i32 0, i32 21
  %238 = load i8, ptr %237, align 4, !tbaa !24
  %239 = load i32, ptr %14, align 4, !tbaa !9
  %240 = load i32, ptr %14, align 4, !tbaa !9
  call void @libxsmm_x86_instruction_vec_compute_2reg_imm8(ptr noundef %235, i32 noundef 611128946, i8 noundef signext %238, i32 noundef %239, i32 noundef %240, i32 noundef 16)
  br label %241

241:                                              ; preds = %227, %200
  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
  ret void
}

declare void @libxsmm_x86_instruction_vec_move(ptr noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i8 noundef signext, i32 noundef, i32 noundef, i32 noundef, i32 noundef) #2

declare void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef, i32 noundef, i8 noundef signext, i32 noundef, i32 noundef) #2

declare void @libxsmm_x86_instruction_vec_compute_3reg(ptr noundef, i32 noundef, i8 noundef signext, i32 noundef, i32 noundef, i32 noundef) #2

declare void @libxsmm_generator_vcvtneps2bf16_avx512_preppedstack(ptr noundef, i8 noundef signext, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) #2

declare void @libxsmm_x86_instruction_vec_compute_2reg_imm8(ptr noundef, i32 noundef, i8 noundef signext, i32 noundef, i32 noundef, i32 noundef) #2

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 = { "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, !10, i64 56}
!12 = !{!"libxsmm_micro_kernel_config", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !10, i64 24, !10, i64 28, !10, i64 32, !10, i64 36, !10, i64 40, !10, i64 44, !10, i64 48, !10, i64 52, !10, i64 56, !10, i64 60, !10, i64 64, !10, i64 68, !10, i64 72, !10, i64 76, !10, i64 80, !7, i64 84, !10, i64 88, !10, i64 92, !10, i64 96, !10, i64 100, !10, i64 104, !10, i64 108, !10, i64 112, !10, i64 116, !10, i64 120, !10, i64 124, !10, i64 128, !10, i64 132, !10, i64 136, !10, i64 140, !10, i64 144, !10, i64 148, !10, i64 152, !10, i64 156, !10, i64 160, !10, i64 164, !10, i64 168, !10, i64 172, !10, i64 176, !10, i64 180, !10, i64 184, !10, i64 188, !10, i64 192, !10, i64 196, !10, i64 200, !10, i64 204, !10, i64 208, !10, i64 212, !10, i64 216, !10, i64 220, !10, i64 224, !10, i64 228, !10, i64 232, !10, i64 236, !10, i64 240, !10, i64 244, !10, i64 248, !10, i64 252, !10, i64 256, !10, i64 260, !10, i64 264, !10, i64 268, !10, i64 272, !10, i64 276, !10, i64 280, !10, i64 284, !10, i64 288, !10, i64 292, !10, i64 296, !10, i64 300, !10, i64 304, !10, i64 308, !10, i64 312, !10, i64 316, !10, i64 320, !10, i64 324, !10, i64 328, !10, i64 332, !10, i64 336, !10, i64 340, !10, i64 344, !10, i64 348, !10, i64 352, !10, i64 356, !10, i64 360, !7, i64 364, !7, i64 380, !7, i64 396, !7, i64 412, !7, i64 428, !7, i64 444, !10, i64 460, !7, i64 464, !13, i64 520, !10, i64 556, !10, i64 560, !10, i64 564, !10, i64 568, !10, i64 572, !10, i64 576, !10, i64 580, !10, i64 584, !6, i64 592, !10, i64 600, !10, i64 604, !10, i64 608, !10, i64 612, !6, i64 616, !10, i64 624, !10, i64 628, !10, i64 632, !10, i64 636, !10, i64 640, !10, i64 644, !10, i64 648, !10, i64 652, !10, i64 656, !10, i64 660, !10, i64 664, !10, i64 668, !10, i64 672, !10, i64 676, !10, i64 680}
!13 = !{!"libxsmm_tile_config", !7, i64 0, !14, i64 2, !7, i64 4, !14, i64 6, !7, i64 8, !14, i64 10, !7, i64 12, !14, i64 14, !7, i64 16, !14, i64 18, !7, i64 20, !14, i64 22, !7, i64 24, !14, i64 26, !7, i64 28, !14, i64 30, !7, i64 32}
!14 = !{!"short", !7, i64 0}
!15 = !{!16, !10, i64 24}
!16 = !{!"libxsmm_gemm_descriptor", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !10, i64 24, !7, i64 28, !7, i64 29, !7, i64 32, !17, i64 33, !17, i64 41, !7, i64 49, !10, i64 50, !10, i64 54, !10, i64 58, !14, i64 62, !14, i64 64, !7, i64 66, !7, i64 67, !7, i64 68, !7, i64 69, !14, i64 70, !14, i64 72, !14, i64 74, !14, i64 76, !14, i64 78, !14, i64 80, !10, i64 82, !10, i64 86, !10, i64 90, !7, i64 94}
!17 = !{!"long long", !7, i64 0}
!18 = !{!12, !10, i64 44}
!19 = !{!12, !10, i64 0}
!20 = !{!21, !10, i64 4}
!21 = !{!"libxsmm_gp_reg_mapping_struct", !10, i64 0, !10, i64 4, !10, i64 8, !10, i64 12, !10, i64 16, !10, i64 20, !10, i64 24, !10, i64 28, !10, i64 32, !10, i64 36, !10, i64 40, !10, i64 44, !10, i64 48, !10, i64 52, !10, i64 56, !10, i64 60, !10, i64 64, !10, i64 68, !10, i64 72, !10, i64 76, !10, i64 80, !10, i64 84, !10, i64 88, !10, i64 92, !10, i64 96, !10, i64 100, !10, i64 104, !10, i64 108, !10, i64 112, !10, i64 116, !10, i64 120, !10, i64 124, !10, i64 128}
!22 = !{!12, !10, i64 12}
!23 = !{!12, !10, i64 8}
!24 = !{!12, !7, i64 84}
!25 = !{!16, !10, i64 12}


; 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
define dso_local void @libxsmm_generator_gemm_avx512_microkernel_loadNinterleave_A_pair_k_i8_to_bf16(ptr noundef %0, ptr nocapture noundef readonly %1, ptr nocapture noundef readonly %2, ptr nocapture noundef readonly %3, i32 noundef %4, i32 noundef %5, i32 noundef %6, i32 noundef %7, i32 noundef %8) local_unnamed_addr #0 {
  %10 = getelementptr inbounds i8, ptr %2, i64 56
  %11 = load i32, ptr %10, align 8, !tbaa !5
  %12 = icmp eq i32 %11, -268032430
  %13 = getelementptr inbounds i8, ptr %3, i64 24
  %14 = load i32, ptr %13, align 1, !tbaa !13
  %15 = and i32 %14, 256
  %.not = icmp eq i32 %15, 0
  %16 = select i1 %.not, i32 537207841, i32 537207857
  %17 = select i1 %.not, i32 537208099, i32 537208115
  %18 = add i32 %7, -1
  %19 = icmp eq i32 %18, %8
  br i1 %19, label %20, label %23

20:                                               ; preds = %9
  %21 = getelementptr inbounds i8, ptr %2, i64 44
  %22 = load i32, ptr %21, align 4, !tbaa !16
  %.not95 = icmp eq i32 %22, 0
  br i1 %.not95, label %23, label %24

23:                                               ; preds = %20, %9
  br label %24

24:                                               ; preds = %20, %23
  %25 = phi i32 [ %16, %23 ], [ -536406417, %20 ]
  %26 = and i32 %14, 524288
  %.not96 = icmp eq i32 %26, 0
  %27 = add i32 %8, 1
  %.0 = select i1 %.not96, i32 1, i32 %27
  %28 = load i32, ptr %2, align 8, !tbaa !17
  %29 = getelementptr inbounds i8, ptr %1, i64 4
  %30 = load i32, ptr %29, align 4, !tbaa !18
  %31 = getelementptr inbounds i8, ptr %2, i64 12
  %32 = load i32, ptr %31, align 4, !tbaa !20
  %33 = getelementptr inbounds i8, ptr %2, i64 8
  %34 = load i32, ptr %33, align 8, !tbaa !21
  %35 = mul i32 %32, %8
  %36 = mul i32 %35, %34
  %37 = getelementptr inbounds i8, ptr %2, i64 84
  %38 = load i8, ptr %37, align 4, !tbaa !22
  br i1 %19, label %39, label %42

39:                                               ; preds = %24
  %40 = getelementptr inbounds i8, ptr %2, i64 44
  %41 = load i32, ptr %40, align 4, !tbaa !16
  br label %42

42:                                               ; preds = %24, %39
  %43 = phi i32 [ %41, %39 ], [ 0, %24 ]
  tail call void @libxsmm_x86_instruction_vec_move(ptr noundef %0, i32 noundef %28, i32 noundef %25, i32 noundef %30, i32 noundef 127, i32 noundef 0, i32 noundef %36, i8 noundef signext %38, i32 noundef %4, i32 noundef %43, i32 noundef 1, i32 noundef 0) #2
  %44 = icmp eq i32 %25, -536406417
  br i1 %44, label %45, label %47

45:                                               ; preds = %42
  %46 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %0, i32 noundef %16, i8 noundef signext %46, i32 noundef %4, i32 noundef %4) #2
  br label %47

47:                                               ; preds = %45, %42
  br i1 %12, label %48, label %72

48:                                               ; preds = %47
  %49 = load i32, ptr %2, align 8, !tbaa !17
  %50 = load i32, ptr %29, align 4, !tbaa !18
  %51 = load i32, ptr %31, align 4, !tbaa !20
  %52 = load i32, ptr %33, align 8, !tbaa !21
  %53 = mul i32 %52, %8
  %54 = getelementptr inbounds i8, ptr %3, i64 12
  %55 = load i32, ptr %54, align 1, !tbaa !23
  %reass.add = add i32 %53, %55
  %reass.mul = mul i32 %reass.add, %51
  %56 = load i8, ptr %37, align 4, !tbaa !22
  br i1 %19, label %57, label %60

57:                                               ; preds = %48
  %58 = getelementptr inbounds i8, ptr %2, i64 44
  %59 = load i32, ptr %58, align 4, !tbaa !16
  br label %60

60:                                               ; preds = %48, %57
  %61 = phi i32 [ %59, %57 ], [ 0, %48 ]
  tail call void @libxsmm_x86_instruction_vec_move(ptr noundef %0, i32 noundef %49, i32 noundef %25, i32 noundef %50, i32 noundef 127, i32 noundef 0, i32 noundef %reass.mul, i8 noundef signext %56, i32 noundef %5, i32 noundef %61, i32 noundef 1, i32 noundef 0) #2
  br i1 %44, label %62, label %64

62:                                               ; preds = %60
  %63 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %0, i32 noundef %16, i8 noundef signext %63, i32 noundef %5, i32 noundef %5) #2
  br label %64

64:                                               ; preds = %60, %62
  %65 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %0, i32 noundef 537138779, i8 noundef signext %65, i32 noundef %4, i32 noundef %4) #2
  %66 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_x86_instruction_vec_compute_3reg(ptr noundef %0, i32 noundef 805574233, i8 noundef signext %66, i32 noundef %4, i32 noundef %.0, i32 noundef %4) #2
  %67 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %0, i32 noundef 537273970, i8 noundef signext %67, i32 noundef %4, i32 noundef %4) #2
  %68 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %0, i32 noundef 537138779, i8 noundef signext %68, i32 noundef %5, i32 noundef %5) #2
  %69 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_x86_instruction_vec_compute_3reg(ptr noundef %0, i32 noundef 805574233, i8 noundef signext %69, i32 noundef %5, i32 noundef %.0, i32 noundef %5) #2
  %70 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %0, i32 noundef 537273970, i8 noundef signext %70, i32 noundef %5, i32 noundef %5) #2
  %71 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_x86_instruction_vec_compute_3reg(ptr noundef %0, i32 noundef -259709315, i8 noundef signext %71, i32 noundef %5, i32 noundef %6, i32 noundef %4) #2
  br label %78

72:                                               ; preds = %47
  %73 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %0, i32 noundef 537138779, i8 noundef signext %73, i32 noundef %4, i32 noundef %4) #2
  %74 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_x86_instruction_vec_compute_3reg(ptr noundef %0, i32 noundef 805574233, i8 noundef signext %74, i32 noundef %4, i32 noundef %.0, i32 noundef %4) #2
  %75 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_generator_vcvtneps2bf16_avx512_preppedstack(ptr noundef %0, i8 noundef signext %75, i32 noundef %4, i32 noundef %4, i32 noundef %5, i32 noundef %6, i32 noundef 6, i32 noundef 7, i32 noundef 0) #2
  %76 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef %0, i32 noundef %17, i8 noundef signext %76, i32 noundef %4, i32 noundef %4) #2
  %77 = load i8, ptr %37, align 4, !tbaa !22
  tail call void @libxsmm_x86_instruction_vec_compute_2reg_imm8(ptr noundef %0, i32 noundef 611128946, i8 noundef signext %77, i32 noundef %4, i32 noundef %4, i32 noundef 16) #2
  br label %78

78:                                               ; preds = %72, %64
  ret void
}

declare void @libxsmm_x86_instruction_vec_move(ptr noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i8 noundef signext, i32 noundef, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #1

declare void @libxsmm_x86_instruction_vec_compute_2reg(ptr noundef, i32 noundef, i8 noundef signext, i32 noundef, i32 noundef) local_unnamed_addr #1

declare void @libxsmm_x86_instruction_vec_compute_3reg(ptr noundef, i32 noundef, i8 noundef signext, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #1

declare void @libxsmm_generator_vcvtneps2bf16_avx512_preppedstack(ptr noundef, i8 noundef signext, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #1

declare void @libxsmm_x86_instruction_vec_compute_2reg_imm8(ptr noundef, i32 noundef, i8 noundef signext, i32 noundef, i32 noundef, i32 noundef) local_unnamed_addr #1

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

!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 56}
!6 = !{!"libxsmm_micro_kernel_config", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !7, i64 16, !7, i64 20, !7, i64 24, !7, i64 28, !7, i64 32, !7, i64 36, !7, i64 40, !7, i64 44, !7, i64 48, !7, i64 52, !7, i64 56, !7, i64 60, !7, i64 64, !7, i64 68, !7, i64 72, !7, i64 76, !7, i64 80, !8, i64 84, !7, i64 88, !7, i64 92, !7, i64 96, !7, i64 100, !7, i64 104, !7, i64 108, !7, i64 112, !7, i64 116, !7, i64 120, !7, i64 124, !7, i64 128, !7, i64 132, !7, i64 136, !7, i64 140, !7, i64 144, !7, i64 148, !7, i64 152, !7, i64 156, !7, i64 160, !7, i64 164, !7, i64 168, !7, i64 172, !7, i64 176, !7, i64 180, !7, i64 184, !7, i64 188, !7, i64 192, !7, i64 196, !7, i64 200, !7, i64 204, !7, i64 208, !7, i64 212, !7, i64 216, !7, i64 220, !7, i64 224, !7, i64 228, !7, i64 232, !7, i64 236, !7, i64 240, !7, i64 244, !7, i64 248, !7, i64 252, !7, i64 256, !7, i64 260, !7, i64 264, !7, i64 268, !7, i64 272, !7, i64 276, !7, i64 280, !7, i64 284, !7, i64 288, !7, i64 292, !7, i64 296, !7, i64 300, !7, i64 304, !7, i64 308, !7, i64 312, !7, i64 316, !7, i64 320, !7, i64 324, !7, i64 328, !7, i64 332, !7, i64 336, !7, i64 340, !7, i64 344, !7, i64 348, !7, i64 352, !7, i64 356, !7, i64 360, !8, i64 364, !8, i64 380, !8, i64 396, !8, i64 412, !8, i64 428, !8, i64 444, !7, i64 460, !8, i64 464, !10, i64 520, !7, i64 556, !7, i64 560, !7, i64 564, !7, i64 568, !7, i64 572, !7, i64 576, !7, i64 580, !7, i64 584, !12, i64 592, !7, i64 600, !7, i64 604, !7, i64 608, !7, i64 612, !12, i64 616, !7, i64 624, !7, i64 628, !7, i64 632, !7, i64 636, !7, i64 640, !7, i64 644, !7, i64 648, !7, i64 652, !7, i64 656, !7, i64 660, !7, i64 664, !7, i64 668, !7, i64 672, !7, i64 676, !7, i64 680}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!"libxsmm_tile_config", !8, i64 0, !11, i64 2, !8, i64 4, !11, i64 6, !8, i64 8, !11, i64 10, !8, i64 12, !11, i64 14, !8, i64 16, !11, i64 18, !8, i64 20, !11, i64 22, !8, i64 24, !11, i64 26, !8, i64 28, !11, i64 30, !8, i64 32}
!11 = !{!"short", !8, i64 0}
!12 = !{!"any pointer", !8, i64 0}
!13 = !{!14, !7, i64 24}
!14 = !{!"libxsmm_gemm_descriptor", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !7, i64 16, !7, i64 20, !7, i64 24, !8, i64 28, !8, i64 29, !8, i64 32, !15, i64 33, !15, i64 41, !8, i64 49, !7, i64 50, !7, i64 54, !7, i64 58, !11, i64 62, !11, i64 64, !8, i64 66, !8, i64 67, !8, i64 68, !8, i64 69, !11, i64 70, !11, i64 72, !11, i64 74, !11, i64 76, !11, i64 78, !11, i64 80, !7, i64 82, !7, i64 86, !7, i64 90, !8, i64 94}
!15 = !{!"long long", !8, i64 0}
!16 = !{!6, !7, i64 44}
!17 = !{!6, !7, i64 0}
!18 = !{!19, !7, i64 4}
!19 = !{!"libxsmm_gp_reg_mapping_struct", !7, i64 0, !7, i64 4, !7, i64 8, !7, i64 12, !7, i64 16, !7, i64 20, !7, i64 24, !7, i64 28, !7, i64 32, !7, i64 36, !7, i64 40, !7, i64 44, !7, i64 48, !7, i64 52, !7, i64 56, !7, i64 60, !7, i64 64, !7, i64 68, !7, i64 72, !7, i64 76, !7, i64 80, !7, i64 84, !7, i64 88, !7, i64 92, !7, i64 96, !7, i64 100, !7, i64 104, !7, i64 108, !7, i64 112, !7, i64 116, !7, i64 120, !7, i64 124, !7, i64 128}
!20 = !{!6, !7, i64 12}
!21 = !{!6, !7, i64 8}
!22 = !{!6, !8, i64 84}
!23 = !{!14, !7, i64 12}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass