; LLVM IR from mitdbg/deneva :: benchmarks/tpcc_wl.ll (ZN12TPCCWorkload13init_tab_distEm)

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

%class.TPCCWorkload = type { %class.Workload, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i64, i32, ptr }
%class.Workload = type { ptr, %"class.std::map", %"class.std::map.0", i64, i64 }
%"class.std::map" = type { %"class.std::_Rb_tree" }
%"class.std::_Rb_tree" = type { %"struct.std::_Rb_tree<std::__cxx11::basic_string<char>, std::pair<const std::__cxx11::basic_string<char>, table_t *>, std::_Select1st<std::pair<const std::__cxx11::basic_string<char>, table_t *>>, std::less<std::__cxx11::basic_string<char>>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<std::__cxx11::basic_string<char>, std::pair<const std::__cxx11::basic_string<char>, table_t *>, std::_Select1st<std::pair<const std::__cxx11::basic_string<char>, table_t *>>, std::less<std::__cxx11::basic_string<char>>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }
%"struct.std::_Rb_tree_header" = type { %"struct.std::_Rb_tree_node_base", i64 }
%"struct.std::_Rb_tree_node_base" = type { i32, ptr, ptr, ptr }
%"class.std::map.0" = type { %"class.std::_Rb_tree.1" }
%"class.std::_Rb_tree.1" = type { %"struct.std::_Rb_tree<std::__cxx11::basic_string<char>, std::pair<const std::__cxx11::basic_string<char>, IndexHash *>, std::_Select1st<std::pair<const std::__cxx11::basic_string<char>, IndexHash *>>, std::less<std::__cxx11::basic_string<char>>>::_Rb_tree_impl" }
%"struct.std::_Rb_tree<std::__cxx11::basic_string<char>, std::pair<const std::__cxx11::basic_string<char>, IndexHash *>, std::_Select1st<std::pair<const std::__cxx11::basic_string<char>, IndexHash *>>, std::less<std::__cxx11::basic_string<char>>>::_Rb_tree_impl" = type { [8 x i8], %"struct.std::_Rb_tree_header" }

@g_dist_per_wh = external global i32, align 4

; 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 noundef i32 @_ZN7table_t11get_new_rowERP5row_tmRm(ptr noundef nonnull align 8 dereferenceable(68), ptr noundef nonnull align 8 dereferenceable(8), i64 noundef, ptr noundef nonnull align 8 dereferenceable(8)) #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN5row_t15set_primary_keyEm(ptr noundef nonnull align 8 dereferenceable(64), i64 noundef) #2 align 2

declare void @_ZN5row_t9set_valueEim(ptr noundef nonnull align 8 dereferenceable(64), i32 noundef, i64 noundef) #1

declare noundef i64 @_Z5URandmm(i64 noundef, i64 noundef) #1

declare void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64), i32 noundef, ptr noundef) #1

declare void @_ZN8Workload12index_insertEP9IndexHashmP5row_tl(ptr noundef nonnull align 8 dereferenceable(120), ptr noundef, i64 noundef, ptr noundef, i64 noundef) #1

declare noundef i64 @_Z10wh_to_partm(i64 noundef) #1

declare noundef i64 @_Z15MakeAlphaStringiiPc(i32 noundef, i32 noundef, ptr noundef) #1

declare noundef i64 @_Z16MakeNumberStringiiPc(i32 noundef, i32 noundef, ptr noundef) #1

declare void @_ZN5row_t9set_valueEid(ptr noundef nonnull align 8 dereferenceable(64), i32 noundef, double noundef) #1

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN12TPCCWorkload13init_tab_distEm(ptr noundef nonnull align 8 dereferenceable(296) %0, i64 noundef %1) #3 align 2 {
  %3 = alloca ptr, align 8
  %4 = alloca i64, align 8
  %5 = alloca i64, align 8
  %6 = alloca ptr, align 8
  %7 = alloca i64, align 8
  %8 = alloca [10 x i8], align 1
  %9 = alloca [20 x i8], align 16
  %10 = alloca [2 x i8], align 1
  %11 = alloca [9 x i8], align 1
  %12 = alloca double, align 8
  %13 = alloca double, align 8
  store ptr %0, ptr %3, align 8, !tbaa !5
  store i64 %1, ptr %4, align 8, !tbaa !9
  %14 = load ptr, ptr %3, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #4
  store i64 1, ptr %5, align 8, !tbaa !9
  br label %15

15:                                               ; preds = %71, %2
  %16 = load i64, ptr %5, align 8, !tbaa !9
  %17 = load i32, ptr @g_dist_per_wh, align 4, !tbaa !11
  %18 = zext i32 %17 to i64
  %19 = icmp ule i64 %16, %18
  br i1 %19, label %21, label %20

20:                                               ; preds = %15
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #4
  br label %74

21:                                               ; preds = %15
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #4
  %22 = getelementptr inbounds %class.TPCCWorkload, ptr %14, i32 0, i32 2
  %23 = load ptr, ptr %22, align 8, !tbaa !13
  %24 = call noundef i32 @_ZN7table_t11get_new_rowERP5row_tmRm(ptr noundef nonnull align 8 dereferenceable(68) %23, ptr noundef nonnull align 8 dereferenceable(8) %6, i64 noundef 0, ptr noundef nonnull align 8 dereferenceable(8) %7)
  %25 = load ptr, ptr %6, align 8, !tbaa !5
  %26 = load i64, ptr %5, align 8, !tbaa !9
  call void @_ZN5row_t15set_primary_keyEm(ptr noundef nonnull align 8 dereferenceable(64) %25, i64 noundef %26)
  %27 = load ptr, ptr %6, align 8, !tbaa !5
  %28 = load i64, ptr %5, align 8, !tbaa !9
  call void @_ZN5row_t9set_valueEim(ptr noundef nonnull align 8 dereferenceable(64) %27, i32 noundef 0, i64 noundef %28)
  %29 = load ptr, ptr %6, align 8, !tbaa !5
  %30 = load i64, ptr %4, align 8, !tbaa !9
  call void @_ZN5row_t9set_valueEim(ptr noundef nonnull align 8 dereferenceable(64) %29, i32 noundef 1, i64 noundef %30)
  call void @llvm.lifetime.start.p0(i64 10, ptr %8) #4
  %31 = getelementptr inbounds [10 x i8], ptr %8, i64 0, i64 0
  %32 = call noundef i64 @_Z15MakeAlphaStringiiPc(i32 noundef 6, i32 noundef 10, ptr noundef %31)
  %33 = load ptr, ptr %6, align 8, !tbaa !5
  %34 = getelementptr inbounds [10 x i8], ptr %8, i64 0, i64 0
  call void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64) %33, i32 noundef 2, ptr noundef %34)
  call void @llvm.lifetime.start.p0(i64 20, ptr %9) #4
  %35 = getelementptr inbounds [20 x i8], ptr %9, i64 0, i64 0
  %36 = call noundef i64 @_Z15MakeAlphaStringiiPc(i32 noundef 10, i32 noundef 20, ptr noundef %35)
  %37 = load ptr, ptr %6, align 8, !tbaa !5
  %38 = getelementptr inbounds [20 x i8], ptr %9, i64 0, i64 0
  call void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64) %37, i32 noundef 3, ptr noundef %38)
  %39 = getelementptr inbounds [20 x i8], ptr %9, i64 0, i64 0
  %40 = call noundef i64 @_Z15MakeAlphaStringiiPc(i32 noundef 10, i32 noundef 20, ptr noundef %39)
  %41 = load ptr, ptr %6, align 8, !tbaa !5
  %42 = getelementptr inbounds [20 x i8], ptr %9, i64 0, i64 0
  call void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64) %41, i32 noundef 4, ptr noundef %42)
  %43 = getelementptr inbounds [20 x i8], ptr %9, i64 0, i64 0
  %44 = call noundef i64 @_Z15MakeAlphaStringiiPc(i32 noundef 10, i32 noundef 20, ptr noundef %43)
  %45 = load ptr, ptr %6, align 8, !tbaa !5
  %46 = getelementptr inbounds [20 x i8], ptr %9, i64 0, i64 0
  call void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64) %45, i32 noundef 5, ptr noundef %46)
  call void @llvm.lifetime.start.p0(i64 2, ptr %10) #4
  %47 = getelementptr inbounds [2 x i8], ptr %10, i64 0, i64 0
  %48 = call noundef i64 @_Z15MakeAlphaStringiiPc(i32 noundef 2, i32 noundef 2, ptr noundef %47)
  %49 = load ptr, ptr %6, align 8, !tbaa !5
  %50 = getelementptr inbounds [2 x i8], ptr %10, i64 0, i64 0
  call void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64) %49, i32 noundef 6, ptr noundef %50)
  call void @llvm.lifetime.start.p0(i64 9, ptr %11) #4
  %51 = getelementptr inbounds [9 x i8], ptr %11, i64 0, i64 0
  %52 = call noundef i64 @_Z16MakeNumberStringiiPc(i32 noundef 9, i32 noundef 9, ptr noundef %51)
  %53 = load ptr, ptr %6, align 8, !tbaa !5
  %54 = getelementptr inbounds [9 x i8], ptr %11, i64 0, i64 0
  call void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64) %53, i32 noundef 7, ptr noundef %54)
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #4
  %55 = call noundef i64 @_Z5URandmm(i64 noundef 0, i64 noundef 200)
  %56 = uitofp i64 %55 to double
  %57 = fdiv double %56, 1.000000e+03
  store double %57, ptr %12, align 8, !tbaa !27
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #4
  store double 3.000000e+04, ptr %13, align 8, !tbaa !27
  %58 = load ptr, ptr %6, align 8, !tbaa !5
  %59 = load double, ptr %12, align 8, !tbaa !27
  call void @_ZN5row_t9set_valueEid(ptr noundef nonnull align 8 dereferenceable(64) %58, i32 noundef 8, double noundef %59)
  %60 = load ptr, ptr %6, align 8, !tbaa !5
  %61 = load double, ptr %13, align 8, !tbaa !27
  call void @_ZN5row_t9set_valueEid(ptr noundef nonnull align 8 dereferenceable(64) %60, i32 noundef 9, double noundef %61)
  %62 = load ptr, ptr %6, align 8, !tbaa !5
  call void @_ZN5row_t9set_valueEii(ptr noundef nonnull align 8 dereferenceable(64) %62, i32 noundef 10, i32 noundef 3001)
  %63 = getelementptr inbounds %class.TPCCWorkload, ptr %14, i32 0, i32 12
  %64 = load ptr, ptr %63, align 8, !tbaa !29
  %65 = load i64, ptr %5, align 8, !tbaa !9
  %66 = load i64, ptr %4, align 8, !tbaa !9
  %67 = call noundef i64 @_Z7distKeymm(i64 noundef %65, i64 noundef %66)
  %68 = load ptr, ptr %6, align 8, !tbaa !5
  %69 = load i64, ptr %4, align 8, !tbaa !9
  %70 = call noundef i64 @_Z10wh_to_partm(i64 noundef %69)
  call void @_ZN8Workload12index_insertEP9IndexHashmP5row_tl(ptr noundef nonnull align 8 dereferenceable(120) %14, ptr noundef %64, i64 noundef %67, ptr noundef %68, i64 noundef %70)
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #4
  call void @llvm.lifetime.end.p0(i64 9, ptr %11) #4
  call void @llvm.lifetime.end.p0(i64 2, ptr %10) #4
  call void @llvm.lifetime.end.p0(i64 20, ptr %9) #4
  call void @llvm.lifetime.end.p0(i64 10, ptr %8) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #4
  br label %71

