; LLVM IR from gem5/gem5 :: ext/systemc/src/sysc/tracing (sc_wif_trace)

; Unoptimized IR (clang -disable-llvm-passes):
target datalayout = "e-m:e-p270:32:32-p271:32:32-p272:64:64-i64:64-i128:128-f80:128-n8:16:32:64-S128"
target triple = "x86_64-unknown-linux-gnu"

%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator" = type { i8 }
%"class.sc_core::sc_trace_file_base" = type <{ %"class.sc_core::sc_trace_file", ptr, double, i8, [7 x i8], %"class.std::__cxx11::basic_string", i8, i8, [6 x i8] }>
%"class.sc_core::sc_trace_file" = type { ptr }
%"class.sc_core::wif_trace_file" = type { %"class.sc_core::sc_trace_file_base.base", i32, i32, i32, double, %"class.std::vector.0" }
%"class.sc_core::sc_trace_file_base.base" = type <{ %"class.sc_core::sc_trace_file", ptr, double, i8, [7 x i8], %"class.std::__cxx11::basic_string", i8, i8 }>
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<sc_core::wif_trace *, std::allocator<sc_core::wif_trace *>>::_Vector_impl" }
%"struct.std::_Vector_base<sc_core::wif_trace *, std::allocator<sc_core::wif_trace *>>::_Vector_impl" = type { %"struct.std::_Vector_base<sc_core::wif_trace *, std::allocator<sc_core::wif_trace *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<sc_core::wif_trace *, std::allocator<sc_core::wif_trace *>>::_Vector_impl_data" = type { ptr, ptr, ptr }

@.str.24 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.25 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.26 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.27 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.28 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.29 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.30 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.31 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.32 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.33 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.34 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.35 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.36 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.37 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.38 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.39 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.40 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.41 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.42 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.44 = external hidden unnamed_addr constant [50 x i8], align 1
@.str.45 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.46 = external hidden unnamed_addr constant [65 x i8], align 1
@.str.47 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.48 = external hidden unnamed_addr constant [50 x i8], align 1
@.str.49 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.50 = external hidden unnamed_addr constant [73 x i8], align 1

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #0 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32)) #0 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN7sc_core14wif_trace_file13do_initializeEv(ptr noundef nonnull align 8 dereferenceable(112) %0) unnamed_addr #3 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca ptr, align 8
  %3 = alloca [2000 x i8], align 16
  %4 = alloca %"class.std::__cxx11::basic_string", align 8
  %5 = alloca i32, align 4
  %6 = alloca ptr, align 8
  %7 = alloca double, align 8
  %8 = alloca %"class.std::__cxx11::basic_string", align 8
  %9 = alloca %"class.std::allocator", align 1
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca ptr, align 8
  store ptr %0, ptr %2, align 8, !tbaa !5
  %13 = load ptr, ptr %2, align 8
  call void @llvm.lifetime.start.p0(i64 2000, ptr %3) #5
  %14 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 1
  %15 = load ptr, ptr %14, align 8, !tbaa !9
  %16 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %15, ptr noundef @.str.24) #5
  %17 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %18 = load double, ptr %17, align 8, !tbaa !17
  %19 = fcmp oeq double %18, 1.000000e-15
  br i1 %19, label %20, label %23

20:                                               ; preds = %1
  %21 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %22 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %21, ptr noundef @.str.25) #5
  br label %159

23:                                               ; preds = %1
  %24 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %25 = load double, ptr %24, align 8, !tbaa !17
  %26 = fcmp oeq double %25, 0x3D06849B86A12B9B
  br i1 %26, label %27, label %30

27:                                               ; preds = %23
  %28 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %29 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %28, ptr noundef @.str.26) #5
  br label %158

30:                                               ; preds = %23
  %31 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %32 = load double, ptr %31, align 8, !tbaa !17
  %33 = fcmp oeq double %32, 1.000000e-13
  br i1 %33, label %34, label %37

34:                                               ; preds = %30
  %35 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %36 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %35, ptr noundef @.str.27) #5
  br label %157

37:                                               ; preds = %30
  %38 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %39 = load double, ptr %38, align 8, !tbaa !17
  %40 = fcmp oeq double %39, 0x3D719799812DEA11
  br i1 %40, label %41, label %44

41:                                               ; preds = %37
  %42 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %43 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %42, ptr noundef @.str.28) #5
  br label %156

44:                                               ; preds = %37
  %45 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %46 = load double, ptr %45, align 8, !tbaa !17
  %47 = fcmp oeq double %46, 0x3DA5FD7FE1796495
  br i1 %47, label %48, label %51

48:                                               ; preds = %44
  %49 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %50 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %49, ptr noundef @.str.29) #5
  br label %155

51:                                               ; preds = %44
  %52 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %53 = load double, ptr %52, align 8, !tbaa !17
  %54 = fcmp oeq double %53, 1.000000e-10
  br i1 %54, label %55, label %58

55:                                               ; preds = %51
  %56 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %57 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %56, ptr noundef @.str.30) #5
  br label %154

58:                                               ; preds = %51
  %59 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %60 = load double, ptr %59, align 8, !tbaa !17
  %61 = fcmp oeq double %60, 1.000000e-09
  br i1 %61, label %62, label %65

62:                                               ; preds = %58
  %63 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %64 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %63, ptr noundef @.str.31) #5
  br label %153

65:                                               ; preds = %58
  %66 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %67 = load double, ptr %66, align 8, !tbaa !17
  %68 = fcmp oeq double %67, 1.000000e-08
  br i1 %68, label %69, label %72

69:                                               ; preds = %65
  %70 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %71 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %70, ptr noundef @.str.32) #5
  br label %152

72:                                               ; preds = %65
  %73 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %74 = load double, ptr %73, align 8, !tbaa !17
  %75 = fcmp oeq double %74, 0x3E7AD7F29ABCAF48
  br i1 %75, label %76, label %79

76:                                               ; preds = %72
  %77 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %78 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %77, ptr noundef @.str.33) #5
  br label %151

79:                                               ; preds = %72
  %80 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %81 = load double, ptr %80, align 8, !tbaa !17
  %82 = fcmp oeq double %81, 0x3EB0C6F7A0B5ED8D
  br i1 %82, label %83, label %86

83:                                               ; preds = %79
  %84 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %85 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %84, ptr noundef @.str.34) #5
  br label %150

86:                                               ; preds = %79
  %87 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %88 = load double, ptr %87, align 8, !tbaa !17
  %89 = fcmp oeq double %88, 1.000000e-05
  br i1 %89, label %90, label %93

90:                                               ; preds = %86
  %91 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %92 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %91, ptr noundef @.str.35) #5
  br label %149

93:                                               ; preds = %86
  %94 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %95 = load double, ptr %94, align 8, !tbaa !17
  %96 = fcmp oeq double %95, 1.000000e-04
  br i1 %96, label %97, label %100

97:                                               ; preds = %93
  %98 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %99 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %98, ptr noundef @.str.36) #5
  br label %148

100:                                              ; preds = %93
  %101 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %102 = load double, ptr %101, align 8, !tbaa !17
  %103 = fcmp oeq double %102, 1.000000e-03
  br i1 %103, label %104, label %107

104:                                              ; preds = %100
  %105 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %106 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %105, ptr noundef @.str.37) #5
  br label %147

107:                                              ; preds = %100
  %108 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %109 = load double, ptr %108, align 8, !tbaa !17
  %110 = fcmp oeq double %109, 1.000000e-02
  br i1 %110, label %111, label %114

111:                                              ; preds = %107
  %112 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %113 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %112, ptr noundef @.str.38) #5
  br label %146

114:                                              ; preds = %107
  %115 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %116 = load double, ptr %115, align 8, !tbaa !17
  %117 = fcmp oeq double %116, 1.000000e-01
  br i1 %117, label %118, label %121

118:                                              ; preds = %114
  %119 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %120 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %119, ptr noundef @.str.39) #5
  br label %145

121:                                              ; preds = %114
  %122 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %123 = load double, ptr %122, align 8, !tbaa !17
  %124 = fcmp oeq double %123, 1.000000e+00
  br i1 %124, label %125, label %128

125:                                              ; preds = %121
  %126 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %127 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %126, ptr noundef @.str.40) #5
  br label %144

128:                                              ; preds = %121
  %129 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %130 = load double, ptr %129, align 8, !tbaa !17
  %131 = fcmp oeq double %130, 1.000000e+01
  br i1 %131, label %132, label %135

132:                                              ; preds = %128
  %133 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %134 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %133, ptr noundef @.str.41) #5
  br label %143

135:                                              ; preds = %128
  %136 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %137 = load double, ptr %136, align 8, !tbaa !17
  %138 = fcmp oeq double %137, 1.000000e+02
  br i1 %138, label %139, label %142

139:                                              ; preds = %135
  %140 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %141 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %140, ptr noundef @.str.42) #5
  br label %142

142:                                              ; preds = %139, %135
  br label %143

143:                                              ; preds = %142, %132
  br label %144

144:                                              ; preds = %143, %125
  br label %145

145:                                              ; preds = %144, %118
  br label %146

146:                                              ; preds = %145, %111
  br label %147

147:                                              ; preds = %146, %104
  br label %148

148:                                              ; preds = %147, %97
  br label %149

149:                                              ; preds = %148, %90
  br label %150

150:                                              ; preds = %149, %83
  br label %151

151:                                              ; preds = %150, %76
  br label %152

152:                                              ; preds = %151, %69
  br label %153

153:                                              ; preds = %152, %62
  br label %154

154:                                              ; preds = %153, %55
  br label %155

155:                                              ; preds = %154, %48
  br label %156

156:                                              ; preds = %155, %41
  br label %157

157:                                              ; preds = %156, %34
  br label %158

158:                                              ; preds = %157, %27
  br label %159

159:                                              ; preds = %158, %20
  %160 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 1
  %161 = load ptr, ptr %160, align 8, !tbaa !9
  %162 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %163 = call noundef ptr @_ZN7sc_core10sc_versionEv()
  %164 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %161, ptr noundef @.str.43, ptr noundef %162, ptr noundef %163) #5
  %165 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 1
  %166 = load ptr, ptr %165, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 32, ptr %4) #5
  call void @_ZN7sc_core16localtime_stringB5cxx11Ev(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8 %4)
  %167 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %4) #5
  %168 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %166, ptr noundef @.str.44, ptr noundef %167) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %4) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr %4) #5
  %169 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 1
  %170 = load ptr, ptr %169, align 8, !tbaa !9
  %171 = call noundef ptr @_ZN7sc_core10sc_versionEv()
  %172 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %170, ptr noundef @.str.45, ptr noundef %171) #5
  %173 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 1
  %174 = load ptr, ptr %173, align 8, !tbaa !9
  %175 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %174, ptr noundef @.str.46) #5
  %176 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 1
  %177 = load ptr, ptr %176, align 8, !tbaa !9
  %178 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %177, ptr noundef @.str.47) #5
  %179 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 1
  %180 = load ptr, ptr %179, align 8, !tbaa !9
  %181 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %180, ptr noundef @.str.48) #5
  %182 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 1
  %183 = load ptr, ptr %182, align 8, !tbaa !9
  %184 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %183, ptr noundef @.str.49) #5
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #5
  store i32 0, ptr %5, align 4, !tbaa !18
  br label %185

185:                                              ; preds = %207, %159
  %186 = load i32, ptr %5, align 4, !tbaa !18
  %187 = getelementptr inbounds %"class.sc_core::wif_trace_file", ptr %13, i32 0, i32 5
  %188 = call noundef i64 @_ZNKSt6vectorIPN7sc_core9wif_traceESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %187) #5
  %189 = trunc i64 %188 to i32
  %190 = icmp slt i32 %186, %189
  br i1 %190, label %191, label %210

191:                                              ; preds = %185
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #5
  %192 = getelementptr inbounds %"class.sc_core::wif_trace_file", ptr %13, i32 0, i32 5
  %193 = load i32, ptr %5, align 4, !tbaa !18
  %194 = sext i32 %193 to i64
  %195 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7sc_core9wif_traceESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %192, i64 noundef %194) #5
  %196 = load ptr, ptr %195, align 8, !tbaa !5
  store ptr %196, ptr %6, align 8, !tbaa !5
  %197 = load ptr, ptr %6, align 8, !tbaa !5
  %198 = load ptr, ptr %197, align 8, !tbaa !20
  %199 = getelementptr inbounds ptr, ptr %198, i64 1
  %200 = load ptr, ptr %199, align 8
  call void %200(ptr noundef nonnull align 8 dereferenceable(84) %197)
  %201 = load ptr, ptr %6, align 8, !tbaa !5
  %202 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 1
  %203 = load ptr, ptr %202, align 8, !tbaa !9
  %204 = load ptr, ptr %201, align 8, !tbaa !20
  %205 = getelementptr inbounds ptr, ptr %204, i64 3
  %206 = load ptr, ptr %205, align 8
  call void %206(ptr noundef nonnull align 8 dereferenceable(84) %201, ptr noundef %203)
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #5
  br label %207

207:                                              ; preds = %191
  %208 = load i32, ptr %5, align 4, !tbaa !18
  %209 = add nsw i32 %208, 1
  store i32 %209, ptr %5, align 4, !tbaa !18
  br label %185, !llvm.loop !22

210:                                              ; preds = %185
  call void @llvm.lifetime.start.p0(i64 8, ptr %7) #5
  %211 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN7sc_core13sc_time_stampEv()
  %212 = call noundef double @_ZNK7sc_core7sc_time10to_secondsEv(ptr noundef nonnull align 8 dereferenceable(8) %211)
  store double %212, ptr %7, align 8, !tbaa !24
  %213 = load double, ptr %7, align 8, !tbaa !24
  %214 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %215 = load double, ptr %214, align 8, !tbaa !17
  %216 = fdiv double %213, %215
  %217 = getelementptr inbounds %"class.sc_core::wif_trace_file", ptr %13, i32 0, i32 4
  store double %216, ptr %217, align 8, !tbaa !25
  %218 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  %219 = load double, ptr %7, align 8, !tbaa !24
  %220 = load double, ptr %7, align 8, !tbaa !24
  %221 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %222 = load double, ptr %221, align 8, !tbaa !17
  %223 = fdiv double %220, %222
  %224 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef %218, ptr noundef @.str.50, double noundef %219, double noundef %223) #5
  call void @llvm.lifetime.start.p0(i64 32, ptr %8) #5
  %225 = getelementptr inbounds [2000 x i8], ptr %3, i64 0, i64 0
  call void @llvm.lifetime.start.p0(i64 1, ptr %9) #5
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #5
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %8, ptr noundef %225, ptr noundef nonnull align 1 dereferenceable(1) %9)
          to label %226 unwind label %258

226:                                              ; preds = %210
  %227 = load ptr, ptr %13, align 8, !tbaa !20
  %228 = getelementptr inbounds ptr, ptr %227, i64 26
  %229 = load ptr, ptr %228, align 8
  invoke void %229(ptr noundef nonnull align 8 dereferenceable(112) %13, ptr noundef nonnull align 8 dereferenceable(32) %8)
          to label %230 unwind label %262

230:                                              ; preds = %226
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #5
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr %8) #5
  %231 = load double, ptr %7, align 8, !tbaa !24
  %232 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 2
  %233 = load double, ptr %232, align 8, !tbaa !17
  %234 = fdiv double %231, %233
  %235 = getelementptr inbounds %"class.sc_core::wif_trace_file", ptr %13, i32 0, i32 3
  %236 = getelementptr inbounds %"class.sc_core::wif_trace_file", ptr %13, i32 0, i32 2
  call void @_ZN7sc_core23double_to_special_int64EdPjS0_(double noundef %234, ptr noundef %235, ptr noundef %236)
  store i32 0, ptr %5, align 4, !tbaa !18
  br label %237

237:                                              ; preds = %255, %230
  %238 = load i32, ptr %5, align 4, !tbaa !18
  %239 = getelementptr inbounds %"class.sc_core::wif_trace_file", ptr %13, i32 0, i32 5
  %240 = call noundef i64 @_ZNKSt6vectorIPN7sc_core9wif_traceESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %239) #5
  %241 = trunc i64 %240 to i32
  %242 = icmp slt i32 %238, %241
  br i1 %242, label %243, label %267

243:                                              ; preds = %237
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #5
  %244 = getelementptr inbounds %"class.sc_core::wif_trace_file", ptr %13, i32 0, i32 5
  %245 = load i32, ptr %5, align 4, !tbaa !18
  %246 = sext i32 %245 to i64
  %247 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7sc_core9wif_traceESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %244, i64 noundef %246) #5
  %248 = load ptr, ptr %247, align 8, !tbaa !5
  store ptr %248, ptr %12, align 8, !tbaa !5
  %249 = load ptr, ptr %12, align 8, !tbaa !5
  %250 = getelementptr inbounds %"class.sc_core::sc_trace_file_base", ptr %13, i32 0, i32 1
  %251 = load ptr, ptr %250, align 8, !tbaa !9
  %252 = load ptr, ptr %249, align 8, !tbaa !20
  %253 = getelementptr inbounds ptr, ptr %252, i64 0
  %254 = load ptr, ptr %253, align 8
  call void %254(ptr noundef nonnull align 8 dereferenceable(84) %249, ptr noundef %251)
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  br label %255

255:                                              ; preds = %243
  %256 = load i32, ptr %5, align 4, !tbaa !18
  %257 = add nsw i32 %256, 1
  store i32 %257, ptr %5, align 4, !tbaa !18
  br label %237, !llvm.loop !31

258:                                              ; preds = %210
  %259 = landingpad { ptr, i32 }
          cleanup
  %260 = extractvalue { ptr, i32 } %259, 0
  store ptr %260, ptr %10, align 8
  %261 = extractvalue { ptr, i32 } %259, 1
  store i32 %261, ptr %11, align 4
  br label %266

262:                                              ; preds = %226
  %263 = landingpad { ptr, i32 }
          cleanup
  %264 = extractvalue { ptr, i32 } %263, 0
  store ptr %264, ptr %10, align 8
  %265 = extractvalue { ptr, i32 } %263, 1
  store i32 %265, ptr %11, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %8) #5
  br label %266

266:                                              ; preds = %262, %258
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %9) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr %9) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr %8) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #5
  call void @llvm.lifetime.end.p0(i64 2000, ptr %3) #5
  br label %268

267:                                              ; preds = %237
  call void @llvm.lifetime.end.p0(i64 8, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #5
  call void @llvm.lifetime.end.p0(i64 2000, ptr %3) #5
  ret void

268:                                              ; preds = %266
  %269 = load ptr, ptr %10, align 8
  %270 = load i32, ptr %11, align 4
  %271 = insertvalue { ptr, i32 } poison, ptr %269, 0
  %272 = insertvalue { ptr, i32 } %271, i32 %270, 1
  resume { ptr, i32 } %272
}

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

declare noundef ptr @_ZN7sc_core10sc_versionEv() #4

declare void @_ZN7sc_core16localtime_stringB5cxx11Ev(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8) #4

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

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

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZN7sc_core13sc_time_stampEv() #4

declare noundef double @_ZNK7sc_core7sc_time10to_secondsEv(ptr noundef nonnull align 8 dereferenceable(8)) #4

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #3 align 2

declare void @_ZN7sc_core23double_to_special_int64EdPjS0_(double noundef, ptr noundef, ptr noundef) #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #0 align 2

attributes #0 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { nounwind "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { "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 }

!llvm.module.flags = !{!0, !1, !2, !3}
!llvm.ident = !{!4}

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !6, i64 8}
!10 = !{!"_ZTSN7sc_core18sc_trace_file_baseE", !11, i64 0, !6, i64 8, !12, i64 16, !13, i64 24, !14, i64 32, !13, i64 64, !13, i64 65}
!11 = !{!"_ZTSN7sc_core13sc_trace_fileE"}
!12 = !{!"double", !7, i64 0}
!13 = !{!"bool", !7, i64 0}
!14 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !15, i64 0, !16, i64 8, !7, i64 16}
!15 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !6, i64 0}
!16 = !{!"long", !7, i64 0}
!17 = !{!10, !12, i64 16}
!18 = !{!19, !19, i64 0}
!19 = !{!"int", !7, i64 0}
!20 = !{!21, !21, i64 0}
!21 = !{!"vtable pointer", !8, i64 0}
!22 = distinct !{!22, !23}
!23 = !{!"llvm.loop.mustprogress"}
!24 = !{!12, !12, i64 0}
!25 = !{!26, !12, i64 80}
!26 = !{!"_ZTSN7sc_core14wif_trace_fileE", !10, i64 0, !19, i64 68, !19, i64 72, !19, i64 76, !12, i64 80, !27, i64 88}
!27 = !{!"_ZTSSt6vectorIPN7sc_core9wif_traceESaIS2_EE", !28, i64 0}
!28 = !{!"_ZTSSt12_Vector_baseIPN7sc_core9wif_traceESaIS2_EE", !29, i64 0}
!29 = !{!"_ZTSNSt12_Vector_baseIPN7sc_core9wif_traceESaIS2_EE12_Vector_implE", !30, i64 0}
!30 = !{!"_ZTSNSt12_Vector_baseIPN7sc_core9wif_traceESaIS2_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!31 = distinct !{!31, !23}


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

%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator" = type { i8 }

@.str.24 = external hidden unnamed_addr constant [9 x i8], align 1
@.str.25 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.26 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.27 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.28 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.29 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.30 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.31 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.32 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.33 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.34 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.35 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.36 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.37 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.38 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.39 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.40 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.41 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.42 = external hidden unnamed_addr constant [3 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.44 = external hidden unnamed_addr constant [50 x i8], align 1
@.str.45 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.46 = external hidden unnamed_addr constant [65 x i8], align 1
@.str.47 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.48 = external hidden unnamed_addr constant [50 x i8], align 1
@.str.49 = external hidden unnamed_addr constant [2 x i8], align 1
@.str.50 = external hidden unnamed_addr constant [73 x i8], align 1

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #0 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #0 align 2

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

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

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN7sc_core14wif_trace_file13do_initializeEv(ptr noundef nonnull align 8 dereferenceable(112) %0) unnamed_addr #3 align 2 personality ptr @__gxx_personality_v0 {
  %2 = alloca [2000 x i8], align 16
  %3 = alloca %"class.std::__cxx11::basic_string", align 8
  %4 = alloca %"class.std::__cxx11::basic_string", align 8
  %5 = alloca %"class.std::allocator", align 1
  call void @llvm.lifetime.start.p0(i64 2000, ptr nonnull %2) #5
  %6 = getelementptr inbounds i8, ptr %0, i64 8
  %7 = load ptr, ptr %6, align 8, !tbaa !5
  %8 = tail call i32 (ptr, ptr, ...) @fprintf(ptr noundef %7, ptr noundef nonnull @.str.24) #5
  %9 = getelementptr inbounds i8, ptr %0, i64 16
  %10 = load double, ptr %9, align 8, !tbaa !16
  %11 = fcmp oeq double %10, 1.000000e-15
  br i1 %11, label %.sink.split, label %12

12:                                               ; preds = %1
  %13 = fcmp oeq double %10, 0x3D06849B86A12B9B
  br i1 %13, label %.sink.split, label %14

14:                                               ; preds = %12
  %15 = fcmp oeq double %10, 1.000000e-13
  br i1 %15, label %.sink.split, label %16

16:                                               ; preds = %14
  %17 = fcmp oeq double %10, 0x3D719799812DEA11
  br i1 %17, label %.sink.split, label %18

18:                                               ; preds = %16
  %19 = fcmp oeq double %10, 0x3DA5FD7FE1796495
  br i1 %19, label %.sink.split, label %20

20:                                               ; preds = %18
  %21 = fcmp oeq double %10, 1.000000e-10
  br i1 %21, label %.sink.split, label %22

22:                                               ; preds = %20
  %23 = fcmp oeq double %10, 1.000000e-09
  br i1 %23, label %.sink.split, label %24

24:                                               ; preds = %22
  %25 = fcmp oeq double %10, 1.000000e-08
  br i1 %25, label %.sink.split, label %26

26:                                               ; preds = %24
  %27 = fcmp oeq double %10, 0x3E7AD7F29ABCAF48
  br i1 %27, label %.sink.split, label %28

28:                                               ; preds = %26
  %29 = fcmp oeq double %10, 0x3EB0C6F7A0B5ED8D
  br i1 %29, label %.sink.split, label %30

30:                                               ; preds = %28
  %31 = fcmp oeq double %10, 1.000000e-05
  br i1 %31, label %.sink.split, label %32

32:                                               ; preds = %30
  %33 = fcmp oeq double %10, 1.000000e-04
  br i1 %33, label %.sink.split, label %34

34:                                               ; preds = %32
  %35 = fcmp oeq double %10, 1.000000e-03
  br i1 %35, label %.sink.split, label %36

36:                                               ; preds = %34
  %37 = fcmp oeq double %10, 1.000000e-02
  br i1 %37, label %.sink.split, label %38

38:                                               ; preds = %36
  %39 = fcmp oeq double %10, 1.000000e-01
  br i1 %39, label %.sink.split, label %40

40:                                               ; preds = %38
  %41 = fcmp oeq double %10, 1.000000e+00
  br i1 %41, label %.sink.split, label %42

42:                                               ; preds = %40
  %43 = fcmp oeq double %10, 1.000000e+01
  br i1 %43, label %.sink.split, label %44

44:                                               ; preds = %42
  %45 = fcmp oeq double %10, 1.000000e+02
  br i1 %45, label %.sink.split, label %47

.sink.split:                                      ; preds = %44, %42, %40, %38, %36, %34, %32, %30, %28, %26, %24, %22, %20, %18, %16, %14, %12, %1
  %.str.26.sink = phi ptr [ @.str.25, %1 ], [ @.str.26, %12 ], [ @.str.27, %14 ], [ @.str.28, %16 ], [ @.str.29, %18 ], [ @.str.30, %20 ], [ @.str.31, %22 ], [ @.str.32, %24 ], [ @.str.33, %26 ], [ @.str.34, %28 ], [ @.str.35, %30 ], [ @.str.36, %32 ], [ @.str.37, %34 ], [ @.str.38, %36 ], [ @.str.39, %38 ], [ @.str.40, %40 ], [ @.str.41, %42 ], [ @.str.42, %44 ]
  %46 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef nonnull dereferenceable(1) %2, ptr noundef nonnull dereferenceable(1) %.str.26.sink) #5
  br label %47

47:                                               ; preds = %.sink.split, %44
  %48 = load ptr, ptr %6, align 8, !tbaa !5
  %49 = tail call noundef ptr @_ZN7sc_core10sc_versionEv()
  %50 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %48, ptr noundef nonnull @.str.43, ptr noundef nonnull %2, ptr noundef %49) #5
  %51 = load ptr, ptr %6, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %3) #5
  call void @_ZN7sc_core16localtime_stringB5cxx11Ev(ptr dead_on_unwind nonnull writable sret(%"class.std::__cxx11::basic_string") align 8 %3)
  %52 = call noundef ptr @_ZNKSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE5c_strEv(ptr noundef nonnull align 8 dereferenceable(32) %3) #5
  %53 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %51, ptr noundef nonnull @.str.44, ptr noundef %52) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %3) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %3) #5
  %54 = load ptr, ptr %6, align 8, !tbaa !5
  %55 = call noundef ptr @_ZN7sc_core10sc_versionEv()
  %56 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %54, ptr noundef nonnull @.str.45, ptr noundef %55) #5
  %57 = load ptr, ptr %6, align 8, !tbaa !5
  %58 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %57, ptr noundef nonnull @.str.46) #5
  %59 = load ptr, ptr %6, align 8, !tbaa !5
  %60 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %59, ptr noundef nonnull @.str.47) #5
  %61 = load ptr, ptr %6, align 8, !tbaa !5
  %62 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %61, ptr noundef nonnull @.str.48) #5
  %63 = load ptr, ptr %6, align 8, !tbaa !5
  %64 = call i32 (ptr, ptr, ...) @fprintf(ptr noundef %63, ptr noundef nonnull @.str.49) #5
  %65 = getelementptr inbounds i8, ptr %0, i64 88
  %66 = call noundef i64 @_ZNKSt6vectorIPN7sc_core9wif_traceESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %65) #5
  %67 = trunc i64 %66 to i32
  %68 = icmp sgt i32 %67, 0
  br i1 %68, label %.lr.ph, label %._crit_edge

