; LLVM IR from thepowersgang/mrustc :: src/expand/cfg.ll (Z14check_cfg_attrRKN3AST9AttributeE)

; 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.ParseState = type { i8, i8, i8, ptr, ptr, ptr }
%"class.std::vector.41" = type { %"struct.std::_Vector_base.42" }
%"struct.std::_Vector_base.42" = type { %"struct.std::_Vector_base<AST::Attribute, std::allocator<AST::Attribute>>::_Vector_impl" }
%"struct.std::_Vector_base<AST::Attribute, std::allocator<AST::Attribute>>::_Vector_impl" = type { %"struct.std::_Vector_base<AST::Attribute, std::allocator<AST::Attribute>>::_Vector_impl_data" }
%"struct.std::_Vector_base<AST::Attribute, std::allocator<AST::Attribute>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.TTStream = type { %class.TokenStream, %"class.std::vector.26", %struct.Span, i32, ptr }
%class.TokenStream = type { ptr, i8, %class.Token, %"class.Ident::Hygiene", i32, %"class.std::vector", %struct.ParseState }
%class.Token = type { ptr, i32, %"class.Token::Data", %class.Position, %"class.Ident::Hygiene" }
%"class.Token::Data" = type { i32, %"union.Token::Data::DataUnion" }
%"union.Token::Data::DataUnion" = type { %"class.std::__cxx11::basic_string" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%class.Position = type { %struct.Span, %class.RcString, i32, i32 }
%class.RcString = type { ptr }
%"class.Ident::Hygiene" = type { %"class.std::unique_ptr" }
%"class.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.22" }
%"struct.std::_Head_base.22" = type { ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<TokenStream::LookaheadEnt, std::allocator<TokenStream::LookaheadEnt>>::_Vector_impl" }
%"struct.std::_Vector_base<TokenStream::LookaheadEnt, std::allocator<TokenStream::LookaheadEnt>>::_Vector_impl" = type { %"struct.std::_Vector_base<TokenStream::LookaheadEnt, std::allocator<TokenStream::LookaheadEnt>>::_Vector_impl_data" }
%"struct.std::_Vector_base<TokenStream::LookaheadEnt, std::allocator<TokenStream::LookaheadEnt>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.26" = type { %"struct.std::_Vector_base.27" }
%"struct.std::_Vector_base.27" = type { %"struct.std::_Vector_base<std::pair<unsigned int, const TokenTree *>, std::allocator<std::pair<unsigned int, const TokenTree *>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<unsigned int, const TokenTree *>, std::allocator<std::pair<unsigned int, const TokenTree *>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<unsigned int, const TokenTree *>, std::allocator<std::pair<unsigned int, const TokenTree *>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<unsigned int, const TokenTree *>, std::allocator<std::pair<unsigned int, const TokenTree *>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%struct.Span = type { ptr }
%"class.AST::Attribute" = type <{ %struct.Span, %"struct.AST::AttributeName", %class.TokenTree, i8, [7 x i8] }>
%"struct.AST::AttributeName" = type { %"class.std::vector.31" }
%"class.std::vector.31" = type { %"struct.std::_Vector_base.32" }
%"struct.std::_Vector_base.32" = type { %"struct.std::_Vector_base<RcString, std::allocator<RcString>>::_Vector_impl" }
%"struct.std::_Vector_base<RcString, std::allocator<RcString>>::_Vector_impl" = type { %"struct.std::_Vector_base<RcString, std::allocator<RcString>>::_Vector_impl_data" }
%"struct.std::_Vector_base<RcString, std::allocator<RcString>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.TokenTree = type { ptr, i32, %"class.Ident::Hygiene", %class.Token, %"class.std::vector.36" }
%"class.std::vector.36" = type { %"struct.std::_Vector_base.37" }
%"struct.std::_Vector_base.37" = type { %"struct.std::_Vector_base<TokenTree, std::allocator<TokenTree>>::_Vector_impl" }
%"struct.std::_Vector_base<TokenTree, std::allocator<TokenTree>>::_Vector_impl" = type { %"struct.std::_Vector_base<TokenTree, std::allocator<TokenTree>>::_Vector_impl_data" }
%"struct.std::_Vector_base<TokenTree, std::allocator<TokenTree>>::_Vector_impl_data" = type { ptr, ptr, 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

declare i32 @__gxx_personality_v0(...)

declare void @_ZN5TokenC1Ev(ptr noundef nonnull align 8 dereferenceable(88)) unnamed_addr #1

; Function Attrs: nounwind
declare void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88)) unnamed_addr #2

declare noundef i32 @_ZN11TokenStream9lookaheadEj(ptr noundef nonnull align 8 dereferenceable(176), i32 noundef) #1

; Function Attrs: mustprogress uwtable
declare hidden noundef zeroext i1 @_ZN12_GLOBAL__N_115check_cfg_innerER11TokenStream(ptr noundef nonnull align 8 dereferenceable(176)) #3

declare void @_ZN4SpanC1ERKS_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN10ParseStateC2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #4 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(136) ptr @_ZNK3AST9Attribute4dataEv(ptr noundef nonnull align 8 dereferenceable(169)) #4 align 2

declare void @_ZN8TTStreamC1E4Span10ParseStateRK9TokenTree(ptr noundef nonnull align 8 dereferenceable(224), ptr noundef, ptr noundef byval(%struct.ParseState) align 8, ptr noundef nonnull align 8 dereferenceable(136)) unnamed_addr #1

; Function Attrs: nounwind
declare void @_ZN4SpanD1Ev(ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #2

; Function Attrs: nounwind
declare void @_ZN8TTStreamD1Ev(ptr noundef nonnull align 8 dereferenceable(224)) unnamed_addr #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZNK3AST9Attribute4spanEv(ptr noundef nonnull align 8 dereferenceable(169)) #4 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_Z14check_cfg_attrRKN3AST9AttributeE(ptr dead_on_unwind noalias writable sret(%"class.std::vector.41") align 8 %0, ptr noundef nonnull align 8 dereferenceable(169) %1) #3 personality ptr @__gxx_personality_v0 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca %class.TTStream, align 8
  %6 = alloca %struct.Span, align 8
  %7 = alloca %struct.ParseState, align 8
  %8 = alloca ptr, align 8
  %9 = alloca i32, align 4
  %10 = alloca %class.Token, align 8
  %11 = alloca %"class.std::vector.41", align 8
  %12 = alloca %class.Token, align 8
  %13 = alloca i8, align 1
  %14 = alloca %class.Token, align 8
  %15 = alloca %"class.AST::Attribute", align 8
  %16 = alloca %class.Token, align 8
  %17 = alloca %class.Token, align 8
  %18 = alloca i32, align 4
  store ptr %0, ptr %3, align 8
  store ptr %1, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 224, ptr %5) #7
  %19 = load ptr, ptr %4, align 8, !tbaa !5
  %20 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK3AST9Attribute4spanEv(ptr noundef nonnull align 8 dereferenceable(169) %19)
  call void @_ZN4SpanC1ERKS_(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(8) %20)
  invoke void @_ZN10ParseStateC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %7)
          to label %21 unwind label %39