71:                                               ; preds = %21
  %72 = load i64, ptr %5, align 8, !tbaa !9
  %73 = add i64 %72, 1
  store i64 %73, ptr %5, align 8, !tbaa !9
  br label %15, !llvm.loop !30

74:                                               ; preds = %20
  ret void
}

declare void @_ZN5row_t9set_valueEii(ptr noundef nonnull align 8 dereferenceable(64), i32 noundef, i32 noundef) #1

declare noundef i64 @_Z7distKeymm(i64 noundef, i64 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 = { mustprogress 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 = { mustprogress 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 #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, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"int", !7, i64 0}
!13 = !{!14, !6, i64 128}
!14 = !{!"_ZTS12TPCCWorkload", !15, i64 0, !6, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !6, i64 200, !6, i64 208, !6, i64 216, !6, i64 224, !6, i64 232, !6, i64 240, !6, i64 248, !6, i64 256, !6, i64 264, !10, i64 272, !12, i64 280, !6, i64 288}
!15 = !{!"_ZTS8Workload", !16, i64 8, !24, i64 56, !10, i64 104, !10, i64 112}
!16 = !{!"_ZTSSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEP7table_tSt4lessIS5_ESaISt4pairIKS5_S7_EEE", !17, i64 0}
!17 = !{!"_ZTSSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_P7table_tESt10_Select1stISA_ESt4lessIS5_ESaISA_EE", !18, i64 0}
!18 = !{!"_ZTSNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_P7table_tESt10_Select1stISA_ESt4lessIS5_ESaISA_EE13_Rb_tree_implISE_Lb1EEE", !19, i64 0, !21, i64 8}
!19 = !{!"_ZTSSt20_Rb_tree_key_compareISt4lessINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEE", !20, i64 0}
!20 = !{!"_ZTSSt4lessINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEE"}
!21 = !{!"_ZTSSt15_Rb_tree_header", !22, i64 0, !10, i64 32}
!22 = !{!"_ZTSSt18_Rb_tree_node_base", !23, i64 0, !6, i64 8, !6, i64 16, !6, i64 24}
!23 = !{!"_ZTSSt14_Rb_tree_color", !7, i64 0}
!24 = !{!"_ZTSSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEP9IndexHashSt4lessIS5_ESaISt4pairIKS5_S7_EEE", !25, i64 0}
!25 = !{!"_ZTSSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_P9IndexHashESt10_Select1stISA_ESt4lessIS5_ESaISA_EE", !26, i64 0}
!26 = !{!"_ZTSNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_P9IndexHashESt10_Select1stISA_ESt4lessIS5_ESaISA_EE13_Rb_tree_implISE_Lb1EEE", !19, i64 0, !21, i64 8}
!27 = !{!28, !28, i64 0}
!28 = !{!"double", !7, i64 0}
!29 = !{!14, !6, i64 208}
!30 = distinct !{!30, !31}
!31 = !{!"llvm.loop.mustprogress"}


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

@g_dist_per_wh = external local_unnamed_addr global i32, align 4

; 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 noundef i32 @_ZN7table_t11get_new_rowERP5row_tmRm(ptr noundef nonnull align 8 dereferenceable(68), ptr noundef nonnull align 8 dereferenceable(8), i64 noundef, ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN5row_t15set_primary_keyEm(ptr noundef nonnull align 8 dereferenceable(64), i64 noundef) local_unnamed_addr #2 align 2

declare void @_ZN5row_t9set_valueEim(ptr noundef nonnull align 8 dereferenceable(64), i32 noundef, i64 noundef) local_unnamed_addr #1

declare noundef i64 @_Z5URandmm(i64 noundef, i64 noundef) local_unnamed_addr #1

declare void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64), i32 noundef, ptr noundef) local_unnamed_addr #1

declare void @_ZN8Workload12index_insertEP9IndexHashmP5row_tl(ptr noundef nonnull align 8 dereferenceable(120), ptr noundef, i64 noundef, ptr noundef, i64 noundef) local_unnamed_addr #1

declare noundef i64 @_Z10wh_to_partm(i64 noundef) local_unnamed_addr #1

declare noundef i64 @_Z15MakeAlphaStringiiPc(i32 noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

declare noundef i64 @_Z16MakeNumberStringiiPc(i32 noundef, i32 noundef, ptr noundef) local_unnamed_addr #1

declare void @_ZN5row_t9set_valueEid(ptr noundef nonnull align 8 dereferenceable(64), i32 noundef, double noundef) local_unnamed_addr #1

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN12TPCCWorkload13init_tab_distEm(ptr noundef nonnull align 8 dereferenceable(296) %0, i64 noundef %1) local_unnamed_addr #3 align 2 {
  %3 = alloca ptr, align 8
  %4 = alloca i64, align 8
  %5 = alloca [10 x i8], align 1
  %6 = alloca [20 x i8], align 16
  %7 = alloca [2 x i8], align 1
  %8 = alloca [9 x i8], align 1
  %9 = load i32, ptr @g_dist_per_wh, align 4, !tbaa !5
  %.not10 = icmp eq i32 %9, 0
  br i1 %.not10, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %2
  %10 = getelementptr inbounds i8, ptr %0, i64 128
  %11 = getelementptr inbounds i8, ptr %0, i64 208
  br label %12

._crit_edge:                                      ; preds = %12, %2
  ret void

12:                                               ; preds = %.lr.ph, %12
  %.011 = phi i64 [ 1, %.lr.ph ], [ %40, %12 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #4
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %4) #4
  %13 = load ptr, ptr %10, align 8, !tbaa !9
  %14 = call noundef i32 @_ZN7table_t11get_new_rowERP5row_tmRm(ptr noundef nonnull align 8 dereferenceable(68) %13, ptr noundef nonnull align 8 dereferenceable(8) %3, i64 noundef 0, ptr noundef nonnull align 8 dereferenceable(8) %4)
  %15 = load ptr, ptr %3, align 8, !tbaa !25
  call void @_ZN5row_t15set_primary_keyEm(ptr noundef nonnull align 8 dereferenceable(64) %15, i64 noundef %.011)
  %16 = load ptr, ptr %3, align 8, !tbaa !25
  call void @_ZN5row_t9set_valueEim(ptr noundef nonnull align 8 dereferenceable(64) %16, i32 noundef 0, i64 noundef %.011)
  %17 = load ptr, ptr %3, align 8, !tbaa !25
  call void @_ZN5row_t9set_valueEim(ptr noundef nonnull align 8 dereferenceable(64) %17, i32 noundef 1, i64 noundef %1)
  call void @llvm.lifetime.start.p0(i64 10, ptr nonnull %5) #4
  %18 = call noundef i64 @_Z15MakeAlphaStringiiPc(i32 noundef 6, i32 noundef 10, ptr noundef nonnull %5)
  %19 = load ptr, ptr %3, align 8, !tbaa !25
  call void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64) %19, i32 noundef 2, ptr noundef nonnull %5)
  call void @llvm.lifetime.start.p0(i64 20, ptr nonnull %6) #4
  %20 = call noundef i64 @_Z15MakeAlphaStringiiPc(i32 noundef 10, i32 noundef 20, ptr noundef nonnull %6)
  %21 = load ptr, ptr %3, align 8, !tbaa !25
  call void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64) %21, i32 noundef 3, ptr noundef nonnull %6)
  %22 = call noundef i64 @_Z15MakeAlphaStringiiPc(i32 noundef 10, i32 noundef 20, ptr noundef nonnull %6)
  %23 = load ptr, ptr %3, align 8, !tbaa !25
  call void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64) %23, i32 noundef 4, ptr noundef nonnull %6)
  %24 = call noundef i64 @_Z15MakeAlphaStringiiPc(i32 noundef 10, i32 noundef 20, ptr noundef nonnull %6)
  %25 = load ptr, ptr %3, align 8, !tbaa !25
  call void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64) %25, i32 noundef 5, ptr noundef nonnull %6)
  call void @llvm.lifetime.start.p0(i64 2, ptr nonnull %7) #4
  %26 = call noundef i64 @_Z15MakeAlphaStringiiPc(i32 noundef 2, i32 noundef 2, ptr noundef nonnull %7)
  %27 = load ptr, ptr %3, align 8, !tbaa !25
  call void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64) %27, i32 noundef 6, ptr noundef nonnull %7)
  call void @llvm.lifetime.start.p0(i64 9, ptr nonnull %8) #4
  %28 = call noundef i64 @_Z16MakeNumberStringiiPc(i32 noundef 9, i32 noundef 9, ptr noundef nonnull %8)
  %29 = load ptr, ptr %3, align 8, !tbaa !25
  call void @_ZN5row_t9set_valueEiPv(ptr noundef nonnull align 8 dereferenceable(64) %29, i32 noundef 7, ptr noundef nonnull %8)
  %30 = call noundef i64 @_Z5URandmm(i64 noundef 0, i64 noundef 200)
  %31 = uitofp i64 %30 to double
  %32 = fdiv double %31, 1.000000e+03
  %33 = load ptr, ptr %3, align 8, !tbaa !25
  call void @_ZN5row_t9set_valueEid(ptr noundef nonnull align 8 dereferenceable(64) %33, i32 noundef 8, double noundef %32)
  %34 = load ptr, ptr %3, align 8, !tbaa !25
  call void @_ZN5row_t9set_valueEid(ptr noundef nonnull align 8 dereferenceable(64) %34, i32 noundef 9, double noundef 3.000000e+04)
  %35 = load ptr, ptr %3, align 8, !tbaa !25
  call void @_ZN5row_t9set_valueEii(ptr noundef nonnull align 8 dereferenceable(64) %35, i32 noundef 10, i32 noundef 3001)
  %36 = load ptr, ptr %11, align 8, !tbaa !26
  %37 = call noundef i64 @_Z7distKeymm(i64 noundef %.011, i64 noundef %1)
  %38 = load ptr, ptr %3, align 8, !tbaa !25
  %39 = call noundef i64 @_Z10wh_to_partm(i64 noundef %1)
  call void @_ZN8Workload12index_insertEP9IndexHashmP5row_tl(ptr noundef nonnull align 8 dereferenceable(120) %0, ptr noundef %36, i64 noundef %37, ptr noundef %38, i64 noundef %39)
  call void @llvm.lifetime.end.p0(i64 9, ptr nonnull %8) #4
  call void @llvm.lifetime.end.p0(i64 2, ptr nonnull %7) #4
  call void @llvm.lifetime.end.p0(i64 20, ptr nonnull %6) #4
  call void @llvm.lifetime.end.p0(i64 10, ptr nonnull %5) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %4) #4
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #4
  %40 = add nuw nsw i64 %.011, 1
  %41 = load i32, ptr @g_dist_per_wh, align 4, !tbaa !5
  %42 = zext i32 %41 to i64
  %.not.not = icmp ult i64 %.011, %42
  br i1 %.not.not, label %12, label %._crit_edge, !llvm.loop !27
}

