; LLVM IR from zsiciarz/aquila :: tests/source/SignalSource.ll (ZNK17SuiteSignalSource15TestLengthAlias7RunImplEv)

; 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.Aquila::SignalSource" = type { ptr, %"class.std::vector", double }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl" }
%"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl" = type { %"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl_data" }
%"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.UnitTest::TestDetails" = type <{ ptr, ptr, ptr, i32, i8, [3 x i8] }>
%"class.UnitTest::MemoryOutStream" = type { %"class.std::__cxx11::basic_ostringstream.base", %"class.std::__cxx11::basic_string", %"class.std::basic_ios" }
%"class.std::__cxx11::basic_ostringstream.base" = type { %"class.std::basic_ostream.base", %"class.std::__cxx11::basic_stringbuf" }
%"class.std::basic_ostream.base" = type { ptr }
%"class.std::__cxx11::basic_stringbuf" = type { %"class.std::basic_streambuf", i32, %"class.std::__cxx11::basic_string" }
%"class.std::basic_streambuf" = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, %"class.std::locale" }
%"class.std::locale" = type { ptr }
%"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.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }

@_ZN17SuiteSignalSource4dataE = external dso_local global %"class.Aquila::SignalSource", align 8
@_ZTISt9exception = external constant ptr
@.str.3 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [74 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [56 x i8], align 1

; Function Attrs: nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #0

declare i32 @__gxx_personality_v0(...)

; 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 void @_ZN8UnitTest10CheckEqualImmEEvRNS_11TestResultsERKT_RKT0_RKNS_11TestDetailsE(ptr noundef nonnull align 8 dereferenceable(21), ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(29)) #1

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7ResultsEv() #2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNK6Aquila12SignalSource6lengthEv(ptr noundef nonnull align 8 dereferenceable(40)) #1 align 2

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7DetailsEv() #2

declare void @_ZN8UnitTest11TestDetailsC1ERKS0_i(ptr noundef nonnull align 8 dereferenceable(29), ptr noundef nonnull align 8 dereferenceable(29), i32 noundef) unnamed_addr #2

; Function Attrs: nounwind memory(none)
declare i32 @llvm.eh.typeid.for.p0(ptr) #3

declare ptr @__cxa_begin_catch(ptr)

declare void @_ZN8UnitTest11TestResults13OnTestFailureERKNS_11TestDetailsEPKc(ptr noundef nonnull align 8 dereferenceable(21), ptr noundef nonnull align 8 dereferenceable(29), ptr noundef) #2

declare void @__cxa_end_catch()

; Function Attrs: noinline noreturn nounwind uwtable
declare hidden void @__clang_call_terminate(ptr noundef) #4

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN8UnitTest15MemoryOutStreamC1Ev(ptr noundef nonnull align 8 dereferenceable(144)) unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) #5

declare noundef ptr @_ZNK8UnitTest15MemoryOutStream7GetTextEv(ptr noundef nonnull align 8 dereferenceable(144)) #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN8UnitTest15MemoryOutStreamD1Ev(ptr noundef nonnull align 8 dereferenceable(144)) unnamed_addr #6 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK17SuiteSignalSource15TestLengthAlias7RunImplEv(ptr noundef nonnull align 8 dereferenceable(49) %0) unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca ptr, align 8
  %3 = alloca ptr, align 8
  %4 = alloca i32, align 4
  %5 = alloca i64, align 8
  %6 = alloca i64, align 8
  %7 = alloca %"class.UnitTest::TestDetails", align 8
  %8 = alloca %"class.UnitTest::TestDetails", align 8
  %9 = alloca ptr, align 8
  %10 = alloca %"class.UnitTest::MemoryOutStream", align 8
  %11 = alloca %"class.UnitTest::TestDetails", align 8
  store ptr %0, ptr %2, align 8, !tbaa !5
  %12 = load ptr, ptr %2, align 8
  br label %13

13:                                               ; preds = %1
  %14 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7ResultsEv()
          to label %15 unwind label %26

