; LLVM IR from HRI-EU/Rcs :: src/RcsCore (Rcs_MatNd)

; 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._MatNd = type { ptr, i32, i32, i32, i8 }

@stderr = external global ptr, align 8
@.str = external hidden unnamed_addr constant [39 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [68 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.24 = external hidden unnamed_addr constant [3 x i8], align 1
@RCS_GLOBAL_RLOG_CB = external global ptr, align 8
@RcsLogLevel = external global i32, align 4
@.str.26 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.33 = external hidden unnamed_addr constant [1 x i8], align 1
@.str.35 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.36 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.37 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.38 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.39 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.40 = external hidden unnamed_addr constant [32 x i8], align 1
@.str.41 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.42 = external hidden unnamed_addr constant [4 x i8], align 1
@__func__.MatNd_gnuplot2 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.44 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.45 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.46 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.47 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.48 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.49 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.50 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.51 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.52 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.53 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.54 = external hidden unnamed_addr constant [9 x i8], align 1

; Function Attrs: nounwind
declare i32 @fprintf(ptr noundef, ptr noundef, ...) #0

declare void @print_trace() #1

; Function Attrs: noreturn nounwind
declare void @exit(i32 noundef) #2

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

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

; Function Attrs: nounwind uwtable
declare dso_local zeroext i1 @MatNd_toFile(ptr noundef, ptr noundef) #4

declare noalias ptr @fopen(ptr noundef, ptr noundef) #1

declare i32 @fclose(ptr noundef) #1

declare ptr @File_createUniqueName(ptr noundef, ptr noundef, ptr noundef) #1

declare i32 @fflush(ptr noundef) #1

; Function Attrs: nounwind uwtable
define dso_local zeroext i1 @MatNd_gnuplot2(ptr noundef %0, ptr noundef %1) #4 {
  %3 = alloca i1, align 1
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca [256 x i8], align 16
  %7 = alloca [256 x i8], align 16
  %8 = alloca i8, align 1
  %9 = alloca i32, align 4
  %10 = alloca [4096 x i8], align 16
  %11 = alloca [512 x i8], align 16
  %12 = alloca i32, align 4
  %13 = alloca ptr, align 8
  %14 = alloca [256 x i8], align 16
  %15 = alloca i32, align 4
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 256, ptr %6) #5
  call void @llvm.lifetime.start.p0(i64 256, ptr %7) #5
  %16 = getelementptr inbounds [256 x i8], ptr %6, i64 0, i64 0
  %17 = call ptr @File_createUniqueName(ptr noundef %16, ptr noundef @.str.36, ptr noundef @.str.37)
  %18 = getelementptr inbounds [256 x i8], ptr %7, i64 0, i64 0
  %19 = call ptr @File_createUniqueName(ptr noundef %18, ptr noundef @.str.36, ptr noundef @.str.42)
  call void @llvm.lifetime.start.p0(i64 1, ptr %8) #5
  %20 = load ptr, ptr %5, align 8, !tbaa !5
  %21 = getelementptr inbounds [256 x i8], ptr %6, i64 0, i64 0
  %22 = call zeroext i1 @MatNd_toFile(ptr noundef %20, ptr noundef %21)
  %23 = zext i1 %22 to i8
  store i8 %23, ptr %8, align 1, !tbaa !9
  %24 = load i8, ptr %8, align 1, !tbaa !9, !range !11, !noundef !12
  %25 = trunc i8 %24 to i1
  %26 = zext i1 %25 to i32
  %27 = icmp eq i32 %26, 0
  br i1 %27, label %28, label %29

28:                                               ; preds = %2
  store i1 false, ptr %3, align 1
  store i32 1, ptr %9, align 4
  br label %261

29:                                               ; preds = %2
  br label %30

30:                                               ; preds = %29
  %31 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %32 = icmp ne ptr %31, null
  br i1 %32, label %33, label %35

33:                                               ; preds = %30
  %34 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  call void (i32, ptr, ptr, i32, ptr, ...) %34(i32 noundef 0, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 608, ptr noundef @.str.43)
  br label %35

35:                                               ; preds = %33, %30
  %36 = load i32, ptr @RcsLogLevel, align 4, !tbaa !13
  %37 = icmp sle i32 0, %36
  br i1 %37, label %38, label %45

38:                                               ; preds = %35
  %39 = load ptr, ptr @stderr, align 8, !tbaa !5
  %40 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %39, ptr noundef @.str.26, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 608) #5
  %41 = load ptr, ptr @stderr, align 8, !tbaa !5
  %42 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %41, ptr noundef @.str.43) #5
  %43 = load ptr, ptr @stderr, align 8, !tbaa !5
  %44 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %43, ptr noundef @.str.4) #5
  br label %45

45:                                               ; preds = %38, %35
  br label %46

46:                                               ; preds = %45
  br label %47

47:                                               ; preds = %46
  call void @llvm.lifetime.start.p0(i64 4096, ptr %10) #5
  call void @llvm.lifetime.start.p0(i64 512, ptr %11) #5
  %48 = load ptr, ptr %4, align 8, !tbaa !5
  %49 = icmp ne ptr %48, null
  br i1 %49, label %50, label %54

50:                                               ; preds = %47
  %51 = getelementptr inbounds [4096 x i8], ptr %10, i64 0, i64 0
  %52 = load ptr, ptr %4, align 8, !tbaa !5
  %53 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %51, ptr noundef @.str.38, ptr noundef %52) #5
  br label %57

54:                                               ; preds = %47
  %55 = getelementptr inbounds [4096 x i8], ptr %10, i64 0, i64 0
  %56 = call ptr @strcpy(ptr noundef %55, ptr noundef @.str.39) #5
  br label %57

57:                                               ; preds = %54, %50
  br label %58

58:                                               ; preds = %57
  %59 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %60 = icmp ne ptr %59, null
  br i1 %60, label %61, label %63

61:                                               ; preds = %58
  %62 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  call void (i32, ptr, ptr, i32, ptr, ...) %62(i32 noundef 0, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 618, ptr noundef @.str.44)
  br label %63

63:                                               ; preds = %61, %58
  %64 = load i32, ptr @RcsLogLevel, align 4, !tbaa !13
  %65 = icmp sle i32 0, %64
  br i1 %65, label %66, label %73

66:                                               ; preds = %63
  %67 = load ptr, ptr @stderr, align 8, !tbaa !5
  %68 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %67, ptr noundef @.str.26, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 618) #5
  %69 = load ptr, ptr @stderr, align 8, !tbaa !5
  %70 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %69, ptr noundef @.str.44) #5
  %71 = load ptr, ptr @stderr, align 8, !tbaa !5
  %72 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %71, ptr noundef @.str.4) #5
  br label %73

73:                                               ; preds = %66, %63
  br label %74

74:                                               ; preds = %73
  br label %75

75:                                               ; preds = %74
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  store i32 1, ptr %12, align 4, !tbaa !13
  br label %76

76:                                               ; preds = %127, %75
  %77 = load i32, ptr %12, align 4, !tbaa !13
  %78 = load ptr, ptr %5, align 8, !tbaa !5
  %79 = getelementptr inbounds %struct._MatNd, ptr %78, i32 0, i32 2
  %80 = load i32, ptr %79, align 4, !tbaa !15
  %81 = icmp ule i32 %77, %80
  br i1 %81, label %83, label %82

82:                                               ; preds = %76
  store i32 6, ptr %9, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  br label %130

83:                                               ; preds = %76
  br label %84

84:                                               ; preds = %83
  %85 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %86 = icmp ne ptr %85, null
  br i1 %86, label %87, label %93

87:                                               ; preds = %84
  %88 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %89 = load i32, ptr %12, align 4, !tbaa !13
  %90 = load ptr, ptr %5, align 8, !tbaa !5
  %91 = getelementptr inbounds %struct._MatNd, ptr %90, i32 0, i32 2
  %92 = load i32, ptr %91, align 4, !tbaa !15
  call void (i32, ptr, ptr, i32, ptr, ...) %88(i32 noundef 0, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 621, ptr noundef @.str.45, i32 noundef %89, i32 noundef %92)
  br label %93

93:                                               ; preds = %87, %84
  %94 = load i32, ptr @RcsLogLevel, align 4, !tbaa !13
  %95 = icmp sle i32 0, %94
  br i1 %95, label %96, label %107

96:                                               ; preds = %93
  %97 = load ptr, ptr @stderr, align 8, !tbaa !5
  %98 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %97, ptr noundef @.str.26, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 621) #5
  %99 = load ptr, ptr @stderr, align 8, !tbaa !5
  %100 = load i32, ptr %12, align 4, !tbaa !13
  %101 = load ptr, ptr %5, align 8, !tbaa !5
  %102 = getelementptr inbounds %struct._MatNd, ptr %101, i32 0, i32 2
  %103 = load i32, ptr %102, align 4, !tbaa !15
  %104 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %99, ptr noundef @.str.45, i32 noundef %100, i32 noundef %103) #5
  %105 = load ptr, ptr @stderr, align 8, !tbaa !5
  %106 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %105, ptr noundef @.str.4) #5
  br label %107

107:                                              ; preds = %96, %93
  br label %108

108:                                              ; preds = %107
  br label %109

109:                                              ; preds = %108
  %110 = getelementptr inbounds [512 x i8], ptr %11, i64 0, i64 0
  %111 = getelementptr inbounds [256 x i8], ptr %6, i64 0, i64 0
  %112 = load i32, ptr %12, align 4, !tbaa !13
  %113 = load i32, ptr %12, align 4, !tbaa !13
  %114 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %110, ptr noundef @.str.40, ptr noundef %111, i32 noundef %112, i32 noundef %113) #5
  %115 = getelementptr inbounds [4096 x i8], ptr %10, i64 0, i64 0
  %116 = getelementptr inbounds [512 x i8], ptr %11, i64 0, i64 0
  %117 = call ptr @strcat(ptr noundef %115, ptr noundef %116) #5
  %118 = load i32, ptr %12, align 4, !tbaa !13
  %119 = load ptr, ptr %5, align 8, !tbaa !5
  %120 = getelementptr inbounds %struct._MatNd, ptr %119, i32 0, i32 2
  %121 = load i32, ptr %120, align 4, !tbaa !15
  %122 = icmp ne i32 %118, %121
  br i1 %122, label %123, label %126

123:                                              ; preds = %109
  %124 = getelementptr inbounds [4096 x i8], ptr %10, i64 0, i64 0
  %125 = call ptr @strcat(ptr noundef %124, ptr noundef @.str.41) #5
  br label %126

126:                                              ; preds = %123, %109
  br label %127

127:                                              ; preds = %126
  %128 = load i32, ptr %12, align 4, !tbaa !13
  %129 = add i32 %128, 1
  store i32 %129, ptr %12, align 4, !tbaa !13
  br label %76, !llvm.loop !17

130:                                              ; preds = %82
  %131 = getelementptr inbounds [4096 x i8], ptr %10, i64 0, i64 0
  %132 = call ptr @strcat(ptr noundef %131, ptr noundef @.str.4) #5
  br label %133

133:                                              ; preds = %130
  %134 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %135 = icmp ne ptr %134, null
  br i1 %135, label %136, label %138

136:                                              ; preds = %133
  %137 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  call void (i32, ptr, ptr, i32, ptr, ...) %137(i32 noundef 0, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 632, ptr noundef @.str.46)
  br label %138

138:                                              ; preds = %136, %133
  %139 = load i32, ptr @RcsLogLevel, align 4, !tbaa !13
  %140 = icmp sle i32 0, %139
  br i1 %140, label %141, label %148

141:                                              ; preds = %138
  %142 = load ptr, ptr @stderr, align 8, !tbaa !5
  %143 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %142, ptr noundef @.str.26, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 632) #5
  %144 = load ptr, ptr @stderr, align 8, !tbaa !5
  %145 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %144, ptr noundef @.str.46) #5
  %146 = load ptr, ptr @stderr, align 8, !tbaa !5
  %147 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %146, ptr noundef @.str.4) #5
  br label %148

148:                                              ; preds = %141, %138
  br label %149

149:                                              ; preds = %148
  br label %150

150:                                              ; preds = %149
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #5
  %151 = getelementptr inbounds [256 x i8], ptr %7, i64 0, i64 0
  %152 = call noalias ptr @fopen(ptr noundef %151, ptr noundef @.str.24)
  store ptr %152, ptr %13, align 8, !tbaa !5
  br label %153

153:                                              ; preds = %150
  %154 = load ptr, ptr %13, align 8, !tbaa !5
  %155 = icmp ne ptr %154, null
  br i1 %155, label %164, label %156

156:                                              ; preds = %153
  %157 = load ptr, ptr @stderr, align 8, !tbaa !5
  %158 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %157, ptr noundef @.str, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 635, ptr noundef @.str.47) #5
  %159 = load ptr, ptr @stderr, align 8, !tbaa !5
  %160 = getelementptr inbounds [256 x i8], ptr %7, i64 0, i64 0
  %161 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %159, ptr noundef @.str.48, ptr noundef %160) #5
  %162 = load ptr, ptr @stderr, align 8, !tbaa !5
  %163 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %162, ptr noundef @.str.4) #5
  call void @print_trace()
  call void @exit(i32 noundef 1) #6
  unreachable

164:                                              ; preds = %153
  br label %165

165:                                              ; preds = %164
  br label %166

166:                                              ; preds = %165
  %167 = load ptr, ptr %13, align 8, !tbaa !5
  %168 = getelementptr inbounds [4096 x i8], ptr %10, i64 0, i64 0
  %169 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %167, ptr noundef @.str.49, ptr noundef %168) #5
  %170 = load ptr, ptr %13, align 8, !tbaa !5
  %171 = call i32 @fflush(ptr noundef %170)
  %172 = load ptr, ptr %13, align 8, !tbaa !5
  %173 = call i32 @fclose(ptr noundef %172)
  br label %174

174:                                              ; preds = %166
  %175 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %176 = icmp ne ptr %175, null
  br i1 %176, label %177, label %179

177:                                              ; preds = %174
  %178 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  call void (i32, ptr, ptr, i32, ptr, ...) %178(i32 noundef 0, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 639, ptr noundef @.str.50)
  br label %179

179:                                              ; preds = %177, %174
  %180 = load i32, ptr @RcsLogLevel, align 4, !tbaa !13
  %181 = icmp sle i32 0, %180
  br i1 %181, label %182, label %189

182:                                              ; preds = %179
  %183 = load ptr, ptr @stderr, align 8, !tbaa !5
  %184 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %183, ptr noundef @.str.26, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 639) #5
  %185 = load ptr, ptr @stderr, align 8, !tbaa !5
  %186 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %185, ptr noundef @.str.50) #5
  %187 = load ptr, ptr @stderr, align 8, !tbaa !5
  %188 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %187, ptr noundef @.str.4) #5
  br label %189

189:                                              ; preds = %182, %179
  br label %190

190:                                              ; preds = %189
  br label %191

191:                                              ; preds = %190
  call void @llvm.lifetime.start.p0(i64 256, ptr %14) #5
  %192 = getelementptr inbounds [256 x i8], ptr %14, i64 0, i64 0
  %193 = getelementptr inbounds [256 x i8], ptr %7, i64 0, i64 0
  %194 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %192, ptr noundef @.str.51, ptr noundef %193) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #5
  %195 = getelementptr inbounds [256 x i8], ptr %14, i64 0, i64 0
  %196 = call i32 @system(ptr noundef %195)
  store i32 %196, ptr %15, align 4, !tbaa !13
  br label %197

197:                                              ; preds = %191
  %198 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %199 = icmp ne ptr %198, null
  br i1 %199, label %200, label %202

200:                                              ; preds = %197
  %201 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  call void (i32, ptr, ptr, i32, ptr, ...) %201(i32 noundef 0, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 649, ptr noundef @.str.52)
  br label %202

202:                                              ; preds = %200, %197
  %203 = load i32, ptr @RcsLogLevel, align 4, !tbaa !13
  %204 = icmp sle i32 0, %203
  br i1 %204, label %205, label %212

205:                                              ; preds = %202
  %206 = load ptr, ptr @stderr, align 8, !tbaa !5
  %207 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %206, ptr noundef @.str.26, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 649) #5
  %208 = load ptr, ptr @stderr, align 8, !tbaa !5
  %209 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %208, ptr noundef @.str.52) #5
  %210 = load ptr, ptr @stderr, align 8, !tbaa !5
  %211 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %210, ptr noundef @.str.4) #5
  br label %212

212:                                              ; preds = %205, %202
  br label %213

213:                                              ; preds = %212
  br label %214

214:                                              ; preds = %213
  %215 = load i32, ptr %15, align 4, !tbaa !13
  %216 = icmp eq i32 %215, -1
  br i1 %216, label %217, label %236

217:                                              ; preds = %214
  br label %218

218:                                              ; preds = %217
  %219 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %220 = icmp ne ptr %219, null
  br i1 %220, label %221, label %223

221:                                              ; preds = %218
  %222 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  call void (i32, ptr, ptr, i32, ptr, ...) %222(i32 noundef 4, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 653, ptr noundef @.str.53)
  br label %223

223:                                              ; preds = %221, %218
  %224 = load i32, ptr @RcsLogLevel, align 4, !tbaa !13
  %225 = icmp sle i32 4, %224
  br i1 %225, label %226, label %233

226:                                              ; preds = %223
  %227 = load ptr, ptr @stderr, align 8, !tbaa !5
  %228 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %227, ptr noundef @.str.26, ptr noundef @.str.1, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 653) #5
  %229 = load ptr, ptr @stderr, align 8, !tbaa !5
  %230 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %229, ptr noundef @.str.53) #5
  %231 = load ptr, ptr @stderr, align 8, !tbaa !5
  %232 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %231, ptr noundef @.str.4) #5
  br label %233

233:                                              ; preds = %226, %223
  br label %234

234:                                              ; preds = %233
  br label %235

235:                                              ; preds = %234
  store i1 false, ptr %3, align 1
  store i32 1, ptr %9, align 4
  br label %260

236:                                              ; preds = %214
  br label %237

237:                                              ; preds = %236
  %238 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %239 = icmp ne ptr %238, null
  br i1 %239, label %240, label %244

240:                                              ; preds = %237
  %241 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %242 = getelementptr inbounds [4096 x i8], ptr %10, i64 0, i64 0
  %243 = getelementptr inbounds [256 x i8], ptr %14, i64 0, i64 0
  call void (i32, ptr, ptr, i32, ptr, ...) %241(i32 noundef 5, ptr noundef @.str.33, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 658, ptr noundef @.str.54, ptr noundef %242, ptr noundef %243)
  br label %244

244:                                              ; preds = %240, %237
  %245 = load i32, ptr @RcsLogLevel, align 4, !tbaa !13
  %246 = icmp sle i32 5, %245
  br i1 %246, label %247, label %256

247:                                              ; preds = %244
  %248 = load ptr, ptr @stderr, align 8, !tbaa !5
  %249 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %248, ptr noundef @.str.35, ptr noundef @__func__.MatNd_gnuplot2, i32 noundef 658) #5
  %250 = load ptr, ptr @stderr, align 8, !tbaa !5
  %251 = getelementptr inbounds [4096 x i8], ptr %10, i64 0, i64 0
  %252 = getelementptr inbounds [256 x i8], ptr %14, i64 0, i64 0
  %253 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %250, ptr noundef @.str.54, ptr noundef %251, ptr noundef %252) #5
  %254 = load ptr, ptr @stderr, align 8, !tbaa !5
  %255 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %254, ptr noundef @.str.4) #5
  br label %256