21:                                               ; preds = %2
  %22 = load ptr, ptr %4, align 8, !tbaa !5
  %23 = invoke noundef nonnull align 8 dereferenceable(136) ptr @_ZNK3AST9Attribute4dataEv(ptr noundef nonnull align 8 dereferenceable(169) %22)
          to label %24 unwind label %39

24:                                               ; preds = %21
  invoke void @_ZN8TTStreamC1E4Span10ParseStateRK9TokenTree(ptr noundef nonnull align 8 dereferenceable(224) %5, ptr noundef %6, ptr noundef byval(%struct.ParseState) align 8 %7, ptr noundef nonnull align 8 dereferenceable(136) %23)
          to label %25 unwind label %39

25:                                               ; preds = %24
  call void @_ZN4SpanD1Ev(ptr noundef nonnull align 8 dereferenceable(8) %6) #7
  call void @llvm.lifetime.start.p0(i64 88, ptr %10) #7
  invoke void @_ZN5TokenC1Ev(ptr noundef nonnull align 8 dereferenceable(88) %10)
          to label %26 unwind label %43

26:                                               ; preds = %25
  call void @llvm.lifetime.start.p0(i64 24, ptr %11) #7
  call void @_ZNSt6vectorIN3AST9AttributeESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %11) #7
  invoke void @_ZN11TokenStream13getTokenCheckE10eTokenType(ptr dead_on_unwind writable sret(%class.Token) align 8 %12, ptr noundef nonnull align 8 dereferenceable(176) %5, i32 noundef 23)
          to label %27 unwind label %47