15:                                               ; preds = %13
  %16 = load ptr, ptr %14, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %5) #7
  %17 = invoke noundef i64 @_ZNK6Aquila12SignalSource15getSamplesCountEv(ptr noundef nonnull align 8 dereferenceable(40) @_ZN17SuiteSignalSource4dataE)
          to label %18 unwind label %30

18:                                               ; preds = %15
  store i64 %17, ptr %5, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #7
  %19 = invoke noundef i64 @_ZNK6Aquila12SignalSource6lengthEv(ptr noundef nonnull align 8 dereferenceable(40) @_ZN17SuiteSignalSource4dataE)
          to label %20 unwind label %34

20:                                               ; preds = %18
  store i64 %19, ptr %6, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 32, ptr %7) #7
  %21 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7DetailsEv()
          to label %22 unwind label %38

22:                                               ; preds = %20
  %23 = load ptr, ptr %21, align 8, !tbaa !5
  invoke void @_ZN8UnitTest11TestDetailsC1ERKS0_i(ptr noundef nonnull align 8 dereferenceable(29) %7, ptr noundef nonnull align 8 dereferenceable(29) %23, i32 noundef 46)
          to label %24 unwind label %38

24:                                               ; preds = %22
  invoke void @_ZN8UnitTest10CheckEqualImmEEvRNS_11TestResultsERKT_RKT0_RKNS_11TestDetailsE(ptr noundef nonnull align 8 dereferenceable(21) %16, ptr noundef nonnull align 8 dereferenceable(8) %5, ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull align 8 dereferenceable(29) %7)
          to label %25 unwind label %38

25:                                               ; preds = %24
  call void @llvm.lifetime.end.p0(i64 32, ptr %7) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #7
  br label %73

26:                                               ; preds = %13
  %27 = landingpad { ptr, i32 }
          catch ptr @_ZTISt9exception
          catch ptr null
  %28 = extractvalue { ptr, i32 } %27, 0
  store ptr %28, ptr %3, align 8
  %29 = extractvalue { ptr, i32 } %27, 1
  store i32 %29, ptr %4, align 4
  br label %44

30:                                               ; preds = %15
  %31 = landingpad { ptr, i32 }
          catch ptr @_ZTISt9exception
          catch ptr null
  %32 = extractvalue { ptr, i32 } %31, 0
  store ptr %32, ptr %3, align 8
  %33 = extractvalue { ptr, i32 } %31, 1
  store i32 %33, ptr %4, align 4
  br label %43

34:                                               ; preds = %18
  %35 = landingpad { ptr, i32 }
          catch ptr @_ZTISt9exception
          catch ptr null
  %36 = extractvalue { ptr, i32 } %35, 0
  store ptr %36, ptr %3, align 8
  %37 = extractvalue { ptr, i32 } %35, 1
  store i32 %37, ptr %4, align 4
  br label %42

38:                                               ; preds = %24, %22, %20
  %39 = landingpad { ptr, i32 }
          catch ptr @_ZTISt9exception
          catch ptr null
  %40 = extractvalue { ptr, i32 } %39, 0
  store ptr %40, ptr %3, align 8
  %41 = extractvalue { ptr, i32 } %39, 1
  store i32 %41, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 32, ptr %7) #7
  br label %42

42:                                               ; preds = %38, %34
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #7
  br label %43

43:                                               ; preds = %42, %30
  call void @llvm.lifetime.end.p0(i64 8, ptr %5) #7
  br label %44

44:                                               ; preds = %43, %26
  %45 = load i32, ptr %4, align 4
  %46 = call i32 @llvm.eh.typeid.for.p0(ptr @_ZTISt9exception) #7
  %47 = icmp eq i32 %45, %46
  br i1 %47, label %48, label %75

48:                                               ; preds = %44
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #7
  %49 = load ptr, ptr %3, align 8
  %50 = call ptr @__cxa_begin_catch(ptr %49) #7
  store ptr %50, ptr %9, align 8
  call void @llvm.lifetime.start.p0(i64 408, ptr %10) #7
  invoke void @_ZN8UnitTest15MemoryOutStreamC1Ev(ptr noundef nonnull align 8 dereferenceable(144) %10)
          to label %51 unwind label %96

