; LLVM IR from stan-dev/math :: lib/sundials_6.1.1/src/idas (idas_ls)

; 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._generic_SUNLinearSolver = type { ptr, ptr, ptr }
%struct._generic_SUNLinearSolver_Ops = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }
%struct.IDAMemRec = type { ptr, double, ptr, ptr, i32, double, double, ptr, i32, i32, ptr, ptr, i32, i32, i32, ptr, ptr, i32, i32, double, double, ptr, i32, i32, i32, i32, ptr, ptr, i32, ptr, ptr, ptr, i32, double, i32, i32, double, ptr, ptr, ptr, i32, ptr, ptr, i32, i32, i32, double, ptr, ptr, ptr, [6 x ptr], [6 x double], [6 x double], [6 x double], [6 x double], [6 x double], ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, [6 x ptr], ptr, ptr, ptr, ptr, [6 x ptr], ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, [6 x ptr], ptr, ptr, ptr, ptr, ptr, double, ptr, ptr, i32, i32, i32, i32, i32, i32, i32, i32, double, double, double, i32, double, i32, i32, i32, i32, i32, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, i32, i32, i32, i32, i64, double, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, double, ptr, ptr, ptr, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, i32, ptr, i32, ptr, i32, ptr, i32, ptr, ptr, ptr, ptr, ptr, ptr, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, i32, ptr, i32, ptr, ptr, double, double, double, ptr, ptr, ptr, double, double, i32, i32, i64, ptr, i32, ptr, [5 x double], ptr, ptr, i32, ptr, i32 }
%struct._generic_N_Vector = type { ptr, ptr, ptr }
%struct._generic_N_Vector_Ops = type { ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr }
%struct.IDALsMemRec = type { i32, i32, i32, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, ptr, i32, double, double, double, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i64, i32, ptr, ptr, ptr, ptr, i32, ptr, ptr, ptr, ptr }

@.str = external hidden unnamed_addr constant [7 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [42 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [48 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [61 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [61 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [62 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [66 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [56 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [36 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [44 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local i32 @IDASetLinearSolver(ptr noundef %0, ptr noundef %1, ptr noundef %2) #0 {
  %4 = alloca i32, align 4
  %5 = alloca ptr, align 8
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  store ptr %0, ptr %5, align 8, !tbaa !5
  store ptr %1, ptr %6, align 8, !tbaa !5
  store ptr %2, ptr %7, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %11) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #6
  call void @llvm.lifetime.start.p0(i64 4, ptr %13) #6
  %15 = load ptr, ptr %5, align 8, !tbaa !5
  %16 = icmp eq ptr %15, null
  br i1 %16, label %17, label %18

17:                                               ; preds = %3
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef null, i32 noundef -1, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.2)
  store i32 -1, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

18:                                               ; preds = %3
  %19 = load ptr, ptr %6, align 8, !tbaa !5
  %20 = icmp eq ptr %19, null
  br i1 %20, label %21, label %22

21:                                               ; preds = %18
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef null, i32 noundef -3, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.3)
  store i32 -3, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

22:                                               ; preds = %18
  %23 = load ptr, ptr %5, align 8, !tbaa !5
  store ptr %23, ptr %8, align 8, !tbaa !5
  %24 = load ptr, ptr %6, align 8, !tbaa !5
  %25 = getelementptr inbounds %struct._generic_SUNLinearSolver, ptr %24, i32 0, i32 1
  %26 = load ptr, ptr %25, align 8, !tbaa !9
  %27 = getelementptr inbounds %struct._generic_SUNLinearSolver_Ops, ptr %26, i32 0, i32 0
  %28 = load ptr, ptr %27, align 8, !tbaa !11
  %29 = icmp eq ptr %28, null
  br i1 %29, label %37, label %30

30:                                               ; preds = %22
  %31 = load ptr, ptr %6, align 8, !tbaa !5
  %32 = getelementptr inbounds %struct._generic_SUNLinearSolver, ptr %31, i32 0, i32 1
  %33 = load ptr, ptr %32, align 8, !tbaa !9
  %34 = getelementptr inbounds %struct._generic_SUNLinearSolver_Ops, ptr %33, i32 0, i32 8
  %35 = load ptr, ptr %34, align 8, !tbaa !13
  %36 = icmp eq ptr %35, null
  br i1 %36, label %37, label %39

37:                                               ; preds = %30, %22
  %38 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %38, i32 noundef -3, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.4)
  store i32 -3, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

39:                                               ; preds = %30
  %40 = load ptr, ptr %6, align 8, !tbaa !5
  %41 = call i32 @SUNLinSolGetType(ptr noundef %40)
  store i32 %41, ptr %11, align 4, !tbaa !14
  %42 = load i32, ptr %11, align 4, !tbaa !14
  %43 = icmp ne i32 %42, 0
  %44 = zext i1 %43 to i32
  store i32 %44, ptr %12, align 4, !tbaa !14
  %45 = load i32, ptr %11, align 4, !tbaa !14
  %46 = icmp ne i32 %45, 1
  br i1 %46, label %47, label %50

47:                                               ; preds = %39
  %48 = load i32, ptr %11, align 4, !tbaa !14
  %49 = icmp ne i32 %48, 3
  br label %50

50:                                               ; preds = %47, %39
  %51 = phi i1 [ false, %39 ], [ %49, %47 ]
  %52 = zext i1 %51 to i32
  store i32 %52, ptr %13, align 4, !tbaa !14
  %53 = load ptr, ptr %8, align 8, !tbaa !5
  %54 = getelementptr inbounds %struct.IDAMemRec, ptr %53, i32 0, i32 66
  %55 = load ptr, ptr %54, align 8, !tbaa !16
  %56 = getelementptr inbounds %struct._generic_N_Vector, ptr %55, i32 0, i32 1
  %57 = load ptr, ptr %56, align 8, !tbaa !20
  %58 = getelementptr inbounds %struct._generic_N_Vector_Ops, ptr %57, i32 0, i32 11
  %59 = load ptr, ptr %58, align 8, !tbaa !22
  %60 = icmp eq ptr %59, null
  br i1 %60, label %70, label %61

61:                                               ; preds = %50
  %62 = load ptr, ptr %8, align 8, !tbaa !5
  %63 = getelementptr inbounds %struct.IDAMemRec, ptr %62, i32 0, i32 66
  %64 = load ptr, ptr %63, align 8, !tbaa !16
  %65 = getelementptr inbounds %struct._generic_N_Vector, ptr %64, i32 0, i32 1
  %66 = load ptr, ptr %65, align 8, !tbaa !20
  %67 = getelementptr inbounds %struct._generic_N_Vector_Ops, ptr %66, i32 0, i32 20
  %68 = load ptr, ptr %67, align 8, !tbaa !24
  %69 = icmp eq ptr %68, null
  br i1 %69, label %70, label %72

70:                                               ; preds = %61, %50
  %71 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %71, i32 noundef -3, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.5)
  store i32 -3, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

72:                                               ; preds = %61
  %73 = load i32, ptr %11, align 4, !tbaa !14
  %74 = icmp eq i32 %73, 3
  br i1 %74, label %75, label %80

75:                                               ; preds = %72
  %76 = load ptr, ptr %7, align 8, !tbaa !5
  %77 = icmp ne ptr %76, null
  br i1 %77, label %78, label %80

78:                                               ; preds = %75
  %79 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %79, i32 noundef -3, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.6)
  store i32 -3, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

80:                                               ; preds = %75, %72
  %81 = load i32, ptr %12, align 4, !tbaa !14
  %82 = icmp ne i32 %81, 0
  br i1 %82, label %83, label %138

83:                                               ; preds = %80
  %84 = load ptr, ptr %8, align 8, !tbaa !5
  %85 = getelementptr inbounds %struct.IDAMemRec, ptr %84, i32 0, i32 66
  %86 = load ptr, ptr %85, align 8, !tbaa !16
  %87 = getelementptr inbounds %struct._generic_N_Vector, ptr %86, i32 0, i32 1
  %88 = load ptr, ptr %87, align 8, !tbaa !20
  %89 = getelementptr inbounds %struct._generic_N_Vector_Ops, ptr %88, i32 0, i32 9
  %90 = load ptr, ptr %89, align 8, !tbaa !25
  %91 = icmp eq ptr %90, null
  br i1 %91, label %92, label %94

92:                                               ; preds = %83
  %93 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %93, i32 noundef -3, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.5)
  store i32 -3, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

94:                                               ; preds = %83
  %95 = load i32, ptr %11, align 4, !tbaa !14
  %96 = icmp ne i32 %95, 3
  br i1 %96, label %97, label %114

97:                                               ; preds = %94
  %98 = load ptr, ptr %6, align 8, !tbaa !5
  %99 = getelementptr inbounds %struct._generic_SUNLinearSolver, ptr %98, i32 0, i32 1
  %100 = load ptr, ptr %99, align 8, !tbaa !9
  %101 = getelementptr inbounds %struct._generic_SUNLinearSolver_Ops, ptr %100, i32 0, i32 13
  %102 = load ptr, ptr %101, align 8, !tbaa !26
  %103 = icmp eq ptr %102, null
  br i1 %103, label %111, label %104

104:                                              ; preds = %97
  %105 = load ptr, ptr %6, align 8, !tbaa !5
  %106 = getelementptr inbounds %struct._generic_SUNLinearSolver, ptr %105, i32 0, i32 1
  %107 = load ptr, ptr %106, align 8, !tbaa !9
  %108 = getelementptr inbounds %struct._generic_SUNLinearSolver_Ops, ptr %107, i32 0, i32 9
  %109 = load ptr, ptr %108, align 8, !tbaa !27
  %110 = icmp eq ptr %109, null
  br i1 %110, label %111, label %113

111:                                              ; preds = %104, %97
  %112 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %112, i32 noundef -3, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.7)
  store i32 -3, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

113:                                              ; preds = %104
  br label %114

114:                                              ; preds = %113, %94
  %115 = load i32, ptr %13, align 4, !tbaa !14
  %116 = icmp ne i32 %115, 0
  br i1 %116, label %129, label %117

117:                                              ; preds = %114
  %118 = load i32, ptr %11, align 4, !tbaa !14
  %119 = icmp ne i32 %118, 3
  br i1 %119, label %120, label %129

120:                                              ; preds = %117
  %121 = load ptr, ptr %6, align 8, !tbaa !5
  %122 = getelementptr inbounds %struct._generic_SUNLinearSolver, ptr %121, i32 0, i32 1
  %123 = load ptr, ptr %122, align 8, !tbaa !9
  %124 = getelementptr inbounds %struct._generic_SUNLinearSolver_Ops, ptr %123, i32 0, i32 2
  %125 = load ptr, ptr %124, align 8, !tbaa !28
  %126 = icmp eq ptr %125, null
  br i1 %126, label %127, label %129

127:                                              ; preds = %120
  %128 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %128, i32 noundef -3, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.8)
  store i32 -3, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

129:                                              ; preds = %120, %117, %114
  %130 = load i32, ptr %13, align 4, !tbaa !14
  %131 = icmp ne i32 %130, 0
  br i1 %131, label %132, label %137

132:                                              ; preds = %129
  %133 = load ptr, ptr %7, align 8, !tbaa !5
  %134 = icmp eq ptr %133, null
  br i1 %134, label %135, label %137

135:                                              ; preds = %132
  %136 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %136, i32 noundef -3, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.9)
  store i32 -3, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

137:                                              ; preds = %132, %129
  br label %144

138:                                              ; preds = %80
  %139 = load ptr, ptr %7, align 8, !tbaa !5
  %140 = icmp eq ptr %139, null
  br i1 %140, label %141, label %143

141:                                              ; preds = %138
  %142 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %142, i32 noundef -3, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.10)
  store i32 -3, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

143:                                              ; preds = %138
  br label %144

144:                                              ; preds = %143, %137
  %145 = load ptr, ptr %8, align 8, !tbaa !5
  %146 = getelementptr inbounds %struct.IDAMemRec, ptr %145, i32 0, i32 205
  %147 = load ptr, ptr %146, align 8, !tbaa !29
  %148 = icmp ne ptr %147, null
  br i1 %148, label %149, label %155

149:                                              ; preds = %144
  %150 = load ptr, ptr %8, align 8, !tbaa !5
  %151 = getelementptr inbounds %struct.IDAMemRec, ptr %150, i32 0, i32 205
  %152 = load ptr, ptr %151, align 8, !tbaa !29
  %153 = load ptr, ptr %8, align 8, !tbaa !5
  %154 = call i32 %152(ptr noundef %153)
  br label %155

155:                                              ; preds = %149, %144
  %156 = load ptr, ptr %8, align 8, !tbaa !5
  %157 = getelementptr inbounds %struct.IDAMemRec, ptr %156, i32 0, i32 201
  store ptr @idaLsInitialize, ptr %157, align 8, !tbaa !30
  %158 = load ptr, ptr %8, align 8, !tbaa !5
  %159 = getelementptr inbounds %struct.IDAMemRec, ptr %158, i32 0, i32 202
  store ptr @idaLsSetup, ptr %159, align 8, !tbaa !31
  %160 = load ptr, ptr %8, align 8, !tbaa !5
  %161 = getelementptr inbounds %struct.IDAMemRec, ptr %160, i32 0, i32 203
  store ptr @idaLsSolve, ptr %161, align 8, !tbaa !32
  %162 = load ptr, ptr %8, align 8, !tbaa !5
  %163 = getelementptr inbounds %struct.IDAMemRec, ptr %162, i32 0, i32 205
  store ptr @idaLsFree, ptr %163, align 8, !tbaa !29
  %164 = load i32, ptr %12, align 4, !tbaa !14
  %165 = icmp ne i32 %164, 0
  %166 = zext i1 %165 to i64
  %167 = select i1 %165, ptr @idaLsPerf, ptr null
  %168 = load ptr, ptr %8, align 8, !tbaa !5
  %169 = getelementptr inbounds %struct.IDAMemRec, ptr %168, i32 0, i32 204
  store ptr %167, ptr %169, align 8, !tbaa !33
  store ptr null, ptr %9, align 8, !tbaa !5
  %170 = call noalias ptr @malloc(i64 noundef 312) #7
  store ptr %170, ptr %9, align 8, !tbaa !5
  %171 = load ptr, ptr %9, align 8, !tbaa !5
  %172 = icmp eq ptr %171, null
  br i1 %172, label %173, label %175

173:                                              ; preds = %155
  %174 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %174, i32 noundef -4, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.11)
  store i32 -4, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

175:                                              ; preds = %155
  %176 = load ptr, ptr %9, align 8, !tbaa !5
  call void @llvm.memset.p0.i64(ptr align 8 %176, i8 0, i64 312, i1 false)
  %177 = load ptr, ptr %6, align 8, !tbaa !5
  %178 = load ptr, ptr %9, align 8, !tbaa !5
  %179 = getelementptr inbounds %struct.IDALsMemRec, ptr %178, i32 0, i32 5
  store ptr %177, ptr %179, align 8, !tbaa !34
  %180 = load i32, ptr %12, align 4, !tbaa !14
  %181 = load ptr, ptr %9, align 8, !tbaa !5
  %182 = getelementptr inbounds %struct.IDALsMemRec, ptr %181, i32 0, i32 0
  store i32 %180, ptr %182, align 8, !tbaa !36
  %183 = load i32, ptr %13, align 4, !tbaa !14
  %184 = load ptr, ptr %9, align 8, !tbaa !5
  %185 = getelementptr inbounds %struct.IDALsMemRec, ptr %184, i32 0, i32 1
  store i32 %183, ptr %185, align 4, !tbaa !37
  %186 = load ptr, ptr %7, align 8, !tbaa !5
  %187 = load ptr, ptr %9, align 8, !tbaa !5
  %188 = getelementptr inbounds %struct.IDALsMemRec, ptr %187, i32 0, i32 6
  store ptr %186, ptr %188, align 8, !tbaa !38
  %189 = load ptr, ptr %7, align 8, !tbaa !5
  %190 = icmp ne ptr %189, null
  br i1 %190, label %191, label %199

191:                                              ; preds = %175
  %192 = load ptr, ptr %9, align 8, !tbaa !5
  %193 = getelementptr inbounds %struct.IDALsMemRec, ptr %192, i32 0, i32 2
  store i32 1, ptr %193, align 8, !tbaa !39
  %194 = load ptr, ptr %9, align 8, !tbaa !5
  %195 = getelementptr inbounds %struct.IDALsMemRec, ptr %194, i32 0, i32 3
  store ptr @idaLsDQJac, ptr %195, align 8, !tbaa !40
  %196 = load ptr, ptr %8, align 8, !tbaa !5
  %197 = load ptr, ptr %9, align 8, !tbaa !5
  %198 = getelementptr inbounds %struct.IDALsMemRec, ptr %197, i32 0, i32 4
  store ptr %196, ptr %198, align 8, !tbaa !41
  br label %206

199:                                              ; preds = %175
  %200 = load ptr, ptr %9, align 8, !tbaa !5
  %201 = getelementptr inbounds %struct.IDALsMemRec, ptr %200, i32 0, i32 2
  store i32 0, ptr %201, align 8, !tbaa !39
  %202 = load ptr, ptr %9, align 8, !tbaa !5
  %203 = getelementptr inbounds %struct.IDALsMemRec, ptr %202, i32 0, i32 3
  store ptr null, ptr %203, align 8, !tbaa !40
  %204 = load ptr, ptr %9, align 8, !tbaa !5
  %205 = getelementptr inbounds %struct.IDALsMemRec, ptr %204, i32 0, i32 4
  store ptr null, ptr %205, align 8, !tbaa !41
  br label %206

206:                                              ; preds = %199, %191
  %207 = load ptr, ptr %9, align 8, !tbaa !5
  %208 = getelementptr inbounds %struct.IDALsMemRec, ptr %207, i32 0, i32 35
  store i32 1, ptr %208, align 8, !tbaa !42
  %209 = load ptr, ptr %9, align 8, !tbaa !5
  %210 = getelementptr inbounds %struct.IDALsMemRec, ptr %209, i32 0, i32 36
  store ptr null, ptr %210, align 8, !tbaa !43
  %211 = load ptr, ptr %9, align 8, !tbaa !5
  %212 = getelementptr inbounds %struct.IDALsMemRec, ptr %211, i32 0, i32 37
  store ptr @idaLsDQJtimes, ptr %212, align 8, !tbaa !44
  %213 = load ptr, ptr %8, align 8, !tbaa !5
  %214 = getelementptr inbounds %struct.IDAMemRec, ptr %213, i32 0, i32 2
  %215 = load ptr, ptr %214, align 8, !tbaa !45
  %216 = load ptr, ptr %9, align 8, !tbaa !5
  %217 = getelementptr inbounds %struct.IDALsMemRec, ptr %216, i32 0, i32 38
  store ptr %215, ptr %217, align 8, !tbaa !46
  %218 = load ptr, ptr %8, align 8, !tbaa !5
  %219 = load ptr, ptr %9, align 8, !tbaa !5
  %220 = getelementptr inbounds %struct.IDALsMemRec, ptr %219, i32 0, i32 39
  store ptr %218, ptr %220, align 8, !tbaa !47
  %221 = load ptr, ptr %9, align 8, !tbaa !5
  %222 = getelementptr inbounds %struct.IDALsMemRec, ptr %221, i32 0, i32 31
  store ptr null, ptr %222, align 8, !tbaa !48
  %223 = load ptr, ptr %9, align 8, !tbaa !5
  %224 = getelementptr inbounds %struct.IDALsMemRec, ptr %223, i32 0, i32 32
  store ptr null, ptr %224, align 8, !tbaa !49
  %225 = load ptr, ptr %9, align 8, !tbaa !5
  %226 = getelementptr inbounds %struct.IDALsMemRec, ptr %225, i32 0, i32 33
  store ptr null, ptr %226, align 8, !tbaa !50
  %227 = load ptr, ptr %8, align 8, !tbaa !5
  %228 = getelementptr inbounds %struct.IDAMemRec, ptr %227, i32 0, i32 3
  %229 = load ptr, ptr %228, align 8, !tbaa !51
  %230 = load ptr, ptr %9, align 8, !tbaa !5
  %231 = getelementptr inbounds %struct.IDALsMemRec, ptr %230, i32 0, i32 34
  store ptr %229, ptr %231, align 8, !tbaa !52
  %232 = load ptr, ptr %9, align 8, !tbaa !5
  %233 = call i32 @idaLsInitializeCounters(ptr noundef %232)
  %234 = load ptr, ptr %9, align 8, !tbaa !5
  %235 = getelementptr inbounds %struct.IDALsMemRec, ptr %234, i32 0, i32 14
  store double 5.000000e-02, ptr %235, align 8, !tbaa !53
  %236 = load ptr, ptr %9, align 8, !tbaa !5
  %237 = getelementptr inbounds %struct.IDALsMemRec, ptr %236, i32 0, i32 16
  store double 1.000000e+00, ptr %237, align 8, !tbaa !54
  %238 = load ptr, ptr %9, align 8, !tbaa !5
  %239 = getelementptr inbounds %struct.IDALsMemRec, ptr %238, i32 0, i32 30
  store i32 0, ptr %239, align 8, !tbaa !55
  %240 = load ptr, ptr %6, align 8, !tbaa !5
  %241 = getelementptr inbounds %struct._generic_SUNLinearSolver, ptr %240, i32 0, i32 1
  %242 = load ptr, ptr %241, align 8, !tbaa !9
  %243 = getelementptr inbounds %struct._generic_SUNLinearSolver_Ops, ptr %242, i32 0, i32 2
  %244 = load ptr, ptr %243, align 8, !tbaa !28
  %245 = icmp ne ptr %244, null
  br i1 %245, label %246, label %256

246:                                              ; preds = %206
  %247 = load ptr, ptr %6, align 8, !tbaa !5
  %248 = load ptr, ptr %8, align 8, !tbaa !5
  %249 = call i32 @SUNLinSolSetATimes(ptr noundef %247, ptr noundef %248, ptr noundef @idaLsATimes)
  store i32 %249, ptr %10, align 4, !tbaa !14
  %250 = load i32, ptr %10, align 4, !tbaa !14
  %251 = icmp ne i32 %250, 0
  br i1 %251, label %252, label %255

252:                                              ; preds = %246
  %253 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %253, i32 noundef -9, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.12)
  %254 = load ptr, ptr %9, align 8, !tbaa !5
  call void @free(ptr noundef %254) #6
  store ptr null, ptr %9, align 8, !tbaa !5
  store i32 -9, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

255:                                              ; preds = %246
  br label %256

256:                                              ; preds = %255, %206
  %257 = load ptr, ptr %6, align 8, !tbaa !5
  %258 = getelementptr inbounds %struct._generic_SUNLinearSolver, ptr %257, i32 0, i32 1
  %259 = load ptr, ptr %258, align 8, !tbaa !9
  %260 = getelementptr inbounds %struct._generic_SUNLinearSolver_Ops, ptr %259, i32 0, i32 3
  %261 = load ptr, ptr %260, align 8, !tbaa !56
  %262 = icmp ne ptr %261, null
  br i1 %262, label %263, label %273

263:                                              ; preds = %256
  %264 = load ptr, ptr %6, align 8, !tbaa !5
  %265 = load ptr, ptr %8, align 8, !tbaa !5
  %266 = call i32 @SUNLinSolSetPreconditioner(ptr noundef %264, ptr noundef %265, ptr noundef null, ptr noundef null)
  store i32 %266, ptr %10, align 4, !tbaa !14
  %267 = load i32, ptr %10, align 4, !tbaa !14
  %268 = icmp ne i32 %267, 0
  br i1 %268, label %269, label %272

269:                                              ; preds = %263
  %270 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %270, i32 noundef -9, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.13)
  %271 = load ptr, ptr %9, align 8, !tbaa !5
  call void @free(ptr noundef %271) #6
  store ptr null, ptr %9, align 8, !tbaa !5
  store i32 -9, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

272:                                              ; preds = %263
  br label %273

273:                                              ; preds = %272, %256
  %274 = load ptr, ptr %8, align 8, !tbaa !5
  %275 = getelementptr inbounds %struct.IDAMemRec, ptr %274, i32 0, i32 66
  %276 = load ptr, ptr %275, align 8, !tbaa !16
  %277 = call ptr @N_VClone(ptr noundef %276)
  %278 = load ptr, ptr %9, align 8, !tbaa !5
  %279 = getelementptr inbounds %struct.IDALsMemRec, ptr %278, i32 0, i32 7
  store ptr %277, ptr %279, align 8, !tbaa !57
  %280 = load ptr, ptr %9, align 8, !tbaa !5
  %281 = getelementptr inbounds %struct.IDALsMemRec, ptr %280, i32 0, i32 7
  %282 = load ptr, ptr %281, align 8, !tbaa !57
  %283 = icmp eq ptr %282, null
  br i1 %283, label %284, label %287

284:                                              ; preds = %273
  %285 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %285, i32 noundef -4, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.11)
  %286 = load ptr, ptr %9, align 8, !tbaa !5
  call void @free(ptr noundef %286) #6
  store ptr null, ptr %9, align 8, !tbaa !5
  store i32 -4, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

287:                                              ; preds = %273
  %288 = load ptr, ptr %8, align 8, !tbaa !5
  %289 = getelementptr inbounds %struct.IDAMemRec, ptr %288, i32 0, i32 66
  %290 = load ptr, ptr %289, align 8, !tbaa !16
  %291 = call ptr @N_VClone(ptr noundef %290)
  %292 = load ptr, ptr %9, align 8, !tbaa !5
  %293 = getelementptr inbounds %struct.IDALsMemRec, ptr %292, i32 0, i32 8
  store ptr %291, ptr %293, align 8, !tbaa !58
  %294 = load ptr, ptr %9, align 8, !tbaa !5
  %295 = getelementptr inbounds %struct.IDALsMemRec, ptr %294, i32 0, i32 8
  %296 = load ptr, ptr %295, align 8, !tbaa !58
  %297 = icmp eq ptr %296, null
  br i1 %297, label %298, label %304

298:                                              ; preds = %287
  %299 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %299, i32 noundef -4, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.11)
  %300 = load ptr, ptr %9, align 8, !tbaa !5
  %301 = getelementptr inbounds %struct.IDALsMemRec, ptr %300, i32 0, i32 7
  %302 = load ptr, ptr %301, align 8, !tbaa !57
  call void @N_VDestroy(ptr noundef %302)
  %303 = load ptr, ptr %9, align 8, !tbaa !5
  call void @free(ptr noundef %303) #6
  store ptr null, ptr %9, align 8, !tbaa !5
  store i32 -4, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

304:                                              ; preds = %287
  %305 = load ptr, ptr %8, align 8, !tbaa !5
  %306 = getelementptr inbounds %struct.IDAMemRec, ptr %305, i32 0, i32 66
  %307 = load ptr, ptr %306, align 8, !tbaa !16
  %308 = call ptr @N_VClone(ptr noundef %307)
  %309 = load ptr, ptr %9, align 8, !tbaa !5
  %310 = getelementptr inbounds %struct.IDALsMemRec, ptr %309, i32 0, i32 9
  store ptr %308, ptr %310, align 8, !tbaa !59
  %311 = load ptr, ptr %9, align 8, !tbaa !5
  %312 = getelementptr inbounds %struct.IDALsMemRec, ptr %311, i32 0, i32 9
  %313 = load ptr, ptr %312, align 8, !tbaa !59
  %314 = icmp eq ptr %313, null
  br i1 %314, label %315, label %324

315:                                              ; preds = %304
  %316 = load ptr, ptr %8, align 8, !tbaa !5
  call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef %316, i32 noundef -4, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @.str.11)
  %317 = load ptr, ptr %9, align 8, !tbaa !5
  %318 = getelementptr inbounds %struct.IDALsMemRec, ptr %317, i32 0, i32 7
  %319 = load ptr, ptr %318, align 8, !tbaa !57
  call void @N_VDestroy(ptr noundef %319)
  %320 = load ptr, ptr %9, align 8, !tbaa !5
  %321 = getelementptr inbounds %struct.IDALsMemRec, ptr %320, i32 0, i32 8
  %322 = load ptr, ptr %321, align 8, !tbaa !58
  call void @N_VDestroy(ptr noundef %322)
  %323 = load ptr, ptr %9, align 8, !tbaa !5
  call void @free(ptr noundef %323) #6
  store ptr null, ptr %9, align 8, !tbaa !5
  store i32 -4, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

324:                                              ; preds = %304
  %325 = load i32, ptr %12, align 4, !tbaa !14
  %326 = icmp ne i32 %325, 0
  br i1 %326, label %327, label %346

327:                                              ; preds = %324
  %328 = load ptr, ptr %9, align 8, !tbaa !5
  %329 = getelementptr inbounds %struct.IDALsMemRec, ptr %328, i32 0, i32 7
  %330 = load ptr, ptr %329, align 8, !tbaa !57
  %331 = call i64 @N_VGetLength(ptr noundef %330)
  %332 = sitofp i64 %331 to double
  %333 = fcmp ole double %332, 0.000000e+00
  br i1 %333, label %334, label %335

334:                                              ; preds = %327
  br label %342

335:                                              ; preds = %327
  %336 = load ptr, ptr %9, align 8, !tbaa !5
  %337 = getelementptr inbounds %struct.IDALsMemRec, ptr %336, i32 0, i32 7
  %338 = load ptr, ptr %337, align 8, !tbaa !57
  %339 = call i64 @N_VGetLength(ptr noundef %338)
  %340 = sitofp i64 %339 to double
  %341 = call double @sqrt(double noundef %340) #6
  br label %342

342:                                              ; preds = %335, %334
  %343 = phi double [ 0.000000e+00, %334 ], [ %341, %335 ]
  %344 = load ptr, ptr %9, align 8, !tbaa !5
  %345 = getelementptr inbounds %struct.IDALsMemRec, ptr %344, i32 0, i32 15
  store double %343, ptr %345, align 8, !tbaa !60
  br label %346

346:                                              ; preds = %342, %324
  %347 = load i32, ptr %13, align 4, !tbaa !14
  %348 = icmp ne i32 %347, 0
  br i1 %348, label %349, label %352

349:                                              ; preds = %346
  %350 = load ptr, ptr %9, align 8, !tbaa !5
  %351 = getelementptr inbounds %struct.IDALsMemRec, ptr %350, i32 0, i32 13
  store i32 1, ptr %351, align 8, !tbaa !61
  br label %355

352:                                              ; preds = %346
  %353 = load ptr, ptr %9, align 8, !tbaa !5
  %354 = getelementptr inbounds %struct.IDALsMemRec, ptr %353, i32 0, i32 13
  store i32 0, ptr %354, align 8, !tbaa !61
  br label %355

355:                                              ; preds = %352, %349
  %356 = load ptr, ptr %9, align 8, !tbaa !5
  %357 = load ptr, ptr %8, align 8, !tbaa !5
  %358 = getelementptr inbounds %struct.IDAMemRec, ptr %357, i32 0, i32 206
  store ptr %356, ptr %358, align 8, !tbaa !62
  store i32 0, ptr %4, align 4
  store i32 1, ptr %14, align 4
  br label %359

359:                                              ; preds = %355, %315, %298, %284, %269, %252, %173, %141, %135, %127, %111, %92, %78, %70, %37, %21, %17
  call void @llvm.lifetime.end.p0(i64 4, ptr %13) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %11) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #6
  %360 = load i32, ptr %4, align 4
  ret i32 %360
}

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

declare void @IDAProcessError(ptr noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, ...) #2

declare i32 @SUNLinSolGetType(ptr noundef) #2

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsInitialize(ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsSetup(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsSolve(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsFree(ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsPerf(ptr noundef, i32 noundef) #0

; Function Attrs: nounwind allocsize(0)
declare noalias ptr @malloc(i64 noundef) #3

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

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsDQJac(double noundef, double noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsDQJtimes(double noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, double noundef, ptr noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsInitializeCounters(ptr noundef) #0

declare i32 @SUNLinSolSetATimes(ptr noundef, ptr noundef, ptr noundef) #2

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsATimes(ptr noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind
declare void @free(ptr noundef) #5

declare i32 @SUNLinSolSetPreconditioner(ptr noundef, ptr noundef, ptr noundef, ptr noundef) #2

declare ptr @N_VClone(ptr noundef) #2

declare void @N_VDestroy(ptr noundef) #2

declare i64 @N_VGetLength(ptr noundef) #2

; Function Attrs: nounwind
declare double @sqrt(double noundef) #5

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

attributes #0 = { 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 #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
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 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 #4 = { nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #5 = { 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 #6 = { nounwind }
attributes #7 = { nounwind 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 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C/C++ TBAA"}
!9 = !{!10, !6, i64 8}
!10 = !{!"_generic_SUNLinearSolver", !6, i64 0, !6, i64 8, !6, i64 16}
!11 = !{!12, !6, i64 0}
!12 = !{!"_generic_SUNLinearSolver_Ops", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112}
!13 = !{!12, !6, i64 64}
!14 = !{!15, !15, i64 0}
!15 = !{!"int", !7, i64 0}
!16 = !{!17, !6, i64 712}
!17 = !{!"IDAMemRec", !6, i64 0, !18, i64 8, !6, i64 16, !6, i64 24, !15, i64 32, !18, i64 40, !18, i64 48, !6, i64 56, !15, i64 64, !15, i64 68, !6, i64 72, !6, i64 80, !15, i64 88, !15, i64 92, !15, i64 96, !6, i64 104, !6, i64 112, !15, i64 120, !15, i64 124, !18, i64 128, !18, i64 136, !6, i64 144, !15, i64 152, !15, i64 156, !15, i64 160, !15, i64 164, !6, i64 168, !6, i64 176, !15, i64 184, !6, i64 192, !6, i64 200, !6, i64 208, !15, i64 216, !18, i64 224, !15, i64 232, !15, i64 236, !18, i64 240, !6, i64 248, !6, i64 256, !6, i64 264, !15, i64 272, !6, i64 280, !6, i64 288, !15, i64 296, !15, i64 300, !15, i64 304, !18, i64 312, !6, i64 320, !6, i64 328, !6, i64 336, !7, i64 344, !7, i64 392, !7, i64 440, !7, i64 488, !7, i64 536, !7, i64 584, !6, i64 632, !6, i64 640, !6, i64 648, !6, i64 656, !6, i64 664, !6, i64 672, !6, i64 680, !6, i64 688, !6, i64 696, !6, i64 704, !6, i64 712, !6, i64 720, !6, i64 728, !6, i64 736, !6, i64 744, !6, i64 752, !6, i64 760, !7, i64 768, !6, i64 816, !6, i64 824, !6, i64 832, !6, i64 840, !7, i64 848, !6, i64 896, !6, i64 904, !6, i64 912, !6, i64 920, !6, i64 928, !6, i64 936, !6, i64 944, !6, i64 952, !6, i64 960, !6, i64 968, !6, i64 976, !6, i64 984, !6, i64 992, !6, i64 1000, !6, i64 1008, !6, i64 1016, !7, i64 1024, !6, i64 1072, !6, i64 1080, !6, i64 1088, !6, i64 1096, !6, i64 1104, !18, i64 1112, !6, i64 1120, !6, i64 1128, !15, i64 1136, !15, i64 1140, !15, i64 1144, !15, i64 1148, !15, i64 1152, !15, i64 1156, !15, i64 1160, !15, i64 1164, !18, i64 1168, !18, i64 1176, !18, i64 1184, !15, i64 1192, !18, i64 1200, !15, i64 1208, !15, i64 1212, !15, i64 1216, !15, i64 1220, !15, i64 1224, !18, i64 1232, !18, i64 1240, !18, i64 1248, !18, i64 1256, !18, i64 1264, !18, i64 1272, !18, i64 1280, !18, i64 1288, !18, i64 1296, !18, i64 1304, !18, i64 1312, !18, i64 1320, !18, i64 1328, !18, i64 1336, !18, i64 1344, !18, i64 1352, !18, i64 1360, !15, i64 1368, !15, i64 1372, !15, i64 1376, !15, i64 1380, !19, i64 1384, !18, i64 1392, !19, i64 1400, !19, i64 1408, !19, i64 1416, !19, i64 1424, !19, i64 1432, !19, i64 1440, !19, i64 1448, !19, i64 1456, !19, i64 1464, !19, i64 1472, !19, i64 1480, !19, i64 1488, !19, i64 1496, !19, i64 1504, !19, i64 1512, !19, i64 1520, !19, i64 1528, !19, i64 1536, !19, i64 1544, !19, i64 1552, !19, i64 1560, !19, i64 1568, !19, i64 1576, !19, i64 1584, !18, i64 1592, !6, i64 1600, !6, i64 1608, !6, i64 1616, !15, i64 1624, !15, i64 1628, !15, i64 1632, !15, i64 1636, !15, i64 1640, !15, i64 1644, !15, i64 1648, !15, i64 1652, !15, i64 1656, !15, i64 1660, !15, i64 1664, !15, i64 1668, !15, i64 1672, !6, i64 1680, !15, i64 1688, !6, i64 1696, !15, i64 1704, !6, i64 1712, !15, i64 1720, !6, i64 1728, !6, i64 1736, !6, i64 1744, !6, i64 1752, !6, i64 1760, !6, i64 1768, !15, i64 1776, !15, i64 1780, !6, i64 1784, !6, i64 1792, !6, i64 1800, !6, i64 1808, !6, i64 1816, !6, i64 1824, !6, i64 1832, !15, i64 1840, !15, i64 1844, !6, i64 1848, !15, i64 1856, !6, i64 1864, !6, i64 1872, !18, i64 1880, !18, i64 1888, !18, i64 1896, !6, i64 1904, !6, i64 1912, !6, i64 1920, !18, i64 1928, !18, i64 1936, !15, i64 1944, !15, i64 1948, !19, i64 1952, !6, i64 1960, !15, i64 1968, !6, i64 1976, !7, i64 1984, !6, i64 2024, !6, i64 2032, !15, i64 2040, !6, i64 2048, !15, i64 2056}
!18 = !{!"double", !7, i64 0}
!19 = !{!"long", !7, i64 0}
!20 = !{!21, !6, i64 8}
!21 = !{!"_generic_N_Vector", !6, i64 0, !6, i64 8, !6, i64 16}
!22 = !{!23, !6, i64 88}
!23 = !{!"_generic_N_Vector_Ops", !6, i64 0, !6, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !6, i64 96, !6, i64 104, !6, i64 112, !6, i64 120, !6, i64 128, !6, i64 136, !6, i64 144, !6, i64 152, !6, i64 160, !6, i64 168, !6, i64 176, !6, i64 184, !6, i64 192, !6, i64 200, !6, i64 208, !6, i64 216, !6, i64 224, !6, i64 232, !6, i64 240, !6, i64 248, !6, i64 256, !6, i64 264, !6, i64 272, !6, i64 280, !6, i64 288, !6, i64 296, !6, i64 304, !6, i64 312, !6, i64 320, !6, i64 328, !6, i64 336, !6, i64 344, !6, i64 352, !6, i64 360, !6, i64 368, !6, i64 376, !6, i64 384, !6, i64 392, !6, i64 400, !6, i64 408, !6, i64 416, !6, i64 424, !6, i64 432}
!24 = !{!23, !6, i64 160}
!25 = !{!23, !6, i64 72}
!26 = !{!12, !6, i64 104}
!27 = !{!12, !6, i64 72}
!28 = !{!12, !6, i64 16}
!29 = !{!17, !6, i64 1824}
!30 = !{!17, !6, i64 1792}
!31 = !{!17, !6, i64 1800}
!32 = !{!17, !6, i64 1808}
!33 = !{!17, !6, i64 1816}
!34 = !{!35, !6, i64 32}
!35 = !{!"IDALsMemRec", !15, i64 0, !15, i64 4, !15, i64 8, !6, i64 16, !6, i64 24, !6, i64 32, !6, i64 40, !6, i64 48, !6, i64 56, !6, i64 64, !6, i64 72, !6, i64 80, !6, i64 88, !15, i64 96, !18, i64 104, !18, i64 112, !18, i64 120, !19, i64 128, !19, i64 136, !19, i64 144, !19, i64 152, !19, i64 160, !19, i64 168, !19, i64 176, !19, i64 184, !19, i64 192, !19, i64 200, !19, i64 208, !19, i64 216, !19, i64 224, !15, i64 232, !6, i64 240, !6, i64 248, !6, i64 256, !6, i64 264, !15, i64 272, !6, i64 280, !6, i64 288, !6, i64 296, !6, i64 304}
!36 = !{!35, !15, i64 0}
!37 = !{!35, !15, i64 4}
!38 = !{!35, !6, i64 40}
!39 = !{!35, !15, i64 8}
!40 = !{!35, !6, i64 16}
!41 = !{!35, !6, i64 24}
!42 = !{!35, !15, i64 272}
!43 = !{!35, !6, i64 280}
!44 = !{!35, !6, i64 288}
!45 = !{!17, !6, i64 16}
!46 = !{!35, !6, i64 296}
!47 = !{!35, !6, i64 304}
!48 = !{!35, !6, i64 240}
!49 = !{!35, !6, i64 248}
!50 = !{!35, !6, i64 256}
!51 = !{!17, !6, i64 24}
!52 = !{!35, !6, i64 264}
!53 = !{!35, !18, i64 104}
!54 = !{!35, !18, i64 120}
!55 = !{!35, !15, i64 232}
!56 = !{!12, !6, i64 24}
!57 = !{!35, !6, i64 48}
!58 = !{!35, !6, i64 56}
!59 = !{!35, !6, i64 64}
!60 = !{!35, !18, i64 112}
!61 = !{!35, !15, i64 96}
!62 = !{!17, !6, i64 1832}


; 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 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.2 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.3 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [42 x i8], align 1
@.str.5 = external hidden unnamed_addr constant [48 x i8], align 1
@.str.6 = external hidden unnamed_addr constant [61 x i8], align 1
@.str.7 = external hidden unnamed_addr constant [61 x i8], align 1
@.str.8 = external hidden unnamed_addr constant [62 x i8], align 1
@.str.9 = external hidden unnamed_addr constant [66 x i8], align 1
@.str.10 = external hidden unnamed_addr constant [56 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [25 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [36 x i8], align 1
@.str.13 = external hidden unnamed_addr constant [44 x i8], align 1

; Function Attrs: nounwind uwtable
define dso_local range(i32 -9, 1) i32 @IDASetLinearSolver(ptr noundef %0, ptr noundef %1, ptr noundef %2) local_unnamed_addr #0 {
  %4 = icmp eq ptr %0, null
  br i1 %4, label %5, label %6

5:                                                ; preds = %3
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef null, i32 noundef -1, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.2) #6
  br label %159

6:                                                ; preds = %3
  %7 = icmp eq ptr %1, null
  br i1 %7, label %8, label %9

8:                                                ; preds = %6
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef null, i32 noundef -3, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.3) #6
  br label %159

9:                                                ; preds = %6
  %10 = getelementptr inbounds i8, ptr %1, i64 8
  %11 = load ptr, ptr %10, align 8, !tbaa !5
  %12 = load ptr, ptr %11, align 8, !tbaa !10
  %13 = icmp eq ptr %12, null
  br i1 %13, label %18, label %14

14:                                               ; preds = %9
  %15 = getelementptr inbounds i8, ptr %11, i64 64
  %16 = load ptr, ptr %15, align 8, !tbaa !12
  %17 = icmp eq ptr %16, null
  br i1 %17, label %18, label %19

18:                                               ; preds = %14, %9
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -3, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.4) #6
  br label %159

19:                                               ; preds = %14
  %20 = tail call i32 @SUNLinSolGetType(ptr noundef nonnull %1) #6
  %21 = icmp ne i32 %20, 0
  %22 = zext i1 %21 to i32
  %23 = icmp ne i32 %20, 1
  %24 = icmp ne i32 %20, 3
  %25 = and i1 %23, %24
  %26 = zext i1 %25 to i32
  %27 = getelementptr inbounds i8, ptr %0, i64 712
  %28 = load ptr, ptr %27, align 8, !tbaa !13
  %29 = getelementptr inbounds i8, ptr %28, i64 8
  %30 = load ptr, ptr %29, align 8, !tbaa !18
  %31 = getelementptr inbounds i8, ptr %30, i64 88
  %32 = load ptr, ptr %31, align 8, !tbaa !20
  %33 = icmp eq ptr %32, null
  br i1 %33, label %38, label %34

34:                                               ; preds = %19
  %35 = getelementptr inbounds i8, ptr %30, i64 160
  %36 = load ptr, ptr %35, align 8, !tbaa !22
  %37 = icmp eq ptr %36, null
  br i1 %37, label %38, label %39

38:                                               ; preds = %34, %19
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -3, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.5) #6
  br label %159

39:                                               ; preds = %34
  %40 = icmp eq i32 %20, 3
  %41 = icmp ne ptr %2, null
  %or.cond = and i1 %41, %40
  br i1 %or.cond, label %42, label %43

42:                                               ; preds = %39
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -3, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.6) #6
  br label %159

43:                                               ; preds = %39
  br i1 %21, label %44, label %70

44:                                               ; preds = %43
  %45 = getelementptr inbounds i8, ptr %30, i64 72
  %46 = load ptr, ptr %45, align 8, !tbaa !23
  %47 = icmp eq ptr %46, null
  br i1 %47, label %48, label %49

48:                                               ; preds = %44
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -3, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.5) #6
  br label %159

49:                                               ; preds = %44
  br i1 %24, label %50, label %60

50:                                               ; preds = %49
  %51 = load ptr, ptr %10, align 8, !tbaa !5
  %52 = getelementptr inbounds i8, ptr %51, i64 104
  %53 = load ptr, ptr %52, align 8, !tbaa !24
  %54 = icmp eq ptr %53, null
  br i1 %54, label %59, label %55

55:                                               ; preds = %50
  %56 = getelementptr inbounds i8, ptr %51, i64 72
  %57 = load ptr, ptr %56, align 8, !tbaa !25
  %58 = icmp eq ptr %57, null
  br i1 %58, label %59, label %60

59:                                               ; preds = %55, %50
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -3, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.7) #6
  br label %159

60:                                               ; preds = %55, %49
  %or.cond3 = xor i1 %24, %25
  br i1 %or.cond3, label %61, label %67

61:                                               ; preds = %60
  %62 = load ptr, ptr %10, align 8, !tbaa !5
  %63 = getelementptr inbounds i8, ptr %62, i64 16
  %64 = load ptr, ptr %63, align 8, !tbaa !26
  %65 = icmp eq ptr %64, null
  br i1 %65, label %66, label %67

66:                                               ; preds = %61
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -3, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.8) #6
  br label %159

67:                                               ; preds = %61, %60
  %68 = icmp eq ptr %2, null
  br i1 %68, label %switch.early.test, label %73

switch.early.test:                                ; preds = %67
  switch i32 %20, label %69 [
    i32 3, label %73
    i32 1, label %73
  ]

69:                                               ; preds = %switch.early.test
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -3, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.9) #6
  br label %159

70:                                               ; preds = %43
  %71 = icmp eq ptr %2, null
  br i1 %71, label %72, label %73

72:                                               ; preds = %70
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -3, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.10) #6
  br label %159

73:                                               ; preds = %switch.early.test, %switch.early.test, %67, %70
  %74 = getelementptr inbounds i8, ptr %0, i64 1824
  %75 = load ptr, ptr %74, align 8, !tbaa !27
  %.not = icmp eq ptr %75, null
  br i1 %.not, label %78, label %76

76:                                               ; preds = %73
  %77 = tail call i32 %75(ptr noundef nonnull %0) #6
  br label %78

78:                                               ; preds = %76, %73
  %79 = getelementptr inbounds i8, ptr %0, i64 1792
  store ptr @idaLsInitialize, ptr %79, align 8, !tbaa !28
  %80 = getelementptr inbounds i8, ptr %0, i64 1800
  store ptr @idaLsSetup, ptr %80, align 8, !tbaa !29
  %81 = getelementptr inbounds i8, ptr %0, i64 1808
  store ptr @idaLsSolve, ptr %81, align 8, !tbaa !30
  store ptr @idaLsFree, ptr %74, align 8, !tbaa !27
  %82 = select i1 %21, ptr @idaLsPerf, ptr null
  %83 = getelementptr inbounds i8, ptr %0, i64 1816
  store ptr %82, ptr %83, align 8, !tbaa !31
  %calloc = tail call dereferenceable_or_null(312) ptr @calloc(i64 1, i64 312)
  %84 = icmp eq ptr %calloc, null
  br i1 %84, label %85, label %86

85:                                               ; preds = %78
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -4, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.11) #6
  br label %159

86:                                               ; preds = %78
  %87 = getelementptr inbounds i8, ptr %calloc, i64 32
  store ptr %1, ptr %87, align 8, !tbaa !32
  store i32 %22, ptr %calloc, align 8, !tbaa !34
  %88 = getelementptr inbounds i8, ptr %calloc, i64 4
  store i32 %26, ptr %88, align 4, !tbaa !35
  %89 = getelementptr inbounds i8, ptr %calloc, i64 40
  store ptr %2, ptr %89, align 8, !tbaa !36
  %.sink129 = zext i1 %41 to i32
  %.sink128 = select i1 %41, ptr @idaLsDQJac, ptr null
  %.sink = select i1 %41, ptr %0, ptr null
  %90 = getelementptr inbounds i8, ptr %calloc, i64 8
  store i32 %.sink129, ptr %90, align 8
  %91 = getelementptr inbounds i8, ptr %calloc, i64 16
  store ptr %.sink128, ptr %91, align 8
  %92 = getelementptr inbounds i8, ptr %calloc, i64 24
  store ptr %.sink, ptr %92, align 8
  %93 = getelementptr inbounds i8, ptr %calloc, i64 272
  store i32 1, ptr %93, align 8, !tbaa !37
  %94 = getelementptr inbounds i8, ptr %calloc, i64 280
  store ptr null, ptr %94, align 8, !tbaa !38
  %95 = getelementptr inbounds i8, ptr %calloc, i64 288
  store ptr @idaLsDQJtimes, ptr %95, align 8, !tbaa !39
  %96 = getelementptr inbounds i8, ptr %0, i64 16
  %97 = load ptr, ptr %96, align 8, !tbaa !40
  %98 = getelementptr inbounds i8, ptr %calloc, i64 296
  store ptr %97, ptr %98, align 8, !tbaa !41
  %99 = getelementptr inbounds i8, ptr %calloc, i64 304
  store ptr %0, ptr %99, align 8, !tbaa !42
  %100 = getelementptr inbounds i8, ptr %calloc, i64 240
  %101 = getelementptr inbounds i8, ptr %0, i64 24
  tail call void @llvm.memset.p0.i64(ptr noundef nonnull align 8 dereferenceable(24) %100, i8 0, i64 24, i1 false)
  %102 = load ptr, ptr %101, align 8, !tbaa !43
  %103 = getelementptr inbounds i8, ptr %calloc, i64 264
  store ptr %102, ptr %103, align 8, !tbaa !44
  %104 = tail call i32 @idaLsInitializeCounters(ptr noundef nonnull %calloc)
  %105 = getelementptr inbounds i8, ptr %calloc, i64 104
  store double 5.000000e-02, ptr %105, align 8, !tbaa !45
  %106 = getelementptr inbounds i8, ptr %calloc, i64 120
  store double 1.000000e+00, ptr %106, align 8, !tbaa !46
  %107 = getelementptr inbounds i8, ptr %calloc, i64 232
  store i32 0, ptr %107, align 8, !tbaa !47
  %108 = load ptr, ptr %10, align 8, !tbaa !5
  %109 = getelementptr inbounds i8, ptr %108, i64 16
  %110 = load ptr, ptr %109, align 8, !tbaa !26
  %.not124 = icmp eq ptr %110, null
  br i1 %.not124, label %114, label %111

111:                                              ; preds = %86
  %112 = tail call i32 @SUNLinSolSetATimes(ptr noundef nonnull %1, ptr noundef nonnull %0, ptr noundef nonnull @idaLsATimes) #6
  %.not125 = icmp eq i32 %112, 0
  br i1 %.not125, label %._crit_edge, label %113

._crit_edge:                                      ; preds = %111
  %.pre = load ptr, ptr %10, align 8, !tbaa !5
  br label %114

113:                                              ; preds = %111
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -9, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.12) #6
  tail call void @free(ptr noundef nonnull %calloc) #6
  br label %159

114:                                              ; preds = %._crit_edge, %86
  %115 = phi ptr [ %.pre, %._crit_edge ], [ %108, %86 ]
  %116 = getelementptr inbounds i8, ptr %115, i64 24
  %117 = load ptr, ptr %116, align 8, !tbaa !48
  %.not126 = icmp eq ptr %117, null
  br i1 %.not126, label %121, label %118

118:                                              ; preds = %114
  %119 = tail call i32 @SUNLinSolSetPreconditioner(ptr noundef nonnull %1, ptr noundef nonnull %0, ptr noundef null, ptr noundef null) #6
  %.not127 = icmp eq i32 %119, 0
  br i1 %.not127, label %121, label %120

120:                                              ; preds = %118
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -9, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.13) #6
  tail call void @free(ptr noundef nonnull %calloc) #6
  br label %159

121:                                              ; preds = %118, %114
  %122 = load ptr, ptr %27, align 8, !tbaa !13
  %123 = tail call ptr @N_VClone(ptr noundef %122) #6
  %124 = getelementptr inbounds i8, ptr %calloc, i64 48
  store ptr %123, ptr %124, align 8, !tbaa !49
  %125 = icmp eq ptr %123, null
  br i1 %125, label %126, label %127

126:                                              ; preds = %121
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -4, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.11) #6
  tail call void @free(ptr noundef nonnull %calloc) #6
  br label %159

127:                                              ; preds = %121
  %128 = load ptr, ptr %27, align 8, !tbaa !13
  %129 = tail call ptr @N_VClone(ptr noundef %128) #6
  %130 = getelementptr inbounds i8, ptr %calloc, i64 56
  store ptr %129, ptr %130, align 8, !tbaa !50
  %131 = icmp eq ptr %129, null
  br i1 %131, label %132, label %134

132:                                              ; preds = %127
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -4, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.11) #6
  %133 = load ptr, ptr %124, align 8, !tbaa !49
  tail call void @N_VDestroy(ptr noundef %133) #6
  tail call void @free(ptr noundef nonnull %calloc) #6
  br label %159

134:                                              ; preds = %127
  %135 = load ptr, ptr %27, align 8, !tbaa !13
  %136 = tail call ptr @N_VClone(ptr noundef %135) #6
  %137 = getelementptr inbounds i8, ptr %calloc, i64 64
  store ptr %136, ptr %137, align 8, !tbaa !51
  %138 = icmp eq ptr %136, null
  br i1 %138, label %139, label %142

139:                                              ; preds = %134
  tail call void (ptr, i32, ptr, ptr, ptr, ...) @IDAProcessError(ptr noundef nonnull %0, i32 noundef -4, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @.str.11) #6
  %140 = load ptr, ptr %124, align 8, !tbaa !49
  tail call void @N_VDestroy(ptr noundef %140) #6
  %141 = load ptr, ptr %130, align 8, !tbaa !50
  tail call void @N_VDestroy(ptr noundef %141) #6
  tail call void @free(ptr noundef nonnull %calloc) #6
  br label %159

142:                                              ; preds = %134
  br i1 %21, label %143, label %.thread

143:                                              ; preds = %142
  %144 = load ptr, ptr %124, align 8, !tbaa !49
  %145 = tail call i64 @N_VGetLength(ptr noundef %144) #6
  %146 = icmp slt i64 %145, 1
  br i1 %146, label %152, label %147

147:                                              ; preds = %143
  %148 = load ptr, ptr %124, align 8, !tbaa !49
  %149 = tail call i64 @N_VGetLength(ptr noundef %148) #6
  %150 = sitofp i64 %149 to double
  %151 = tail call double @sqrt(double noundef %150) #6
  br label %152

152:                                              ; preds = %147, %143
  %153 = phi double [ %151, %147 ], [ 0.000000e+00, %143 ]
  %154 = getelementptr inbounds i8, ptr %calloc, i64 112
  store double %153, ptr %154, align 8, !tbaa !52
  %155 = add i32 %20, -1
  %switch.and = and i32 %155, -3
  %switch.selectcmp = icmp ne i32 %switch.and, 0
  %156 = zext i1 %switch.selectcmp to i32
  br label %.thread

.thread:                                          ; preds = %142, %152
  %.sink130 = phi i32 [ %156, %152 ], [ 1, %142 ]
  %157 = getelementptr inbounds i8, ptr %calloc, i64 96
  store i32 %.sink130, ptr %157, align 8, !tbaa !53
  %158 = getelementptr inbounds i8, ptr %0, i64 1832
  store ptr %calloc, ptr %158, align 8, !tbaa !54
  br label %159

159:                                              ; preds = %.thread, %139, %132, %126, %120, %113, %85, %72, %69, %66, %59, %48, %42, %38, %18, %8, %5
  %.0 = phi i32 [ -1, %5 ], [ -3, %8 ], [ -3, %18 ], [ -3, %38 ], [ -3, %42 ], [ -3, %48 ], [ -3, %59 ], [ -3, %66 ], [ -3, %69 ], [ -4, %85 ], [ -9, %113 ], [ -9, %120 ], [ -4, %126 ], [ -4, %132 ], [ -4, %139 ], [ 0, %.thread ], [ -3, %72 ]
  ret i32 %.0
}

declare void @IDAProcessError(ptr noundef, i32 noundef, ptr noundef, ptr noundef, ptr noundef, ...) local_unnamed_addr #1

declare i32 @SUNLinSolGetType(ptr noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsInitialize(ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsSetup(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsSolve(ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsFree(ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsPerf(ptr noundef, i32 noundef) #0

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

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsDQJac(double noundef, double noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsDQJtimes(double noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, ptr noundef, double noundef, ptr noundef, ptr noundef, ptr noundef) #0

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsInitializeCounters(ptr noundef) local_unnamed_addr #0

declare i32 @SUNLinSolSetATimes(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: nounwind uwtable
declare dso_local i32 @idaLsATimes(ptr noundef, ptr noundef, ptr noundef) #0

; Function Attrs: mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite)
declare void @free(ptr allocptr nocapture noundef) local_unnamed_addr #3

declare i32 @SUNLinSolSetPreconditioner(ptr noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

declare ptr @N_VClone(ptr noundef) local_unnamed_addr #1

declare void @N_VDestroy(ptr noundef) local_unnamed_addr #1

declare i64 @N_VGetLength(ptr noundef) local_unnamed_addr #1

; Function Attrs: mustprogress nofree nounwind willreturn memory(write)
declare double @sqrt(double noundef) local_unnamed_addr #4

; Function Attrs: nofree nounwind willreturn allockind("alloc,zeroed") allocsize(0,1) memory(inaccessiblemem: readwrite)
declare noalias noundef ptr @calloc(i64 noundef, i64 noundef) local_unnamed_addr #5

attributes #0 = { 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 #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 nocallback nofree nounwind willreturn memory(argmem: write) }
attributes #3 = { mustprogress nounwind willreturn allockind("free") memory(argmem: readwrite, inaccessiblemem: readwrite) "alloc-family"="malloc" "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 nofree nounwind willreturn memory(write) "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 = { nofree nounwind willreturn allockind("alloc,zeroed") allocsize(0,1) memory(inaccessiblemem: readwrite) "alloc-family"="malloc" }
attributes #6 = { 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, !7, i64 8}
!6 = !{!"_generic_SUNLinearSolver", !7, i64 0, !7, i64 8, !7, i64 16}
!7 = !{!"any pointer", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C/C++ TBAA"}
!10 = !{!11, !7, i64 0}
!11 = !{!"_generic_SUNLinearSolver_Ops", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !7, i64 48, !7, i64 56, !7, i64 64, !7, i64 72, !7, i64 80, !7, i64 88, !7, i64 96, !7, i64 104, !7, i64 112}
!12 = !{!11, !7, i64 64}
!13 = !{!14, !7, i64 712}
!14 = !{!"IDAMemRec", !7, i64 0, !15, i64 8, !7, i64 16, !7, i64 24, !16, i64 32, !15, i64 40, !15, i64 48, !7, i64 56, !16, i64 64, !16, i64 68, !7, i64 72, !7, i64 80, !16, i64 88, !16, i64 92, !16, i64 96, !7, i64 104, !7, i64 112, !16, i64 120, !16, i64 124, !15, i64 128, !15, i64 136, !7, i64 144, !16, i64 152, !16, i64 156, !16, i64 160, !16, i64 164, !7, i64 168, !7, i64 176, !16, i64 184, !7, i64 192, !7, i64 200, !7, i64 208, !16, i64 216, !15, i64 224, !16, i64 232, !16, i64 236, !15, i64 240, !7, i64 248, !7, i64 256, !7, i64 264, !16, i64 272, !7, i64 280, !7, i64 288, !16, i64 296, !16, i64 300, !16, i64 304, !15, i64 312, !7, i64 320, !7, i64 328, !7, i64 336, !8, i64 344, !8, i64 392, !8, i64 440, !8, i64 488, !8, i64 536, !8, i64 584, !7, i64 632, !7, i64 640, !7, i64 648, !7, i64 656, !7, i64 664, !7, i64 672, !7, i64 680, !7, i64 688, !7, i64 696, !7, i64 704, !7, i64 712, !7, i64 720, !7, i64 728, !7, i64 736, !7, i64 744, !7, i64 752, !7, i64 760, !8, i64 768, !7, i64 816, !7, i64 824, !7, i64 832, !7, i64 840, !8, i64 848, !7, i64 896, !7, i64 904, !7, i64 912, !7, i64 920, !7, i64 928, !7, i64 936, !7, i64 944, !7, i64 952, !7, i64 960, !7, i64 968, !7, i64 976, !7, i64 984, !7, i64 992, !7, i64 1000, !7, i64 1008, !7, i64 1016, !8, i64 1024, !7, i64 1072, !7, i64 1080, !7, i64 1088, !7, i64 1096, !7, i64 1104, !15, i64 1112, !7, i64 1120, !7, i64 1128, !16, i64 1136, !16, i64 1140, !16, i64 1144, !16, i64 1148, !16, i64 1152, !16, i64 1156, !16, i64 1160, !16, i64 1164, !15, i64 1168, !15, i64 1176, !15, i64 1184, !16, i64 1192, !15, i64 1200, !16, i64 1208, !16, i64 1212, !16, i64 1216, !16, i64 1220, !16, i64 1224, !15, i64 1232, !15, i64 1240, !15, i64 1248, !15, i64 1256, !15, i64 1264, !15, i64 1272, !15, i64 1280, !15, i64 1288, !15, i64 1296, !15, i64 1304, !15, i64 1312, !15, i64 1320, !15, i64 1328, !15, i64 1336, !15, i64 1344, !15, i64 1352, !15, i64 1360, !16, i64 1368, !16, i64 1372, !16, i64 1376, !16, i64 1380, !17, i64 1384, !15, i64 1392, !17, i64 1400, !17, i64 1408, !17, i64 1416, !17, i64 1424, !17, i64 1432, !17, i64 1440, !17, i64 1448, !17, i64 1456, !17, i64 1464, !17, i64 1472, !17, i64 1480, !17, i64 1488, !17, i64 1496, !17, i64 1504, !17, i64 1512, !17, i64 1520, !17, i64 1528, !17, i64 1536, !17, i64 1544, !17, i64 1552, !17, i64 1560, !17, i64 1568, !17, i64 1576, !17, i64 1584, !15, i64 1592, !7, i64 1600, !7, i64 1608, !7, i64 1616, !16, i64 1624, !16, i64 1628, !16, i64 1632, !16, i64 1636, !16, i64 1640, !16, i64 1644, !16, i64 1648, !16, i64 1652, !16, i64 1656, !16, i64 1660, !16, i64 1664, !16, i64 1668, !16, i64 1672, !7, i64 1680, !16, i64 1688, !7, i64 1696, !16, i64 1704, !7, i64 1712, !16, i64 1720, !7, i64 1728, !7, i64 1736, !7, i64 1744, !7, i64 1752, !7, i64 1760, !7, i64 1768, !16, i64 1776, !16, i64 1780, !7, i64 1784, !7, i64 1792, !7, i64 1800, !7, i64 1808, !7, i64 1816, !7, i64 1824, !7, i64 1832, !16, i64 1840, !16, i64 1844, !7, i64 1848, !16, i64 1856, !7, i64 1864, !7, i64 1872, !15, i64 1880, !15, i64 1888, !15, i64 1896, !7, i64 1904, !7, i64 1912, !7, i64 1920, !15, i64 1928, !15, i64 1936, !16, i64 1944, !16, i64 1948, !17, i64 1952, !7, i64 1960, !16, i64 1968, !7, i64 1976, !8, i64 1984, !7, i64 2024, !7, i64 2032, !16, i64 2040, !7, i64 2048, !16, i64 2056}
!15 = !{!"double", !8, i64 0}
!16 = !{!"int", !8, i64 0}
!17 = !{!"long", !8, i64 0}
!18 = !{!19, !7, i64 8}
!19 = !{!"_generic_N_Vector", !7, i64 0, !7, i64 8, !7, i64 16}
!20 = !{!21, !7, i64 88}
!21 = !{!"_generic_N_Vector_Ops", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !7, i64 48, !7, i64 56, !7, i64 64, !7, i64 72, !7, i64 80, !7, i64 88, !7, i64 96, !7, i64 104, !7, i64 112, !7, i64 120, !7, i64 128, !7, i64 136, !7, i64 144, !7, i64 152, !7, i64 160, !7, i64 168, !7, i64 176, !7, i64 184, !7, i64 192, !7, i64 200, !7, i64 208, !7, i64 216, !7, i64 224, !7, i64 232, !7, i64 240, !7, i64 248, !7, i64 256, !7, i64 264, !7, i64 272, !7, i64 280, !7, i64 288, !7, i64 296, !7, i64 304, !7, i64 312, !7, i64 320, !7, i64 328, !7, i64 336, !7, i64 344, !7, i64 352, !7, i64 360, !7, i64 368, !7, i64 376, !7, i64 384, !7, i64 392, !7, i64 400, !7, i64 408, !7, i64 416, !7, i64 424, !7, i64 432}
!22 = !{!21, !7, i64 160}
!23 = !{!21, !7, i64 72}
!24 = !{!11, !7, i64 104}
!25 = !{!11, !7, i64 72}
!26 = !{!11, !7, i64 16}
!27 = !{!14, !7, i64 1824}
!28 = !{!14, !7, i64 1792}
!29 = !{!14, !7, i64 1800}
!30 = !{!14, !7, i64 1808}
!31 = !{!14, !7, i64 1816}
!32 = !{!33, !7, i64 32}
!33 = !{!"IDALsMemRec", !16, i64 0, !16, i64 4, !16, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !7, i64 48, !7, i64 56, !7, i64 64, !7, i64 72, !7, i64 80, !7, i64 88, !16, i64 96, !15, i64 104, !15, i64 112, !15, i64 120, !17, i64 128, !17, i64 136, !17, i64 144, !17, i64 152, !17, i64 160, !17, i64 168, !17, i64 176, !17, i64 184, !17, i64 192, !17, i64 200, !17, i64 208, !17, i64 216, !17, i64 224, !16, i64 232, !7, i64 240, !7, i64 248, !7, i64 256, !7, i64 264, !16, i64 272, !7, i64 280, !7, i64 288, !7, i64 296, !7, i64 304}
!34 = !{!33, !16, i64 0}
!35 = !{!33, !16, i64 4}
!36 = !{!33, !7, i64 40}
!37 = !{!33, !16, i64 272}
!38 = !{!33, !7, i64 280}
!39 = !{!33, !7, i64 288}
!40 = !{!14, !7, i64 16}
!41 = !{!33, !7, i64 296}
!42 = !{!33, !7, i64 304}
!43 = !{!14, !7, i64 24}
!44 = !{!33, !7, i64 264}
!45 = !{!33, !15, i64 104}
!46 = !{!33, !15, i64 120}
!47 = !{!33, !16, i64 232}
!48 = !{!11, !7, i64 24}
!49 = !{!33, !7, i64 48}
!50 = !{!33, !7, i64 56}
!51 = !{!33, !7, i64 64}
!52 = !{!33, !15, i64 112}
!53 = !{!33, !16, i64 96}
!54 = !{!14, !7, i64 1832}


; Effective O3 passes: CorrelatedValuePropagationPass,DSEPass,EarlyCSEPass,GVNPass,GlobalOptPass,IPSCCPPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,MemCpyOptPass,MergedLoadStoreMotionPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass