; LLVM IR from TLE-MEC/Hack-CP-DSA :: Hackerrank/Cycle Detection (solution)

; 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.std::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"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 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ofstream" = type { %"class.std::basic_ostream.base", %"class.std::basic_filebuf", %"class.std::basic_ios" }
%"class.std::basic_ostream.base" = type { ptr }
%"class.std::basic_filebuf" = type { %"class.std::basic_streambuf", %union.pthread_mutex_t, %"class.std::__basic_file", i32, %struct.__mbstate_t, %struct.__mbstate_t, %struct.__mbstate_t, ptr, i64, i8, i8, i8, i8, ptr, ptr, i8, ptr, ptr, i64, ptr, ptr }
%"class.std::basic_streambuf" = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, %"class.std::locale" }
%union.pthread_mutex_t = type { %struct.__pthread_mutex_s }
%struct.__pthread_mutex_s = type { i32, i32, i32, i32, i32, i16, i16, %struct.__pthread_internal_list }
%struct.__pthread_internal_list = type { ptr, ptr }
%"class.std::__basic_file" = type <{ ptr, i8, [7 x i8] }>
%struct.__mbstate_t = type { i32, %union.anon.0 }
%union.anon.0 = type { i32 }
%class.SinglyLinkedList = type { ptr, ptr }
%class.SinglyLinkedListNode = type { i32, ptr }

@.str = external hidden unnamed_addr constant [12 x i8], align 1
@_ZSt3cin = external global %"class.std::basic_istream", align 8
@.str.1 = external hidden unnamed_addr constant [2 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

; 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 zeroext i1 @_Z9has_cycleP20SinglyLinkedListNode(ptr noundef) #1

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() #2 personality ptr @__gxx_personality_v0 {
  %1 = alloca i32, align 4
  %2 = alloca %"class.std::basic_ofstream", align 8
  %3 = alloca i32, align 4
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca i32, align 4
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca i32, align 4
  %16 = alloca i8, align 1
  store i32 0, ptr %1, align 4
  call void @llvm.lifetime.start.p0(i64 512, ptr %2) #9
  %17 = call ptr @getenv(ptr noundef @.str) #9
  call void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(248) %2, ptr noundef %17, i32 noundef 16)
  call void @llvm.lifetime.start.p0(i64 4, ptr %3) #9
  %18 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %3)
          to label %19 unwind label %28

19:                                               ; preds = %0
  %20 = call noundef i64 @_ZNSt14numeric_limitsIlE3maxEv() #9
  %21 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi6ignoreEli(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, i64 noundef %20, i32 noundef 10)
          to label %22 unwind label %28

22:                                               ; preds = %19
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #9
  store i32 0, ptr %6, align 4, !tbaa !5
  br label %23

23:                                               ; preds = %138, %22
  %24 = load i32, ptr %6, align 4, !tbaa !5
  %25 = load i32, ptr %3, align 4, !tbaa !5
  %26 = icmp slt i32 %24, %25
  br i1 %26, label %32, label %27

27:                                               ; preds = %23
  store i32 2, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #9
  br label %149

28:                                               ; preds = %149, %19, %0
  %29 = landingpad { ptr, i32 }
          cleanup
  %30 = extractvalue { ptr, i32 } %29, 0
  store ptr %30, ptr %4, align 8
  %31 = extractvalue { ptr, i32 } %29, 1
  store i32 %31, ptr %5, align 4
  br label %152

32:                                               ; preds = %23
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #9
  %33 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %8)
          to label %34 unwind label %51

34:                                               ; preds = %32
  %35 = call noundef i64 @_ZNSt14numeric_limitsIlE3maxEv() #9
  %36 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi6ignoreEli(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, i64 noundef %35, i32 noundef 10)
          to label %37 unwind label %51

37:                                               ; preds = %34
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #9
  %38 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef 16) #10
          to label %39 unwind label %55

39:                                               ; preds = %37
  invoke void @_ZN16SinglyLinkedListC2Ev(ptr noundef nonnull align 8 dereferenceable(16) %38)
          to label %40 unwind label %59

40:                                               ; preds = %39
  store ptr %38, ptr %9, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #9
  %41 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %10)
          to label %42 unwind label %63

42:                                               ; preds = %40
  %43 = call noundef i64 @_ZNSt14numeric_limitsIlE3maxEv() #9
  %44 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi6ignoreEli(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, i64 noundef %43, i32 noundef 10)
          to label %45 unwind label %63

45:                                               ; preds = %42
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #9
  store i32 0, ptr %11, align 4, !tbaa !5
  br label %46

46:                                               ; preds = %76, %45
  %47 = load i32, ptr %11, align 4, !tbaa !5
  %48 = load i32, ptr %10, align 4, !tbaa !5
  %49 = icmp slt i32 %47, %48
  br i1 %49, label %67, label %50

50:                                               ; preds = %46
  store i32 5, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #9
  br label %83

51:                                               ; preds = %34, %32
  %52 = landingpad { ptr, i32 }
          cleanup
  %53 = extractvalue { ptr, i32 } %52, 0
  store ptr %53, ptr %4, align 8
  %54 = extractvalue { ptr, i32 } %52, 1
  store i32 %54, ptr %5, align 4
  br label %148

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

59:                                               ; preds = %39
  %60 = landingpad { ptr, i32 }
          cleanup
  %61 = extractvalue { ptr, i32 } %60, 0
  store ptr %61, ptr %4, align 8
  %62 = extractvalue { ptr, i32 } %60, 1
  store i32 %62, ptr %5, align 4
  call void @_ZdlPvm(ptr noundef %38, i64 noundef 16) #11
  br label %147

63:                                               ; preds = %42, %40
  %64 = landingpad { ptr, i32 }
          cleanup
  %65 = extractvalue { ptr, i32 } %64, 0
  store ptr %65, ptr %4, align 8
  %66 = extractvalue { ptr, i32 } %64, 1
  store i32 %66, ptr %5, align 4
  br label %146

67:                                               ; preds = %46
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #9
  %68 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %12)
          to label %69 unwind label %79

69:                                               ; preds = %67
  %70 = call noundef i64 @_ZNSt14numeric_limitsIlE3maxEv() #9
  %71 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi6ignoreEli(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, i64 noundef %70, i32 noundef 10)
          to label %72 unwind label %79

72:                                               ; preds = %69
  %73 = load ptr, ptr %9, align 8, !tbaa !9
  %74 = load i32, ptr %12, align 4, !tbaa !5
  invoke void @_ZN16SinglyLinkedList11insert_nodeEi(ptr noundef nonnull align 8 dereferenceable(16) %73, i32 noundef %74)
          to label %75 unwind label %79

75:                                               ; preds = %72
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #9
  br label %76

76:                                               ; preds = %75
  %77 = load i32, ptr %11, align 4, !tbaa !5
  %78 = add nsw i32 %77, 1
  store i32 %78, ptr %11, align 4, !tbaa !5
  br label %46, !llvm.loop !11

79:                                               ; preds = %72, %69, %67
  %80 = landingpad { ptr, i32 }
          cleanup
  %81 = extractvalue { ptr, i32 } %80, 0
  store ptr %81, ptr %4, align 8
  %82 = extractvalue { ptr, i32 } %80, 1
  store i32 %82, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #9
  br label %146

83:                                               ; preds = %50
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #9
  %84 = invoke noalias noundef nonnull ptr @_Znwm(i64 noundef 16) #10
          to label %85 unwind label %95

85:                                               ; preds = %83
  invoke void @_ZN20SinglyLinkedListNodeC2Ei(ptr noundef nonnull align 8 dereferenceable(16) %84, i32 noundef -1)
          to label %86 unwind label %99

86:                                               ; preds = %85
  store ptr %84, ptr %13, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #9
  %87 = load ptr, ptr %9, align 8, !tbaa !9
  %88 = getelementptr inbounds %class.SinglyLinkedList, ptr %87, i32 0, i32 0
  %89 = load ptr, ptr %88, align 8, !tbaa !13
  store ptr %89, ptr %14, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #9
  store i32 0, ptr %15, align 4, !tbaa !5
  br label %90