51:                                               ; preds = %48
  %52 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %10, ptr noundef @.str.3)
          to label %53 unwind label %100

53:                                               ; preds = %51
  %54 = load ptr, ptr %9, align 8, !tbaa !5
  %55 = load ptr, ptr %54, align 8, !tbaa !11
  %56 = getelementptr inbounds ptr, ptr %55, i64 2
  %57 = load ptr, ptr %56, align 8
  %58 = call noundef ptr %57(ptr noundef nonnull align 8 dereferenceable(8) %54) #7
  %59 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %52, ptr noundef %58)
          to label %60 unwind label %100

60:                                               ; preds = %53
  %61 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %59, ptr noundef @.str.20)
          to label %62 unwind label %100

62:                                               ; preds = %60
  %63 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7ResultsEv()
          to label %64 unwind label %100

64:                                               ; preds = %62
  %65 = load ptr, ptr %63, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr %11) #7
  %66 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7DetailsEv()
          to label %67 unwind label %104

67:                                               ; preds = %64
  %68 = load ptr, ptr %66, align 8, !tbaa !5
  invoke void @_ZN8UnitTest11TestDetailsC1ERKS0_i(ptr noundef nonnull align 8 dereferenceable(29) %11, ptr noundef nonnull align 8 dereferenceable(29) %68, i32 noundef 46)
          to label %69 unwind label %104

69:                                               ; preds = %67
  %70 = invoke noundef ptr @_ZNK8UnitTest15MemoryOutStream7GetTextEv(ptr noundef nonnull align 8 dereferenceable(144) %10)
          to label %71 unwind label %104

71:                                               ; preds = %69
  invoke void @_ZN8UnitTest11TestResults13OnTestFailureERKNS_11TestDetailsEPKc(ptr noundef nonnull align 8 dereferenceable(21) %65, ptr noundef nonnull align 8 dereferenceable(29) %11, ptr noundef %70)
          to label %72 unwind label %104

72:                                               ; preds = %71
  call void @llvm.lifetime.end.p0(i64 32, ptr %11) #7
  call void @_ZN8UnitTest15MemoryOutStreamD1Ev(ptr noundef nonnull align 8 dereferenceable(144) %10) #7
  call void @llvm.lifetime.end.p0(i64 408, ptr %10) #7
  call void @__cxa_end_catch()
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #7
  br label %73

73:                                               ; preds = %85, %72, %25
  br label %74

74:                                               ; preds = %73
  ret void

75:                                               ; preds = %44
  %76 = load ptr, ptr %3, align 8
  %77 = call ptr @__cxa_begin_catch(ptr %76) #7
  %78 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7ResultsEv()
          to label %79 unwind label %86

79:                                               ; preds = %75
  %80 = load ptr, ptr %78, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr %8) #7
  %81 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7DetailsEv()
          to label %82 unwind label %90

82:                                               ; preds = %79
  %83 = load ptr, ptr %81, align 8, !tbaa !5
  invoke void @_ZN8UnitTest11TestDetailsC1ERKS0_i(ptr noundef nonnull align 8 dereferenceable(29) %8, ptr noundef nonnull align 8 dereferenceable(29) %83, i32 noundef 46)
          to label %84 unwind label %90

84:                                               ; preds = %82
  invoke void @_ZN8UnitTest11TestResults13OnTestFailureERKNS_11TestDetailsEPKc(ptr noundef nonnull align 8 dereferenceable(21) %80, ptr noundef nonnull align 8 dereferenceable(29) %8, ptr noundef @.str.19)
          to label %85 unwind label %90

85:                                               ; preds = %84
  call void @llvm.lifetime.end.p0(i64 32, ptr %8) #7
  call void @__cxa_end_catch()
  br label %73

86:                                               ; preds = %75
  %87 = landingpad { ptr, i32 }
          cleanup
  %88 = extractvalue { ptr, i32 } %87, 0
  store ptr %88, ptr %3, align 8
  %89 = extractvalue { ptr, i32 } %87, 1
  store i32 %89, ptr %4, align 4
  br label %94

90:                                               ; preds = %84, %82, %79
  %91 = landingpad { ptr, i32 }
          cleanup
  %92 = extractvalue { ptr, i32 } %91, 0
  store ptr %92, ptr %3, align 8
  %93 = extractvalue { ptr, i32 } %91, 1
  store i32 %93, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 32, ptr %8) #7
  br label %94

94:                                               ; preds = %90, %86
  invoke void @__cxa_end_catch()
          to label %95 unwind label %116

95:                                               ; preds = %94
  br label %111

96:                                               ; preds = %48
  %97 = landingpad { ptr, i32 }
          cleanup
  %98 = extractvalue { ptr, i32 } %97, 0
  store ptr %98, ptr %3, align 8
  %99 = extractvalue { ptr, i32 } %97, 1
  store i32 %99, ptr %4, align 4
  br label %109

100:                                              ; preds = %62, %60, %53, %51
  %101 = landingpad { ptr, i32 }
          cleanup
  %102 = extractvalue { ptr, i32 } %101, 0
  store ptr %102, ptr %3, align 8
  %103 = extractvalue { ptr, i32 } %101, 1
  store i32 %103, ptr %4, align 4
  br label %108

104:                                              ; preds = %71, %69, %67, %64
  %105 = landingpad { ptr, i32 }
          cleanup
  %106 = extractvalue { ptr, i32 } %105, 0
  store ptr %106, ptr %3, align 8
  %107 = extractvalue { ptr, i32 } %105, 1
  store i32 %107, ptr %4, align 4
  call void @llvm.lifetime.end.p0(i64 32, ptr %11) #7
  br label %108

108:                                              ; preds = %104, %100
  call void @_ZN8UnitTest15MemoryOutStreamD1Ev(ptr noundef nonnull align 8 dereferenceable(144) %10) #7
  br label %109

109:                                              ; preds = %108, %96
  call void @llvm.lifetime.end.p0(i64 408, ptr %10) #7
  invoke void @__cxa_end_catch()
          to label %110 unwind label %116

110:                                              ; preds = %109
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #7
  br label %111

111:                                              ; preds = %110, %95
  %112 = load ptr, ptr %3, align 8
  %113 = load i32, ptr %4, align 4
  %114 = insertvalue { ptr, i32 } poison, ptr %112, 0
  %115 = insertvalue { ptr, i32 } %114, i32 %113, 1
  resume { ptr, i32 } %115

116:                                              ; preds = %109, %94
  %117 = landingpad { ptr, i32 }
          catch ptr null
  %118 = extractvalue { ptr, i32 } %117, 0
  call void @__clang_call_terminate(ptr %118) #8
  unreachable
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNK6Aquila12SignalSource15getSamplesCountEv(ptr noundef nonnull align 8 dereferenceable(40)) unnamed_addr #6 align 2

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 = { "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 memory(none) }
attributes #4 = { noinline noreturn nounwind uwtable "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 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 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 #7 = { nounwind }
attributes #8 = { noreturn 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 = !{!"vtable pointer", !8, i64 0}


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

%"class.Aquila::SignalSource" = type { ptr, %"class.std::vector", double }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl" }
%"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl" = type { %"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl_data" }
%"struct.std::_Vector_base<double, std::allocator<double>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.UnitTest::TestDetails" = type <{ ptr, ptr, ptr, i32, i8, [3 x i8] }>
%"class.UnitTest::MemoryOutStream" = type { %"class.std::__cxx11::basic_ostringstream.base", %"class.std::__cxx11::basic_string", %"class.std::basic_ios" }
%"class.std::__cxx11::basic_ostringstream.base" = type { %"class.std::basic_ostream.base", %"class.std::__cxx11::basic_stringbuf" }
%"class.std::basic_ostream.base" = type { ptr }
%"class.std::__cxx11::basic_stringbuf" = type { %"class.std::basic_streambuf", i32, %"class.std::__cxx11::basic_string" }
%"class.std::basic_streambuf" = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, %"class.std::locale" }
%"class.std::locale" = type { ptr }
%"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.std::basic_ios" = type { %"class.std::ios_base", ptr, i8, i8, ptr, ptr, ptr, ptr }
%"class.std::ios_base" = type { ptr, i64, i64, i32, i32, i32, ptr, %"struct.std::ios_base::_Words", [8 x %"struct.std::ios_base::_Words"], i32, ptr, %"class.std::locale" }
%"struct.std::ios_base::_Words" = type { ptr, i64 }

@_ZN17SuiteSignalSource4dataE = external dso_local global %"class.Aquila::SignalSource", align 8
@_ZTISt9exception = external constant ptr
@.str.3 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.19 = external hidden unnamed_addr constant [74 x i8], align 1
@.str.20 = external hidden unnamed_addr constant [56 x i8], align 1

; Function Attrs: mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite)
declare void @llvm.lifetime.start.p0(i64 immarg, ptr nocapture) #0

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress 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 void @_ZN8UnitTest10CheckEqualImmEEvRNS_11TestResultsERKT_RKT0_RKNS_11TestDetailsE(ptr noundef nonnull align 8 dereferenceable(21), ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(8), ptr noundef nonnull align 8 dereferenceable(29)) local_unnamed_addr #1

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7ResultsEv() local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i64 @_ZNK6Aquila12SignalSource6lengthEv(ptr noundef nonnull align 8 dereferenceable(40)) local_unnamed_addr #1 align 2

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7DetailsEv() local_unnamed_addr #2

declare void @_ZN8UnitTest11TestDetailsC1ERKS0_i(ptr noundef nonnull align 8 dereferenceable(29), ptr noundef nonnull align 8 dereferenceable(29), i32 noundef) unnamed_addr #2

; Function Attrs: nofree nosync nounwind memory(none)
declare i32 @llvm.eh.typeid.for.p0(ptr) #3

declare ptr @__cxa_begin_catch(ptr) local_unnamed_addr

declare void @_ZN8UnitTest11TestResults13OnTestFailureERKNS_11TestDetailsEPKc(ptr noundef nonnull align 8 dereferenceable(21), ptr noundef nonnull align 8 dereferenceable(29), ptr noundef) local_unnamed_addr #2

declare void @__cxa_end_catch() local_unnamed_addr

; Function Attrs: noinline noreturn nounwind uwtable
declare hidden void @__clang_call_terminate(ptr noundef) local_unnamed_addr #4

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN8UnitTest15MemoryOutStreamC1Ev(ptr noundef nonnull align 8 dereferenceable(144)) unnamed_addr #1 align 2

; Function Attrs: inlinehint mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8), ptr noundef) local_unnamed_addr #5

declare noundef ptr @_ZNK8UnitTest15MemoryOutStream7GetTextEv(ptr noundef nonnull align 8 dereferenceable(144)) local_unnamed_addr #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN8UnitTest15MemoryOutStreamD1Ev(ptr noundef nonnull align 8 dereferenceable(144)) unnamed_addr #6 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK17SuiteSignalSource15TestLengthAlias7RunImplEv(ptr nocapture noundef nonnull readnone align 8 dereferenceable(49) %0) unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca i64, align 8
  %3 = alloca i64, align 8
  %4 = alloca %"class.UnitTest::TestDetails", align 8
  %5 = alloca %"class.UnitTest::TestDetails", align 8
  %6 = alloca %"class.UnitTest::MemoryOutStream", align 8
  %7 = alloca %"class.UnitTest::TestDetails", align 8
  %8 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7ResultsEv()
          to label %9 unwind label %19

9:                                                ; preds = %1
  %10 = load ptr, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %2) #7
  %11 = tail call noundef i64 @_ZNK6Aquila12SignalSource15getSamplesCountEv(ptr noundef nonnull align 8 dereferenceable(40) @_ZN17SuiteSignalSource4dataE)
  store i64 %11, ptr %2, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #7
  %12 = invoke noundef i64 @_ZNK6Aquila12SignalSource6lengthEv(ptr noundef nonnull align 8 dereferenceable(40) @_ZN17SuiteSignalSource4dataE)
          to label %13 unwind label %21

13:                                               ; preds = %9
  store i64 %12, ptr %3, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %4) #7
  %14 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7DetailsEv()
          to label %15 unwind label %23