declare void @_ZN5row_t9set_valueEii(ptr noundef nonnull align 8 dereferenceable(64), i32 noundef, i32 noundef) local_unnamed_addr #1

declare noundef i64 @_Z7distKeymm(i64 noundef, i64 noundef) local_unnamed_addr #1

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { mustprogress 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 = { mustprogress 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 #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, !6, i64 0}
!6 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !20, i64 128}
!10 = !{!"_ZTS12TPCCWorkload", !11, i64 0, !20, i64 120, !20, i64 128, !20, i64 136, !20, i64 144, !20, i64 152, !20, i64 160, !20, i64 168, !20, i64 176, !20, i64 184, !20, i64 192, !20, i64 200, !20, i64 208, !20, i64 216, !20, i64 224, !20, i64 232, !20, i64 240, !20, i64 248, !20, i64 256, !20, i64 264, !21, i64 272, !6, i64 280, !20, i64 288}
!11 = !{!"_ZTS8Workload", !12, i64 8, !22, i64 56, !21, i64 104, !21, i64 112}
!12 = !{!"_ZTSSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEP7table_tSt4lessIS5_ESaISt4pairIKS5_S7_EEE", !13, i64 0}
!13 = !{!"_ZTSSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_P7table_tESt10_Select1stISA_ESt4lessIS5_ESaISA_EE", !14, i64 0}
!14 = !{!"_ZTSNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_P7table_tESt10_Select1stISA_ESt4lessIS5_ESaISA_EE13_Rb_tree_implISE_Lb1EEE", !15, i64 0, !17, i64 8}
!15 = !{!"_ZTSSt20_Rb_tree_key_compareISt4lessINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEEE", !16, i64 0}
!16 = !{!"_ZTSSt4lessINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEE"}
!17 = !{!"_ZTSSt15_Rb_tree_header", !18, i64 0, !21, i64 32}
!18 = !{!"_ZTSSt18_Rb_tree_node_base", !19, i64 0, !20, i64 8, !20, i64 16, !20, i64 24}
!19 = !{!"_ZTSSt14_Rb_tree_color", !7, i64 0}
!20 = !{!"any pointer", !7, i64 0}
!21 = !{!"long", !7, i64 0}
!22 = !{!"_ZTSSt3mapINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEEP9IndexHashSt4lessIS5_ESaISt4pairIKS5_S7_EEE", !23, i64 0}
!23 = !{!"_ZTSSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_P9IndexHashESt10_Select1stISA_ESt4lessIS5_ESaISA_EE", !24, i64 0}
!24 = !{!"_ZTSNSt8_Rb_treeINSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEESt4pairIKS5_P9IndexHashESt10_Select1stISA_ESt4lessIS5_ESaISA_EE13_Rb_tree_implISE_Lb1EEE", !15, i64 0, !17, i64 8}
!25 = !{!20, !20, i64 0}
!26 = !{!10, !20, i64 208}
!27 = distinct !{!27, !28}
!28 = !{!"llvm.loop.mustprogress"}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass