; LLVM IR from sp-nitech/SPTK :: src/generation/delta_calculation.ll (ZN4sptk16DeltaCalculation3GetEPSt6vectorIdSaIdEE)

; 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.__gnu_cxx::__normal_iterator" = type { ptr }
%"class.sptk::DeltaCalculation" = type { %"class.sptk::InputSourceInterface", i32, i32, %"class.std::vector", ptr, i8, double, i8, i32, %"class.std::vector.0", %"class.std::vector.0", %"struct.sptk::DeltaCalculation::Buffer" }
%"class.sptk::InputSourceInterface" = type { ptr }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<std::vector<double>, std::allocator<std::vector<double>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::vector<double>, std::allocator<std::vector<double>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::vector<double>, std::allocator<std::vector<double>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::vector<double>, std::allocator<std::vector<double>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl" = type { %"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" }
%"struct.std::_Vector_base<int, std::allocator<int>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.sptk::DeltaCalculation::Buffer" = type <{ %"class.std::vector", i32, i32, i8, [7 x i8] }>

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

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN4sptk16DeltaCalculation7ForwardEv(ptr noundef nonnull align 8 dereferenceable(160)) #2 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_ZN4sptk16DeltaCalculation3GetEPSt6vectorIdSaIdEE(ptr noundef nonnull align 8 dereferenceable(160) %0, ptr noundef %1) unnamed_addr #2 align 2 {
  %3 = alloca i1, align 1
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca i32, align 4
  %8 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %9 = alloca %"class.__gnu_cxx::__normal_iterator", align 8
  %10 = alloca double, align 8
  %11 = alloca ptr, align 8
  %12 = alloca i32, align 4
  %13 = alloca i32, align 4
  %14 = alloca i32, align 4
  %15 = alloca i32, align 4
  %16 = alloca i32, align 4
  %17 = alloca i32, align 4
  %18 = alloca i32, align 4
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  %19 = load ptr, ptr %4, align 8
  %20 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 7
  %21 = load i8, ptr %20, align 8, !tbaa !9, !range !24, !noundef !25
  %22 = trunc i8 %21 to i1
  br i1 %22, label %23, label %26

23:                                               ; preds = %2
  %24 = load ptr, ptr %5, align 8, !tbaa !5
  %25 = icmp eq ptr null, %24
  br i1 %25, label %26, label %27

26:                                               ; preds = %23, %2
  store i1 false, ptr %3, align 1
  br label %198

27:                                               ; preds = %23
  %28 = call noundef zeroext i1 @_ZN4sptk16DeltaCalculation7ForwardEv(ptr noundef nonnull align 8 dereferenceable(160) %19)
  br i1 %28, label %30, label %29

29:                                               ; preds = %27
  store i1 false, ptr %3, align 1
  br label %198

30:                                               ; preds = %27
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #5
  %31 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 1
  %32 = load i32, ptr %31, align 8, !tbaa !26
  %33 = add nsw i32 %32, 1
  store i32 %33, ptr %6, align 4, !tbaa !27
  call void @llvm.lifetime.start.p0(i64 4, ptr %7) #5
  %34 = load ptr, ptr %19, align 8, !tbaa !28
  %35 = getelementptr inbounds ptr, ptr %34, i64 2
  %36 = load ptr, ptr %35, align 8
  %37 = call noundef i32 %36(ptr noundef nonnull align 8 dereferenceable(160) %19)
  store i32 %37, ptr %7, align 4, !tbaa !27
  %38 = load ptr, ptr %5, align 8, !tbaa !5
  %39 = call noundef i64 @_ZNKSt6vectorIdSaIdEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %38) #5
  %40 = load i32, ptr %7, align 4, !tbaa !27
  %41 = sext i32 %40 to i64
  %42 = icmp ne i64 %39, %41
  br i1 %42, label %43, label %47

43:                                               ; preds = %30
  %44 = load ptr, ptr %5, align 8, !tbaa !5
  %45 = load i32, ptr %7, align 4, !tbaa !27
  %46 = sext i32 %45 to i64
  call void @_ZNSt6vectorIdSaIdEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %44, i64 noundef %46)
  br label %47

47:                                               ; preds = %43, %30
  %48 = load ptr, ptr %5, align 8, !tbaa !5
  %49 = call ptr @_ZNSt6vectorIdSaIdEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %48) #5
  %50 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %8, i32 0, i32 0
  store ptr %49, ptr %50, align 8
  %51 = load ptr, ptr %5, align 8, !tbaa !5
  %52 = call ptr @_ZNSt6vectorIdSaIdEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %51) #5
  %53 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %9, i32 0, i32 0
  store ptr %52, ptr %53, align 8
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #5
  store double 0.000000e+00, ptr %10, align 8, !tbaa !30
  %54 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %8, i32 0, i32 0
  %55 = load ptr, ptr %54, align 8
  %56 = getelementptr inbounds %"class.__gnu_cxx::__normal_iterator", ptr %9, i32 0, i32 0
  %57 = load ptr, ptr %56, align 8
  call void @_ZSt4fillIN9__gnu_cxx17__normal_iteratorIPdSt6vectorIdSaIdEEEEdEvT_S7_RKT0_(ptr %55, ptr %57, ptr noundef nonnull align 8 dereferenceable(8) %10)
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  %58 = load ptr, ptr %5, align 8, !tbaa !5
  %59 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %58, i64 noundef 0) #5
  store ptr %59, ptr %11, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %12) #5
  store i32 0, ptr %12, align 4, !tbaa !27
  br label %60

60:                                               ; preds = %194, %47
  %61 = load i32, ptr %12, align 4, !tbaa !27
  %62 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 2
  %63 = load i32, ptr %62, align 4, !tbaa !31
  %64 = icmp slt i32 %61, %63
  br i1 %64, label %66, label %65

65:                                               ; preds = %60
  store i32 2, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %12) #5
  br label %197

66:                                               ; preds = %60
  call void @llvm.lifetime.start.p0(i64 4, ptr %14) #5
  %67 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 9
  %68 = load i32, ptr %12, align 4, !tbaa !27
  %69 = sext i32 %68 to i64
  %70 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %67, i64 noundef %69) #5
  %71 = load i32, ptr %70, align 4, !tbaa !27
  store i32 %71, ptr %14, align 4, !tbaa !27
  call void @llvm.lifetime.start.p0(i64 4, ptr %15) #5
  store i32 0, ptr %15, align 4, !tbaa !27
  br label %72

72:                                               ; preds = %188, %66
  %73 = load i32, ptr %14, align 4, !tbaa !27
  %74 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 10
  %75 = load i32, ptr %12, align 4, !tbaa !27
  %76 = sext i32 %75 to i64
  %77 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %74, i64 noundef %76) #5
  %78 = load i32, ptr %77, align 4, !tbaa !27
  %79 = icmp sle i32 %73, %78
  br i1 %79, label %81, label %80

80:                                               ; preds = %72
  store i32 5, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %14) #5
  br label %193

81:                                               ; preds = %72
  call void @llvm.lifetime.start.p0(i64 4, ptr %16) #5
  %82 = load i32, ptr %14, align 4, !tbaa !27
  %83 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 8
  %84 = load i32, ptr %83, align 4, !tbaa !32
  %85 = add nsw i32 %84, 1
  %86 = sdiv i32 %85, 2
  %87 = sub nsw i32 %82, %86
  %88 = call noundef i32 @_ZN4sptk16DeltaCalculation15GetPointerIndexEi(ptr noundef nonnull align 8 dereferenceable(160) %19, i32 noundef %87)
  store i32 %88, ptr %16, align 4, !tbaa !27
  call void @llvm.lifetime.start.p0(i64 4, ptr %17) #5
  store i32 0, ptr %17, align 4, !tbaa !27
  br label %89

89:                                               ; preds = %184, %81
  %90 = load i32, ptr %17, align 4, !tbaa !27
  %91 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 1
  %92 = load i32, ptr %91, align 8, !tbaa !26
  %93 = icmp sle i32 %90, %92
  br i1 %93, label %95, label %94

94:                                               ; preds = %89
  store i32 8, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 4, ptr %17) #5
  br label %187

95:                                               ; preds = %89
  call void @llvm.lifetime.start.p0(i64 4, ptr %18) #5
  %96 = load i32, ptr %17, align 4, !tbaa !27
  %97 = load i32, ptr %6, align 4, !tbaa !27
  %98 = load i32, ptr %12, align 4, !tbaa !27
  %99 = mul nsw i32 %97, %98
  %100 = add nsw i32 %96, %99
  store i32 %100, ptr %18, align 4, !tbaa !27
  %101 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 5
  %102 = load i8, ptr %101, align 8, !tbaa !33, !range !24, !noundef !25
  %103 = trunc i8 %102 to i1
  br i1 %103, label %104, label %159

104:                                              ; preds = %95
  %105 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 6
  %106 = load double, ptr %105, align 8, !tbaa !34
  %107 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 11
  %108 = getelementptr inbounds %"struct.sptk::DeltaCalculation::Buffer", ptr %107, i32 0, i32 0
  %109 = load i32, ptr %16, align 4, !tbaa !27
  %110 = sext i32 %109 to i64
  %111 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_IdSaIdEESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %108, i64 noundef %110) #5
  %112 = load i32, ptr %17, align 4, !tbaa !27
  %113 = sext i32 %112 to i64
  %114 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %111, i64 noundef %113) #5
  %115 = load double, ptr %114, align 8, !tbaa !30
  %116 = fcmp oeq double %106, %115
  br i1 %116, label %117, label %124

117:                                              ; preds = %104
  %118 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 6
  %119 = load double, ptr %118, align 8, !tbaa !34
  %120 = load ptr, ptr %11, align 8, !tbaa !5
  %121 = load i32, ptr %18, align 4, !tbaa !27
  %122 = sext i32 %121 to i64
  %123 = getelementptr inbounds double, ptr %120, i64 %122
  store double %119, ptr %123, align 8, !tbaa !30
  br label %158

124:                                              ; preds = %104
  %125 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 6
  %126 = load double, ptr %125, align 8, !tbaa !34
  %127 = load ptr, ptr %11, align 8, !tbaa !5
  %128 = load i32, ptr %18, align 4, !tbaa !27
  %129 = sext i32 %128 to i64
  %130 = getelementptr inbounds double, ptr %127, i64 %129
  %131 = load double, ptr %130, align 8, !tbaa !30
  %132 = fcmp une double %126, %131
  br i1 %132, label %133, label %157

133:                                              ; preds = %124
  %134 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 3
  %135 = load i32, ptr %12, align 4, !tbaa !27
  %136 = sext i32 %135 to i64
  %137 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNKSt6vectorIS_IdSaIdEESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %134, i64 noundef %136) #5
  %138 = load i32, ptr %15, align 4, !tbaa !27
  %139 = sext i32 %138 to i64
  %140 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %137, i64 noundef %139) #5
  %141 = load double, ptr %140, align 8, !tbaa !30
  %142 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 11
  %143 = getelementptr inbounds %"struct.sptk::DeltaCalculation::Buffer", ptr %142, i32 0, i32 0
  %144 = load i32, ptr %16, align 4, !tbaa !27
  %145 = sext i32 %144 to i64
  %146 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_IdSaIdEESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %143, i64 noundef %145) #5
  %147 = load i32, ptr %17, align 4, !tbaa !27
  %148 = sext i32 %147 to i64
  %149 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %146, i64 noundef %148) #5
  %150 = load double, ptr %149, align 8, !tbaa !30
  %151 = load ptr, ptr %11, align 8, !tbaa !5
  %152 = load i32, ptr %18, align 4, !tbaa !27
  %153 = sext i32 %152 to i64
  %154 = getelementptr inbounds double, ptr %151, i64 %153
  %155 = load double, ptr %154, align 8, !tbaa !30
  %156 = call double @llvm.fmuladd.f64(double %141, double %150, double %155)
  store double %156, ptr %154, align 8, !tbaa !30
  br label %157

157:                                              ; preds = %133, %124
  br label %158

158:                                              ; preds = %157, %117
  br label %183

159:                                              ; preds = %95
  %160 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 3
  %161 = load i32, ptr %12, align 4, !tbaa !27
  %162 = sext i32 %161 to i64
  %163 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNKSt6vectorIS_IdSaIdEESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %160, i64 noundef %162) #5
  %164 = load i32, ptr %15, align 4, !tbaa !27
  %165 = sext i32 %164 to i64
  %166 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %163, i64 noundef %165) #5
  %167 = load double, ptr %166, align 8, !tbaa !30
  %168 = getelementptr inbounds %"class.sptk::DeltaCalculation", ptr %19, i32 0, i32 11
  %169 = getelementptr inbounds %"struct.sptk::DeltaCalculation::Buffer", ptr %168, i32 0, i32 0
  %170 = load i32, ptr %16, align 4, !tbaa !27
  %171 = sext i32 %170 to i64
  %172 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_IdSaIdEESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %169, i64 noundef %171) #5
  %173 = load i32, ptr %17, align 4, !tbaa !27
  %174 = sext i32 %173 to i64
  %175 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %172, i64 noundef %174) #5
  %176 = load double, ptr %175, align 8, !tbaa !30
  %177 = load ptr, ptr %11, align 8, !tbaa !5
  %178 = load i32, ptr %18, align 4, !tbaa !27
  %179 = sext i32 %178 to i64
  %180 = getelementptr inbounds double, ptr %177, i64 %179
  %181 = load double, ptr %180, align 8, !tbaa !30
  %182 = call double @llvm.fmuladd.f64(double %167, double %176, double %181)
  store double %182, ptr %180, align 8, !tbaa !30
  br label %183

183:                                              ; preds = %159, %158
  call void @llvm.lifetime.end.p0(i64 4, ptr %18) #5
  br label %184

184:                                              ; preds = %183
  %185 = load i32, ptr %17, align 4, !tbaa !27
  %186 = add nsw i32 %185, 1
  store i32 %186, ptr %17, align 4, !tbaa !27
  br label %89, !llvm.loop !35

187:                                              ; preds = %94
  call void @llvm.lifetime.end.p0(i64 4, ptr %16) #5
  br label %188

188:                                              ; preds = %187
  %189 = load i32, ptr %14, align 4, !tbaa !27
  %190 = add nsw i32 %189, 1
  store i32 %190, ptr %14, align 4, !tbaa !27
  %191 = load i32, ptr %15, align 4, !tbaa !27
  %192 = add nsw i32 %191, 1
  store i32 %192, ptr %15, align 4, !tbaa !27
  br label %72, !llvm.loop !37

193:                                              ; preds = %80
  br label %194

194:                                              ; preds = %193
  %195 = load i32, ptr %12, align 4, !tbaa !27
  %196 = add nsw i32 %195, 1
  store i32 %196, ptr %12, align 4, !tbaa !27
  br label %60, !llvm.loop !38

197:                                              ; preds = %65
  store i1 true, ptr %3, align 1
  store i32 1, ptr %13, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %7) #5
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #5
  br label %198

198:                                              ; preds = %197, %29, %26
  %199 = load i1, ptr %3, align 1
  ret i1 %199
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4fillIN9__gnu_cxx17__normal_iteratorIPdSt6vectorIdSaIdEEEEdEvT_S7_RKT0_(ptr, ptr, ptr noundef nonnull align 8 dereferenceable(8)) #3

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN4sptk16DeltaCalculation15GetPointerIndexEi(ptr noundef nonnull align 8 dereferenceable(160), i32 noundef) #1 align 2

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

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #4

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { 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 #3 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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, !17, i64 64}
!10 = !{!"_ZTSN4sptk16DeltaCalculationE", !11, i64 0, !12, i64 8, !12, i64 12, !13, i64 16, !6, i64 40, !17, i64 48, !18, i64 56, !17, i64 64, !12, i64 68, !19, i64 72, !19, i64 96, !23, i64 120}
!11 = !{!"_ZTSN4sptk20InputSourceInterfaceE"}
!12 = !{!"int", !7, i64 0}
!13 = !{!"_ZTSSt6vectorIS_IdSaIdEESaIS1_EE", !14, i64 0}
!14 = !{!"_ZTSSt12_Vector_baseISt6vectorIdSaIdEESaIS2_EE", !15, i64 0}
!15 = !{!"_ZTSNSt12_Vector_baseISt6vectorIdSaIdEESaIS2_EE12_Vector_implE", !16, i64 0}
!16 = !{!"_ZTSNSt12_Vector_baseISt6vectorIdSaIdEESaIS2_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!17 = !{!"bool", !7, i64 0}
!18 = !{!"double", !7, i64 0}
!19 = !{!"_ZTSSt6vectorIiSaIiEE", !20, i64 0}
!20 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !21, i64 0}
!21 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !22, i64 0}
!22 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!23 = !{!"_ZTSN4sptk16DeltaCalculation6BufferE", !13, i64 0, !12, i64 24, !12, i64 28, !17, i64 32}
!24 = !{i8 0, i8 2}
!25 = !{}
!26 = !{!10, !12, i64 8}
!27 = !{!12, !12, i64 0}
!28 = !{!29, !29, i64 0}
!29 = !{!"vtable pointer", !8, i64 0}
!30 = !{!18, !18, i64 0}
!31 = !{!10, !12, i64 12}
!32 = !{!10, !12, i64 68}
!33 = !{!10, !17, i64 48}
!34 = !{!10, !18, i64 56}
!35 = distinct !{!35, !36}
!36 = !{!"llvm.loop.mustprogress"}
!37 = distinct !{!37, !36}
!38 = distinct !{!38, !36}


; 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"

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

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef zeroext i1 @_ZN4sptk16DeltaCalculation7ForwardEv(ptr noundef nonnull align 8 dereferenceable(160)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
define dso_local noundef zeroext i1 @_ZN4sptk16DeltaCalculation3GetEPSt6vectorIdSaIdEE(ptr noundef nonnull align 8 dereferenceable(160) %0, ptr noundef %1) unnamed_addr #2 align 2 {
  %3 = alloca double, align 8
  %4 = getelementptr inbounds i8, ptr %0, i64 64
  %5 = load i8, ptr %4, align 8, !tbaa !5, !range !23, !noundef !24
  %6 = trunc nuw i8 %5 to i1
  %7 = icmp ne ptr %1, null
  %or.cond.not = and i1 %7, %6
  br i1 %or.cond.not, label %8, label %.loopexit

8:                                                ; preds = %2
  %9 = tail call noundef zeroext i1 @_ZN4sptk16DeltaCalculation7ForwardEv(ptr noundef nonnull align 8 dereferenceable(160) %0)
  br i1 %9, label %10, label %.loopexit

10:                                               ; preds = %8
  %11 = getelementptr inbounds i8, ptr %0, i64 8
  %12 = load i32, ptr %11, align 8, !tbaa !25
  %13 = add nsw i32 %12, 1
  %14 = load ptr, ptr %0, align 8, !tbaa !26
  %15 = getelementptr inbounds i8, ptr %14, i64 16
  %16 = load ptr, ptr %15, align 8
  %17 = tail call noundef i32 %16(ptr noundef nonnull align 8 dereferenceable(160) %0)
  %18 = tail call noundef i64 @_ZNKSt6vectorIdSaIdEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #5
  %19 = sext i32 %17 to i64
  %.not = icmp eq i64 %18, %19
  br i1 %.not, label %21, label %20

20:                                               ; preds = %10
  tail call void @_ZNSt6vectorIdSaIdEE6resizeEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %19)
  br label %21

21:                                               ; preds = %20, %10
  %22 = tail call ptr @_ZNSt6vectorIdSaIdEE5beginEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #5
  %23 = tail call ptr @_ZNSt6vectorIdSaIdEE3endEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %3) #5
  store double 0.000000e+00, ptr %3, align 8, !tbaa !28
  call void @_ZSt4fillIN9__gnu_cxx17__normal_iteratorIPdSt6vectorIdSaIdEEEEdEvT_S7_RKT0_(ptr %22, ptr %23, ptr noundef nonnull align 8 dereferenceable(8) %3)
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %3) #5
  %24 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef 0) #5
  %25 = getelementptr inbounds i8, ptr %0, i64 12
  %26 = load i32, ptr %25, align 4, !tbaa !29
  %27 = icmp sgt i32 %26, 0
  br i1 %27, label %.lr.ph61, label %.loopexit

.lr.ph61:                                         ; preds = %21
  %28 = getelementptr inbounds i8, ptr %0, i64 72
  %29 = getelementptr inbounds i8, ptr %0, i64 96
  %30 = getelementptr inbounds i8, ptr %0, i64 68
  %31 = getelementptr inbounds i8, ptr %0, i64 48
  %32 = getelementptr inbounds i8, ptr %0, i64 16
  %33 = getelementptr inbounds i8, ptr %0, i64 120
  %34 = getelementptr inbounds i8, ptr %0, i64 56
  %35 = sext i32 %13 to i64
  br label %36

36:                                               ; preds = %.lr.ph61, %._crit_edge58
  %indvars.iv66 = phi i64 [ 0, %.lr.ph61 ], [ %indvars.iv.next67, %._crit_edge58 ]
  %37 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %28, i64 noundef %indvars.iv66) #5
  %38 = load i32, ptr %37, align 4, !tbaa !30
  %39 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %29, i64 noundef %indvars.iv66) #5
  %40 = load i32, ptr %39, align 4, !tbaa !30
  %.not4953 = icmp sgt i32 %38, %40
  br i1 %.not4953, label %._crit_edge58, label %.lr.ph57

.lr.ph57:                                         ; preds = %36
  %41 = mul nsw i64 %indvars.iv66, %35
  %invariant.gep = getelementptr double, ptr %24, i64 %41
  br label %45

._crit_edge58:                                    ; preds = %._crit_edge, %36
  %indvars.iv.next67 = add nuw nsw i64 %indvars.iv66, 1
  %42 = load i32, ptr %25, align 4, !tbaa !29
  %43 = sext i32 %42 to i64
  %44 = icmp slt i64 %indvars.iv.next67, %43
  br i1 %44, label %36, label %.loopexit, !llvm.loop !31

45:                                               ; preds = %.lr.ph57, %._crit_edge
  %indvars.iv63 = phi i64 [ 0, %.lr.ph57 ], [ %indvars.iv.next64, %._crit_edge ]
  %.04554 = phi i32 [ %38, %.lr.ph57 ], [ %52, %._crit_edge ]
  %46 = load i32, ptr %30, align 4, !tbaa !33
  %47 = add nsw i32 %46, 1
  %.neg = sdiv i32 %47, -2
  %48 = add i32 %.neg, %.04554
  %49 = call noundef i32 @_ZN4sptk16DeltaCalculation15GetPointerIndexEi(ptr noundef nonnull align 8 dereferenceable(160) %0, i32 noundef %48)
  %50 = load i32, ptr %11, align 8, !tbaa !25
  %.not5051 = icmp slt i32 %50, 0
  br i1 %.not5051, label %._crit_edge, label %.lr.ph

.lr.ph:                                           ; preds = %45
  %51 = sext i32 %49 to i64
  br label %55

._crit_edge:                                      ; preds = %76, %45
  %52 = add nsw i32 %.04554, 1
  %indvars.iv.next64 = add nuw nsw i64 %indvars.iv63, 1
  %53 = call noundef nonnull align 4 dereferenceable(4) ptr @_ZNSt6vectorIiSaIiEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %29, i64 noundef %indvars.iv66) #5
  %54 = load i32, ptr %53, align 4, !tbaa !30
  %.not49.not = icmp slt i32 %.04554, %54
  br i1 %.not49.not, label %45, label %._crit_edge58, !llvm.loop !34

55:                                               ; preds = %.lr.ph, %76
  %indvars.iv = phi i64 [ 0, %.lr.ph ], [ %indvars.iv.next, %76 ]
  %56 = load i8, ptr %31, align 8, !tbaa !35, !range !23, !noundef !24
  %57 = trunc nuw i8 %56 to i1
  %gep = getelementptr double, ptr %invariant.gep, i64 %indvars.iv
  br i1 %57, label %58, label %.sink.split.sink.split

58:                                               ; preds = %55
  %59 = load double, ptr %34, align 8, !tbaa !36
  %60 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_IdSaIdEESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %33, i64 noundef %51) #5
  %61 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %60, i64 noundef %indvars.iv) #5
  %62 = load double, ptr %61, align 8, !tbaa !28
  %63 = fcmp oeq double %59, %62
  %64 = load double, ptr %34, align 8, !tbaa !36
  br i1 %63, label %.sink.split, label %65

65:                                               ; preds = %58
  %66 = load double, ptr %gep, align 8, !tbaa !28
  %67 = fcmp une double %64, %66
  br i1 %67, label %.sink.split.sink.split, label %76

.sink.split.sink.split:                           ; preds = %55, %65
  %68 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNKSt6vectorIS_IdSaIdEESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %32, i64 noundef %indvars.iv66) #5
  %69 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %68, i64 noundef %indvars.iv63) #5
  %70 = load double, ptr %69, align 8, !tbaa !28
  %71 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt6vectorIS_IdSaIdEESaIS1_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %33, i64 noundef %51) #5
  %72 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIdSaIdEEixEm(ptr noundef nonnull align 8 dereferenceable(24) %71, i64 noundef %indvars.iv) #5
  %73 = load double, ptr %72, align 8, !tbaa !28
  %74 = load double, ptr %gep, align 8, !tbaa !28
  %75 = call double @llvm.fmuladd.f64(double %70, double %73, double %74)
  br label %.sink.split

.sink.split:                                      ; preds = %.sink.split.sink.split, %58
  %.sink = phi double [ %64, %58 ], [ %75, %.sink.split.sink.split ]
  store double %.sink, ptr %gep, align 8, !tbaa !28
  br label %76

76:                                               ; preds = %.sink.split, %65
  %indvars.iv.next = add nuw nsw i64 %indvars.iv, 1
  %77 = load i32, ptr %11, align 8, !tbaa !25
  %78 = sext i32 %77 to i64
  %.not50.not = icmp slt i64 %indvars.iv, %78
  br i1 %.not50.not, label %55, label %._crit_edge, !llvm.loop !37

.loopexit:                                        ; preds = %._crit_edge58, %21, %8, %2
  %.0 = phi i1 [ false, %2 ], [ false, %8 ], [ true, %21 ], [ true, %._crit_edge58 ]
  ret i1 %.0
}

; Function Attrs: inlinehint mustprogress uwtable
declare dso_local void @_ZSt4fillIN9__gnu_cxx17__normal_iteratorIPdSt6vectorIdSaIdEEEEdEvT_S7_RKT0_(ptr, ptr, ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #3

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

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

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef i32 @_ZN4sptk16DeltaCalculation15GetPointerIndexEi(ptr noundef nonnull align 8 dereferenceable(160), i32 noundef) local_unnamed_addr #1 align 2

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

; Function Attrs: mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare double @llvm.fmuladd.f64(double, double, double) #4

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { 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 #3 = { inlinehint mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { mustprogress nocallback nofree nosync nounwind speculatable willreturn memory(none) }
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, !16, i64 64}
!6 = !{!"_ZTSN4sptk16DeltaCalculationE", !7, i64 0, !8, i64 8, !8, i64 12, !11, i64 16, !15, i64 40, !16, i64 48, !17, i64 56, !16, i64 64, !8, i64 68, !18, i64 72, !18, i64 96, !22, i64 120}
!7 = !{!"_ZTSN4sptk20InputSourceInterfaceE"}
!8 = !{!"int", !9, i64 0}
!9 = !{!"omnipotent char", !10, i64 0}
!10 = !{!"Simple C++ TBAA"}
!11 = !{!"_ZTSSt6vectorIS_IdSaIdEESaIS1_EE", !12, i64 0}
!12 = !{!"_ZTSSt12_Vector_baseISt6vectorIdSaIdEESaIS2_EE", !13, i64 0}
!13 = !{!"_ZTSNSt12_Vector_baseISt6vectorIdSaIdEESaIS2_EE12_Vector_implE", !14, i64 0}
!14 = !{!"_ZTSNSt12_Vector_baseISt6vectorIdSaIdEESaIS2_EE17_Vector_impl_dataE", !15, i64 0, !15, i64 8, !15, i64 16}
!15 = !{!"any pointer", !9, i64 0}
!16 = !{!"bool", !9, i64 0}
!17 = !{!"double", !9, i64 0}
!18 = !{!"_ZTSSt6vectorIiSaIiEE", !19, i64 0}
!19 = !{!"_ZTSSt12_Vector_baseIiSaIiEE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE12_Vector_implE", !21, i64 0}
!21 = !{!"_ZTSNSt12_Vector_baseIiSaIiEE17_Vector_impl_dataE", !15, i64 0, !15, i64 8, !15, i64 16}
!22 = !{!"_ZTSN4sptk16DeltaCalculation6BufferE", !11, i64 0, !8, i64 24, !8, i64 28, !16, i64 32}
!23 = !{i8 0, i8 2}
!24 = !{}
!25 = !{!6, !8, i64 8}
!26 = !{!27, !27, i64 0}
!27 = !{!"vtable pointer", !10, i64 0}
!28 = !{!17, !17, i64 0}
!29 = !{!6, !8, i64 12}
!30 = !{!8, !8, i64 0}
!31 = distinct !{!31, !32}
!32 = !{!"llvm.loop.mustprogress"}
!33 = !{!6, !8, i64 68}
!34 = distinct !{!34, !32}
!35 = !{!6, !16, i64 48}
!36 = !{!6, !17, i64 56}
!37 = distinct !{!37, !32}


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