90:                                               ; preds = %119, %86
  %91 = load i32, ptr %15, align 4, !tbaa !5
  %92 = load i32, ptr %10, align 4, !tbaa !5
  %93 = icmp slt i32 %91, %92
  br i1 %93, label %103, label %94

94:                                               ; preds = %90
  store i32 8, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #9
  br label %122

95:                                               ; preds = %83
  %96 = landingpad { ptr, i32 }
          cleanup
  %97 = extractvalue { ptr, i32 } %96, 0
  store ptr %97, ptr %4, align 8
  %98 = extractvalue { ptr, i32 } %96, 1
  store i32 %98, ptr %5, align 4
  br label %145

99:                                               ; preds = %85
  %100 = landingpad { ptr, i32 }
          cleanup
  %101 = extractvalue { ptr, i32 } %100, 0
  store ptr %101, ptr %4, align 8
  %102 = extractvalue { ptr, i32 } %100, 1
  store i32 %102, ptr %5, align 4
  call void @_ZdlPvm(ptr noundef %84, i64 noundef 16) #11
  br label %145

103:                                              ; preds = %90
  %104 = load i32, ptr %15, align 4, !tbaa !5
  %105 = load i32, ptr %8, align 4, !tbaa !5
  %106 = icmp eq i32 %104, %105
  br i1 %106, label %107, label %109

107:                                              ; preds = %103
  %108 = load ptr, ptr %14, align 8, !tbaa !9
  store ptr %108, ptr %13, align 8, !tbaa !9
  br label %109

109:                                              ; preds = %107, %103
  %110 = load i32, ptr %15, align 4, !tbaa !5
  %111 = load i32, ptr %10, align 4, !tbaa !5
  %112 = sub nsw i32 %111, 1
  %113 = icmp ne i32 %110, %112
  br i1 %113, label %114, label %118

114:                                              ; preds = %109
  %115 = load ptr, ptr %14, align 8, !tbaa !9
  %116 = getelementptr inbounds %class.SinglyLinkedListNode, ptr %115, i32 0, i32 1
  %117 = load ptr, ptr %116, align 8, !tbaa !15
  store ptr %117, ptr %14, align 8, !tbaa !9
  br label %118

118:                                              ; preds = %114, %109
  br label %119

119:                                              ; preds = %118
  %120 = load i32, ptr %15, align 4, !tbaa !5
  %121 = add nsw i32 %120, 1
  store i32 %121, ptr %15, align 4, !tbaa !5
  br label %90, !llvm.loop !17

122:                                              ; preds = %94
  %123 = load ptr, ptr %13, align 8, !tbaa !9
  %124 = load ptr, ptr %14, align 8, !tbaa !9
  %125 = getelementptr inbounds %class.SinglyLinkedListNode, ptr %124, i32 0, i32 1
  store ptr %123, ptr %125, align 8, !tbaa !15
  call void @llvm.lifetime.start.p0(i64 1, ptr %16) #9
  %126 = load ptr, ptr %9, align 8, !tbaa !9
  %127 = getelementptr inbounds %class.SinglyLinkedList, ptr %126, i32 0, i32 0
  %128 = load ptr, ptr %127, align 8, !tbaa !13
  %129 = invoke noundef zeroext i1 @_Z9has_cycleP20SinglyLinkedListNode(ptr noundef %128)
          to label %130 unwind label %141

130:                                              ; preds = %122
  %131 = zext i1 %129 to i8
  store i8 %131, ptr %16, align 1, !tbaa !18
  %132 = load i8, ptr %16, align 1, !tbaa !18, !range !20, !noundef !21
  %133 = trunc i8 %132 to i1
  %134 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEb(ptr noundef nonnull align 8 dereferenceable(8) %2, i1 noundef zeroext %133)
          to label %135 unwind label %141

135:                                              ; preds = %130
  %136 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %134, ptr noundef @.str.1)
          to label %137 unwind label %141

137:                                              ; preds = %135
  call void @llvm.lifetime.end.p0(i64 1, ptr %16) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #9
  br label %138