27:                                               ; preds = %26
  call void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88) %12) #7
  call void @llvm.lifetime.start.p0(i64 1, ptr %13) #7
  %28 = invoke noundef zeroext i1 @_ZN12_GLOBAL__N_115check_cfg_innerER11TokenStream(ptr noundef nonnull align 8 dereferenceable(176) %5)
          to label %29 unwind label %51

29:                                               ; preds = %27
  %30 = zext i1 %28 to i8
  store i8 %30, ptr %13, align 1, !tbaa !9
  br label %31

31:                                               ; preds = %38, %29
  %32 = invoke noundef i32 @_ZN11TokenStream9lookaheadEj(ptr noundef nonnull align 8 dereferenceable(176) %5, i32 noundef 0)
          to label %33 unwind label %51

33:                                               ; preds = %31
  %34 = icmp eq i32 %32, 31
  br i1 %34, label %35, label %64

35:                                               ; preds = %33
  invoke void @_ZN11TokenStream13getTokenCheckE10eTokenType(ptr dead_on_unwind writable sret(%class.Token) align 8 %14, ptr noundef nonnull align 8 dereferenceable(176) %5, i32 noundef 31)
          to label %36 unwind label %51

36:                                               ; preds = %35
  call void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88) %14) #7
  call void @llvm.lifetime.start.p0(i64 176, ptr %15) #7
  invoke void @_Z14Parse_MetaItemR11TokenStream(ptr dead_on_unwind writable sret(%"class.AST::Attribute") align 8 %15, ptr noundef nonnull align 8 dereferenceable(176) %5)
          to label %37 unwind label %55

37:                                               ; preds = %36
  invoke void @_ZNSt6vectorIN3AST9AttributeESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24) %11, ptr noundef nonnull align 8 dereferenceable(169) %15)
          to label %38 unwind label %59

38:                                               ; preds = %37
  call void @_ZN3AST9AttributeD2Ev(ptr noundef nonnull align 8 dereferenceable(169) %15) #7
  call void @llvm.lifetime.end.p0(i64 176, ptr %15) #7
  br label %31, !llvm.loop !11

39:                                               ; preds = %24, %21, %2
  %40 = landingpad { ptr, i32 }
          cleanup
  %41 = extractvalue { ptr, i32 } %40, 0
  store ptr %41, ptr %8, align 8
  %42 = extractvalue { ptr, i32 } %40, 1
  store i32 %42, ptr %9, align 4
  call void @_ZN4SpanD1Ev(ptr noundef nonnull align 8 dereferenceable(8) %6) #7
  br label %75

43:                                               ; preds = %25
  %44 = landingpad { ptr, i32 }
          cleanup
  %45 = extractvalue { ptr, i32 } %44, 0
  store ptr %45, ptr %8, align 8
  %46 = extractvalue { ptr, i32 } %44, 1
  store i32 %46, ptr %9, align 4
  br label %74

47:                                               ; preds = %26
  %48 = landingpad { ptr, i32 }
          cleanup
  %49 = extractvalue { ptr, i32 } %48, 0
  store ptr %49, ptr %8, align 8
  %50 = extractvalue { ptr, i32 } %48, 1
  store i32 %50, ptr %9, align 4
  br label %73

51:                                               ; preds = %65, %64, %35, %31, %27
  %52 = landingpad { ptr, i32 }
          cleanup
  %53 = extractvalue { ptr, i32 } %52, 0
  store ptr %53, ptr %8, align 8
  %54 = extractvalue { ptr, i32 } %52, 1
  store i32 %54, ptr %9, align 4
  br label %72

