; LLVM IR from vczh/herodb :: Kernel/Source (Vlpp)

; 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.vl::parsing::analyzing::Transition" = type { %"class.vl::Object", ptr, ptr, %"class.vl::collections::List.386", i32, i32, ptr }
%"class.vl::Object" = type { ptr }
%"class.vl::collections::List.386" = type { %"class.vl::collections::ListBase.base.392", %"class.vl::collections::IEnumerable.390" }
%"class.vl::collections::ListBase.base.392" = type <{ %"class.vl::collections::ArrayBase.base.391", i64, i8 }>
%"class.vl::collections::ArrayBase.base.391" = type { %"class.vl::collections::ListStore.389", ptr, i64 }
%"class.vl::collections::ListStore.389" = type { %"class.vl::Object" }
%"class.vl::collections::IEnumerable.390" = type { %"class.vl::Interface" }
%"class.vl::Interface" = type { ptr }

; 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: mustprogress uwtable
declare dso_local noundef ptr @_ZN2vl7parsing9analyzing9Automaton16CreateTransitionEPNS1_5StateES4_(ptr noundef nonnull align 8 dereferenceable(224), ptr noundef, ptr noundef) #1 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef ptr @_ZN2vl7parsing9analyzing9Automaton14CopyTransitionEPNS1_5StateES4_PNS1_10TransitionE(ptr noundef nonnull align 8 dereferenceable(224) %0, ptr noundef %1, ptr noundef %2, ptr noundef %3) #1 align 2 {
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  store ptr %3, ptr %8, align 8, !tbaa !5
  %10 = load ptr, ptr %5, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #2
  %11 = load ptr, ptr %6, align 8, !tbaa !5
  %12 = load ptr, ptr %7, align 8, !tbaa !5
  %13 = call noundef ptr @_ZN2vl7parsing9analyzing9Automaton16CreateTransitionEPNS1_5StateES4_(ptr noundef nonnull align 8 dereferenceable(224) %10, ptr noundef %11, ptr noundef %12)
  store ptr %13, ptr %9, align 8, !tbaa !5
  %14 = load ptr, ptr %8, align 8, !tbaa !5
  %15 = getelementptr inbounds %"class.vl::parsing::analyzing::Transition", ptr %14, i32 0, i32 4
  %16 = load i32, ptr %15, align 8, !tbaa !9
  %17 = load ptr, ptr %9, align 8, !tbaa !5
  %18 = getelementptr inbounds %"class.vl::parsing::analyzing::Transition", ptr %17, i32 0, i32 4
  store i32 %16, ptr %18, align 8, !tbaa !9
  %19 = load ptr, ptr %8, align 8, !tbaa !5
  %20 = getelementptr inbounds %"class.vl::parsing::analyzing::Transition", ptr %19, i32 0, i32 5
  %21 = load i32, ptr %20, align 4, !tbaa !20
  %22 = load ptr, ptr %9, align 8, !tbaa !5
  %23 = getelementptr inbounds %"class.vl::parsing::analyzing::Transition", ptr %22, i32 0, i32 5
  store i32 %21, ptr %23, align 4, !tbaa !20
  %24 = load ptr, ptr %8, align 8, !tbaa !5
  %25 = getelementptr inbounds %"class.vl::parsing::analyzing::Transition", ptr %24, i32 0, i32 6
  %26 = load ptr, ptr %25, align 8, !tbaa !21
  %27 = load ptr, ptr %9, align 8, !tbaa !5
  %28 = getelementptr inbounds %"class.vl::parsing::analyzing::Transition", ptr %27, i32 0, i32 6
  store ptr %26, ptr %28, align 8, !tbaa !21
  %29 = load ptr, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #2
  ret ptr %29
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #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++ TBAA"}
!9 = !{!10, !18, i64 72}
!10 = !{!"_ZTSN2vl7parsing9analyzing10TransitionE", !11, i64 0, !6, i64 8, !6, i64 16, !12, i64 24, !18, i64 72, !19, i64 76, !6, i64 80}
!11 = !{!"_ZTSN2vl6ObjectE"}
!12 = !{!"_ZTSN2vl11collections4ListINS_3PtrINS_7parsing9analyzing6ActionEEEPS5_EE", !13, i64 0}
!13 = !{!"_ZTSN2vl11collections8ListBaseINS_3PtrINS_7parsing9analyzing6ActionEEEPS5_EE", !14, i64 0, !16, i64 24, !17, i64 32}
!14 = !{!"_ZTSN2vl11collections9ArrayBaseINS_3PtrINS_7parsing9analyzing6ActionEEEEE", !15, i64 0, !6, i64 8, !16, i64 16}
!15 = !{!"_ZTSN2vl11collections9ListStoreINS_3PtrINS_7parsing9analyzing6ActionEEELb0EEE", !11, i64 0}
!16 = !{!"long", !7, i64 0}
!17 = !{!"bool", !7, i64 0}
!18 = !{!"_ZTSN2vl7parsing9analyzing10Transition14TransitionTypeE", !7, i64 0}
!19 = !{!"_ZTSN2vl7parsing9analyzing10Transition18StackOperationTypeE", !7, i64 0}
!20 = !{!10, !19, i64 76}
!21 = !{!10, !6, i64 80}


; 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: mustprogress uwtable
declare dso_local noundef ptr @_ZN2vl7parsing9analyzing9Automaton16CreateTransitionEPNS1_5StateES4_(ptr noundef nonnull align 8 dereferenceable(224), ptr noundef, ptr noundef) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef ptr @_ZN2vl7parsing9analyzing9Automaton14CopyTransitionEPNS1_5StateES4_PNS1_10TransitionE(ptr noundef nonnull align 8 dereferenceable(224) %0, ptr noundef %1, ptr noundef %2, ptr nocapture noundef readonly %3) local_unnamed_addr #0 align 2 {
  %5 = tail call noundef ptr @_ZN2vl7parsing9analyzing9Automaton16CreateTransitionEPNS1_5StateES4_(ptr noundef nonnull align 8 dereferenceable(224) %0, ptr noundef %1, ptr noundef %2)
  %6 = getelementptr inbounds i8, ptr %3, i64 72
  %7 = getelementptr inbounds i8, ptr %5, i64 72
  %8 = load <2 x i32>, ptr %6, align 8, !tbaa !5
  store <2 x i32> %8, ptr %7, align 8, !tbaa !5
  %9 = getelementptr inbounds i8, ptr %3, i64 80
  %10 = load ptr, ptr %9, align 8, !tbaa !8
  %11 = getelementptr inbounds i8, ptr %5, i64 80
  store ptr %10, ptr %11, align 8, !tbaa !8
  ret ptr %5
}

attributes #0 = { 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" }

!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 = !{!"omnipotent char", !7, i64 0}
!7 = !{!"Simple C++ TBAA"}
!8 = !{!9, !11, i64 80}
!9 = !{!"_ZTSN2vl7parsing9analyzing10TransitionE", !10, i64 0, !11, i64 8, !11, i64 16, !12, i64 24, !18, i64 72, !19, i64 76, !11, i64 80}
!10 = !{!"_ZTSN2vl6ObjectE"}
!11 = !{!"any pointer", !6, i64 0}
!12 = !{!"_ZTSN2vl11collections4ListINS_3PtrINS_7parsing9analyzing6ActionEEEPS5_EE", !13, i64 0}
!13 = !{!"_ZTSN2vl11collections8ListBaseINS_3PtrINS_7parsing9analyzing6ActionEEEPS5_EE", !14, i64 0, !16, i64 24, !17, i64 32}
!14 = !{!"_ZTSN2vl11collections9ArrayBaseINS_3PtrINS_7parsing9analyzing6ActionEEEEE", !15, i64 0, !11, i64 8, !16, i64 16}
!15 = !{!"_ZTSN2vl11collections9ListStoreINS_3PtrINS_7parsing9analyzing6ActionEEELb0EEE", !10, i64 0}
!16 = !{!"long", !6, i64 0}
!17 = !{!"bool", !6, i64 0}
!18 = !{!"_ZTSN2vl7parsing9analyzing10Transition14TransitionTypeE", !6, i64 0}
!19 = !{!"_ZTSN2vl7parsing9analyzing10Transition18StackOperationTypeE", !6, i64 0}


; Effective O3 passes: GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,PostOrderFunctionAttrsPass,SLPVectorizerPass,SROAPass,TailCallElimPass