138:                                              ; preds = %137
  %139 = load i32, ptr %6, align 4, !tbaa !5
  %140 = add nsw i32 %139, 1
  store i32 %140, ptr %6, align 4, !tbaa !5
  br label %23, !llvm.loop !22

141:                                              ; preds = %135, %130, %122
  %142 = landingpad { ptr, i32 }
          cleanup
  %143 = extractvalue { ptr, i32 } %142, 0
  store ptr %143, ptr %4, align 8
  %144 = extractvalue { ptr, i32 } %142, 1
  store i32 %144, ptr %5, align 4
  call void @llvm.lifetime.end.p0(i64 1, ptr %16) #9
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #9
  br label %145

145:                                              ; preds = %141, %99, %95
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #9
  br label %146

146:                                              ; preds = %145, %79, %63
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #9
  br label %147

147:                                              ; preds = %146, %59, %55
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #9
  br label %148

148:                                              ; preds = %147, %51
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #9
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #9
  br label %152

149:                                              ; preds = %27
  invoke void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEE5closeEv(ptr noundef nonnull align 8 dereferenceable(248) %2)
          to label %150 unwind label %28

150:                                              ; preds = %149
  store i32 0, ptr %1, align 4
  store i32 1, ptr %7, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #9
  call void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(248) %2) #9
  call void @llvm.lifetime.end.p0(i64 512, ptr %2) #9
  %151 = load i32, ptr %1, align 4
  ret i32 %151

152:                                              ; preds = %148, %28
  call void @llvm.lifetime.end.p0(i64 4, ptr %3) #9
  call void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(248) %2) #9
  call void @llvm.lifetime.end.p0(i64 512, ptr %2) #9
  br label %153

153:                                              ; preds = %152
  %154 = load ptr, ptr %4, align 8
  %155 = load i32, ptr %5, align 4
  %156 = insertvalue { ptr, i32 } poison, ptr %154, 0
  %157 = insertvalue { ptr, i32 } %156, i32 %155, 1
  resume { ptr, i32 } %157
}

; Function Attrs: nounwind
declare ptr @getenv(ptr noundef) #3

; Function Attrs: mustprogress uwtable
declare void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(248), ptr noundef, i32 noundef) unnamed_addr #1 align 2

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(4)) #4

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi6ignoreEli(ptr noundef nonnull align 8 dereferenceable(16), i64 noundef, i32 noundef) #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNSt14numeric_limitsIlE3maxEv() #5 align 2

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znwm(i64 noundef) #6

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

; Function Attrs: nobuiltin nounwind
declare void @_ZdlPvm(ptr noundef, i64 noundef) #7

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN16SinglyLinkedList11insert_nodeEi(ptr noundef nonnull align 8 dereferenceable(16), i32 noundef) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN20SinglyLinkedListNodeC2Ei(ptr noundef nonnull align 8 dereferenceable(16), i32 noundef) unnamed_addr #5 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) #8

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEb(ptr noundef nonnull align 8 dereferenceable(8), i1 noundef zeroext) #1 align 2

; Function Attrs: mustprogress uwtable
declare void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEE5closeEv(ptr noundef nonnull align 8 dereferenceable(248)) #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(248)) unnamed_addr #5 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 = { mustprogress norecurse 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 = { 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 #4 = { "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 = { 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 = { nobuiltin allocsize(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 = { nobuiltin 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 #8 = { 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 #9 = { nounwind }
attributes #10 = { builtin allocsize(0) }
attributes #11 = { builtin 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, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = !{!14, !10, i64 0}
!14 = !{!"_ZTS16SinglyLinkedList", !10, i64 0, !10, i64 8}
!15 = !{!16, !10, i64 8}
!16 = !{!"_ZTS20SinglyLinkedListNode", !6, i64 0, !10, i64 8}
!17 = distinct !{!17, !12}
!18 = !{!19, !19, i64 0}
!19 = !{!"bool", !7, i64 0}
!20 = !{i8 0, i8 2}
!21 = !{}
!22 = distinct !{!22, !12}