55:                                               ; preds = %36
  %56 = landingpad { ptr, i32 }
          cleanup
  %57 = extractvalue { ptr, i32 } %56, 0
  store ptr %57, ptr %8, align 8
  %58 = extractvalue { ptr, i32 } %56, 1
  store i32 %58, ptr %9, align 4
  br label %63

59:                                               ; preds = %37
  %60 = landingpad { ptr, i32 }
          cleanup
  %61 = extractvalue { ptr, i32 } %60, 0
  store ptr %61, ptr %8, align 8
  %62 = extractvalue { ptr, i32 } %60, 1
  store i32 %62, ptr %9, align 4
  call void @_ZN3AST9AttributeD2Ev(ptr noundef nonnull align 8 dereferenceable(169) %15) #7
  br label %63

63:                                               ; preds = %59, %55
  call void @llvm.lifetime.end.p0(i64 176, ptr %15) #7
  br label %72

64:                                               ; preds = %33
  invoke void @_ZN11TokenStream13getTokenCheckE10eTokenType(ptr dead_on_unwind writable sret(%class.Token) align 8 %16, ptr noundef nonnull align 8 dereferenceable(176) %5, i32 noundef 24)
          to label %65 unwind label %51

65:                                               ; preds = %64
  call void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88) %16) #7
  invoke void @_ZN11TokenStream13getTokenCheckE10eTokenType(ptr dead_on_unwind writable sret(%class.Token) align 8 %17, ptr noundef nonnull align 8 dereferenceable(176) %5, i32 noundef 1)
          to label %66 unwind label %51

66:                                               ; preds = %65
  call void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88) %17) #7
  %67 = load i8, ptr %13, align 1, !tbaa !9, !range !13, !noundef !14
  %68 = trunc i8 %67 to i1
  br i1 %68, label %69, label %70

69:                                               ; preds = %66
  call void @_ZNSt6vectorIN3AST9AttributeESaIS1_EEC2EOS3_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 8 dereferenceable(24) %11) #7
  store i32 1, ptr %18, align 4
  br label %71

70:                                               ; preds = %66
  call void @llvm.memset.p0.i64(ptr align 8 %0, i8 0, i64 24, i1 false)
  call void @_ZNSt6vectorIN3AST9AttributeESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %0) #7
  store i32 1, ptr %18, align 4
  br label %71

71:                                               ; preds = %70, %69
  call void @llvm.lifetime.end.p0(i64 1, ptr %13) #7
  call void @_ZNSt6vectorIN3AST9AttributeESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %11) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %11) #7
  call void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88) %10) #7
  call void @llvm.lifetime.end.p0(i64 88, ptr %10) #7
  call void @_ZN8TTStreamD1Ev(ptr noundef nonnull align 8 dereferenceable(224) %5) #7
  call void @llvm.lifetime.end.p0(i64 224, ptr %5) #7
  ret void

72:                                               ; preds = %63, %51
  call void @llvm.lifetime.end.p0(i64 1, ptr %13) #7
  br label %73

73:                                               ; preds = %72, %47
  call void @_ZNSt6vectorIN3AST9AttributeESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %11) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr %11) #7
  call void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88) %10) #7
  br label %74

74:                                               ; preds = %73, %43
  call void @llvm.lifetime.end.p0(i64 88, ptr %10) #7
  call void @_ZN8TTStreamD1Ev(ptr noundef nonnull align 8 dereferenceable(224) %5) #7
  br label %75

75:                                               ; preds = %74, %39
  call void @llvm.lifetime.end.p0(i64 224, ptr %5) #7
  br label %76

76:                                               ; preds = %75
  %77 = load ptr, ptr %8, align 8
  %78 = load i32, ptr %9, align 4
  %79 = insertvalue { ptr, i32 } poison, ptr %77, 0
  %80 = insertvalue { ptr, i32 } %79, i32 %78, 1
  resume { ptr, i32 } %80
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIN3AST9AttributeESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #4 align 2

declare void @_ZN11TokenStream13getTokenCheckE10eTokenType(ptr dead_on_unwind writable sret(%class.Token) align 8, ptr noundef nonnull align 8 dereferenceable(176), i32 noundef) #1

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIN3AST9AttributeESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(169)) #3 align 2

declare void @_Z14Parse_MetaItemR11TokenStream(ptr dead_on_unwind writable sret(%"class.AST::Attribute") align 8, ptr noundef nonnull align 8 dereferenceable(176)) #1

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3AST9AttributeD2Ev(ptr noundef nonnull align 8 dereferenceable(169)) unnamed_addr #5 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIN3AST9AttributeESaIS1_EEC2EOS3_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #4 align 2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #6

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIN3AST9AttributeESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #4 align 2

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 = { nounwind "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 = { 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 #5 = { inlinehint 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 #6 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #7 = { 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 = !{!"bool", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{i8 0, i8 2}
!14 = !{}


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

%struct.ParseState = type { i8, i8, i8, ptr, ptr, ptr }
%"class.std::vector.41" = type { %"struct.std::_Vector_base.42" }
%"struct.std::_Vector_base.42" = type { %"struct.std::_Vector_base<AST::Attribute, std::allocator<AST::Attribute>>::_Vector_impl" }
%"struct.std::_Vector_base<AST::Attribute, std::allocator<AST::Attribute>>::_Vector_impl" = type { %"struct.std::_Vector_base<AST::Attribute, std::allocator<AST::Attribute>>::_Vector_impl_data" }
%"struct.std::_Vector_base<AST::Attribute, std::allocator<AST::Attribute>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.TTStream = type { %class.TokenStream, %"class.std::vector.26", %struct.Span, i32, ptr }
%class.TokenStream = type { ptr, i8, %class.Token, %"class.Ident::Hygiene", i32, %"class.std::vector", %struct.ParseState }
%class.Token = type { ptr, i32, %"class.Token::Data", %class.Position, %"class.Ident::Hygiene" }
%"class.Token::Data" = type { i32, %"union.Token::Data::DataUnion" }
%"union.Token::Data::DataUnion" = type { %"class.std::__cxx11::basic_string" }
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%class.Position = type { %struct.Span, %class.RcString, i32, i32 }
%class.RcString = type { ptr }
%"class.Ident::Hygiene" = type { %"class.std::unique_ptr" }
%"class.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.22" }
%"struct.std::_Head_base.22" = type { ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<TokenStream::LookaheadEnt, std::allocator<TokenStream::LookaheadEnt>>::_Vector_impl" }
%"struct.std::_Vector_base<TokenStream::LookaheadEnt, std::allocator<TokenStream::LookaheadEnt>>::_Vector_impl" = type { %"struct.std::_Vector_base<TokenStream::LookaheadEnt, std::allocator<TokenStream::LookaheadEnt>>::_Vector_impl_data" }
%"struct.std::_Vector_base<TokenStream::LookaheadEnt, std::allocator<TokenStream::LookaheadEnt>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.26" = type { %"struct.std::_Vector_base.27" }
%"struct.std::_Vector_base.27" = type { %"struct.std::_Vector_base<std::pair<unsigned int, const TokenTree *>, std::allocator<std::pair<unsigned int, const TokenTree *>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<unsigned int, const TokenTree *>, std::allocator<std::pair<unsigned int, const TokenTree *>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<unsigned int, const TokenTree *>, std::allocator<std::pair<unsigned int, const TokenTree *>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<unsigned int, const TokenTree *>, std::allocator<std::pair<unsigned int, const TokenTree *>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%struct.Span = type { ptr }
%"class.AST::Attribute" = type <{ %struct.Span, %"struct.AST::AttributeName", %class.TokenTree, i8, [7 x i8] }>
%"struct.AST::AttributeName" = type { %"class.std::vector.31" }
%"class.std::vector.31" = type { %"struct.std::_Vector_base.32" }
%"struct.std::_Vector_base.32" = type { %"struct.std::_Vector_base<RcString, std::allocator<RcString>>::_Vector_impl" }
%"struct.std::_Vector_base<RcString, std::allocator<RcString>>::_Vector_impl" = type { %"struct.std::_Vector_base<RcString, std::allocator<RcString>>::_Vector_impl_data" }
%"struct.std::_Vector_base<RcString, std::allocator<RcString>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%class.TokenTree = type { ptr, i32, %"class.Ident::Hygiene", %class.Token, %"class.std::vector.36" }
%"class.std::vector.36" = type { %"struct.std::_Vector_base.37" }
%"struct.std::_Vector_base.37" = type { %"struct.std::_Vector_base<TokenTree, std::allocator<TokenTree>>::_Vector_impl" }
%"struct.std::_Vector_base<TokenTree, std::allocator<TokenTree>>::_Vector_impl" = type { %"struct.std::_Vector_base<TokenTree, std::allocator<TokenTree>>::_Vector_impl_data" }
%"struct.std::_Vector_base<TokenTree, std::allocator<TokenTree>>::_Vector_impl_data" = type { ptr, ptr, ptr }

; 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 i32 @__gxx_personality_v0(...)

declare void @_ZN5TokenC1Ev(ptr noundef nonnull align 8 dereferenceable(88)) unnamed_addr #1

; Function Attrs: nounwind
declare void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88)) unnamed_addr #2

declare noundef i32 @_ZN11TokenStream9lookaheadEj(ptr noundef nonnull align 8 dereferenceable(176), i32 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress uwtable
declare hidden noundef zeroext i1 @_ZN12_GLOBAL__N_115check_cfg_innerER11TokenStream(ptr noundef nonnull align 8 dereferenceable(176)) local_unnamed_addr #3

declare void @_ZN4SpanC1ERKS_(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN10ParseStateC2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #4 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(136) ptr @_ZNK3AST9Attribute4dataEv(ptr noundef nonnull align 8 dereferenceable(169)) local_unnamed_addr #4 align 2

declare void @_ZN8TTStreamC1E4Span10ParseStateRK9TokenTree(ptr noundef nonnull align 8 dereferenceable(224), ptr noundef, ptr noundef byval(%struct.ParseState) align 8, ptr noundef nonnull align 8 dereferenceable(136)) unnamed_addr #1

; Function Attrs: nounwind
declare void @_ZN4SpanD1Ev(ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #2

; Function Attrs: nounwind
declare void @_ZN8TTStreamD1Ev(ptr noundef nonnull align 8 dereferenceable(224)) unnamed_addr #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 8 dereferenceable(8) ptr @_ZNK3AST9Attribute4spanEv(ptr noundef nonnull align 8 dereferenceable(169)) local_unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_Z14check_cfg_attrRKN3AST9AttributeE(ptr dead_on_unwind noalias writable sret(%"class.std::vector.41") align 8 %0, ptr noundef nonnull align 8 dereferenceable(169) %1) local_unnamed_addr #3 personality ptr @__gxx_personality_v0 {
  %3 = alloca %class.TTStream, align 8
  %4 = alloca %struct.Span, align 8
  %5 = alloca %struct.ParseState, align 8
  %6 = alloca %class.Token, align 8
  %7 = alloca %"class.std::vector.41", align 8
  %8 = alloca %class.Token, align 8
  %9 = alloca %class.Token, align 8
  %10 = alloca %"class.AST::Attribute", align 8
  %11 = alloca %class.Token, align 8
  %12 = alloca %class.Token, align 8
  call void @llvm.lifetime.start.p0(i64 224, ptr nonnull %3) #7
  %13 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNK3AST9Attribute4spanEv(ptr noundef nonnull align 8 dereferenceable(169) %1)
  call void @_ZN4SpanC1ERKS_(ptr noundef nonnull align 8 dereferenceable(8) %4, ptr noundef nonnull align 8 dereferenceable(8) %13)
  call void @_ZN10ParseStateC2Ev(ptr noundef nonnull align 8 dereferenceable(32) %5)
  %14 = call noundef nonnull align 8 dereferenceable(136) ptr @_ZNK3AST9Attribute4dataEv(ptr noundef nonnull align 8 dereferenceable(169) %1)
  invoke void @_ZN8TTStreamC1E4Span10ParseStateRK9TokenTree(ptr noundef nonnull align 8 dereferenceable(224) %3, ptr noundef nonnull %4, ptr noundef nonnull byval(%struct.ParseState) align 8 %5, ptr noundef nonnull align 8 dereferenceable(136) %14)
          to label %15 unwind label %26

15:                                               ; preds = %2
  call void @_ZN4SpanD1Ev(ptr noundef nonnull align 8 dereferenceable(8) %4) #7
  call void @llvm.lifetime.start.p0(i64 88, ptr nonnull %6) #7
  invoke void @_ZN5TokenC1Ev(ptr noundef nonnull align 8 dereferenceable(88) %6)
          to label %16 unwind label %28

16:                                               ; preds = %15
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #7
  call void @_ZNSt6vectorIN3AST9AttributeESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  invoke void @_ZN11TokenStream13getTokenCheckE10eTokenType(ptr dead_on_unwind nonnull writable sret(%class.Token) align 8 %8, ptr noundef nonnull align 8 dereferenceable(176) %3, i32 noundef 23)
          to label %17 unwind label %30

17:                                               ; preds = %16
  call void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88) %8) #7
  %18 = invoke noundef zeroext i1 @_ZN12_GLOBAL__N_115check_cfg_innerER11TokenStream(ptr noundef nonnull align 8 dereferenceable(176) %3)
          to label %.preheader unwind label %.loopexit.split-lp

.preheader:                                       ; preds = %17, %25
  %19 = invoke noundef i32 @_ZN11TokenStream9lookaheadEj(ptr noundef nonnull align 8 dereferenceable(176) %3, i32 noundef 0)
          to label %20 unwind label %.loopexit

20:                                               ; preds = %.preheader
  %21 = icmp eq i32 %19, 31
  br i1 %21, label %22, label %37

22:                                               ; preds = %20
  invoke void @_ZN11TokenStream13getTokenCheckE10eTokenType(ptr dead_on_unwind nonnull writable sret(%class.Token) align 8 %9, ptr noundef nonnull align 8 dereferenceable(176) %3, i32 noundef 31)
          to label %23 unwind label %.loopexit

23:                                               ; preds = %22
  call void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88) %9) #7
  call void @llvm.lifetime.start.p0(i64 176, ptr nonnull %10) #7
  invoke void @_Z14Parse_MetaItemR11TokenStream(ptr dead_on_unwind nonnull writable sret(%"class.AST::Attribute") align 8 %10, ptr noundef nonnull align 8 dereferenceable(176) %3)
          to label %24 unwind label %32

24:                                               ; preds = %23
  invoke void @_ZNSt6vectorIN3AST9AttributeESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(169) %10)
          to label %25 unwind label %34

25:                                               ; preds = %24
  call void @_ZN3AST9AttributeD2Ev(ptr noundef nonnull align 8 dereferenceable(169) %10) #7
  call void @llvm.lifetime.end.p0(i64 176, ptr nonnull %10) #7
  br label %.preheader, !llvm.loop !5

26:                                               ; preds = %2
  %27 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN4SpanD1Ev(ptr noundef nonnull align 8 dereferenceable(8) %4) #7
  br label %45

28:                                               ; preds = %15
  %29 = landingpad { ptr, i32 }
          cleanup
  br label %44

30:                                               ; preds = %16
  %31 = landingpad { ptr, i32 }
          cleanup
  br label %43

.loopexit:                                        ; preds = %.preheader, %22
  %lpad.loopexit = landingpad { ptr, i32 }
          cleanup
  br label %43

.loopexit.split-lp:                               ; preds = %17, %37, %38
  %lpad.loopexit.split-lp = landingpad { ptr, i32 }
          cleanup
  br label %43

32:                                               ; preds = %23
  %33 = landingpad { ptr, i32 }
          cleanup
  br label %36

34:                                               ; preds = %24
  %35 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN3AST9AttributeD2Ev(ptr noundef nonnull align 8 dereferenceable(169) %10) #7
  br label %36

36:                                               ; preds = %34, %32
  %.pn = phi { ptr, i32 } [ %35, %34 ], [ %33, %32 ]
  call void @llvm.lifetime.end.p0(i64 176, ptr nonnull %10) #7
  br label %43

37:                                               ; preds = %20
  invoke void @_ZN11TokenStream13getTokenCheckE10eTokenType(ptr dead_on_unwind nonnull writable sret(%class.Token) align 8 %11, ptr noundef nonnull align 8 dereferenceable(176) %3, i32 noundef 24)
          to label %38 unwind label %.loopexit.split-lp

38:                                               ; preds = %37
  call void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88) %11) #7
  invoke void @_ZN11TokenStream13getTokenCheckE10eTokenType(ptr dead_on_unwind nonnull writable sret(%class.Token) align 8 %12, ptr noundef nonnull align 8 dereferenceable(176) %3, i32 noundef 1)
          to label %39 unwind label %.loopexit.split-lp

39:                                               ; preds = %38
  call void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88) %12) #7
  br i1 %18, label %40, label %41

40:                                               ; preds = %39
  call void @_ZNSt6vectorIN3AST9AttributeESaIS1_EEC2EOS3_(ptr noundef nonnull align 8 dereferenceable(24) %0, ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  br label %42

41:                                               ; preds = %39
  call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %0, i8 0, i64 24, i1 false)
  call void @_ZNSt6vectorIN3AST9AttributeESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %0) #7
  br label %42

42:                                               ; preds = %41, %40
  call void @_ZNSt6vectorIN3AST9AttributeESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #7
  call void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88) %6) #7
  call void @llvm.lifetime.end.p0(i64 88, ptr nonnull %6) #7
  call void @_ZN8TTStreamD1Ev(ptr noundef nonnull align 8 dereferenceable(224) %3) #7
  call void @llvm.lifetime.end.p0(i64 224, ptr nonnull %3) #7
  ret void

43:                                               ; preds = %.loopexit, %.loopexit.split-lp, %36, %30
  %.pn.pn.pn = phi { ptr, i32 } [ %31, %30 ], [ %.pn, %36 ], [ %lpad.loopexit, %.loopexit ], [ %lpad.loopexit.split-lp, %.loopexit.split-lp ]
  call void @_ZNSt6vectorIN3AST9AttributeESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #7
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #7
  call void @_ZN5TokenD1Ev(ptr noundef nonnull align 8 dereferenceable(88) %6) #7
  br label %44

44:                                               ; preds = %43, %28
  %.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn.pn, %43 ], [ %29, %28 ]
  call void @llvm.lifetime.end.p0(i64 88, ptr nonnull %6) #7
  call void @_ZN8TTStreamD1Ev(ptr noundef nonnull align 8 dereferenceable(224) %3) #7
  br label %45

45:                                               ; preds = %44, %26
  %.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn.pn.pn.pn, %44 ], [ %27, %26 ]
  call void @llvm.lifetime.end.p0(i64 224, ptr nonnull %3) #7
  resume { ptr, i32 } %.pn.pn.pn.pn.pn
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIN3AST9AttributeESaIS1_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #4 align 2

declare void @_ZN11TokenStream13getTokenCheckE10eTokenType(ptr dead_on_unwind writable sret(%class.Token) align 8, ptr noundef nonnull align 8 dereferenceable(176), i32 noundef) local_unnamed_addr #1

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt6vectorIN3AST9AttributeESaIS1_EE9push_backEOS1_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(169)) local_unnamed_addr #3 align 2

declare void @_Z14Parse_MetaItemR11TokenStream(ptr dead_on_unwind writable sret(%"class.AST::Attribute") align 8, ptr noundef nonnull align 8 dereferenceable(176)) local_unnamed_addr #1

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN3AST9AttributeD2Ev(ptr noundef nonnull align 8 dereferenceable(169)) unnamed_addr #5 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIN3AST9AttributeESaIS1_EEC2EOS3_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #4 align 2

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: write)
declare void @llvm.memset.p0.i64(ptr nocapture writeonly, i8, i64, i1 immarg) #6

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt6vectorIN3AST9AttributeESaIS1_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #4 align 2

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 = { nounwind "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 = { 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 #5 = { inlinehint 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 #6 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #7 = { 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 = distinct !{!5, !6}
!6 = !{!"llvm.loop.mustprogress"}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass,TailCallElimPass