.lr.ph:                                           ; preds = %47, %.lr.ph
  %indvars.iv = phi i64 [ %indvars.iv.next, %.lr.ph ], [ 0, %47 ]
  %69 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7sc_core9wif_traceESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %65, i64 noundef %indvars.iv) #5
  %70 = load ptr, ptr %69, align 8, !tbaa !17
  %71 = load ptr, ptr %70, align 8, !tbaa !18
  %72 = getelementptr inbounds i8, ptr %71, i64 8
  %73 = load ptr, ptr %72, align 8
  call void %73(ptr noundef nonnull align 8 dereferenceable(84) %70)
  %74 = load ptr, ptr %6, align 8, !tbaa !5
  %75 = load ptr, ptr %70, align 8, !tbaa !18
  %76 = getelementptr inbounds i8, ptr %75, i64 24
  %77 = load ptr, ptr %76, align 8
  call void %77(ptr noundef nonnull align 8 dereferenceable(84) %70, ptr noundef %74)
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %78 = call noundef i64 @_ZNKSt6vectorIPN7sc_core9wif_traceESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %65) #5
  %sext = shl i64 %78, 32
  %79 = ashr exact i64 %sext, 32
  %80 = icmp slt i64 %indvars.iv.next, %79
  br i1 %80, label %.lr.ph, label %._crit_edge, !llvm.loop !20

._crit_edge:                                      ; preds = %.lr.ph, %47
  %81 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZN7sc_core13sc_time_stampEv()
  %82 = call noundef double @_ZNK7sc_core7sc_time10to_secondsEv(ptr noundef nonnull align 8 dereferenceable(8) %81)
  %83 = load double, ptr %9, align 8, !tbaa !16
  %84 = fdiv double %82, %83
  %85 = getelementptr inbounds i8, ptr %0, i64 80
  store double %84, ptr %85, align 8, !tbaa !22
  %86 = call i32 (ptr, ptr, ...) @sprintf(ptr noundef nonnull dereferenceable(1) %2, ptr noundef nonnull dereferenceable(1) @.str.50, double noundef %82, double noundef %84) #5
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %4) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %5) #5
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #5
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %4, ptr noundef nonnull %2, ptr noundef nonnull align 1 dereferenceable(1) %5)
          to label %87 unwind label %107

87:                                               ; preds = %._crit_edge
  %88 = load ptr, ptr %0, align 8, !tbaa !18
  %89 = getelementptr inbounds i8, ptr %88, i64 208
  %90 = load ptr, ptr %89, align 8
  invoke void %90(ptr noundef nonnull align 8 dereferenceable(112) %0, ptr noundef nonnull align 8 dereferenceable(32) %4)
          to label %91 unwind label %109

91:                                               ; preds = %87
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %4) #5
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %5) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #5
  %92 = load double, ptr %9, align 8, !tbaa !16
  %93 = fdiv double %82, %92
  %94 = getelementptr inbounds i8, ptr %0, i64 76
  %95 = getelementptr inbounds i8, ptr %0, i64 72
  call void @_ZN7sc_core23double_to_special_int64EdPjS0_(double noundef %93, ptr noundef nonnull %94, ptr noundef nonnull %95)
  %96 = call noundef i64 @_ZNKSt6vectorIPN7sc_core9wif_traceESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %65) #5
  %97 = trunc i64 %96 to i32
  %98 = icmp sgt i32 %97, 0
  br i1 %98, label %.lr.ph22, label %._crit_edge23

.lr.ph22:                                         ; preds = %91, %.lr.ph22
  %indvars.iv25 = phi i64 [ %indvars.iv.next26, %.lr.ph22 ], [ 0, %91 ]
  %99 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN7sc_core9wif_traceESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %65, i64 noundef %indvars.iv25) #5
  %100 = load ptr, ptr %99, align 8, !tbaa !17
  %101 = load ptr, ptr %6, align 8, !tbaa !5
  %102 = load ptr, ptr %100, align 8, !tbaa !18
  %103 = load ptr, ptr %102, align 8
  call void %103(ptr noundef nonnull align 8 dereferenceable(84) %100, ptr noundef %101)
  %indvars.iv.next26 = add nuw nsw i64 %indvars.iv25, 1
  %104 = call noundef i64 @_ZNKSt6vectorIPN7sc_core9wif_traceESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %65) #5
  %sext28 = shl i64 %104, 32
  %105 = ashr exact i64 %sext28, 32
  %106 = icmp slt i64 %indvars.iv.next26, %105
  br i1 %106, label %.lr.ph22, label %._crit_edge23, !llvm.loop !29

107:                                              ; preds = %._crit_edge
  %108 = landingpad { ptr, i32 }
          cleanup
  br label %111

109:                                              ; preds = %87
  %110 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %4) #5
  br label %111

111:                                              ; preds = %109, %107
  %.pn = phi { ptr, i32 } [ %110, %109 ], [ %108, %107 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %5) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %5) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %4) #5
  call void @llvm.lifetime.end.p0(i64 2000, ptr nonnull %2) #5
  resume { ptr, i32 } %.pn

._crit_edge23:                                    ; preds = %.lr.ph22, %91
  call void @llvm.lifetime.end.p0(i64 2000, ptr nonnull %2) #5
  ret void
}

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

declare noundef ptr @_ZN7sc_core10sc_versionEv() local_unnamed_addr #4

declare void @_ZN7sc_core16localtime_stringB5cxx11Ev(ptr dead_on_unwind writable sret(%"class.std::__cxx11::basic_string") align 8) local_unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i64 @_ZNKSt6vectorIPN7sc_core9wif_traceESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #0 align 2

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

declare noundef nonnull align 8 dereferenceable(8) ptr @_ZN7sc_core13sc_time_stampEv() local_unnamed_addr #4

declare noundef double @_ZNK7sc_core7sc_time10to_secondsEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #4

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32), ptr noundef, ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #3 align 2

declare void @_ZN7sc_core23double_to_special_int64EdPjS0_(double noundef, ptr noundef, ptr noundef) local_unnamed_addr #4

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #0 align 2

attributes #0 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { 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 #3 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { "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 }

!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, !8, i64 8}
!6 = !{!"_ZTSN7sc_core18sc_trace_file_baseE", !7, i64 0, !8, i64 8, !11, i64 16, !12, i64 24, !13, i64 32, !12, i64 64, !12, i64 65}
!7 = !{!"_ZTSN7sc_core13sc_trace_fileE"}
!8 = !{!"any pointer", !9, i64 0}
!9 = !{!"omnipotent char", !10, i64 0}
!10 = !{!"Simple C++ TBAA"}
!11 = !{!"double", !9, i64 0}
!12 = !{!"bool", !9, i64 0}
!13 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE", !14, i64 0, !15, i64 8, !9, i64 16}
!14 = !{!"_ZTSNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE12_Alloc_hiderE", !8, i64 0}
!15 = !{!"long", !9, i64 0}
!16 = !{!6, !11, i64 16}
!17 = !{!8, !8, i64 0}
!18 = !{!19, !19, i64 0}
!19 = !{!"vtable pointer", !10, i64 0}
!20 = distinct !{!20, !21}
!21 = !{!"llvm.loop.mustprogress"}
!22 = !{!23, !11, i64 80}
!23 = !{!"_ZTSN7sc_core14wif_trace_fileE", !6, i64 0, !24, i64 68, !24, i64 72, !24, i64 76, !11, i64 80, !25, i64 88}
!24 = !{!"int", !9, i64 0}
!25 = !{!"_ZTSSt6vectorIPN7sc_core9wif_traceESaIS2_EE", !26, i64 0}
!26 = !{!"_ZTSSt12_Vector_baseIPN7sc_core9wif_traceESaIS2_EE", !27, i64 0}
!27 = !{!"_ZTSNSt12_Vector_baseIPN7sc_core9wif_traceESaIS2_EE12_Vector_implE", !28, i64 0}
!28 = !{!"_ZTSNSt12_Vector_baseIPN7sc_core9wif_traceESaIS2_EE17_Vector_impl_dataE", !8, i64 0, !8, i64 8, !8, i64 16}
!29 = distinct !{!29, !21}


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