; Optimized IR (opt -passes='default<O3>'):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::basic_istream" = type { ptr, i64, %"class.std::basic_ios" }
%"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 }
%"class.std::locale" = type { ptr }
%"class.std::basic_ofstream" = type { %"class.std::basic_ostream.base", %"class.std::basic_filebuf", %"class.std::basic_ios" }
%"class.std::basic_ostream.base" = type { ptr }
%"class.std::basic_filebuf" = type { %"class.std::basic_streambuf", %union.pthread_mutex_t, %"class.std::__basic_file", i32, %struct.__mbstate_t, %struct.__mbstate_t, %struct.__mbstate_t, ptr, i64, i8, i8, i8, i8, ptr, ptr, i8, ptr, ptr, i64, ptr, ptr }
%"class.std::basic_streambuf" = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, %"class.std::locale" }
%union.pthread_mutex_t = type { %struct.__pthread_mutex_s }
%struct.__pthread_mutex_s = type { i32, i32, i32, i32, i32, i16, i16, %struct.__pthread_internal_list }
%struct.__pthread_internal_list = type { ptr, ptr }
%"class.std::__basic_file" = type <{ ptr, i8, [7 x i8] }>
%struct.__mbstate_t = type { i32, %union.anon.0 }
%union.anon.0 = type { i32 }

@.str = external hidden unnamed_addr constant [12 x i8], align 1
@_ZSt3cin = external global %"class.std::basic_istream", align 8
@.str.1 = external hidden unnamed_addr constant [2 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

; 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 noundef zeroext i1 @_Z9has_cycleP20SinglyLinkedListNode(ptr noundef) local_unnamed_addr #1

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress norecurse uwtable
define dso_local noundef i32 @main() local_unnamed_addr #2 personality ptr @__gxx_personality_v0 {
  %1 = alloca %"class.std::basic_ofstream", align 8
  %2 = alloca i32, align 4
  %3 = alloca i32, align 4
  %4 = alloca i32, align 4
  %5 = alloca i32, align 4
  call void @llvm.lifetime.start.p0(i64 512, ptr nonnull %1) #8
  %6 = tail call ptr @getenv(ptr noundef nonnull @.str) #8
  call void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(248) %1, ptr noundef %6, i32 noundef 16)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %2) #8
  %7 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %2)
          to label %8 unwind label %13

8:                                                ; preds = %0
  %9 = call noundef i64 @_ZNSt14numeric_limitsIlE3maxEv() #8
  %10 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi6ignoreEli(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, i64 noundef %9, i32 noundef 10)
          to label %.preheader36 unwind label %13

.preheader36:                                     ; preds = %8
  %11 = load i32, ptr %2, align 4, !tbaa !5
  %12 = icmp sgt i32 %11, 0
  br i1 %12, label %.lr.ph46, label %._crit_edge47

._crit_edge47:                                    ; preds = %79, %.preheader36
  invoke void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEE5closeEv(ptr noundef nonnull align 8 dereferenceable(248) %1)
          to label %87 unwind label %13

13:                                               ; preds = %._crit_edge47, %8, %0
  %14 = landingpad { ptr, i32 }
          cleanup
  br label %88

.lr.ph46:                                         ; preds = %.preheader36, %79
  %.02445 = phi i32 [ %80, %79 ], [ 0, %.preheader36 ]
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %3) #8
  %15 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %3)
          to label %16 unwind label %29

16:                                               ; preds = %.lr.ph46
  %17 = call noundef i64 @_ZNSt14numeric_limitsIlE3maxEv() #8
  %18 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi6ignoreEli(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, i64 noundef %17, i32 noundef 10)
          to label %19 unwind label %29

19:                                               ; preds = %16
  %20 = invoke noalias noundef nonnull dereferenceable(16) ptr @_Znwm(i64 noundef 16) #9
          to label %21 unwind label %31

21:                                               ; preds = %19
  call void @_ZN16SinglyLinkedListC2Ev(ptr noundef nonnull align 8 dereferenceable(16) %20)
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %4) #8
  %22 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %4)
          to label %23 unwind label %33

23:                                               ; preds = %21
  %24 = call noundef i64 @_ZNSt14numeric_limitsIlE3maxEv() #8
  %25 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi6ignoreEli(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, i64 noundef %24, i32 noundef 10)
          to label %.preheader unwind label %33

.preheader:                                       ; preds = %23
  %26 = load i32, ptr %4, align 4, !tbaa !5
  %27 = icmp sgt i32 %26, 0
  br i1 %27, label %.lr.ph, label %._crit_edge

._crit_edge:                                      ; preds = %41, %.preheader
  %28 = invoke noalias noundef nonnull dereferenceable(16) ptr @_Znwm(i64 noundef 16) #9
          to label %47 unwind label %60

29:                                               ; preds = %16, %.lr.ph46
  %30 = landingpad { ptr, i32 }
          cleanup
  br label %86

31:                                               ; preds = %19
  %32 = landingpad { ptr, i32 }
          cleanup
  br label %86

33:                                               ; preds = %23, %21
  %34 = landingpad { ptr, i32 }
          cleanup
  br label %85

.lr.ph:                                           ; preds = %.preheader, %41
  %.02137 = phi i32 [ %42, %41 ], [ 0, %.preheader ]
  call void @llvm.lifetime.start.p0(i64 4, ptr nonnull %5) #8
  %35 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, ptr noundef nonnull align 4 dereferenceable(4) %5)
          to label %36 unwind label %45

36:                                               ; preds = %.lr.ph
  %37 = call noundef i64 @_ZNSt14numeric_limitsIlE3maxEv() #8
  %38 = invoke noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi6ignoreEli(ptr noundef nonnull align 8 dereferenceable(16) @_ZSt3cin, i64 noundef %37, i32 noundef 10)
          to label %39 unwind label %45

39:                                               ; preds = %36
  %40 = load i32, ptr %5, align 4, !tbaa !5
  invoke void @_ZN16SinglyLinkedList11insert_nodeEi(ptr noundef nonnull align 8 dereferenceable(16) %20, i32 noundef %40)
          to label %41 unwind label %45

41:                                               ; preds = %39
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #8
  %42 = add nuw nsw i32 %.02137, 1
  %43 = load i32, ptr %4, align 4, !tbaa !5
  %44 = icmp slt i32 %42, %43
  br i1 %44, label %.lr.ph, label %._crit_edge, !llvm.loop !9

45:                                               ; preds = %39, %36, %.lr.ph
  %46 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %5) #8
  br label %85

47:                                               ; preds = %._crit_edge
  call void @_ZN20SinglyLinkedListNodeC2Ei(ptr noundef nonnull align 8 dereferenceable(16) %28, i32 noundef -1)
  %48 = load ptr, ptr %20, align 8, !tbaa !11
  %49 = load i32, ptr %4, align 4, !tbaa !5
  %50 = icmp sgt i32 %49, 0
  br i1 %50, label %.lr.ph42, label %._crit_edge43

.lr.ph42:                                         ; preds = %47
  %51 = load i32, ptr %3, align 4, !tbaa !5
  %52 = add nsw i32 %49, -1
  %xtraiter = and i32 %49, 1
  %53 = icmp eq i32 %52, 0
  br i1 %53, label %._crit_edge43.loopexit.unr-lcssa, label %.lr.ph42.new

.lr.ph42.new:                                     ; preds = %.lr.ph42
  %unroll_iter = and i32 %49, 2147483646
  br label %62

._crit_edge43.loopexit.unr-lcssa:                 ; preds = %73, %.lr.ph42
  %.1.lcssa.ph = phi ptr [ poison, %.lr.ph42 ], [ %.1.1, %73 ]
  %spec.select.lcssa.ph = phi ptr [ poison, %.lr.ph42 ], [ %spec.select.1, %73 ]
  %.040.unr = phi i32 [ 0, %.lr.ph42 ], [ %74, %73 ]
  %.01839.unr = phi ptr [ %48, %.lr.ph42 ], [ %.1.1, %73 ]
  %.01938.unr = phi ptr [ %28, %.lr.ph42 ], [ %spec.select.1, %73 ]
  %lcmp.mod.not = icmp eq i32 %xtraiter, 0
  br i1 %lcmp.mod.not, label %._crit_edge43, label %.epil.preheader

.epil.preheader:                                  ; preds = %._crit_edge43.loopexit.unr-lcssa
  %54 = icmp eq i32 %.040.unr, %51
  %spec.select.epil = select i1 %54, ptr %.01839.unr, ptr %.01938.unr
  %.not.epil = icmp eq i32 %.040.unr, %52
  br i1 %.not.epil, label %._crit_edge43, label %55

55:                                               ; preds = %.epil.preheader
  %56 = getelementptr inbounds i8, ptr %.01839.unr, i64 8
  %57 = load ptr, ptr %56, align 8, !tbaa !14
  br label %._crit_edge43

._crit_edge43:                                    ; preds = %._crit_edge43.loopexit.unr-lcssa, %55, %.epil.preheader, %47
  %.019.lcssa = phi ptr [ %28, %47 ], [ %spec.select.lcssa.ph, %._crit_edge43.loopexit.unr-lcssa ], [ %spec.select.epil, %55 ], [ %spec.select.epil, %.epil.preheader ]
  %.018.lcssa = phi ptr [ %48, %47 ], [ %.1.lcssa.ph, %._crit_edge43.loopexit.unr-lcssa ], [ %57, %55 ], [ %.01839.unr, %.epil.preheader ]
  %58 = getelementptr inbounds i8, ptr %.018.lcssa, i64 8
  store ptr %.019.lcssa, ptr %58, align 8, !tbaa !14
  %59 = invoke noundef zeroext i1 @_Z9has_cycleP20SinglyLinkedListNode(ptr noundef %48)
          to label %75 unwind label %83

60:                                               ; preds = %._crit_edge
  %61 = landingpad { ptr, i32 }
          cleanup
  br label %85

62:                                               ; preds = %73, %.lr.ph42.new
  %.040 = phi i32 [ 0, %.lr.ph42.new ], [ %74, %73 ]
  %.01839 = phi ptr [ %48, %.lr.ph42.new ], [ %.1.1, %73 ]
  %.01938 = phi ptr [ %28, %.lr.ph42.new ], [ %spec.select.1, %73 ]
  %niter = phi i32 [ 0, %.lr.ph42.new ], [ %niter.next.1, %73 ]
  %63 = icmp eq i32 %.040, %51
  %spec.select = select i1 %63, ptr %.01839, ptr %.01938
  %.not = icmp eq i32 %.040, %52
  br i1 %.not, label %67, label %64

64:                                               ; preds = %62
  %65 = getelementptr inbounds i8, ptr %.01839, i64 8
  %66 = load ptr, ptr %65, align 8, !tbaa !14
  br label %67

67:                                               ; preds = %62, %64
  %.1 = phi ptr [ %66, %64 ], [ %.01839, %62 ]
  %68 = or disjoint i32 %.040, 1
  %69 = icmp eq i32 %68, %51
  %spec.select.1 = select i1 %69, ptr %.1, ptr %spec.select
  %.not.1 = icmp eq i32 %68, %52
  br i1 %.not.1, label %73, label %70

70:                                               ; preds = %67
  %71 = getelementptr inbounds i8, ptr %.1, i64 8
  %72 = load ptr, ptr %71, align 8, !tbaa !14
  br label %73

73:                                               ; preds = %70, %67
  %.1.1 = phi ptr [ %72, %70 ], [ %.1, %67 ]
  %74 = add nuw nsw i32 %.040, 2
  %niter.next.1 = add i32 %niter, 2
  %niter.ncmp.1 = icmp eq i32 %niter.next.1, %unroll_iter
  br i1 %niter.ncmp.1, label %._crit_edge43.loopexit.unr-lcssa, label %62, !llvm.loop !16

75:                                               ; preds = %._crit_edge43
  %76 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEb(ptr noundef nonnull align 8 dereferenceable(8) %1, i1 noundef zeroext %59)
          to label %77 unwind label %83

77:                                               ; preds = %75
  %78 = invoke noundef nonnull align 8 dereferenceable(8) ptr @_ZStlsISt11char_traitsIcEERSt13basic_ostreamIcT_ES5_PKc(ptr noundef nonnull align 8 dereferenceable(8) %76, ptr noundef nonnull @.str.1)
          to label %79 unwind label %83

79:                                               ; preds = %77
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #8
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #8
  %80 = add nuw nsw i32 %.02445, 1
  %81 = load i32, ptr %2, align 4, !tbaa !5
  %82 = icmp slt i32 %80, %81
  br i1 %82, label %.lr.ph46, label %._crit_edge47, !llvm.loop !17

83:                                               ; preds = %77, %75, %._crit_edge43
  %84 = landingpad { ptr, i32 }
          cleanup
  br label %85

85:                                               ; preds = %60, %83, %45, %33
  %.pn31 = phi { ptr, i32 } [ %46, %45 ], [ %34, %33 ], [ %84, %83 ], [ %61, %60 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %4) #8
  br label %86

86:                                               ; preds = %31, %85, %29
  %.pn31.pn.pn = phi { ptr, i32 } [ %30, %29 ], [ %.pn31, %85 ], [ %32, %31 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %3) #8
  br label %88

87:                                               ; preds = %._crit_edge47
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #8
  call void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(248) %1) #8
  call void @llvm.lifetime.end.p0(i64 512, ptr nonnull %1) #8
  ret i32 0

88:                                               ; preds = %86, %13
  %.pn31.pn.pn.pn = phi { ptr, i32 } [ %.pn31.pn.pn, %86 ], [ %14, %13 ]
  call void @llvm.lifetime.end.p0(i64 4, ptr nonnull %2) #8
  call void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(248) %1) #8
  call void @llvm.lifetime.end.p0(i64 512, ptr nonnull %1) #8
  resume { ptr, i32 } %.pn31.pn.pn.pn
}

; Function Attrs: nofree nounwind memory(read)
declare noundef ptr @getenv(ptr nocapture noundef) local_unnamed_addr #3

; Function Attrs: mustprogress uwtable
declare void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEEC1EPKcSt13_Ios_Openmode(ptr noundef nonnull align 8 dereferenceable(248), ptr noundef, i32 noundef) unnamed_addr #1 align 2

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSirsERi(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull align 4 dereferenceable(4)) local_unnamed_addr #4

declare noundef nonnull align 8 dereferenceable(16) ptr @_ZNSi6ignoreEli(ptr noundef nonnull align 8 dereferenceable(16), i64 noundef, i32 noundef) local_unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNSt14numeric_limitsIlE3maxEv() local_unnamed_addr #5 align 2

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znwm(i64 noundef) local_unnamed_addr #6

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

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN16SinglyLinkedList11insert_nodeEi(ptr noundef nonnull align 8 dereferenceable(16), i32 noundef) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZN20SinglyLinkedListNodeC2Ei(ptr noundef nonnull align 8 dereferenceable(16), i32 noundef) unnamed_addr #5 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 #7

; Function Attrs: mustprogress uwtable
declare noundef nonnull align 8 dereferenceable(8) ptr @_ZNSolsEb(ptr noundef nonnull align 8 dereferenceable(8), i1 noundef zeroext) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress uwtable
declare void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEE5closeEv(ptr noundef nonnull align 8 dereferenceable(248)) local_unnamed_addr #1 align 2

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt14basic_ofstreamIcSt11char_traitsIcEED1Ev(ptr noundef nonnull align 8 dereferenceable(248)) unnamed_addr #5 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 = { mustprogress norecurse 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 = { nofree nounwind memory(read) "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 = { "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 = { 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 = { nobuiltin allocsize(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 = { 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 #8 = { nounwind }
attributes #9 = { builtin allocsize(0) }

!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 = distinct !{!9, !10}
!10 = !{!"llvm.loop.mustprogress"}
!11 = !{!12, !13, i64 0}
!12 = !{!"_ZTS16SinglyLinkedList", !13, i64 0, !13, i64 8}
!13 = !{!"any pointer", !7, i64 0}
!14 = !{!15, !13, i64 8}
!15 = !{!"_ZTS20SinglyLinkedListNode", !6, i64 0, !13, i64 8}
!16 = distinct !{!16, !10}
!17 = distinct !{!17, !10}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,IndVarSimplifyPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,SROAPass,SimplifyCFGPass,TailCallElimPass