15:                                               ; preds = %13
  %16 = load ptr, ptr %14, align 8, !tbaa !5
  invoke void @_ZN8UnitTest11TestDetailsC1ERKS0_i(ptr noundef nonnull align 8 dereferenceable(29) %4, ptr noundef nonnull align 8 dereferenceable(29) %16, i32 noundef 46)
          to label %17 unwind label %23

17:                                               ; preds = %15
  invoke void @_ZN8UnitTest10CheckEqualImmEEvRNS_11TestResultsERKT_RKT0_RKNS_11TestDetailsE(ptr noundef nonnull align 8 dereferenceable(21) %10, ptr noundef nonnull align 8 dereferenceable(8) %2, ptr noundef nonnull align 8 dereferenceable(8) %3, ptr noundef nonnull align 8 dereferenceable(29) %4)
          to label %18 unwind label %23

18:                                               ; preds = %17
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #7
  br label %52

19:                                               ; preds = %1
  %20 = landingpad { ptr, i32 }
          catch ptr @_ZTISt9exception
          catch ptr null
  br label %26

21:                                               ; preds = %9
  %22 = landingpad { ptr, i32 }
          catch ptr @_ZTISt9exception
          catch ptr null
  br label %25

23:                                               ; preds = %17, %15, %13
  %24 = landingpad { ptr, i32 }
          catch ptr @_ZTISt9exception
          catch ptr null
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #7
  br label %25

25:                                               ; preds = %23, %21
  %.pn = phi { ptr, i32 } [ %24, %23 ], [ %22, %21 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %2) #7
  br label %26

26:                                               ; preds = %25, %19
  %.pn.pn = phi { ptr, i32 } [ %.pn, %25 ], [ %20, %19 ]
  %.1 = extractvalue { ptr, i32 } %.pn.pn, 0
  %.17 = extractvalue { ptr, i32 } %.pn.pn, 1
  %27 = call i32 @llvm.eh.typeid.for.p0(ptr nonnull @_ZTISt9exception) #7
  %28 = icmp eq i32 %.17, %27
  %29 = call ptr @__cxa_begin_catch(ptr %.1) #7
  br i1 %28, label %30, label %53

30:                                               ; preds = %26
  call void @llvm.lifetime.start.p0(i64 408, ptr nonnull %6) #7
  invoke void @_ZN8UnitTest15MemoryOutStreamC1Ev(ptr noundef nonnull align 8 dereferenceable(144) %6)
          to label %31 unwind label %67

31:                                               ; preds = %30
  %32 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %6, ptr noundef nonnull @.str.3)
          to label %33 unwind label %69

33:                                               ; preds = %31
  %34 = load ptr, ptr %29, align 8, !tbaa !11
  %35 = getelementptr inbounds i8, ptr %34, i64 16
  %36 = load ptr, ptr %35, align 8
  %37 = call noundef ptr %36(ptr noundef nonnull align 8 dereferenceable(8) %29) #7
  %38 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %32, ptr noundef %37)
          to label %39 unwind label %69

39:                                               ; preds = %33
  %40 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %38, ptr noundef nonnull @.str.20)
          to label %41 unwind label %69

41:                                               ; preds = %39
  %42 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7ResultsEv()
          to label %43 unwind label %69

43:                                               ; preds = %41
  %44 = load ptr, ptr %42, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %7) #7
  %45 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7DetailsEv()
          to label %46 unwind label %71

46:                                               ; preds = %43
  %47 = load ptr, ptr %45, align 8, !tbaa !5
  invoke void @_ZN8UnitTest11TestDetailsC1ERKS0_i(ptr noundef nonnull align 8 dereferenceable(29) %7, ptr noundef nonnull align 8 dereferenceable(29) %47, i32 noundef 46)
          to label %48 unwind label %71

48:                                               ; preds = %46
  %49 = invoke noundef ptr @_ZNK8UnitTest15MemoryOutStream7GetTextEv(ptr noundef nonnull align 8 dereferenceable(144) %6)
          to label %50 unwind label %71

50:                                               ; preds = %48
  invoke void @_ZN8UnitTest11TestResults13OnTestFailureERKNS_11TestDetailsEPKc(ptr noundef nonnull align 8 dereferenceable(21) %44, ptr noundef nonnull align 8 dereferenceable(29) %7, ptr noundef %49)
          to label %51 unwind label %71

51:                                               ; preds = %50
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %7) #7
  call void @_ZN8UnitTest15MemoryOutStreamD1Ev(ptr noundef nonnull align 8 dereferenceable(144) %6) #7
  call void @llvm.lifetime.end.p0(i64 408, ptr nonnull %6) #7
  call void @__cxa_end_catch()
  br label %52

52:                                               ; preds = %18, %51, %61
  ret void

53:                                               ; preds = %26
  %54 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7ResultsEv()
          to label %55 unwind label %62

55:                                               ; preds = %53
  %56 = load ptr, ptr %54, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %5) #7
  %57 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZN8UnitTest11CurrentTest7DetailsEv()
          to label %58 unwind label %64

58:                                               ; preds = %55
  %59 = load ptr, ptr %57, align 8, !tbaa !5
  invoke void @_ZN8UnitTest11TestDetailsC1ERKS0_i(ptr noundef nonnull align 8 dereferenceable(29) %5, ptr noundef nonnull align 8 dereferenceable(29) %59, i32 noundef 46)
          to label %60 unwind label %64

60:                                               ; preds = %58
  invoke void @_ZN8UnitTest11TestResults13OnTestFailureERKNS_11TestDetailsEPKc(ptr noundef nonnull align 8 dereferenceable(21) %56, ptr noundef nonnull align 8 dereferenceable(29) %5, ptr noundef nonnull @.str.19)
          to label %61 unwind label %64

61:                                               ; preds = %60
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #7
  call void @__cxa_end_catch()
  br label %52

62:                                               ; preds = %53
  %63 = landingpad { ptr, i32 }
          cleanup
  br label %66

64:                                               ; preds = %60, %58, %55
  %65 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %5) #7
  br label %66

66:                                               ; preds = %64, %62
  %.pn14 = phi { ptr, i32 } [ %65, %64 ], [ %63, %62 ]
  invoke void @__cxa_end_catch()
          to label %75 unwind label %76

67:                                               ; preds = %30
  %68 = landingpad { ptr, i32 }
          cleanup
  br label %74

69:                                               ; preds = %41, %39, %33, %31
  %70 = landingpad { ptr, i32 }
          cleanup
  br label %73

71:                                               ; preds = %50, %48, %46, %43
  %72 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %7) #7
  br label %73

73:                                               ; preds = %71, %69
  %.pn16 = phi { ptr, i32 } [ %72, %71 ], [ %70, %69 ]
  call void @_ZN8UnitTest15MemoryOutStreamD1Ev(ptr noundef nonnull align 8 dereferenceable(144) %6) #7
  br label %74

74:                                               ; preds = %73, %67
  %.pn16.pn = phi { ptr, i32 } [ %.pn16, %73 ], [ %68, %67 ]
  call void @llvm.lifetime.end.p0(i64 408, ptr nonnull %6) #7
  invoke void @__cxa_end_catch()
          to label %75 unwind label %76

75:                                               ; preds = %74, %66
  %.pn16.pn.pn = phi { ptr, i32 } [ %.pn14, %66 ], [ %.pn16.pn, %74 ]
  resume { ptr, i32 } %.pn16.pn.pn

76:                                               ; preds = %74, %66
  %77 = landingpad { ptr, i32 }
          catch ptr null
  %78 = extractvalue { ptr, i32 } %77, 0
  call void @__clang_call_terminate(ptr %78) #8
  unreachable
}

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNK6Aquila12SignalSource15getSamplesCountEv(ptr noundef nonnull align 8 dereferenceable(40)) unnamed_addr #6 align 2

attributes #0 = { mustprogress 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 = { "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 = { nofree nosync nounwind memory(none) }
attributes #4 = { noinline noreturn nounwind uwtable "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 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 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 #7 = { nounwind }
attributes #8 = { noreturn 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 = !{!"vtable pointer", !8, i64 0}


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