256:                                              ; preds = %247, %244
  br label %257

257:                                              ; preds = %256
  br label %258

258:                                              ; preds = %257
  br label %259

259:                                              ; preds = %258
  store i1 true, ptr %3, align 1
  store i32 1, ptr %9, align 4
  br label %260

260:                                              ; preds = %259, %235
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 256, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 512, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 4096, ptr %10) #5
  br label %261

261:                                              ; preds = %260, %28
  call void @llvm.lifetime.end.p0(i64 1, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 256, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 256, ptr %6) #5
  %262 = load i1, ptr %3, align 1
  ret i1 %262
}

; Function Attrs: nounwind
declare i32 @sprintf(ptr noundef, ptr noundef, ...) #0

; Function Attrs: nounwind
declare ptr @strcpy(ptr noundef, ptr noundef) #0

; Function Attrs: nounwind
declare ptr @strcat(ptr noundef, ptr noundef) #0

declare i32 @system(ptr noundef) #1

attributes #0 = { 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 #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 = { 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 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { 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/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"_Bool", !7, i64 0}
!11 = !{i8 0, i8 2}
!12 = !{}
!13 = !{!14, !14, i64 0}
!14 = !{!"int", !7, i64 0}
!15 = !{!16, !14, i64 12}
!16 = !{!"_MatNd", !6, i64 0, !14, i64 8, !14, i64 12, !14, i64 16, !10, i64 20}
!17 = distinct !{!17, !18}
!18 = !{!"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"

@stderr = external local_unnamed_addr global ptr, align 8
@.str = external hidden unnamed_addr constant [39 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [68 x i8], align 1
@.str.4 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.24 = external hidden unnamed_addr constant [3 x i8], align 1
@RCS_GLOBAL_RLOG_CB = external local_unnamed_addr global ptr, align 8
@RcsLogLevel = external local_unnamed_addr global i32, align 4
@.str.26 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.33 = external hidden unnamed_addr constant [1 x i8], align 1
@.str.35 = external hidden unnamed_addr constant [11 x i8], align 1
@.str.36 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.37 = external hidden unnamed_addr constant [4 x i8], align 1
@.str.38 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.39 = external hidden unnamed_addr constant [16 x i8], align 1
@.str.40 = external hidden unnamed_addr constant [32 x i8], align 1
@.str.41 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.42 = external hidden unnamed_addr constant [4 x i8], align 1
@__func__.MatNd_gnuplot2 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.44 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.45 = external hidden unnamed_addr constant [15 x i8], align 1
@.str.46 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.47 = external hidden unnamed_addr constant [7 x i8], align 1
@.str.48 = external hidden unnamed_addr constant [24 x i8], align 1
@.str.49 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.50 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.51 = external hidden unnamed_addr constant [29 x i8], align 1
@.str.52 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.53 = external hidden unnamed_addr constant [23 x i8], align 1
@.str.54 = external hidden unnamed_addr constant [9 x i8], align 1

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

declare void @print_trace() local_unnamed_addr #1

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

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

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

; Function Attrs: nounwind uwtable
declare dso_local zeroext i1 @MatNd_toFile(ptr noundef, ptr noundef) local_unnamed_addr #4

; Function Attrs: nofree nounwind
declare noalias noundef ptr @fopen(ptr nocapture noundef readonly, ptr nocapture noundef readonly) local_unnamed_addr #0

; Function Attrs: nofree nounwind
declare noundef i32 @fclose(ptr nocapture noundef) local_unnamed_addr #0

declare ptr @File_createUniqueName(ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #1

; Function Attrs: nofree nounwind
declare noundef i32 @fflush(ptr nocapture noundef) local_unnamed_addr #0

; Function Attrs: nounwind uwtable
define dso_local noundef zeroext i1 @MatNd_gnuplot2(ptr noundef %0, ptr noundef %1) local_unnamed_addr #4 {
  %3 = alloca [256 x i8], align 16
  %4 = alloca [256 x i8], align 16
  %5 = alloca [4096 x i8], align 16
  %6 = alloca [512 x i8], align 16
  %7 = alloca [256 x i8], align 16
  call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %3) #7
  call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %4) #7
  %8 = call ptr @File_createUniqueName(ptr noundef nonnull %3, ptr noundef nonnull @.str.36, ptr noundef nonnull @.str.37) #7
  %9 = call ptr @File_createUniqueName(ptr noundef nonnull %4, ptr noundef nonnull @.str.36, ptr noundef nonnull @.str.42) #7
  %10 = call zeroext i1 @MatNd_toFile(ptr noundef %1, ptr noundef nonnull %3)
  br i1 %10, label %11, label %146

11:                                               ; preds = %2
  %12 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %.not = icmp eq ptr %12, null
  br i1 %.not, label %14, label %13

13:                                               ; preds = %11
  call void (i32, ptr, ptr, i32, ptr, ...) %12(i32 noundef 0, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 608, ptr noundef nonnull @.str.43) #7
  br label %14

14:                                               ; preds = %13, %11
  %15 = load i32, ptr @RcsLogLevel, align 4, !tbaa !9
  %16 = icmp sgt i32 %15, -1
  br i1 %16, label %17, label %24

17:                                               ; preds = %14
  %18 = load ptr, ptr @stderr, align 8, !tbaa !5
  %19 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %18, ptr noundef nonnull @.str.26, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 608) #8
  %20 = load ptr, ptr @stderr, align 8, !tbaa !5
  %21 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %20, ptr noundef nonnull @.str.43) #8
  %22 = load ptr, ptr @stderr, align 8, !tbaa !5
  %23 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %22, ptr noundef nonnull @.str.4) #8
  br label %24

24:                                               ; preds = %17, %14
  call void @llvm.lifetime.start.p0(i64 4096, ptr nonnull %5) #7
  call void @llvm.lifetime.start.p0(i64 512, ptr nonnull %6) #7
  %.not32 = icmp eq ptr %0, null
  br i1 %.not32, label %27, label %25

25:                                               ; preds = %24
  %26 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef nonnull dereferenceable(1) %5, ptr noundef nonnull dereferenceable(1) @.str.38, ptr noundef nonnull %0) #7
  br label %29

27:                                               ; preds = %24
  %28 = call ptr @strcpy(ptr noundef nonnull dereferenceable(1) %5, ptr noundef nonnull dereferenceable(1) @.str.39) #7
  br label %29

29:                                               ; preds = %25, %27
  %30 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %.not33 = icmp eq ptr %30, null
  br i1 %.not33, label %32, label %31

31:                                               ; preds = %29
  call void (i32, ptr, ptr, i32, ptr, ...) %30(i32 noundef 0, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 618, ptr noundef nonnull @.str.44) #7
  br label %32

32:                                               ; preds = %31, %29
  %33 = load i32, ptr @RcsLogLevel, align 4, !tbaa !9
  %34 = icmp sgt i32 %33, -1
  br i1 %34, label %35, label %42

35:                                               ; preds = %32
  %36 = load ptr, ptr @stderr, align 8, !tbaa !5
  %37 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %36, ptr noundef nonnull @.str.26, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 618) #8
  %38 = load ptr, ptr @stderr, align 8, !tbaa !5
  %39 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %38, ptr noundef nonnull @.str.44) #8
  %40 = load ptr, ptr @stderr, align 8, !tbaa !5
  %41 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %40, ptr noundef nonnull @.str.4) #8
  br label %42

42:                                               ; preds = %35, %32
  %43 = getelementptr inbounds i8, ptr %1, i64 12
  %44 = load i32, ptr %43, align 4, !tbaa !11
  %.not3443 = icmp eq i32 %44, 0
  br i1 %.not3443, label %._crit_edge, label %.lr.ph

._crit_edge:                                      ; preds = %67, %42
  %45 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %5, ptr noundef nonnull dereferenceable(1) @.str.4) #7
  %46 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %.not35 = icmp eq ptr %46, null
  br i1 %.not35, label %70, label %69

.lr.ph:                                           ; preds = %42, %67
  %47 = phi i32 [ %64, %67 ], [ %44, %42 ]
  %.02044 = phi i32 [ %68, %67 ], [ 1, %42 ]
  %48 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %.not41 = icmp eq ptr %48, null
  br i1 %.not41, label %50, label %49

49:                                               ; preds = %.lr.ph
  call void (i32, ptr, ptr, i32, ptr, ...) %48(i32 noundef 0, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 621, ptr noundef nonnull @.str.45, i32 noundef %.02044, i32 noundef %47) #7
  br label %50

50:                                               ; preds = %49, %.lr.ph
  %51 = load i32, ptr @RcsLogLevel, align 4, !tbaa !9
  %52 = icmp sgt i32 %51, -1
  br i1 %52, label %53, label %61

53:                                               ; preds = %50
  %54 = load ptr, ptr @stderr, align 8, !tbaa !5
  %55 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %54, ptr noundef nonnull @.str.26, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 621) #8
  %56 = load ptr, ptr @stderr, align 8, !tbaa !5
  %57 = load i32, ptr %43, align 4, !tbaa !11
  %58 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %56, ptr noundef nonnull @.str.45, i32 noundef %.02044, i32 noundef %57) #8
  %59 = load ptr, ptr @stderr, align 8, !tbaa !5
  %60 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %59, ptr noundef nonnull @.str.4) #8
  br label %61

61:                                               ; preds = %53, %50
  %62 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef nonnull dereferenceable(1) %6, ptr noundef nonnull dereferenceable(1) @.str.40, ptr noundef nonnull %3, i32 noundef %.02044, i32 noundef %.02044) #7
  %63 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %5, ptr noundef nonnull dereferenceable(1) %6) #7
  %64 = load i32, ptr %43, align 4, !tbaa !11
  %.not42 = icmp eq i32 %.02044, %64
  br i1 %.not42, label %67, label %65

65:                                               ; preds = %61
  %66 = call ptr @strcat(ptr noundef nonnull dereferenceable(1) %5, ptr noundef nonnull dereferenceable(1) @.str.41) #7
  br label %67

67:                                               ; preds = %61, %65
  %68 = add i32 %.02044, 1
  %.not34 = icmp ugt i32 %68, %64
  br i1 %.not34, label %._crit_edge, label %.lr.ph, !llvm.loop !14

69:                                               ; preds = %._crit_edge
  call void (i32, ptr, ptr, i32, ptr, ...) %46(i32 noundef 0, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 632, ptr noundef nonnull @.str.46) #7
  br label %70

70:                                               ; preds = %69, %._crit_edge
  %71 = load i32, ptr @RcsLogLevel, align 4, !tbaa !9
  %72 = icmp sgt i32 %71, -1
  br i1 %72, label %73, label %80

73:                                               ; preds = %70
  %74 = load ptr, ptr @stderr, align 8, !tbaa !5
  %75 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %74, ptr noundef nonnull @.str.26, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 632) #8
  %76 = load ptr, ptr @stderr, align 8, !tbaa !5
  %77 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %76, ptr noundef nonnull @.str.46) #8
  %78 = load ptr, ptr @stderr, align 8, !tbaa !5
  %79 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %78, ptr noundef nonnull @.str.4) #8
  br label %80

80:                                               ; preds = %73, %70
  %81 = call noalias ptr @fopen(ptr noundef nonnull %4, ptr noundef nonnull @.str.24)
  %.not36 = icmp eq ptr %81, null
  br i1 %.not36, label %82, label %89

82:                                               ; preds = %80
  %83 = load ptr, ptr @stderr, align 8, !tbaa !5
  %84 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %83, ptr noundef nonnull @.str, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 635, ptr noundef nonnull @.str.47) #8
  %85 = load ptr, ptr @stderr, align 8, !tbaa !5
  %86 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %85, ptr noundef nonnull @.str.48, ptr noundef nonnull %4) #8
  %87 = load ptr, ptr @stderr, align 8, !tbaa !5
  %88 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %87, ptr noundef nonnull @.str.4) #8
  call void @print_trace() #7
  call void @exit(i32 noundef 1) #9
  unreachable

89:                                               ; preds = %80
  %90 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef nonnull %81, ptr noundef nonnull @.str.49, ptr noundef nonnull %5) #7
  %91 = call i32 @fflush(ptr noundef nonnull %81)
  %92 = call i32 @fclose(ptr noundef nonnull %81)
  %93 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %.not37 = icmp eq ptr %93, null
  br i1 %.not37, label %95, label %94

94:                                               ; preds = %89
  call void (i32, ptr, ptr, i32, ptr, ...) %93(i32 noundef 0, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 639, ptr noundef nonnull @.str.50) #7
  br label %95

95:                                               ; preds = %94, %89
  %96 = load i32, ptr @RcsLogLevel, align 4, !tbaa !9
  %97 = icmp sgt i32 %96, -1
  br i1 %97, label %98, label %105

98:                                               ; preds = %95
  %99 = load ptr, ptr @stderr, align 8, !tbaa !5
  %100 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %99, ptr noundef nonnull @.str.26, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 639) #8
  %101 = load ptr, ptr @stderr, align 8, !tbaa !5
  %102 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %101, ptr noundef nonnull @.str.50) #8
  %103 = load ptr, ptr @stderr, align 8, !tbaa !5
  %104 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %103, ptr noundef nonnull @.str.4) #8
  br label %105

105:                                              ; preds = %98, %95
  call void @llvm.lifetime.start.p0(i64 256, ptr nonnull %7) #7
  %106 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef nonnull dereferenceable(1) %7, ptr noundef nonnull dereferenceable(1) @.str.51, ptr noundef nonnull %4) #7
  %107 = call i32 @system(ptr noundef nonnull %7) #7
  %108 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %.not38 = icmp eq ptr %108, null
  br i1 %.not38, label %110, label %109

109:                                              ; preds = %105
  call void (i32, ptr, ptr, i32, ptr, ...) %108(i32 noundef 0, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 649, ptr noundef nonnull @.str.52) #7
  br label %110

110:                                              ; preds = %109, %105
  %111 = load i32, ptr @RcsLogLevel, align 4, !tbaa !9
  %112 = icmp sgt i32 %111, -1
  br i1 %112, label %113, label %120

113:                                              ; preds = %110
  %114 = load ptr, ptr @stderr, align 8, !tbaa !5
  %115 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %114, ptr noundef nonnull @.str.26, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 649) #8
  %116 = load ptr, ptr @stderr, align 8, !tbaa !5
  %117 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %116, ptr noundef nonnull @.str.52) #8
  %118 = load ptr, ptr @stderr, align 8, !tbaa !5
  %119 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %118, ptr noundef nonnull @.str.4) #8
  br label %120

120:                                              ; preds = %113, %110
  %121 = icmp ne i32 %107, -1
  %122 = load ptr, ptr @RCS_GLOBAL_RLOG_CB, align 8, !tbaa !5
  %.not39 = icmp eq ptr %122, null
  br i1 %121, label %133, label %123

123:                                              ; preds = %120
  br i1 %.not39, label %125, label %124

124:                                              ; preds = %123
  call void (i32, ptr, ptr, i32, ptr, ...) %122(i32 noundef 4, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 653, ptr noundef nonnull @.str.53) #7
  br label %125

125:                                              ; preds = %124, %123
  %126 = load i32, ptr @RcsLogLevel, align 4, !tbaa !9
  %127 = icmp sgt i32 %126, 3
  br i1 %127, label %128, label %145

128:                                              ; preds = %125
  %129 = load ptr, ptr @stderr, align 8, !tbaa !5
  %130 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %129, ptr noundef nonnull @.str.26, ptr noundef nonnull @.str.1, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 653) #8
  %131 = load ptr, ptr @stderr, align 8, !tbaa !5
  %132 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %131, ptr noundef nonnull @.str.53) #8
  br label %.sink.split

133:                                              ; preds = %120
  br i1 %.not39, label %135, label %134

134:                                              ; preds = %133
  call void (i32, ptr, ptr, i32, ptr, ...) %122(i32 noundef 5, ptr noundef nonnull @.str.33, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 658, ptr noundef nonnull @.str.54, ptr noundef nonnull %5, ptr noundef nonnull %7) #7
  br label %135

135:                                              ; preds = %134, %133
  %136 = load i32, ptr @RcsLogLevel, align 4, !tbaa !9
  %137 = icmp sgt i32 %136, 4
  br i1 %137, label %138, label %145

138:                                              ; preds = %135
  %139 = load ptr, ptr @stderr, align 8, !tbaa !5
  %140 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %139, ptr noundef nonnull @.str.35, ptr noundef nonnull @__func__.MatNd_gnuplot2, i32 noundef 658) #8
  %141 = load ptr, ptr @stderr, align 8, !tbaa !5
  %142 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %141, ptr noundef nonnull @.str.54, ptr noundef nonnull %5, ptr noundef nonnull %7) #8
  br label %.sink.split

.sink.split:                                      ; preds = %128, %138
  %143 = load ptr, ptr @stderr, align 8, !tbaa !5
  %144 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %143, ptr noundef nonnull @.str.4) #8
  br label %145

145:                                              ; preds = %.sink.split, %135, %125
  call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %7) #7
  call void @llvm.lifetime.end.p0(i64 512, ptr nonnull %6) #7
  call void @llvm.lifetime.end.p0(i64 4096, ptr nonnull %5) #7
  br label %146

146:                                              ; preds = %2, %145
  %.1 = phi i1 [ %121, %145 ], [ false, %2 ]
  call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %4) #7
  call void @llvm.lifetime.end.p0(i64 256, ptr nonnull %3) #7
  ret i1 %.1
}

; Function Attrs: nofree nounwind
declare noundef i32 @sprintf(ptr noalias nocapture noundef writeonly, ptr nocapture noundef readonly, ...) local_unnamed_addr #0

; Function Attrs: mustprogress nofree nounwind willreturn memory(argmem: readwrite)
declare ptr @strcpy(ptr noalias noundef returned writeonly, ptr noalias nocapture noundef readonly) local_unnamed_addr #5

; Function Attrs: mustprogress nofree nounwind willreturn memory(argmem: readwrite)
declare ptr @strcat(ptr noalias noundef returned, ptr noalias nocapture noundef readonly) local_unnamed_addr #5

; Function Attrs: nofree
declare noundef i32 @system(ptr nocapture noundef readonly) local_unnamed_addr #6

attributes #0 = { 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 #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 = { 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 nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { mustprogress nofree nounwind willreturn memory(argmem: readwrite) "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 = { nofree "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nounwind }
attributes #8 = { cold nounwind }
attributes #9 = { 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/C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"int", !7, i64 0}
!11 = !{!12, !10, i64 12}
!12 = !{!"_MatNd", !6, i64 0, !10, i64 8, !10, i64 12, !10, i64 16, !13, i64 20}
!13 = !{!"_Bool", !7, i64 0}
!14 = distinct !{!14, !15}
!15 = !{!"llvm.loop.mustprogress"}


; Effective O3 passes: EarlyCSEPass,GVNPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,JumpThreadingPass,LICMPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,PostOrderFunctionAttrsPass,SROAPass,SimplifyCFGPass