; LLVM IR from ERGO-Code/HiGHS :: src/util/HighsUtils.ll (Z2okRK20HighsIndexCollection)

; 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.HighsIndexCollection = type { i32, i8, i32, i32, i8, i32, %"class.std::vector", i8, %"class.std::vector" }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@.str.52 = external hidden unnamed_addr constant [73 x i8], align 1
@.str.53 = external hidden unnamed_addr constant [43 x i8], align 1
@.str.54 = external hidden unnamed_addr constant [44 x i8], align 1
@.str.55 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.56 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.57 = external hidden unnamed_addr constant [43 x i8], align 1
@.str.58 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.59 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.60 = external hidden unnamed_addr constant [55 x i8], align 1
@.str.61 = external hidden unnamed_addr constant [68 x i8], align 1
@.str.62 = external hidden unnamed_addr constant [43 x i8], align 1
@__PRETTY_FUNCTION__._Z2okRK20HighsIndexCollection = external hidden unnamed_addr constant [38 x i8], align 1
@.str.63 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.64 = external hidden unnamed_addr constant [44 x i8], align 1
@.str.65 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.66 = external hidden unnamed_addr constant [28 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

declare noundef zeroext i1 @_Z15increasingSetOkRKSt6vectorIiSaIiEEiib(ptr noundef nonnull align 8 dereferenceable(24), i32 noundef, i32 noundef, i1 noundef zeroext) #1

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

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) #3

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_Z2okRK20HighsIndexCollection(ptr noundef nonnull align 8 dereferenceable(80) %0) #4 {
  %2 = alloca i1, align 1
  %3 = alloca ptr, align 8
  %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 i32, align 4
  store ptr %0, ptr %3, align 8, !tbaa !5
  %10 = load ptr, ptr %3, align 8, !tbaa !5
  %11 = getelementptr inbounds %struct.HighsIndexCollection, ptr %10, i32 0, i32 1
  %12 = load i8, ptr %11, align 4, !tbaa !9, !range !17, !noundef !18
  %13 = trunc i8 %12 to i1
  br i1 %13, label %14, label %57

14:                                               ; preds = %1
  %15 = load ptr, ptr %3, align 8, !tbaa !5
  %16 = getelementptr inbounds %struct.HighsIndexCollection, ptr %15, i32 0, i32 4
  %17 = load i8, ptr %16, align 8, !tbaa !19, !range !17, !noundef !18
  %18 = trunc i8 %17 to i1
  br i1 %18, label %19, label %21

19:                                               ; preds = %14
  %20 = call i32 (ptr, ...) @printf(ptr noundef @.str.53)
  store i1 false, ptr %2, align 1
  br label %191

21:                                               ; preds = %14
  %22 = load ptr, ptr %3, align 8, !tbaa !5
  %23 = getelementptr inbounds %struct.HighsIndexCollection, ptr %22, i32 0, i32 7
  %24 = load i8, ptr %23, align 8, !tbaa !20, !range !17, !noundef !18
  %25 = trunc i8 %24 to i1
  br i1 %25, label %26, label %28

26:                                               ; preds = %21
  %27 = call i32 (ptr, ...) @printf(ptr noundef @.str.54)
  store i1 false, ptr %2, align 1
  br label %191

28:                                               ; preds = %21
  %29 = load ptr, ptr %3, align 8, !tbaa !5
  %30 = getelementptr inbounds %struct.HighsIndexCollection, ptr %29, i32 0, i32 2
  %31 = load i32, ptr %30, align 8, !tbaa !21
  %32 = icmp slt i32 %31, 0
  br i1 %32, label %33, label %38

33:                                               ; preds = %28
  %34 = load ptr, ptr %3, align 8, !tbaa !5
  %35 = getelementptr inbounds %struct.HighsIndexCollection, ptr %34, i32 0, i32 2
  %36 = load i32, ptr %35, align 8, !tbaa !21
  %37 = call i32 (ptr, ...) @printf(ptr noundef @.str.55, i32 noundef %36)
  store i1 false, ptr %2, align 1
  br label %191

38:                                               ; preds = %28
  %39 = load ptr, ptr %3, align 8, !tbaa !5
  %40 = getelementptr inbounds %struct.HighsIndexCollection, ptr %39, i32 0, i32 3
  %41 = load i32, ptr %40, align 4, !tbaa !22
  %42 = load ptr, ptr %3, align 8, !tbaa !5
  %43 = getelementptr inbounds %struct.HighsIndexCollection, ptr %42, i32 0, i32 0
  %44 = load i32, ptr %43, align 8, !tbaa !23
  %45 = sub nsw i32 %44, 1
  %46 = icmp sgt i32 %41, %45
  br i1 %46, label %47, label %56

47:                                               ; preds = %38
  %48 = load ptr, ptr %3, align 8, !tbaa !5
  %49 = getelementptr inbounds %struct.HighsIndexCollection, ptr %48, i32 0, i32 3
  %50 = load i32, ptr %49, align 4, !tbaa !22
  %51 = load ptr, ptr %3, align 8, !tbaa !5
  %52 = getelementptr inbounds %struct.HighsIndexCollection, ptr %51, i32 0, i32 0
  %53 = load i32, ptr %52, align 8, !tbaa !23
  %54 = sub nsw i32 %53, 1
  %55 = call i32 (ptr, ...) @printf(ptr noundef @.str.56, i32 noundef %50, i32 noundef %54)
  store i1 false, ptr %2, align 1
  br label %191

56:                                               ; preds = %38
  br label %190

57:                                               ; preds = %1
  %58 = load ptr, ptr %3, align 8, !tbaa !5
  %59 = getelementptr inbounds %struct.HighsIndexCollection, ptr %58, i32 0, i32 4
  %60 = load i8, ptr %59, align 8, !tbaa !19, !range !17, !noundef !18
  %61 = trunc i8 %60 to i1
  br i1 %61, label %62, label %160

62:                                               ; preds = %57
  %63 = load ptr, ptr %3, align 8, !tbaa !5
  %64 = getelementptr inbounds %struct.HighsIndexCollection, ptr %63, i32 0, i32 1
  %65 = load i8, ptr %64, align 4, !tbaa !9, !range !17, !noundef !18
  %66 = trunc i8 %65 to i1
  br i1 %66, label %67, label %69

67:                                               ; preds = %62
  %68 = call i32 (ptr, ...) @printf(ptr noundef @.str.57)
  store i1 false, ptr %2, align 1
  br label %191

69:                                               ; preds = %62
  %70 = load ptr, ptr %3, align 8, !tbaa !5
  %71 = getelementptr inbounds %struct.HighsIndexCollection, ptr %70, i32 0, i32 7
  %72 = load i8, ptr %71, align 8, !tbaa !20, !range !17, !noundef !18
  %73 = trunc i8 %72 to i1
  br i1 %73, label %74, label %76

74:                                               ; preds = %69
  %75 = call i32 (ptr, ...) @printf(ptr noundef @.str.58)
  store i1 false, ptr %2, align 1
  br label %191

76:                                               ; preds = %69
  %77 = load ptr, ptr %3, align 8, !tbaa !5
  %78 = getelementptr inbounds %struct.HighsIndexCollection, ptr %77, i32 0, i32 6
  %79 = call noundef zeroext i1 @_ZNKSt6vectorIiSaIiEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %78) #5
  br i1 %79, label %80, label %82

80:                                               ; preds = %76
  %81 = call i32 (ptr, ...) @printf(ptr noundef @.str.59)
  store i1 false, ptr %2, align 1
  br label %191

82:                                               ; preds = %76
  call void @llvm.lifetime.start.p0(i64 8, ptr %4) #5
  %83 = load ptr, ptr %3, align 8, !tbaa !5
  %84 = getelementptr inbounds %struct.HighsIndexCollection, ptr %83, i32 0, i32 6
  store ptr %84, ptr %4, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #5
  %85 = load ptr, ptr %3, align 8, !tbaa !5
  %86 = getelementptr inbounds %struct.HighsIndexCollection, ptr %85, i32 0, i32 5
  %87 = load i32, ptr %86, align 4, !tbaa !24
  store i32 %87, ptr %5, align 4, !tbaa !25
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #5
  %88 = load ptr, ptr %3, align 8, !tbaa !5
  %89 = getelementptr inbounds %struct.HighsIndexCollection, ptr %88, i32 0, i32 0
  %90 = load i32, ptr %89, align 8, !tbaa !23
  %91 = sub nsw i32 %90, 1
  store i32 %91, ptr %6, align 4, !tbaa !25
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #5
  store i32 -1, ptr %7, align 4, !tbaa !25
  call void @llvm.lifetime.start.p0(i64 4, ptr %8) #5
  store i32 0, ptr %8, align 4, !tbaa !25
  br label %92

92:                                               ; preds = %144, %82
  %93 = load i32, ptr %8, align 4, !tbaa !25
  %94 = load i32, ptr %5, align 4, !tbaa !25
  %95 = icmp slt i32 %93, %94
  br i1 %95, label %97, label %96

96:                                               ; preds = %92
  store i32 2, ptr %9, align 4
  br label %147

97:                                               ; preds = %92
  %98 = load ptr, ptr %4, align 8, !tbaa !5
  %99 = load i32, ptr %8, align 4, !tbaa !25
  %100 = sext i32 %99 to i64
  %101 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %98, i64 noundef %100) #5
  %102 = load i32, ptr %101, align 4, !tbaa !25
  %103 = icmp slt i32 %102, 0
  br i1 %103, label %112, label %104

104:                                              ; preds = %97
  %105 = load ptr, ptr %4, align 8, !tbaa !5
  %106 = load i32, ptr %8, align 4, !tbaa !25
  %107 = sext i32 %106 to i64
  %108 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %105, i64 noundef %107) #5
  %109 = load i32, ptr %108, align 4, !tbaa !25
  %110 = load i32, ptr %6, align 4, !tbaa !25
  %111 = icmp sgt i32 %109, %110
  br i1 %111, label %112, label %121

112:                                              ; preds = %104, %97
  %113 = load i32, ptr %8, align 4, !tbaa !25
  %114 = load ptr, ptr %4, align 8, !tbaa !5
  %115 = load i32, ptr %8, align 4, !tbaa !25
  %116 = sext i32 %115 to i64
  %117 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %114, i64 noundef %116) #5
  %118 = load i32, ptr %117, align 4, !tbaa !25
  %119 = load i32, ptr %6, align 4, !tbaa !25
  %120 = call i32 (ptr, ...) @printf(ptr noundef @.str.60, i32 noundef %113, i32 noundef %118, i32 noundef %119)
  store i1 false, ptr %2, align 1
  store i32 1, ptr %9, align 4
  br label %147

121:                                              ; preds = %104
  %122 = load ptr, ptr %4, align 8, !tbaa !5
  %123 = load i32, ptr %8, align 4, !tbaa !25
  %124 = sext i32 %123 to i64
  %125 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %122, i64 noundef %124) #5
  %126 = load i32, ptr %125, align 4, !tbaa !25
  %127 = load i32, ptr %7, align 4, !tbaa !25
  %128 = icmp sle i32 %126, %127
  br i1 %128, label %129, label %138

129:                                              ; preds = %121
  %130 = load i32, ptr %8, align 4, !tbaa !25
  %131 = load ptr, ptr %4, align 8, !tbaa !5
  %132 = load i32, ptr %8, align 4, !tbaa !25
  %133 = sext i32 %132 to i64
  %134 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %131, i64 noundef %133) #5
  %135 = load i32, ptr %134, align 4, !tbaa !25
  %136 = load i32, ptr %7, align 4, !tbaa !25
  %137 = call i32 (ptr, ...) @printf(ptr noundef @.str.61, i32 noundef %130, i32 noundef %135, i32 noundef %136)
  store i1 false, ptr %2, align 1
  store i32 1, ptr %9, align 4
  br label %147

138:                                              ; preds = %121
  %139 = load ptr, ptr %4, align 8, !tbaa !5
  %140 = load i32, ptr %8, align 4, !tbaa !25
  %141 = sext i32 %140 to i64
  %142 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %139, i64 noundef %141) #5
  %143 = load i32, ptr %142, align 4, !tbaa !25
  store i32 %143, ptr %7, align 4, !tbaa !25
  br label %144

144:                                              ; preds = %138
  %145 = load i32, ptr %8, align 4, !tbaa !25
  %146 = add nsw i32 %145, 1
  store i32 %146, ptr %8, align 4, !tbaa !25
  br label %92, !llvm.loop !26

147:                                              ; preds = %129, %112, %96
  call void @llvm.lifetime.end.p0(i64 4, ptr %8) #5
  %148 = load i32, ptr %9, align 4
  switch i32 %148, label %157 [
    i32 2, label %149
  ]

149:                                              ; preds = %147
  %150 = load ptr, ptr %4, align 8, !tbaa !5
  %151 = load i32, ptr %6, align 4, !tbaa !25
  %152 = call noundef zeroext i1 @_Z15increasingSetOkRKSt6vectorIiSaIiEEiib(ptr noundef nonnull align 8 dereferenceable(24) %150, i32 noundef 0, i32 noundef %151, i1 noundef zeroext true)
  br i1 %152, label %153, label %154

153:                                              ; preds = %149
  br label %156

154:                                              ; preds = %149
  call void @__assert_fail(ptr noundef @.str.62, ptr noundef @.str.52, i32 noundef 152, ptr noundef @__PRETTY_FUNCTION__._Z2okRK20HighsIndexCollection) #6
  unreachable

155:                                              ; No predecessors!
  br label %156

156:                                              ; preds = %155, %153
  store i32 0, ptr %9, align 4
  br label %157

157:                                              ; preds = %156, %147
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %4) #5
  %158 = load i32, ptr %9, align 4
  switch i32 %158, label %193 [
    i32 0, label %159
    i32 1, label %191
  ]

159:                                              ; preds = %157
  br label %189

160:                                              ; preds = %57
  %161 = load ptr, ptr %3, align 8, !tbaa !5
  %162 = getelementptr inbounds %struct.HighsIndexCollection, ptr %161, i32 0, i32 7
  %163 = load i8, ptr %162, align 8, !tbaa !20, !range !17, !noundef !18
  %164 = trunc i8 %163 to i1
  br i1 %164, label %165, label %186

165:                                              ; preds = %160
  %166 = load ptr, ptr %3, align 8, !tbaa !5
  %167 = getelementptr inbounds %struct.HighsIndexCollection, ptr %166, i32 0, i32 8
  %168 = call noundef zeroext i1 @_ZNKSt6vectorIiSaIiEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %167) #5
  br i1 %168, label %169, label %171

169:                                              ; preds = %165
  %170 = call i32 (ptr, ...) @printf(ptr noundef @.str.63)
  store i1 false, ptr %2, align 1
  br label %191

171:                                              ; preds = %165
  %172 = load ptr, ptr %3, align 8, !tbaa !5
  %173 = getelementptr inbounds %struct.HighsIndexCollection, ptr %172, i32 0, i32 1
  %174 = load i8, ptr %173, align 4, !tbaa !9, !range !17, !noundef !18
  %175 = trunc i8 %174 to i1
  br i1 %175, label %176, label %178

176:                                              ; preds = %171
  %177 = call i32 (ptr, ...) @printf(ptr noundef @.str.64)
  store i1 false, ptr %2, align 1
  br label %191

178:                                              ; preds = %171
  %179 = load ptr, ptr %3, align 8, !tbaa !5
  %180 = getelementptr inbounds %struct.HighsIndexCollection, ptr %179, i32 0, i32 4
  %181 = load i8, ptr %180, align 8, !tbaa !19, !range !17, !noundef !18
  %182 = trunc i8 %181 to i1
  br i1 %182, label %183, label %185

183:                                              ; preds = %178
  %184 = call i32 (ptr, ...) @printf(ptr noundef @.str.65)
  store i1 false, ptr %2, align 1
  br label %191

185:                                              ; preds = %178
  br label %188

186:                                              ; preds = %160
  %187 = call i32 (ptr, ...) @printf(ptr noundef @.str.66)
  store i1 false, ptr %2, align 1
  br label %191

188:                                              ; preds = %185
  br label %189

189:                                              ; preds = %188, %159
  br label %190

190:                                              ; preds = %189, %56
  store i1 true, ptr %2, align 1
  br label %191

191:                                              ; preds = %190, %186, %183, %176, %169, %157, %80, %74, %67, %47, %33, %26, %19
  %192 = load i1, ptr %2, align 1
  ret i1 %192

193:                                              ; preds = %157
  unreachable
}

declare i32 @printf(ptr noundef, ...) #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNKSt6vectorIiSaIiEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24)) #2 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 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { noreturn 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 = { 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 #5 = { nounwind }
attributes #6 = { 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, !12, i64 4}
!10 = !{!"_ZTS20HighsIndexCollection", !11, i64 0, !12, i64 4, !11, i64 8, !11, i64 12, !12, i64 16, !11, i64 20, !13, i64 24, !12, i64 48, !13, i64 56}
!11 = !{!"int", !7, i64 0}
!12 = !{!"bool", !7, i64 0}
!13 = !{!"_ZTSSt6vectorIiSaIiEE", !14, i64 0}
!14 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !15, i64 0}
!15 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !16, i64 0}
!16 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!17 = !{i8 0, i8 2}
!18 = !{}
!19 = !{!10, !12, i64 16}
!20 = !{!10, !12, i64 48}
!21 = !{!10, !11, i64 8}
!22 = !{!10, !11, i64 12}
!23 = !{!10, !11, i64 0}
!24 = !{!10, !11, i64 20}
!25 = !{!11, !11, i64 0}
!26 = distinct !{!26, !27}
!27 = !{!"llvm.loop.mustprogress"}


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

@.str.52 = external hidden unnamed_addr constant [73 x i8], align 1
@.str.53 = external hidden unnamed_addr constant [43 x i8], align 1
@.str.54 = external hidden unnamed_addr constant [44 x i8], align 1
@.str.55 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.56 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.58 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.59 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.60 = external hidden unnamed_addr constant [55 x i8], align 1
@.str.61 = external hidden unnamed_addr constant [68 x i8], align 1
@.str.62 = external hidden unnamed_addr constant [43 x i8], align 1
@__PRETTY_FUNCTION__._Z2okRK20HighsIndexCollection = external hidden unnamed_addr constant [38 x i8], align 1
@.str.63 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.64 = external hidden unnamed_addr constant [44 x i8], align 1
@.str.65 = external hidden unnamed_addr constant [39 x i8], align 1
@.str.66 = external hidden unnamed_addr constant [28 x i8], align 1

declare noundef zeroext i1 @_Z15increasingSetOkRKSt6vectorIiSaIiEEiib(ptr noundef nonnull align 8 dereferenceable(24), i32 noundef, i32 noundef, i1 noundef zeroext) local_unnamed_addr #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24), i64 noundef) local_unnamed_addr #1 align 2

; Function Attrs: noreturn nounwind
declare void @__assert_fail(ptr noundef, ptr noundef, i32 noundef, ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_Z2okRK20HighsIndexCollection(ptr noundef nonnull align 8 dereferenceable(80) %0) local_unnamed_addr #3 {
  %2 = getelementptr inbounds i8, ptr %0, i64 4
  %3 = load i8, ptr %2, align 4, !tbaa !5, !range !16, !noundef !17
  %4 = trunc nuw i8 %3 to i1
  %5 = getelementptr inbounds i8, ptr %0, i64 16
  %6 = load i8, ptr %5, align 8, !tbaa !18, !range !16, !noundef !17
  %7 = trunc nuw i8 %6 to i1
  br i1 %4, label %8, label %30

8:                                                ; preds = %1
  br i1 %7, label %9, label %11

9:                                                ; preds = %8
  %10 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.53)
  br label %.thread

11:                                               ; preds = %8
  %12 = getelementptr inbounds i8, ptr %0, i64 48
  %13 = load i8, ptr %12, align 8, !tbaa !19, !range !16, !noundef !17
  %14 = trunc nuw i8 %13 to i1
  br i1 %14, label %15, label %17

15:                                               ; preds = %11
  %16 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.54)
  br label %.thread

17:                                               ; preds = %11
  %18 = getelementptr inbounds i8, ptr %0, i64 8
  %19 = load i32, ptr %18, align 8, !tbaa !20
  %20 = icmp slt i32 %19, 0
  br i1 %20, label %21, label %23

21:                                               ; preds = %17
  %22 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.55, i32 noundef %19)
  br label %.thread

23:                                               ; preds = %17
  %24 = getelementptr inbounds i8, ptr %0, i64 12
  %25 = load i32, ptr %24, align 4, !tbaa !21
  %26 = load i32, ptr %0, align 8, !tbaa !22
  %.not54 = icmp slt i32 %25, %26
  br i1 %.not54, label %.thread, label %27

27:                                               ; preds = %23
  %28 = add nsw i32 %26, -1
  %29 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.56, i32 noundef %25, i32 noundef %28)
  br label %.thread

30:                                               ; preds = %1
  %31 = getelementptr inbounds i8, ptr %0, i64 48
  %32 = load i8, ptr %31, align 8, !tbaa !19, !range !16, !noundef !17
  %33 = trunc nuw i8 %32 to i1
  br i1 %7, label %34, label %71

34:                                               ; preds = %30
  br i1 %33, label %35, label %37

35:                                               ; preds = %34
  %36 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.58)
  br label %.thread

37:                                               ; preds = %34
  %38 = getelementptr inbounds i8, ptr %0, i64 24
  %39 = tail call noundef zeroext i1 @_ZNKSt6vectorIiSaIiEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %38) #5
  br i1 %39, label %40, label %42

40:                                               ; preds = %37
  %41 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.59)
  br label %.thread

42:                                               ; preds = %37
  %43 = getelementptr inbounds i8, ptr %0, i64 20
  %44 = load i32, ptr %43, align 4, !tbaa !23
  %45 = load i32, ptr %0, align 8, !tbaa !22
  %46 = add nsw i32 %45, -1
  %.not5361 = icmp sgt i32 %44, 0
  br i1 %.not5361, label %.lr.ph.preheader, label %.critedge

.lr.ph.preheader:                                 ; preds = %42
  %wide.trip.count = zext nneg i32 %44 to i64
  br label %.lr.ph

.lr.ph:                                           ; preds = %.lr.ph.preheader, %66
  %indvars.iv = phi i64 [ 0, %.lr.ph.preheader ], [ %indvars.iv.next, %66 ]
  %.04662 = phi i32 [ -1, %.lr.ph.preheader ], [ %68, %66 ]
  %47 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %38, i64 noundef %indvars.iv) #5
  %48 = load i32, ptr %47, align 4, !tbaa !24
  %49 = icmp slt i32 %48, 0
  br i1 %49, label %53, label %50

50:                                               ; preds = %.lr.ph
  %51 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %38, i64 noundef %indvars.iv) #5
  %52 = load i32, ptr %51, align 4, !tbaa !24
  %.not = icmp slt i32 %52, %45
  br i1 %.not, label %58, label %53

53:                                               ; preds = %50, %.lr.ph
  %54 = trunc nuw nsw i64 %indvars.iv to i32
  %55 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %38, i64 noundef %indvars.iv) #5
  %56 = load i32, ptr %55, align 4, !tbaa !24
  %57 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.60, i32 noundef %54, i32 noundef %56, i32 noundef %46)
  br label %.thread

58:                                               ; preds = %50
  %59 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %38, i64 noundef %indvars.iv) #5
  %60 = load i32, ptr %59, align 4, !tbaa !24
  %.not52 = icmp sgt i32 %60, %.04662
  br i1 %.not52, label %66, label %61

61:                                               ; preds = %58
  %62 = trunc nuw nsw i64 %indvars.iv to i32
  %63 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %38, i64 noundef %indvars.iv) #5
  %64 = load i32, ptr %63, align 4, !tbaa !24
  %65 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.61, i32 noundef %62, i32 noundef %64, i32 noundef %.04662)
  br label %.thread

66:                                               ; preds = %58
  %67 = tail call noundef nonnull align 4 dereferenceable(4) ptr @_ZNKSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %38, i64 noundef %indvars.iv) #5
  %68 = load i32, ptr %67, align 4, !tbaa !24
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %exitcond.not = icmp eq i64 %indvars.iv.next, %wide.trip.count
  br i1 %exitcond.not, label %.critedge, label %.lr.ph, !llvm.loop !25

.critedge:                                        ; preds = %66, %42
  %69 = tail call noundef zeroext i1 @_Z15increasingSetOkRKSt6vectorIiSaIiEEiib(ptr noundef nonnull align 8 dereferenceable(24) %38, i32 noundef 0, i32 noundef %46, i1 noundef zeroext true)
  br i1 %69, label %.thread, label %70

70:                                               ; preds = %.critedge
  tail call void @__assert_fail(ptr noundef nonnull @.str.62, ptr noundef nonnull @.str.52, i32 noundef 152, ptr noundef nonnull @__PRETTY_FUNCTION__._Z2okRK20HighsIndexCollection) #6
  unreachable

71:                                               ; preds = %30
  br i1 %33, label %72, label %87

72:                                               ; preds = %71
  %73 = getelementptr inbounds i8, ptr %0, i64 56
  %74 = tail call noundef zeroext i1 @_ZNKSt6vectorIiSaIiEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24) %73) #5
  br i1 %74, label %75, label %77

75:                                               ; preds = %72
  %76 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.63)
  br label %.thread

77:                                               ; preds = %72
  %78 = load i8, ptr %2, align 4, !tbaa !5, !range !16, !noundef !17
  %79 = trunc nuw i8 %78 to i1
  br i1 %79, label %80, label %82

80:                                               ; preds = %77
  %81 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.64)
  br label %.thread

82:                                               ; preds = %77
  %83 = load i8, ptr %5, align 8, !tbaa !18, !range !16, !noundef !17
  %84 = trunc nuw i8 %83 to i1
  br i1 %84, label %85, label %.thread

85:                                               ; preds = %82
  %86 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.65)
  br label %.thread

87:                                               ; preds = %71
  %88 = tail call i32 (ptr, ...) @printf(ptr noundef nonnull dereferenceable(1) @.str.66)
  br label %.thread

.thread:                                          ; preds = %61, %53, %23, %82, %.critedge, %87, %85, %80, %75, %40, %35, %27, %21, %15, %9
  %.148 = phi i1 [ false, %9 ], [ false, %15 ], [ false, %21 ], [ false, %27 ], [ false, %35 ], [ false, %40 ], [ false, %75 ], [ false, %80 ], [ false, %85 ], [ false, %87 ], [ true, %.critedge ], [ true, %82 ], [ true, %23 ], [ false, %53 ], [ false, %61 ]
  ret i1 %.148
}

; Function Attrs: nofree nounwind
declare noundef i32 @printf(ptr nocapture noundef readonly, ...) local_unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef zeroext i1 @_ZNKSt6vectorIiSaIiEE5emptyEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #1 align 2

attributes #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 #1 = { 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 #2 = { noreturn 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 = { nofree 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 #5 = { nounwind }
attributes #6 = { 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, !10, i64 4}
!6 = !{!"_ZTS20HighsIndexCollection", !7, i64 0, !10, i64 4, !7, i64 8, !7, i64 12, !10, i64 16, !7, i64 20, !11, i64 24, !10, i64 48, !11, i64 56}
!7 = !{!"int", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"bool", !8, i64 0}
!11 = !{!"_ZTSSt6vectorIiSaIiEE", !12, i64 0}
!12 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !13, i64 0}
!13 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !14, i64 0}
!14 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !15, i64 0, !15, i64 8, !15, i64 16}
!15 = !{!"any pointer", !8, i64 0}
!16 = !{i8 0, i8 2}
!17 = !{}
!18 = !{!6, !10, i64 16}
!19 = !{!6, !10, i64 48}
!20 = !{!6, !7, i64 8}
!21 = !{!6, !7, i64 12}
!22 = !{!6, !7, i64 0}
!23 = !{!6, !7, i64 20}
!24 = !{!7, !7, i64 0}
!25 = distinct !{!25, !26}
!26 = !{!"llvm.loop.mustprogress"}


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