; LLVM IR from interpretml/interpret :: shared/libebm/Tensor.ll (ZN14NAMESPACE_MAIN6Tensor3AddERKS0_)

; 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.NAMESPACE_MAIN::Tensor::DimensionInfoStack" = type { ptr, ptr, i64 }
%"class.NAMESPACE_MAIN::Tensor" = type { i64, i64, i64, i64, ptr, i8, [1 x %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo"] }
%"struct.NAMESPACE_MAIN::Tensor::DimensionInfo" = type { i64, ptr, i64 }

@.str = external hidden unnamed_addr constant [80 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.44 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.45 = external hidden unnamed_addr constant [45 x i8], align 1
@.str.46 = external hidden unnamed_addr constant [48 x i8], align 1
@__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_ = external hidden unnamed_addr constant [4 x i8], align 1
@__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_ = external hidden unnamed_addr constant [53 x i8], align 1
@.str.55 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.56 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.57 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.58 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.59 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.60 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.61 = external hidden unnamed_addr constant [62 x i8], align 1
@.str.62 = external hidden unnamed_addr constant [65 x i8], align 1
@.str.63 = external hidden unnamed_addr constant [45 x i8], align 1
@.str.64 = external hidden unnamed_addr constant [48 x i8], align 1
@.str.65 = external hidden unnamed_addr constant [45 x i8], align 1
@.str.66 = external hidden unnamed_addr constant [48 x i8], align 1
@.str.67 = external hidden unnamed_addr constant [49 x i8], align 1
@.str.68 = external hidden unnamed_addr constant [52 x i8], align 1
@.str.69 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.70 = external hidden unnamed_addr constant [40 x i8], align 1
@.str.71 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.72 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.73 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.74 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.75 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.76 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.77 = external hidden unnamed_addr constant [115 x i8], align 1
@.str.78 = external hidden unnamed_addr constant [118 x i8], align 1
@.str.79 = external hidden unnamed_addr constant [36 x i8], align 1
@.str.80 = external hidden unnamed_addr constant [39 x i8], align 1

declare void @LogAssertFailure(i64 noundef, ptr noundef, ptr noundef, ptr noundef) #0

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef zeroext i1 @_ZN14NAMESPACE_MAINL15IsMultiplyErrorImEEbT_S1_(i64 noundef, i64 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: nocallback nofree nosync nounwind willreturn memory(none)
declare i64 @llvm.expect.i64(i64, i64) #4

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZN14NAMESPACE_MAIN6Tensor13GetDimensionsEv(ptr noundef nonnull align 8 dereferenceable(72)) #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZN14NAMESPACE_MAIN6Tensor14SetCountSlicesEmm(ptr noundef nonnull align 8 dereferenceable(72), i64 noundef, i64 noundef) #5 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZN14NAMESPACE_MAIN6Tensor25EnsureTensorScoreCapacityEm(ptr noundef nonnull align 8 dereferenceable(72), i64 noundef) #5 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNK14NAMESPACE_MAIN6Tensor13GetDimensionsEv(ptr noundef nonnull align 8 dereferenceable(72)) #2 align 2

; Function Attrs: nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #6

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN14NAMESPACE_MAIN6Tensor3AddERKS0_(ptr noundef nonnull align 8 dereferenceable(72) %0, ptr noundef nonnull align 8 dereferenceable(72) %1) #5 align 2 {
  %3 = alloca i32, align 4
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i32, align 4
  %7 = alloca [30 x %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack"], align 16
  %8 = alloca ptr, align 8
  %9 = alloca ptr, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca ptr, align 8
  %13 = alloca ptr, align 8
  %14 = alloca ptr, align 8
  %15 = alloca ptr, align 8
  %16 = alloca i64, align 8
  %17 = alloca i64, align 8
  %18 = alloca i64, align 8
  %19 = alloca i64, align 8
  %20 = alloca ptr, align 8
  %21 = alloca i64, align 8
  %22 = alloca ptr, align 8
  %23 = alloca ptr, align 8
  %24 = alloca ptr, align 8
  %25 = alloca i64, align 8
  %26 = alloca i64, align 8
  %27 = alloca i64, align 8
  %28 = alloca ptr, align 8
  %29 = alloca ptr, align 8
  %30 = alloca ptr, align 8
  %31 = alloca ptr, align 8
  %32 = alloca ptr, align 8
  %33 = alloca ptr, align 8
  %34 = alloca ptr, align 8
  %35 = alloca ptr, align 8
  %36 = alloca ptr, align 8
  %37 = alloca ptr, align 8
  %38 = alloca ptr, align 8
  %39 = alloca ptr, align 8
  %40 = alloca i64, align 8
  %41 = alloca i64, align 8
  %42 = alloca ptr, align 8
  %43 = alloca ptr, align 8
  %44 = alloca ptr, align 8
  %45 = alloca ptr, align 8
  %46 = alloca ptr, align 8
  %47 = alloca ptr, align 8
  %48 = alloca i64, align 8
  %49 = alloca i64, align 8
  %50 = alloca i8, align 1
  %51 = alloca i8, align 1
  %52 = alloca i64, align 8
  %53 = alloca i64, align 8
  %54 = alloca ptr, align 8
  %55 = alloca ptr, align 8
  %56 = alloca ptr, align 8
  %57 = alloca i64, align 8
  %58 = alloca i64, align 8
  %59 = alloca i64, align 8
  %60 = alloca ptr, align 8
  %61 = alloca ptr, align 8
  %62 = alloca ptr, align 8
  %63 = alloca ptr, align 8
  %64 = alloca ptr, align 8
  %65 = alloca i64, align 8
  %66 = alloca i64, align 8
  %67 = alloca i64, align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  %68 = load ptr, ptr %4, align 8
  call void @llvm.lifetime.start.p0(i64 4, ptr %6) #7
  call void @llvm.lifetime.start.p0(i64 720, ptr %7) #7
  %69 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 3
  %70 = load i64, ptr %69, align 8, !tbaa !9
  %71 = load ptr, ptr %5, align 8, !tbaa !5
  %72 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %71, i32 0, i32 3
  %73 = load i64, ptr %72, align 8, !tbaa !9
  %74 = icmp eq i64 %70, %73
  br i1 %74, label %77, label %75

75:                                               ; preds = %2
  call void @LogAssertFailure(i64 noundef 466, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.11)
  call void @__assert_fail(ptr noundef @.str.12, ptr noundef @.str, i32 noundef 466, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

76:                                               ; No predecessors!
  br label %77

77:                                               ; preds = %76, %2
  %78 = phi i1 [ true, %2 ], [ false, %76 ]
  %79 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 3
  %80 = load i64, ptr %79, align 8, !tbaa !9
  %81 = icmp eq i64 0, %80
  br i1 %81, label %82, label %123

82:                                               ; preds = %77
  %83 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 0
  %84 = load i64, ptr %83, align 8, !tbaa !13
  %85 = icmp ule i64 1, %84
  br i1 %85, label %88, label %86

86:                                               ; preds = %82
  call void @LogAssertFailure(i64 noundef 469, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.55)
  call void @__assert_fail(ptr noundef @.str.56, ptr noundef @.str, i32 noundef 469, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

87:                                               ; No predecessors!
  br label %88

88:                                               ; preds = %87, %82
  %89 = phi i1 [ true, %82 ], [ false, %87 ]
  %90 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 4
  %91 = load ptr, ptr %90, align 8, !tbaa !14
  %92 = icmp ne ptr null, %91
  br i1 %92, label %95, label %93

93:                                               ; preds = %88
  call void @LogAssertFailure(i64 noundef 470, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.57)
  call void @__assert_fail(ptr noundef @.str.58, ptr noundef @.str, i32 noundef 470, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

94:                                               ; No predecessors!
  br label %95

95:                                               ; preds = %94, %88
  %96 = phi i1 [ true, %88 ], [ false, %94 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr %8) #7
  %97 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 4
  %98 = load ptr, ptr %97, align 8, !tbaa !14
  %99 = getelementptr inbounds double, ptr %98, i64 0
  store ptr %99, ptr %8, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #7
  %100 = load ptr, ptr %5, align 8, !tbaa !5
  %101 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %100, i32 0, i32 4
  %102 = load ptr, ptr %101, align 8, !tbaa !14
  %103 = getelementptr inbounds double, ptr %102, i64 0
  store ptr %103, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %10) #7
  %104 = load ptr, ptr %8, align 8, !tbaa !5
  %105 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 1
  %106 = load i64, ptr %105, align 8, !tbaa !15
  %107 = getelementptr inbounds double, ptr %104, i64 %106
  store ptr %107, ptr %10, align 8, !tbaa !5
  br label %108

108:                                              ; preds = %118, %95
  %109 = load ptr, ptr %9, align 8, !tbaa !5
  %110 = load double, ptr %109, align 8, !tbaa !16
  %111 = load ptr, ptr %8, align 8, !tbaa !5
  %112 = load double, ptr %111, align 8, !tbaa !16
  %113 = fadd double %112, %110
  store double %113, ptr %111, align 8, !tbaa !16
  %114 = load ptr, ptr %8, align 8, !tbaa !5
  %115 = getelementptr inbounds double, ptr %114, i32 1
  store ptr %115, ptr %8, align 8, !tbaa !5
  %116 = load ptr, ptr %9, align 8, !tbaa !5
  %117 = getelementptr inbounds double, ptr %116, i32 1
  store ptr %117, ptr %9, align 8, !tbaa !5
  br label %118

118:                                              ; preds = %108
  %119 = load ptr, ptr %10, align 8, !tbaa !5
  %120 = load ptr, ptr %8, align 8, !tbaa !5
  %121 = icmp ne ptr %119, %120
  br i1 %121, label %108, label %122, !llvm.loop !18

122:                                              ; preds = %118
  store i32 0, ptr %3, align 4
  store i32 1, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %10) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %8) #7
  br label %785

123:                                              ; preds = %77
  %124 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 5
  %125 = load i8, ptr %124, align 8, !tbaa !20, !range !21, !noundef !22
  %126 = trunc i8 %125 to i1
  br i1 %126, label %127, label %128

127:                                              ; preds = %123
  br label %128

128:                                              ; preds = %127, %123
  %129 = load ptr, ptr %5, align 8, !tbaa !5
  %130 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %129, i32 0, i32 5
  %131 = load i8, ptr %130, align 8, !tbaa !20, !range !21, !noundef !22
  %132 = trunc i8 %131 to i1
  br i1 %132, label %133, label %134

133:                                              ; preds = %128
  br label %134

134:                                              ; preds = %133, %128
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #7
  %135 = call noundef ptr @_ZN14NAMESPACE_MAIN6Tensor13GetDimensionsEv(ptr noundef nonnull align 8 dereferenceable(72) %68)
  store ptr %135, ptr %12, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #7
  %136 = load ptr, ptr %5, align 8, !tbaa !5
  %137 = call noundef ptr @_ZNK14NAMESPACE_MAIN6Tensor13GetDimensionsEv(ptr noundef nonnull align 8 dereferenceable(72) %136)
  store ptr %137, ptr %13, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #7
  %138 = getelementptr inbounds [30 x %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack"], ptr %7, i64 0, i64 0
  store ptr %138, ptr %14, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #7
  %139 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 3
  %140 = load i64, ptr %139, align 8, !tbaa !9
  %141 = getelementptr inbounds [30 x %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack"], ptr %7, i64 0, i64 %140
  store ptr %141, ptr %15, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #7
  %142 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 1
  %143 = load i64, ptr %142, align 8, !tbaa !15
  store i64 %143, ptr %16, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #7
  %144 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 1
  %145 = load i64, ptr %144, align 8, !tbaa !15
  store i64 %145, ptr %17, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #7
  %146 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 1
  %147 = load i64, ptr %146, align 8, !tbaa !15
  store i64 %147, ptr %18, align 8, !tbaa !23
  %148 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 3
  %149 = load i64, ptr %148, align 8, !tbaa !9
  %150 = icmp ule i64 1, %149
  br i1 %150, label %153, label %151

151:                                              ; preds = %134
  call void @LogAssertFailure(i64 noundef 502, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.59)
  call void @__assert_fail(ptr noundef @.str.60, ptr noundef @.str, i32 noundef 502, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

152:                                              ; No predecessors!
  br label %153

153:                                              ; preds = %152, %134
  %154 = phi i1 [ true, %134 ], [ false, %152 ]
  br label %155

155:                                              ; preds = %276, %153
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #7
  %156 = load ptr, ptr %12, align 8, !tbaa !5
  %157 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %156, i32 0, i32 0
  %158 = load i64, ptr %157, align 8, !tbaa !24
  store i64 %158, ptr %19, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #7
  %159 = load ptr, ptr %12, align 8, !tbaa !5
  %160 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %159, i32 0, i32 1
  %161 = load ptr, ptr %160, align 8, !tbaa !26
  store ptr %161, ptr %20, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %21) #7
  %162 = load ptr, ptr %13, align 8, !tbaa !5
  %163 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %162, i32 0, i32 0
  %164 = load i64, ptr %163, align 8, !tbaa !24
  store i64 %164, ptr %21, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #7
  %165 = load ptr, ptr %13, align 8, !tbaa !5
  %166 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %165, i32 0, i32 1
  %167 = load ptr, ptr %166, align 8, !tbaa !26
  store ptr %167, ptr %22, align 8, !tbaa !5
  %168 = load i64, ptr %19, align 8, !tbaa !23
  %169 = load i64, ptr %16, align 8, !tbaa !23
  %170 = mul i64 %169, %168
  store i64 %170, ptr %16, align 8, !tbaa !23
  %171 = load i64, ptr %21, align 8, !tbaa !23
  %172 = load i64, ptr %17, align 8, !tbaa !23
  %173 = mul i64 %172, %171
  store i64 %173, ptr %17, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %23) #7
  %174 = load ptr, ptr %20, align 8, !tbaa !5
  %175 = load i64, ptr %19, align 8, !tbaa !23
  %176 = sub i64 %175, 1
  %177 = getelementptr inbounds i64, ptr %174, i64 %176
  store ptr %177, ptr %23, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %24) #7
  %178 = load ptr, ptr %22, align 8, !tbaa !5
  %179 = load i64, ptr %21, align 8, !tbaa !23
  %180 = sub i64 %179, 1
  %181 = getelementptr inbounds i64, ptr %178, i64 %180
  store ptr %181, ptr %24, align 8, !tbaa !5
  %182 = load ptr, ptr %23, align 8, !tbaa !5
  %183 = load ptr, ptr %14, align 8, !tbaa !5
  %184 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %183, i32 0, i32 0
  store ptr %182, ptr %184, align 8, !tbaa !27
  %185 = load ptr, ptr %24, align 8, !tbaa !5
  %186 = load ptr, ptr %14, align 8, !tbaa !5
  %187 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %186, i32 0, i32 1
  store ptr %185, ptr %187, align 8, !tbaa !29
  call void @llvm.lifetime.start.p0(i64 8, ptr %25) #7
  store i64 1, ptr %25, align 8, !tbaa !23
  br label %188

188:                                              ; preds = %254, %155
  br label %189

189:                                              ; preds = %188
  %190 = load ptr, ptr %24, align 8, !tbaa !5
  %191 = load ptr, ptr %22, align 8, !tbaa !5
  %192 = icmp eq ptr %190, %191
  %193 = xor i1 %192, true
  %194 = xor i1 %193, true
  %195 = zext i1 %194 to i64
  %196 = call i64 @llvm.expect.i64(i64 %195, i64 0)
  %197 = icmp ne i64 %196, 0
  br i1 %197, label %198, label %207

198:                                              ; preds = %189
  %199 = load ptr, ptr %23, align 8, !tbaa !5
  %200 = load ptr, ptr %20, align 8, !tbaa !5
  %201 = ptrtoint ptr %199 to i64
  %202 = ptrtoint ptr %200 to i64
  %203 = sub i64 %201, %202
  %204 = sdiv exact i64 %203, 8
  %205 = load i64, ptr %25, align 8, !tbaa !23
  %206 = add i64 %205, %204
  store i64 %206, ptr %25, align 8, !tbaa !23
  br label %256

207:                                              ; preds = %189
  %208 = load ptr, ptr %23, align 8, !tbaa !5
  %209 = load ptr, ptr %20, align 8, !tbaa !5
  %210 = icmp eq ptr %208, %209
  %211 = xor i1 %210, true
  %212 = xor i1 %211, true
  %213 = zext i1 %212 to i64
  %214 = call i64 @llvm.expect.i64(i64 %213, i64 0)
  %215 = icmp ne i64 %214, 0
  br i1 %215, label %216, label %225

216:                                              ; preds = %207
  %217 = load ptr, ptr %24, align 8, !tbaa !5
  %218 = load ptr, ptr %22, align 8, !tbaa !5
  %219 = ptrtoint ptr %217 to i64
  %220 = ptrtoint ptr %218 to i64
  %221 = sub i64 %219, %220
  %222 = sdiv exact i64 %221, 8
  %223 = load i64, ptr %25, align 8, !tbaa !23
  %224 = add i64 %223, %222
  store i64 %224, ptr %25, align 8, !tbaa !23
  br label %256

225:                                              ; preds = %207
  %226 = load i64, ptr %25, align 8, !tbaa !23
  %227 = add i64 %226, 1
  store i64 %227, ptr %25, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #7
  %228 = load ptr, ptr %20, align 8, !tbaa !5
  %229 = load i64, ptr %228, align 8, !tbaa !23
  store i64 %229, ptr %26, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %27) #7
  %230 = load ptr, ptr %22, align 8, !tbaa !5
  %231 = load i64, ptr %230, align 8, !tbaa !23
  store i64 %231, ptr %27, align 8, !tbaa !23
  %232 = load i64, ptr %26, align 8, !tbaa !23
  %233 = load i64, ptr %27, align 8, !tbaa !23
  %234 = icmp ule i64 %232, %233
  %235 = xor i1 %234, true
  %236 = xor i1 %235, true
  br i1 %236, label %237, label %240, !unpredictable !22

237:                                              ; preds = %225
  %238 = load ptr, ptr %20, align 8, !tbaa !5
  %239 = getelementptr inbounds i64, ptr %238, i64 1
  br label %242

240:                                              ; preds = %225
  %241 = load ptr, ptr %20, align 8, !tbaa !5
  br label %242

242:                                              ; preds = %240, %237
  %243 = phi ptr [ %239, %237 ], [ %241, %240 ]
  store ptr %243, ptr %20, align 8, !tbaa !5
  %244 = load i64, ptr %27, align 8, !tbaa !23
  %245 = load i64, ptr %26, align 8, !tbaa !23
  %246 = icmp ule i64 %244, %245
  %247 = xor i1 %246, true
  %248 = xor i1 %247, true
  br i1 %248, label %249, label %252, !unpredictable !22

249:                                              ; preds = %242
  %250 = load ptr, ptr %22, align 8, !tbaa !5
  %251 = getelementptr inbounds i64, ptr %250, i64 1
  br label %254

252:                                              ; preds = %242
  %253 = load ptr, ptr %22, align 8, !tbaa !5
  br label %254

254:                                              ; preds = %252, %249
  %255 = phi ptr [ %251, %249 ], [ %253, %252 ]
  store ptr %255, ptr %22, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %27) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #7
  br label %188, !llvm.loop !30

256:                                              ; preds = %216, %198
  %257 = load i64, ptr %25, align 8, !tbaa !23
  %258 = load ptr, ptr %14, align 8, !tbaa !5
  %259 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %258, i32 0, i32 2
  store i64 %257, ptr %259, align 8, !tbaa !31
  %260 = load i64, ptr %18, align 8, !tbaa !23
  %261 = load i64, ptr %25, align 8, !tbaa !23
  %262 = call noundef zeroext i1 @_ZN14NAMESPACE_MAINL15IsMultiplyErrorImEEbT_S1_(i64 noundef %260, i64 noundef %261) #7
  br i1 %262, label %263, label %265

263:                                              ; preds = %256
  call void @LogAssertFailure(i64 noundef 546, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.61)
  call void @__assert_fail(ptr noundef @.str.62, ptr noundef @.str, i32 noundef 546, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

264:                                              ; No predecessors!
  br label %265

265:                                              ; preds = %264, %256
  %266 = phi i1 [ true, %256 ], [ false, %264 ]
  %267 = load i64, ptr %25, align 8, !tbaa !23
  %268 = load i64, ptr %18, align 8, !tbaa !23
  %269 = mul i64 %268, %267
  store i64 %269, ptr %18, align 8, !tbaa !23
  %270 = load ptr, ptr %12, align 8, !tbaa !5
  %271 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %270, i32 1
  store ptr %271, ptr %12, align 8, !tbaa !5
  %272 = load ptr, ptr %13, align 8, !tbaa !5
  %273 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %272, i32 1
  store ptr %273, ptr %13, align 8, !tbaa !5
  %274 = load ptr, ptr %14, align 8, !tbaa !5
  %275 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %274, i32 1
  store ptr %275, ptr %14, align 8, !tbaa !5
  call void @llvm.lifetime.end.p0(i64 8, ptr %25) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %24) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %23) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %21) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #7
  br label %276

276:                                              ; preds = %265
  %277 = load ptr, ptr %15, align 8, !tbaa !5
  %278 = load ptr, ptr %14, align 8, !tbaa !5
  %279 = icmp ne ptr %277, %278
  br i1 %279, label %155, label %280, !llvm.loop !32

280:                                              ; preds = %276
  %281 = load i64, ptr %18, align 8, !tbaa !23
  %282 = call noundef i32 @_ZN14NAMESPACE_MAIN6Tensor25EnsureTensorScoreCapacityEm(ptr noundef nonnull align 8 dereferenceable(72) %68, i64 noundef %281)
  store i32 %282, ptr %6, align 4, !tbaa !33
  %283 = load i32, ptr %6, align 4, !tbaa !33
  %284 = icmp ne i32 0, %283
  %285 = xor i1 %284, true
  %286 = xor i1 %285, true
  %287 = zext i1 %286 to i64
  %288 = call i64 @llvm.expect.i64(i64 %287, i64 0)
  %289 = icmp ne i64 %288, 0
  br i1 %289, label %290, label %292

290:                                              ; preds = %280
  %291 = load i32, ptr %6, align 4, !tbaa !33
  store i32 %291, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %784

292:                                              ; preds = %280
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #7
  %293 = load ptr, ptr %5, align 8, !tbaa !5
  %294 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %293, i32 0, i32 4
  %295 = load ptr, ptr %294, align 8, !tbaa !14
  %296 = load i64, ptr %17, align 8, !tbaa !23
  %297 = getelementptr inbounds double, ptr %295, i64 %296
  store ptr %297, ptr %28, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #7
  %298 = load ptr, ptr %5, align 8, !tbaa !5
  %299 = call noundef ptr @_ZNK14NAMESPACE_MAIN6Tensor13GetDimensionsEv(ptr noundef nonnull align 8 dereferenceable(72) %298)
  store ptr %299, ptr %29, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #7
  %300 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 4
  %301 = load ptr, ptr %300, align 8, !tbaa !14
  store ptr %301, ptr %30, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %31) #7
  %302 = call noundef ptr @_ZN14NAMESPACE_MAIN6Tensor13GetDimensionsEv(ptr noundef nonnull align 8 dereferenceable(72) %68)
  store ptr %302, ptr %31, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #7
  %303 = load ptr, ptr %30, align 8, !tbaa !5
  %304 = load i64, ptr %16, align 8, !tbaa !23
  %305 = getelementptr inbounds double, ptr %303, i64 %304
  store ptr %305, ptr %32, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %33) #7
  %306 = load ptr, ptr %30, align 8, !tbaa !5
  %307 = load i64, ptr %18, align 8, !tbaa !23
  %308 = getelementptr inbounds double, ptr %306, i64 %307
  store ptr %308, ptr %33, align 8, !tbaa !5
  br label %309

309:                                              ; preds = %529, %292
  br label %310

310:                                              ; preds = %309
  call void @llvm.lifetime.start.p0(i64 8, ptr %34) #7
  %311 = load ptr, ptr %32, align 8, !tbaa !5
  store ptr %311, ptr %34, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %35) #7
  %312 = load ptr, ptr %28, align 8, !tbaa !5
  store ptr %312, ptr %35, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %36) #7
  %313 = load ptr, ptr %33, align 8, !tbaa !5
  %314 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 1
  %315 = load i64, ptr %314, align 8, !tbaa !15
  %316 = sub i64 0, %315
  %317 = getelementptr inbounds double, ptr %313, i64 %316
  store ptr %317, ptr %36, align 8, !tbaa !5
  br label %318

318:                                              ; preds = %331, %310
  %319 = load ptr, ptr %34, align 8, !tbaa !5
  %320 = getelementptr inbounds double, ptr %319, i32 -1
  store ptr %320, ptr %34, align 8, !tbaa !5
  %321 = load ptr, ptr %35, align 8, !tbaa !5
  %322 = getelementptr inbounds double, ptr %321, i32 -1
  store ptr %322, ptr %35, align 8, !tbaa !5
  %323 = load ptr, ptr %33, align 8, !tbaa !5
  %324 = getelementptr inbounds double, ptr %323, i32 -1
  store ptr %324, ptr %33, align 8, !tbaa !5
  %325 = load ptr, ptr %34, align 8, !tbaa !5
  %326 = load double, ptr %325, align 8, !tbaa !16
  %327 = load ptr, ptr %35, align 8, !tbaa !5
  %328 = load double, ptr %327, align 8, !tbaa !16
  %329 = fadd double %326, %328
  %330 = load ptr, ptr %33, align 8, !tbaa !5
  store double %329, ptr %330, align 8, !tbaa !16
  br label %331

331:                                              ; preds = %318
  %332 = load ptr, ptr %36, align 8, !tbaa !5
  %333 = load ptr, ptr %33, align 8, !tbaa !5
  %334 = icmp ne ptr %332, %333
  br i1 %334, label %318, label %335, !llvm.loop !35

335:                                              ; preds = %331
  %336 = load ptr, ptr %30, align 8, !tbaa !5
  %337 = load ptr, ptr %33, align 8, !tbaa !5
  %338 = icmp eq ptr %336, %337
  %339 = xor i1 %338, true
  %340 = xor i1 %339, true
  %341 = zext i1 %340 to i64
  %342 = call i64 @llvm.expect.i64(i64 %341, i64 0)
  %343 = icmp ne i64 %342, 0
  br i1 %343, label %344, label %345

344:                                              ; preds = %335
  store i32 9, ptr %11, align 4
  br label %527

345:                                              ; preds = %335
  call void @llvm.lifetime.start.p0(i64 8, ptr %37) #7
  %346 = getelementptr inbounds [30 x %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack"], ptr %7, i64 0, i64 0
  store ptr %346, ptr %37, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %38) #7
  %347 = load ptr, ptr %31, align 8, !tbaa !5
  store ptr %347, ptr %38, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %39) #7
  %348 = load ptr, ptr %29, align 8, !tbaa !5
  store ptr %348, ptr %39, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %40) #7
  %349 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 1
  %350 = load i64, ptr %349, align 8, !tbaa !15
  store i64 %350, ptr %40, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %41) #7
  %351 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 1
  %352 = load i64, ptr %351, align 8, !tbaa !15
  store i64 %352, ptr %41, align 8, !tbaa !23
  br label %353

353:                                              ; preds = %524, %345
  br label %354

354:                                              ; preds = %353
  call void @llvm.lifetime.start.p0(i64 8, ptr %42) #7
  %355 = load ptr, ptr %37, align 8, !tbaa !5
  %356 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %355, i32 0, i32 0
  %357 = load ptr, ptr %356, align 8, !tbaa !27
  store ptr %357, ptr %42, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %43) #7
  %358 = load ptr, ptr %37, align 8, !tbaa !5
  %359 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %358, i32 0, i32 1
  %360 = load ptr, ptr %359, align 8, !tbaa !29
  store ptr %360, ptr %43, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %44) #7
  %361 = load ptr, ptr %38, align 8, !tbaa !5
  %362 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %361, i32 0, i32 1
  %363 = load ptr, ptr %362, align 8, !tbaa !26
  store ptr %363, ptr %44, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %45) #7
  %364 = load ptr, ptr %39, align 8, !tbaa !5
  %365 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %364, i32 0, i32 1
  %366 = load ptr, ptr %365, align 8, !tbaa !26
  store ptr %366, ptr %45, align 8, !tbaa !5
  %367 = load ptr, ptr %44, align 8, !tbaa !5
  %368 = load ptr, ptr %42, align 8, !tbaa !5
  %369 = icmp ult ptr %367, %368
  %370 = xor i1 %369, true
  %371 = xor i1 %370, true
  br i1 %371, label %372, label %450, !unpredictable !22

372:                                              ; preds = %354
  %373 = load ptr, ptr %45, align 8, !tbaa !5
  %374 = load ptr, ptr %43, align 8, !tbaa !5
  %375 = icmp ult ptr %373, %374
  %376 = xor i1 %375, true
  %377 = xor i1 %376, true
  br i1 %377, label %378, label %441, !unpredictable !22

378:                                              ; preds = %372
  call void @llvm.lifetime.start.p0(i64 8, ptr %46) #7
  %379 = load ptr, ptr %42, align 8, !tbaa !5
  %380 = getelementptr inbounds i64, ptr %379, i64 -1
  store ptr %380, ptr %46, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %47) #7
  %381 = load ptr, ptr %43, align 8, !tbaa !5
  %382 = getelementptr inbounds i64, ptr %381, i64 -1
  store ptr %382, ptr %47, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %48) #7
  %383 = load ptr, ptr %46, align 8, !tbaa !5
  %384 = load i64, ptr %383, align 8, !tbaa !23
  store i64 %384, ptr %48, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %49) #7
  %385 = load ptr, ptr %47, align 8, !tbaa !5
  %386 = load i64, ptr %385, align 8, !tbaa !23
  store i64 %386, ptr %49, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 1, ptr %50) #7
  %387 = load i64, ptr %49, align 8, !tbaa !23
  %388 = load i64, ptr %48, align 8, !tbaa !23
  %389 = icmp ule i64 %387, %388
  %390 = xor i1 %389, true
  %391 = xor i1 %390, true
  %392 = zext i1 %391 to i8
  store i8 %392, ptr %50, align 1, !tbaa !36
  %393 = load i8, ptr %50, align 1, !tbaa !36, !range !21, !noundef !22
  %394 = trunc i8 %393 to i1
  br i1 %394, label %395, label %397

395:                                              ; preds = %378
  %396 = load ptr, ptr %46, align 8, !tbaa !5
  br label %399

397:                                              ; preds = %378
  %398 = load ptr, ptr %42, align 8, !tbaa !5
  br label %399

399:                                              ; preds = %397, %395
  %400 = phi ptr [ %396, %395 ], [ %398, %397 ]
  %401 = load ptr, ptr %37, align 8, !tbaa !5
  %402 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %401, i32 0, i32 0
  store ptr %400, ptr %402, align 8, !tbaa !27
  %403 = load i8, ptr %50, align 1, !tbaa !36, !range !21, !noundef !22
  %404 = trunc i8 %403 to i1
  br i1 %404, label %405, label %410

405:                                              ; preds = %399
  %406 = load ptr, ptr %32, align 8, !tbaa !5
  %407 = load i64, ptr %40, align 8, !tbaa !23
  %408 = sub i64 0, %407
  %409 = getelementptr inbounds double, ptr %406, i64 %408
  br label %412

410:                                              ; preds = %399
  %411 = load ptr, ptr %32, align 8, !tbaa !5
  br label %412

412:                                              ; preds = %410, %405
  %413 = phi ptr [ %409, %405 ], [ %411, %410 ]
  store ptr %413, ptr %32, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 1, ptr %51) #7
  %414 = load i64, ptr %48, align 8, !tbaa !23
  %415 = load i64, ptr %49, align 8, !tbaa !23
  %416 = icmp ule i64 %414, %415
  %417 = xor i1 %416, true
  %418 = xor i1 %417, true
  %419 = zext i1 %418 to i8
  store i8 %419, ptr %51, align 1, !tbaa !36
  %420 = load i8, ptr %51, align 1, !tbaa !36, !range !21, !noundef !22
  %421 = trunc i8 %420 to i1
  br i1 %421, label %422, label %424

422:                                              ; preds = %412
  %423 = load ptr, ptr %47, align 8, !tbaa !5
  br label %426

424:                                              ; preds = %412
  %425 = load ptr, ptr %43, align 8, !tbaa !5
  br label %426

426:                                              ; preds = %424, %422
  %427 = phi ptr [ %423, %422 ], [ %425, %424 ]
  %428 = load ptr, ptr %37, align 8, !tbaa !5
  %429 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %428, i32 0, i32 1
  store ptr %427, ptr %429, align 8, !tbaa !29
  %430 = load i8, ptr %51, align 1, !tbaa !36, !range !21, !noundef !22
  %431 = trunc i8 %430 to i1
  br i1 %431, label %432, label %437

432:                                              ; preds = %426
  %433 = load ptr, ptr %28, align 8, !tbaa !5
  %434 = load i64, ptr %41, align 8, !tbaa !23
  %435 = sub i64 0, %434
  %436 = getelementptr inbounds double, ptr %433, i64 %435
  br label %439

437:                                              ; preds = %426
  %438 = load ptr, ptr %28, align 8, !tbaa !5
  br label %439

439:                                              ; preds = %437, %432
  %440 = phi ptr [ %436, %432 ], [ %438, %437 ]
  store ptr %440, ptr %28, align 8, !tbaa !5
  store i32 13, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 1, ptr %51) #7
  call void @llvm.lifetime.end.p0(i64 1, ptr %50) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %49) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %48) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %47) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %46) #7
  br label %524

441:                                              ; preds = %372
  %442 = load i64, ptr %40, align 8, !tbaa !23
  %443 = load ptr, ptr %32, align 8, !tbaa !5
  %444 = sub i64 0, %442
  %445 = getelementptr inbounds double, ptr %443, i64 %444
  store ptr %445, ptr %32, align 8, !tbaa !5
  %446 = load ptr, ptr %42, align 8, !tbaa !5
  %447 = getelementptr inbounds i64, ptr %446, i64 -1
  %448 = load ptr, ptr %37, align 8, !tbaa !5
  %449 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %448, i32 0, i32 0
  store ptr %447, ptr %449, align 8, !tbaa !27
  store i32 13, ptr %11, align 4
  br label %524

450:                                              ; preds = %354
  %451 = load ptr, ptr %45, align 8, !tbaa !5
  %452 = load ptr, ptr %43, align 8, !tbaa !5
  %453 = icmp ult ptr %451, %452
  %454 = xor i1 %453, true
  %455 = xor i1 %454, true
  br i1 %455, label %456, label %465, !unpredictable !22

456:                                              ; preds = %450
  %457 = load i64, ptr %41, align 8, !tbaa !23
  %458 = load ptr, ptr %28, align 8, !tbaa !5
  %459 = sub i64 0, %457
  %460 = getelementptr inbounds double, ptr %458, i64 %459
  store ptr %460, ptr %28, align 8, !tbaa !5
  %461 = load ptr, ptr %43, align 8, !tbaa !5
  %462 = getelementptr inbounds i64, ptr %461, i64 -1
  %463 = load ptr, ptr %37, align 8, !tbaa !5
  %464 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %463, i32 0, i32 1
  store ptr %462, ptr %464, align 8, !tbaa !29
  store i32 13, ptr %11, align 4
  br label %524

465:                                              ; preds = %450
  %466 = load i64, ptr %40, align 8, !tbaa !23
  %467 = load ptr, ptr %32, align 8, !tbaa !5
  %468 = sub i64 0, %466
  %469 = getelementptr inbounds double, ptr %467, i64 %468
  store ptr %469, ptr %32, align 8, !tbaa !5
  %470 = load i64, ptr %41, align 8, !tbaa !23
  %471 = load ptr, ptr %28, align 8, !tbaa !5
  %472 = sub i64 0, %470
  %473 = getelementptr inbounds double, ptr %471, i64 %472
  store ptr %473, ptr %28, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %52) #7
  %474 = load ptr, ptr %38, align 8, !tbaa !5
  %475 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %474, i32 0, i32 0
  %476 = load i64, ptr %475, align 8, !tbaa !24
  store i64 %476, ptr %52, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %53) #7
  %477 = load ptr, ptr %39, align 8, !tbaa !5
  %478 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %477, i32 0, i32 0
  %479 = load i64, ptr %478, align 8, !tbaa !24
  store i64 %479, ptr %53, align 8, !tbaa !23
  %480 = load i64, ptr %40, align 8, !tbaa !23
  %481 = load i64, ptr %52, align 8, !tbaa !23
  %482 = call noundef zeroext i1 @_ZN14NAMESPACE_MAINL15IsMultiplyErrorImEEbT_S1_(i64 noundef %480, i64 noundef %481) #7
  br i1 %482, label %483, label %485

483:                                              ; preds = %465
  call void @LogAssertFailure(i64 noundef 647, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.63)
  call void @__assert_fail(ptr noundef @.str.64, ptr noundef @.str, i32 noundef 647, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

484:                                              ; No predecessors!
  br label %485

485:                                              ; preds = %484, %465
  %486 = phi i1 [ true, %465 ], [ false, %484 ]
  %487 = load i64, ptr %52, align 8, !tbaa !23
  %488 = load i64, ptr %40, align 8, !tbaa !23
  %489 = mul i64 %488, %487
  store i64 %489, ptr %40, align 8, !tbaa !23
  %490 = load i64, ptr %41, align 8, !tbaa !23
  %491 = load i64, ptr %53, align 8, !tbaa !23
  %492 = call noundef zeroext i1 @_ZN14NAMESPACE_MAINL15IsMultiplyErrorImEEbT_S1_(i64 noundef %490, i64 noundef %491) #7
  br i1 %492, label %493, label %495

493:                                              ; preds = %485
  call void @LogAssertFailure(i64 noundef 650, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.65)
  call void @__assert_fail(ptr noundef @.str.66, ptr noundef @.str, i32 noundef 650, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

494:                                              ; No predecessors!
  br label %495

495:                                              ; preds = %494, %485
  %496 = phi i1 [ true, %485 ], [ false, %494 ]
  %497 = load i64, ptr %53, align 8, !tbaa !23
  %498 = load i64, ptr %41, align 8, !tbaa !23
  %499 = mul i64 %498, %497
  store i64 %499, ptr %41, align 8, !tbaa !23
  %500 = load i64, ptr %40, align 8, !tbaa !23
  %501 = load ptr, ptr %32, align 8, !tbaa !5
  %502 = getelementptr inbounds double, ptr %501, i64 %500
  store ptr %502, ptr %32, align 8, !tbaa !5
  %503 = load i64, ptr %41, align 8, !tbaa !23
  %504 = load ptr, ptr %28, align 8, !tbaa !5
  %505 = getelementptr inbounds double, ptr %504, i64 %503
  store ptr %505, ptr %28, align 8, !tbaa !5
  %506 = load ptr, ptr %44, align 8, !tbaa !5
  %507 = load i64, ptr %52, align 8, !tbaa !23
  %508 = sub i64 %507, 1
  %509 = getelementptr inbounds i64, ptr %506, i64 %508
  %510 = load ptr, ptr %37, align 8, !tbaa !5
  %511 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %510, i32 0, i32 0
  store ptr %509, ptr %511, align 8, !tbaa !27
  %512 = load ptr, ptr %45, align 8, !tbaa !5
  %513 = load i64, ptr %53, align 8, !tbaa !23
  %514 = sub i64 %513, 1
  %515 = getelementptr inbounds i64, ptr %512, i64 %514
  %516 = load ptr, ptr %37, align 8, !tbaa !5
  %517 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %516, i32 0, i32 1
  store ptr %515, ptr %517, align 8, !tbaa !29
  %518 = load ptr, ptr %38, align 8, !tbaa !5
  %519 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %518, i32 1
  store ptr %519, ptr %38, align 8, !tbaa !5
  %520 = load ptr, ptr %39, align 8, !tbaa !5
  %521 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %520, i32 1
  store ptr %521, ptr %39, align 8, !tbaa !5
  %522 = load ptr, ptr %37, align 8, !tbaa !5
  %523 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %522, i32 1
  store ptr %523, ptr %37, align 8, !tbaa !5
  store i32 12, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %53) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %52) #7
  br label %524

524:                                              ; preds = %495, %456, %441, %439
  call void @llvm.lifetime.end.p0(i64 8, ptr %45) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %44) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %43) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %42) #7
  %525 = load i32, ptr %11, align 4
  switch i32 %525, label %787 [
    i32 13, label %526
    i32 12, label %353
  ]

526:                                              ; preds = %524
  call void @llvm.lifetime.end.p0(i64 8, ptr %41) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %40) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %39) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %38) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %37) #7
  store i32 0, ptr %11, align 4
  br label %527

527:                                              ; preds = %526, %344
  call void @llvm.lifetime.end.p0(i64 8, ptr %36) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %35) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %34) #7
  %528 = load i32, ptr %11, align 4
  switch i32 %528, label %787 [
    i32 0, label %529
    i32 9, label %530
  ]

529:                                              ; preds = %527
  br label %309, !llvm.loop !37

530:                                              ; preds = %527
  %531 = load ptr, ptr %33, align 8, !tbaa !5
  %532 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 4
  %533 = load ptr, ptr %532, align 8, !tbaa !14
  %534 = icmp eq ptr %531, %533
  br i1 %534, label %537, label %535

535:                                              ; preds = %530
  call void @LogAssertFailure(i64 noundef 671, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.43)
  call void @__assert_fail(ptr noundef @.str.44, ptr noundef @.str, i32 noundef 671, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

536:                                              ; No predecessors!
  br label %537

537:                                              ; preds = %536, %530
  %538 = phi i1 [ true, %530 ], [ false, %536 ]
  %539 = load ptr, ptr %32, align 8, !tbaa !5
  %540 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 4
  %541 = load ptr, ptr %540, align 8, !tbaa !14
  %542 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 1
  %543 = load i64, ptr %542, align 8, !tbaa !15
  %544 = getelementptr inbounds double, ptr %541, i64 %543
  %545 = icmp eq ptr %539, %544
  br i1 %545, label %548, label %546

546:                                              ; preds = %537
  call void @LogAssertFailure(i64 noundef 672, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.45)
  call void @__assert_fail(ptr noundef @.str.46, ptr noundef @.str, i32 noundef 672, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

547:                                              ; No predecessors!
  br label %548

548:                                              ; preds = %547, %537
  %549 = phi i1 [ true, %537 ], [ false, %547 ]
  %550 = load ptr, ptr %28, align 8, !tbaa !5
  %551 = load ptr, ptr %5, align 8, !tbaa !5
  %552 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %551, i32 0, i32 4
  %553 = load ptr, ptr %552, align 8, !tbaa !14
  %554 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 1
  %555 = load i64, ptr %554, align 8, !tbaa !15
  %556 = getelementptr inbounds double, ptr %553, i64 %555
  %557 = icmp eq ptr %550, %556
  br i1 %557, label %560, label %558

558:                                              ; preds = %548
  call void @LogAssertFailure(i64 noundef 673, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.67)
  call void @__assert_fail(ptr noundef @.str.68, ptr noundef @.str, i32 noundef 673, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

559:                                              ; No predecessors!
  br label %560

560:                                              ; preds = %559, %548
  %561 = phi i1 [ true, %548 ], [ false, %559 ]
  call void @llvm.lifetime.start.p0(i64 8, ptr %54) #7
  %562 = getelementptr inbounds [30 x %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack"], ptr %7, i64 0, i64 0
  store ptr %562, ptr %54, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %55) #7
  %563 = load ptr, ptr %31, align 8, !tbaa !5
  store ptr %563, ptr %55, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %56) #7
  %564 = load ptr, ptr %29, align 8, !tbaa !5
  store ptr %564, ptr %56, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %57) #7
  store i64 0, ptr %57, align 8, !tbaa !23
  br label %565

565:                                              ; preds = %777, %560
  call void @llvm.lifetime.start.p0(i64 8, ptr %58) #7
  %566 = load ptr, ptr %54, align 8, !tbaa !5
  %567 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %566, i32 0, i32 2
  %568 = load i64, ptr %567, align 8, !tbaa !31
  store i64 %568, ptr %58, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %59) #7
  %569 = load ptr, ptr %55, align 8, !tbaa !5
  %570 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %569, i32 0, i32 0
  %571 = load i64, ptr %570, align 8, !tbaa !24
  store i64 %571, ptr %59, align 8, !tbaa !23
  %572 = load i64, ptr %57, align 8, !tbaa !23
  %573 = load i64, ptr %58, align 8, !tbaa !23
  %574 = call noundef i32 @_ZN14NAMESPACE_MAIN6Tensor14SetCountSlicesEmm(ptr noundef nonnull align 8 dereferenceable(72) %68, i64 noundef %572, i64 noundef %573)
  store i32 %574, ptr %6, align 4, !tbaa !33
  %575 = load i32, ptr %6, align 4, !tbaa !33
  %576 = icmp ne i32 0, %575
  %577 = xor i1 %576, true
  %578 = xor i1 %577, true
  %579 = zext i1 %578 to i64
  %580 = call i64 @llvm.expect.i64(i64 %579, i64 0)
  %581 = icmp ne i64 %580, 0
  br i1 %581, label %582, label %584

582:                                              ; preds = %565
  %583 = load i32, ptr %6, align 4, !tbaa !33
  store i32 %583, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %774

584:                                              ; preds = %565
  call void @llvm.lifetime.start.p0(i64 8, ptr %60) #7
  %585 = load ptr, ptr %55, align 8, !tbaa !5
  %586 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %585, i32 0, i32 1
  %587 = load ptr, ptr %586, align 8, !tbaa !26
  %588 = load i64, ptr %59, align 8, !tbaa !23
  %589 = sub i64 %588, 1
  %590 = getelementptr inbounds i64, ptr %587, i64 %589
  store ptr %590, ptr %60, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %61) #7
  %591 = load ptr, ptr %56, align 8, !tbaa !5
  %592 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %591, i32 0, i32 1
  %593 = load ptr, ptr %592, align 8, !tbaa !26
  %594 = load ptr, ptr %56, align 8, !tbaa !5
  %595 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %594, i32 0, i32 0
  %596 = load i64, ptr %595, align 8, !tbaa !24
  %597 = sub i64 %596, 1
  %598 = getelementptr inbounds i64, ptr %593, i64 %597
  store ptr %598, ptr %61, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %62) #7
  %599 = load ptr, ptr %55, align 8, !tbaa !5
  %600 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %599, i32 0, i32 1
  %601 = load ptr, ptr %600, align 8, !tbaa !26
  %602 = load i64, ptr %58, align 8, !tbaa !23
  %603 = sub i64 %602, 1
  %604 = getelementptr inbounds i64, ptr %601, i64 %603
  store ptr %604, ptr %62, align 8, !tbaa !5
  br label %605

605:                                              ; preds = %759, %584
  br label %606

606:                                              ; preds = %605
  %607 = load ptr, ptr %55, align 8, !tbaa !5
  %608 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %607, i32 0, i32 1
  %609 = load ptr, ptr %608, align 8, !tbaa !26
  %610 = load ptr, ptr %62, align 8, !tbaa !5
  %611 = icmp ule ptr %609, %610
  br i1 %611, label %614, label %612

612:                                              ; preds = %606
  call void @LogAssertFailure(i64 noundef 701, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.69)
  call void @__assert_fail(ptr noundef @.str.70, ptr noundef @.str, i32 noundef 701, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

613:                                              ; No predecessors!
  br label %614

614:                                              ; preds = %613, %606
  %615 = phi i1 [ true, %606 ], [ false, %613 ]
  %616 = load ptr, ptr %55, align 8, !tbaa !5
  %617 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %616, i32 0, i32 1
  %618 = load ptr, ptr %617, align 8, !tbaa !26
  %619 = load ptr, ptr %60, align 8, !tbaa !5
  %620 = icmp ule ptr %618, %619
  br i1 %620, label %623, label %621

621:                                              ; preds = %614
  call void @LogAssertFailure(i64 noundef 702, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.71)
  call void @__assert_fail(ptr noundef @.str.72, ptr noundef @.str, i32 noundef 702, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

622:                                              ; No predecessors!
  br label %623

623:                                              ; preds = %622, %614
  %624 = phi i1 [ true, %614 ], [ false, %622 ]
  %625 = load ptr, ptr %56, align 8, !tbaa !5
  %626 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %625, i32 0, i32 1
  %627 = load ptr, ptr %626, align 8, !tbaa !26
  %628 = load ptr, ptr %61, align 8, !tbaa !5
  %629 = icmp ule ptr %627, %628
  br i1 %629, label %632, label %630

630:                                              ; preds = %623
  call void @LogAssertFailure(i64 noundef 703, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.73)
  call void @__assert_fail(ptr noundef @.str.74, ptr noundef @.str, i32 noundef 703, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

631:                                              ; No predecessors!
  br label %632

632:                                              ; preds = %631, %623
  %633 = phi i1 [ true, %623 ], [ false, %631 ]
  %634 = load ptr, ptr %60, align 8, !tbaa !5
  %635 = load ptr, ptr %62, align 8, !tbaa !5
  %636 = icmp ule ptr %634, %635
  br i1 %636, label %639, label %637

637:                                              ; preds = %632
  call void @LogAssertFailure(i64 noundef 704, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.75)
  call void @__assert_fail(ptr noundef @.str.76, ptr noundef @.str, i32 noundef 704, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

638:                                              ; No predecessors!
  br label %639

639:                                              ; preds = %638, %632
  %640 = phi i1 [ true, %632 ], [ false, %638 ]
  %641 = load ptr, ptr %61, align 8, !tbaa !5
  %642 = load ptr, ptr %56, align 8, !tbaa !5
  %643 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %642, i32 0, i32 1
  %644 = load ptr, ptr %643, align 8, !tbaa !26
  %645 = ptrtoint ptr %641 to i64
  %646 = ptrtoint ptr %644 to i64
  %647 = sub i64 %645, %646
  %648 = sdiv exact i64 %647, 8
  %649 = load ptr, ptr %62, align 8, !tbaa !5
  %650 = load ptr, ptr %55, align 8, !tbaa !5
  %651 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %650, i32 0, i32 1
  %652 = load ptr, ptr %651, align 8, !tbaa !26
  %653 = ptrtoint ptr %649 to i64
  %654 = ptrtoint ptr %652 to i64
  %655 = sub i64 %653, %654
  %656 = sdiv exact i64 %655, 8
  %657 = icmp ule i64 %648, %656
  br i1 %657, label %660, label %658

658:                                              ; preds = %639
  call void @LogAssertFailure(i64 noundef 706, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.77)
  call void @__assert_fail(ptr noundef @.str.78, ptr noundef @.str, i32 noundef 706, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

659:                                              ; No predecessors!
  br label %660

660:                                              ; preds = %659, %639
  %661 = phi i1 [ true, %639 ], [ false, %659 ]
  %662 = load ptr, ptr %62, align 8, !tbaa !5
  %663 = load ptr, ptr %60, align 8, !tbaa !5
  %664 = icmp eq ptr %662, %663
  %665 = xor i1 %664, true
  %666 = xor i1 %665, true
  %667 = zext i1 %666 to i64
  %668 = call i64 @llvm.expect.i64(i64 %667, i64 0)
  %669 = icmp ne i64 %668, 0
  br i1 %669, label %670, label %671

670:                                              ; preds = %660
  br label %765

671:                                              ; preds = %660
  %672 = load ptr, ptr %62, align 8, !tbaa !5
  %673 = load ptr, ptr %55, align 8, !tbaa !5
  %674 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %673, i32 0, i32 1
  %675 = load ptr, ptr %674, align 8, !tbaa !26
  %676 = ptrtoint ptr %672 to i64
  %677 = ptrtoint ptr %675 to i64
  %678 = sub i64 %676, %677
  %679 = sdiv exact i64 %678, 8
  %680 = load ptr, ptr %61, align 8, !tbaa !5
  %681 = load ptr, ptr %56, align 8, !tbaa !5
  %682 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %681, i32 0, i32 1
  %683 = load ptr, ptr %682, align 8, !tbaa !26
  %684 = ptrtoint ptr %680 to i64
  %685 = ptrtoint ptr %683 to i64
  %686 = sub i64 %684, %685
  %687 = sdiv exact i64 %686, 8
  %688 = icmp eq i64 %679, %687
  %689 = xor i1 %688, true
  %690 = xor i1 %689, true
  %691 = zext i1 %690 to i64
  %692 = call i64 @llvm.expect.i64(i64 %691, i64 0)
  %693 = icmp ne i64 %692, 0
  br i1 %693, label %694, label %719

694:                                              ; preds = %671
  %695 = load ptr, ptr %55, align 8, !tbaa !5
  %696 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %695, i32 0, i32 1
  %697 = load ptr, ptr %696, align 8, !tbaa !26
  %698 = load ptr, ptr %62, align 8, !tbaa !5
  %699 = icmp ult ptr %697, %698
  br i1 %699, label %702, label %700

700:                                              ; preds = %694
  call void @LogAssertFailure(i64 noundef 717, ptr noundef @.str, ptr noundef @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef @.str.79)
  call void @__assert_fail(ptr noundef @.str.80, ptr noundef @.str, i32 noundef 717, ptr noundef @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

701:                                              ; No predecessors!
  br label %702

702:                                              ; preds = %701, %694
  %703 = phi i1 [ true, %694 ], [ false, %701 ]
  %704 = load ptr, ptr %55, align 8, !tbaa !5
  %705 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %704, i32 0, i32 1
  %706 = load ptr, ptr %705, align 8, !tbaa !26
  %707 = load ptr, ptr %56, align 8, !tbaa !5
  %708 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %707, i32 0, i32 1
  %709 = load ptr, ptr %708, align 8, !tbaa !26
  %710 = load ptr, ptr %62, align 8, !tbaa !5
  %711 = load ptr, ptr %55, align 8, !tbaa !5
  %712 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %711, i32 0, i32 1
  %713 = load ptr, ptr %712, align 8, !tbaa !26
  %714 = ptrtoint ptr %710 to i64
  %715 = ptrtoint ptr %713 to i64
  %716 = sub i64 %714, %715
  %717 = sdiv exact i64 %716, 8
  %718 = mul i64 %717, 8
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %706, ptr align 8 %709, i64 %718, i1 false)
  br label %765

719:                                              ; preds = %671
  call void @llvm.lifetime.start.p0(i64 8, ptr %63) #7
  %720 = load ptr, ptr %60, align 8, !tbaa !5
  %721 = getelementptr inbounds i64, ptr %720, i64 -1
  store ptr %721, ptr %63, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %64) #7
  %722 = load ptr, ptr %61, align 8, !tbaa !5
  %723 = getelementptr inbounds i64, ptr %722, i64 -1
  store ptr %723, ptr %64, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %65) #7
  %724 = load ptr, ptr %63, align 8, !tbaa !5
  %725 = load i64, ptr %724, align 8, !tbaa !23
  store i64 %725, ptr %65, align 8, !tbaa !23
  call void @llvm.lifetime.start.p0(i64 8, ptr %66) #7
  %726 = load ptr, ptr %64, align 8, !tbaa !5
  %727 = load i64, ptr %726, align 8, !tbaa !23
  store i64 %727, ptr %66, align 8, !tbaa !23
  %728 = load i64, ptr %66, align 8, !tbaa !23
  %729 = load i64, ptr %65, align 8, !tbaa !23
  %730 = icmp ule i64 %728, %729
  %731 = xor i1 %730, true
  %732 = xor i1 %731, true
  br i1 %732, label %733, label %735, !unpredictable !22

733:                                              ; preds = %719
  %734 = load ptr, ptr %63, align 8, !tbaa !5
  br label %737

735:                                              ; preds = %719
  %736 = load ptr, ptr %60, align 8, !tbaa !5
  br label %737

737:                                              ; preds = %735, %733
  %738 = phi ptr [ %734, %733 ], [ %736, %735 ]
  store ptr %738, ptr %60, align 8, !tbaa !5
  %739 = load i64, ptr %65, align 8, !tbaa !23
  %740 = load i64, ptr %66, align 8, !tbaa !23
  %741 = icmp ule i64 %739, %740
  %742 = xor i1 %741, true
  %743 = xor i1 %742, true
  br i1 %743, label %744, label %746, !unpredictable !22

744:                                              ; preds = %737
  %745 = load ptr, ptr %64, align 8, !tbaa !5
  br label %748

746:                                              ; preds = %737
  %747 = load ptr, ptr %61, align 8, !tbaa !5
  br label %748

748:                                              ; preds = %746, %744
  %749 = phi ptr [ %745, %744 ], [ %747, %746 ]
  store ptr %749, ptr %61, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %67) #7
  %750 = load i64, ptr %65, align 8, !tbaa !23
  %751 = load i64, ptr %66, align 8, !tbaa !23
  %752 = icmp ule i64 %750, %751
  %753 = xor i1 %752, true
  %754 = xor i1 %753, true
  br i1 %754, label %755, label %757, !unpredictable !22

755:                                              ; preds = %748
  %756 = load i64, ptr %66, align 8, !tbaa !23
  br label %759

757:                                              ; preds = %748
  %758 = load i64, ptr %65, align 8, !tbaa !23
  br label %759

759:                                              ; preds = %757, %755
  %760 = phi i64 [ %756, %755 ], [ %758, %757 ]
  store i64 %760, ptr %67, align 8, !tbaa !23
  %761 = load ptr, ptr %62, align 8, !tbaa !5
  %762 = getelementptr inbounds i64, ptr %761, i32 -1
  store ptr %762, ptr %62, align 8, !tbaa !5
  %763 = load i64, ptr %67, align 8, !tbaa !23
  %764 = load ptr, ptr %62, align 8, !tbaa !5
  store i64 %763, ptr %764, align 8, !tbaa !23
  call void @llvm.lifetime.end.p0(i64 8, ptr %67) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %66) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %65) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %64) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %63) #7
  br label %605, !llvm.loop !38

765:                                              ; preds = %702, %670
  %766 = load ptr, ptr %55, align 8, !tbaa !5
  %767 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %766, i32 1
  store ptr %767, ptr %55, align 8, !tbaa !5
  %768 = load ptr, ptr %56, align 8, !tbaa !5
  %769 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfo", ptr %768, i32 1
  store ptr %769, ptr %56, align 8, !tbaa !5
  %770 = load ptr, ptr %54, align 8, !tbaa !5
  %771 = getelementptr inbounds %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack", ptr %770, i32 1
  store ptr %771, ptr %54, align 8, !tbaa !5
  %772 = load i64, ptr %57, align 8, !tbaa !23
  %773 = add i64 %772, 1
  store i64 %773, ptr %57, align 8, !tbaa !23
  call void @llvm.lifetime.end.p0(i64 8, ptr %62) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %61) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %60) #7
  store i32 0, ptr %11, align 4
  br label %774

774:                                              ; preds = %765, %582
  call void @llvm.lifetime.end.p0(i64 8, ptr %59) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %58) #7
  %775 = load i32, ptr %11, align 4
  switch i32 %775, label %783 [
    i32 0, label %776
  ]

776:                                              ; preds = %774
  br label %777

777:                                              ; preds = %776
  %778 = load i64, ptr %57, align 8, !tbaa !23
  %779 = getelementptr inbounds %"class.NAMESPACE_MAIN::Tensor", ptr %68, i32 0, i32 3
  %780 = load i64, ptr %779, align 8, !tbaa !9
  %781 = icmp ne i64 %778, %780
  br i1 %781, label %565, label %782, !llvm.loop !39

782:                                              ; preds = %777
  store i32 0, ptr %3, align 4
  store i32 1, ptr %11, align 4
  br label %783

783:                                              ; preds = %782, %774
  call void @llvm.lifetime.end.p0(i64 8, ptr %57) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %56) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %55) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %54) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %33) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %31) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #7
  br label %784

784:                                              ; preds = %783, %290
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #7
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #7
  br label %785

785:                                              ; preds = %784, %122
  call void @llvm.lifetime.end.p0(i64 720, ptr %7) #7
  call void @llvm.lifetime.end.p0(i64 4, ptr %6) #7
  %786 = load i32, ptr %3, align 4
  ret i32 %786

787:                                              ; preds = %527, %524
  unreachable
}

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

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

!0 = !{i32 1, !"wchar_size", i32 4}
!1 = !{i32 8, !"PIC Level", i32 2}
!2 = !{i32 7, !"PIE Level", i32 2}
!3 = !{i32 7, !"uwtable", i32 2}
!4 = !{!"clang version 19.1.0 (git@github.com:llvm/llvm-project.git a4bf6cd7cfb1a1421ba92bca9d017b49936c55e4)"}
!5 = !{!6, !6, i64 0}
!6 = !{!"any pointer", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !11, i64 24}
!10 = !{!"_ZTSN14NAMESPACE_MAIN6TensorE", !11, i64 0, !11, i64 8, !11, i64 16, !11, i64 24, !6, i64 32, !12, i64 40, !7, i64 48}
!11 = !{!"long", !7, i64 0}
!12 = !{!"bool", !7, i64 0}
!13 = !{!10, !11, i64 0}
!14 = !{!10, !6, i64 32}
!15 = !{!10, !11, i64 8}
!16 = !{!17, !17, i64 0}
!17 = !{!"double", !7, i64 0}
!18 = distinct !{!18, !19}
!19 = !{!"llvm.loop.mustprogress"}
!20 = !{!10, !12, i64 40}
!21 = !{i8 0, i8 2}
!22 = !{}
!23 = !{!11, !11, i64 0}
!24 = !{!25, !11, i64 0}
!25 = !{!"_ZTSN14NAMESPACE_MAIN6Tensor13DimensionInfoE", !11, i64 0, !6, i64 8, !11, i64 16}
!26 = !{!25, !6, i64 8}
!27 = !{!28, !6, i64 0}
!28 = !{!"_ZTSN14NAMESPACE_MAIN6Tensor18DimensionInfoStackE", !6, i64 0, !6, i64 8, !11, i64 16}
!29 = !{!28, !6, i64 8}
!30 = distinct !{!30, !19}
!31 = !{!28, !11, i64 16}
!32 = distinct !{!32, !19}
!33 = !{!34, !34, i64 0}
!34 = !{!"int", !7, i64 0}
!35 = distinct !{!35, !19}
!36 = !{!12, !12, i64 0}
!37 = distinct !{!37, !19}
!38 = distinct !{!38, !19}
!39 = distinct !{!39, !19}


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

%"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack" = type { ptr, ptr, i64 }

@.str = external hidden unnamed_addr constant [80 x i8], align 1
@.str.11 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.12 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.43 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.44 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.45 = external hidden unnamed_addr constant [45 x i8], align 1
@.str.46 = external hidden unnamed_addr constant [48 x i8], align 1
@__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_ = external hidden unnamed_addr constant [4 x i8], align 1
@__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_ = external hidden unnamed_addr constant [53 x i8], align 1
@.str.55 = external hidden unnamed_addr constant [28 x i8], align 1
@.str.56 = external hidden unnamed_addr constant [31 x i8], align 1
@.str.57 = external hidden unnamed_addr constant [27 x i8], align 1
@.str.58 = external hidden unnamed_addr constant [30 x i8], align 1
@.str.59 = external hidden unnamed_addr constant [19 x i8], align 1
@.str.60 = external hidden unnamed_addr constant [22 x i8], align 1
@.str.61 = external hidden unnamed_addr constant [62 x i8], align 1
@.str.62 = external hidden unnamed_addr constant [65 x i8], align 1
@.str.63 = external hidden unnamed_addr constant [45 x i8], align 1
@.str.64 = external hidden unnamed_addr constant [48 x i8], align 1
@.str.65 = external hidden unnamed_addr constant [45 x i8], align 1
@.str.66 = external hidden unnamed_addr constant [48 x i8], align 1
@.str.67 = external hidden unnamed_addr constant [49 x i8], align 1
@.str.68 = external hidden unnamed_addr constant [52 x i8], align 1
@.str.69 = external hidden unnamed_addr constant [37 x i8], align 1
@.str.70 = external hidden unnamed_addr constant [40 x i8], align 1
@.str.71 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.72 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.73 = external hidden unnamed_addr constant [35 x i8], align 1
@.str.74 = external hidden unnamed_addr constant [38 x i8], align 1
@.str.75 = external hidden unnamed_addr constant [17 x i8], align 1
@.str.76 = external hidden unnamed_addr constant [20 x i8], align 1
@.str.77 = external hidden unnamed_addr constant [115 x i8], align 1
@.str.78 = external hidden unnamed_addr constant [118 x i8], align 1
@.str.79 = external hidden unnamed_addr constant [36 x i8], align 1
@.str.80 = external hidden unnamed_addr constant [39 x i8], align 1

declare void @LogAssertFailure(i64 noundef, ptr noundef, ptr noundef, ptr noundef) local_unnamed_addr #0

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare hidden noundef zeroext i1 @_ZN14NAMESPACE_MAINL15IsMultiplyErrorImEEbT_S1_(i64 noundef, i64 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: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZN14NAMESPACE_MAIN6Tensor13GetDimensionsEv(ptr noundef nonnull align 8 dereferenceable(72)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZN14NAMESPACE_MAIN6Tensor14SetCountSlicesEmm(ptr noundef nonnull align 8 dereferenceable(72), i64 noundef, i64 noundef) local_unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef i32 @_ZN14NAMESPACE_MAIN6Tensor25EnsureTensorScoreCapacityEm(ptr noundef nonnull align 8 dereferenceable(72), i64 noundef) local_unnamed_addr #4 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local noundef ptr @_ZNK14NAMESPACE_MAIN6Tensor13GetDimensionsEv(ptr noundef nonnull align 8 dereferenceable(72)) local_unnamed_addr #2 align 2

; Function Attrs: mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite)
declare void @llvm.memcpy.p0.p0.i64(ptr noalias nocapture writeonly, ptr noalias nocapture readonly, i64, i1 immarg) #5

; Function Attrs: mustprogress uwtable
define dso_local noundef i32 @_ZN14NAMESPACE_MAIN6Tensor3AddERKS0_(ptr noundef nonnull align 8 dereferenceable(72) %0, ptr noundef nonnull align 8 dereferenceable(72) %1) local_unnamed_addr #4 align 2 {
  %3 = alloca [30 x %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack"], align 16
  call void @llvm.lifetime.start.p0(i64 720, ptr nonnull %3) #7
  %4 = getelementptr inbounds i8, ptr %0, i64 24
  %5 = load i64, ptr %4, align 8, !tbaa !5
  %6 = getelementptr inbounds i8, ptr %1, i64 24
  %7 = load i64, ptr %6, align 8, !tbaa !5
  %8 = icmp eq i64 %5, %7
  br i1 %8, label %10, label %9

9:                                                ; preds = %2
  tail call void @LogAssertFailure(i64 noundef 466, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.11)
  tail call void @__assert_fail(ptr noundef nonnull @.str.12, ptr noundef nonnull @.str, i32 noundef 466, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

10:                                               ; preds = %2
  %11 = icmp eq i64 %5, 0
  br i1 %11, label %12, label %41

12:                                               ; preds = %10
  %13 = load i64, ptr %0, align 8, !tbaa !12
  %.not307 = icmp eq i64 %13, 0
  br i1 %.not307, label %14, label %15

14:                                               ; preds = %12
  tail call void @LogAssertFailure(i64 noundef 469, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.55)
  tail call void @__assert_fail(ptr noundef nonnull @.str.56, ptr noundef nonnull @.str, i32 noundef 469, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

15:                                               ; preds = %12
  %16 = getelementptr inbounds i8, ptr %0, i64 32
  %17 = load ptr, ptr %16, align 8, !tbaa !13
  %.not308 = icmp eq ptr %17, null
  br i1 %.not308, label %18, label %19

18:                                               ; preds = %15
  tail call void @LogAssertFailure(i64 noundef 470, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.57)
  tail call void @__assert_fail(ptr noundef nonnull @.str.58, ptr noundef nonnull @.str, i32 noundef 470, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

19:                                               ; preds = %15
  %20 = getelementptr inbounds i8, ptr %1, i64 32
  %21 = load ptr, ptr %20, align 8, !tbaa !13
  %22 = getelementptr inbounds i8, ptr %0, i64 8
  %23 = load i64, ptr %22, align 8, !tbaa !14
  %24 = getelementptr inbounds double, ptr %17, i64 %23
  %25 = add i64 %23, 2305843009213693951
  %26 = and i64 %25, 2305843009213693951
  %27 = add nuw nsw i64 %26, 1
  %min.iters.check612 = icmp ult i64 %26, 13
  br i1 %min.iters.check612, label %scalar.ph611.preheader, label %vector.memcheck607

vector.memcheck607:                               ; preds = %19
  %28 = shl i64 %23, 3
  %scevgep608 = getelementptr i8, ptr %17, i64 %28
  %scevgep609 = getelementptr i8, ptr %21, i64 %28
  %bound0 = icmp ult ptr %17, %scevgep609
  %bound1 = icmp ult ptr %21, %scevgep608
  %found.conflict = and i1 %bound0, %bound1
  br i1 %found.conflict, label %scalar.ph611.preheader, label %vector.ph613

vector.ph613:                                     ; preds = %vector.memcheck607
  %n.vec615 = and i64 %27, 4611686018427387900
  %29 = shl i64 %n.vec615, 3
  %ind.end616 = getelementptr i8, ptr %21, i64 %29
  %30 = shl i64 %n.vec615, 3
  %ind.end618 = getelementptr i8, ptr %17, i64 %30
  br label %vector.body620

vector.body620:                                   ; preds = %vector.body620, %vector.ph613
  %index621 = phi i64 [ 0, %vector.ph613 ], [ %index.next632, %vector.body620 ]
  %offset.idx622 = shl i64 %index621, 3
  %next.gep623 = getelementptr i8, ptr %21, i64 %offset.idx622
  %offset.idx625 = shl i64 %index621, 3
  %next.gep626 = getelementptr i8, ptr %17, i64 %offset.idx625
  %31 = getelementptr i8, ptr %next.gep623, i64 16
  %wide.load628 = load <2 x double>, ptr %next.gep623, align 8, !tbaa !15, !alias.scope !17
  %wide.load629 = load <2 x double>, ptr %31, align 8, !tbaa !15, !alias.scope !17
  %32 = getelementptr i8, ptr %next.gep626, i64 16
  %wide.load630 = load <2 x double>, ptr %next.gep626, align 8, !tbaa !15, !alias.scope !20, !noalias !17
  %wide.load631 = load <2 x double>, ptr %32, align 8, !tbaa !15, !alias.scope !20, !noalias !17
  %33 = fadd <2 x double> %wide.load628, %wide.load630
  %34 = fadd <2 x double> %wide.load629, %wide.load631
  store <2 x double> %33, ptr %next.gep626, align 8, !tbaa !15, !alias.scope !20, !noalias !17
  store <2 x double> %34, ptr %32, align 8, !tbaa !15, !alias.scope !20, !noalias !17
  %index.next632 = add nuw i64 %index621, 4
  %35 = icmp eq i64 %index.next632, %n.vec615
  br i1 %35, label %middle.block610, label %vector.body620, !llvm.loop !22

middle.block610:                                  ; preds = %vector.body620
  %cmp.n633 = icmp eq i64 %27, %n.vec615
  br i1 %cmp.n633, label %.thread329, label %scalar.ph611.preheader

scalar.ph611.preheader:                           ; preds = %middle.block610, %vector.memcheck607, %19
  %.0224.ph = phi ptr [ %21, %vector.memcheck607 ], [ %21, %19 ], [ %ind.end616, %middle.block610 ]
  %.0223.ph = phi ptr [ %17, %vector.memcheck607 ], [ %17, %19 ], [ %ind.end618, %middle.block610 ]
  br label %scalar.ph611

scalar.ph611:                                     ; preds = %scalar.ph611.preheader, %scalar.ph611
  %.0224 = phi ptr [ %40, %scalar.ph611 ], [ %.0224.ph, %scalar.ph611.preheader ]
  %.0223 = phi ptr [ %39, %scalar.ph611 ], [ %.0223.ph, %scalar.ph611.preheader ]
  %36 = load double, ptr %.0224, align 8, !tbaa !15
  %37 = load double, ptr %.0223, align 8, !tbaa !15
  %38 = fadd double %36, %37
  store double %38, ptr %.0223, align 8, !tbaa !15
  %39 = getelementptr inbounds i8, ptr %.0223, i64 8
  %40 = getelementptr inbounds i8, ptr %.0224, i64 8
  %.not309 = icmp eq ptr %24, %39
  br i1 %.not309, label %.thread329, label %scalar.ph611, !llvm.loop !26

41:                                               ; preds = %10
  %42 = tail call noundef ptr @_ZN14NAMESPACE_MAIN6Tensor13GetDimensionsEv(ptr noundef nonnull align 8 dereferenceable(72) %0)
  %43 = tail call noundef ptr @_ZNK14NAMESPACE_MAIN6Tensor13GetDimensionsEv(ptr noundef nonnull align 8 dereferenceable(72) %1)
  %44 = load i64, ptr %4, align 8, !tbaa !5
  %45 = getelementptr inbounds [30 x %"struct.NAMESPACE_MAIN::Tensor::DimensionInfoStack"], ptr %3, i64 0, i64 %44
  %46 = getelementptr inbounds i8, ptr %0, i64 8
  %.not = icmp eq i64 %44, 0
  br i1 %.not, label %48, label %.preheader337.preheader

.preheader337.preheader:                          ; preds = %41
  %47 = load i64, ptr %46, align 8, !tbaa !14
  br label %.preheader337

48:                                               ; preds = %41
  tail call void @LogAssertFailure(i64 noundef 502, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.59)
  tail call void @__assert_fail(ptr noundef nonnull @.str.60, ptr noundef nonnull @.str, i32 noundef 502, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

.preheader337:                                    ; preds = %.preheader337.preheader, %77
  %.0244 = phi i64 [ %78, %77 ], [ %47, %.preheader337.preheader ]
  %.0243 = phi i64 [ %56, %77 ], [ %47, %.preheader337.preheader ]
  %.0242 = phi i64 [ %55, %77 ], [ %47, %.preheader337.preheader ]
  %.0241 = phi ptr [ %81, %77 ], [ %3, %.preheader337.preheader ]
  %.0232 = phi ptr [ %80, %77 ], [ %43, %.preheader337.preheader ]
  %.0231 = phi ptr [ %79, %77 ], [ %42, %.preheader337.preheader ]
  %49 = load i64, ptr %.0231, align 8, !tbaa !27
  %50 = getelementptr inbounds i8, ptr %.0231, i64 8
  %51 = load ptr, ptr %50, align 8, !tbaa !29
  %52 = load i64, ptr %.0232, align 8, !tbaa !27
  %53 = getelementptr inbounds i8, ptr %.0232, i64 8
  %54 = load ptr, ptr %53, align 8, !tbaa !29
  %55 = mul i64 %49, %.0242
  %56 = mul i64 %52, %.0243
  %57 = getelementptr i64, ptr %51, i64 %49
  %58 = getelementptr i8, ptr %57, i64 -8
  %59 = getelementptr i64, ptr %54, i64 %52
  %60 = getelementptr i8, ptr %59, i64 -8
  store ptr %58, ptr %.0241, align 8, !tbaa !30
  %61 = getelementptr inbounds i8, ptr %.0241, i64 8
  store ptr %60, ptr %61, align 8, !tbaa !32
  %62 = icmp eq ptr %60, %54
  br i1 %62, label %._crit_edge, label %.lr.ph, !prof !33

.lr.ph:                                           ; preds = %.preheader337, %64
  %.0245394 = phi ptr [ %68, %64 ], [ %51, %.preheader337 ]
  %.0246393 = phi ptr [ %69, %64 ], [ %54, %.preheader337 ]
  %.0247392 = phi i64 [ %65, %64 ], [ 1, %.preheader337 ]
  %63 = icmp eq ptr %58, %.0245394
  br i1 %63, label %._crit_edge, label %64, !prof !34

64:                                               ; preds = %.lr.ph
  %65 = add i64 %.0247392, 1
  %66 = load i64, ptr %.0245394, align 8, !tbaa !35
  %67 = load i64, ptr %.0246393, align 8, !tbaa !35
  %.not288 = icmp ugt i64 %66, %67
  %.idx = select i1 %.not288, i64 0, i64 8, !unpredictable !36
  %68 = getelementptr inbounds i8, ptr %.0245394, i64 %.idx
  %.not289 = icmp ugt i64 %67, %66
  %.idx290 = select i1 %.not289, i64 0, i64 8, !unpredictable !36
  %69 = getelementptr inbounds i8, ptr %.0246393, i64 %.idx290
  %70 = icmp eq ptr %60, %69
  br i1 %70, label %._crit_edge, label %.lr.ph, !prof !37, !llvm.loop !38

._crit_edge:                                      ; preds = %.lr.ph, %64, %.preheader337
  %.sink527 = phi ptr [ %58, %.preheader337 ], [ %58, %64 ], [ %60, %.lr.ph ]
  %.0246393.lcssa.sink = phi ptr [ %51, %.preheader337 ], [ %68, %64 ], [ %.0246393, %.lr.ph ]
  %.0247386 = phi i64 [ 1, %.preheader337 ], [ %65, %64 ], [ %.0247392, %.lr.ph ]
  %71 = ptrtoint ptr %.sink527 to i64
  %72 = ptrtoint ptr %.0246393.lcssa.sink to i64
  %73 = sub i64 %71, %72
  %.pn = ashr exact i64 %73, 3
  %.1248 = add i64 %.pn, %.0247386
  %74 = getelementptr inbounds i8, ptr %.0241, i64 16
  store i64 %.1248, ptr %74, align 8, !tbaa !39
  %75 = call noundef zeroext i1 @_ZN14NAMESPACE_MAINL15IsMultiplyErrorImEEbT_S1_(i64 noundef %.0244, i64 noundef %.1248) #7
  br i1 %75, label %76, label %77

76:                                               ; preds = %._crit_edge
  call void @LogAssertFailure(i64 noundef 546, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.61)
  call void @__assert_fail(ptr noundef nonnull @.str.62, ptr noundef nonnull @.str, i32 noundef 546, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

77:                                               ; preds = %._crit_edge
  %78 = mul i64 %.1248, %.0244
  %79 = getelementptr inbounds i8, ptr %.0231, i64 24
  %80 = getelementptr inbounds i8, ptr %.0232, i64 24
  %81 = getelementptr inbounds i8, ptr %.0241, i64 24
  %.not291 = icmp eq ptr %45, %81
  br i1 %.not291, label %82, label %.preheader337, !llvm.loop !40

82:                                               ; preds = %77
  %83 = call noundef i32 @_ZN14NAMESPACE_MAIN6Tensor25EnsureTensorScoreCapacityEm(ptr noundef nonnull align 8 dereferenceable(72) %0, i64 noundef %78)
  %.not292 = icmp eq i32 %83, 0
  br i1 %.not292, label %84, label %.thread329, !prof !41

84:                                               ; preds = %82
  %85 = getelementptr inbounds i8, ptr %1, i64 32
  %86 = load ptr, ptr %85, align 8, !tbaa !13
  %87 = getelementptr inbounds double, ptr %86, i64 %56
  %88 = call noundef ptr @_ZNK14NAMESPACE_MAIN6Tensor13GetDimensionsEv(ptr noundef nonnull align 8 dereferenceable(72) %1)
  %89 = getelementptr inbounds i8, ptr %0, i64 32
  %90 = load ptr, ptr %89, align 8, !tbaa !13
  %91 = call noundef ptr @_ZN14NAMESPACE_MAIN6Tensor13GetDimensionsEv(ptr noundef nonnull align 8 dereferenceable(72) %0)
  %92 = getelementptr inbounds double, ptr %90, i64 %55
  %93 = getelementptr inbounds double, ptr %90, i64 %78
  %94 = getelementptr inbounds i8, ptr %3, i64 8
  %95 = getelementptr inbounds i8, ptr %91, i64 8
  %96 = getelementptr inbounds i8, ptr %88, i64 8
  br label %97

97:                                               ; preds = %.backedge, %84
  %.0257 = phi ptr [ %93, %84 ], [ %100, %.backedge ]
  %.0253 = phi ptr [ %92, %84 ], [ %.0253.be, %.backedge ]
  %.0249 = phi ptr [ %87, %84 ], [ %.0249.be, %.backedge ]
  %.0249584 = ptrtoint ptr %.0249 to i64
  %.0257585 = ptrtoint ptr %.0257 to i64
  %.0253586 = ptrtoint ptr %.0253 to i64
  %98 = load i64, ptr %46, align 8, !tbaa !14
  %99 = sub i64 0, %98
  %100 = getelementptr inbounds double, ptr %.0257, i64 %99
  %101 = add i64 %98, 2305843009213693951
  %102 = and i64 %101, 2305843009213693951
  %103 = add nuw nsw i64 %102, 1
  %min.iters.check = icmp ult i64 %102, 37
  br i1 %min.iters.check, label %scalar.ph.preheader, label %vector.scevcheck

vector.scevcheck:                                 ; preds = %97
  %104 = add i64 %98, 2305843009213693951
  %105 = and i64 %104, 2305843009213693951
  %scevgep = getelementptr i8, ptr %.0257, i64 -8
  %mul.neg = mul i64 %105, -8
  %106 = getelementptr i8, ptr %scevgep, i64 %mul.neg
  %107 = icmp ugt ptr %106, %scevgep
  %scevgep576 = getelementptr i8, ptr %.0253, i64 -8
  %mul577.neg = mul i64 %105, -8
  %108 = getelementptr i8, ptr %scevgep576, i64 %mul577.neg
  %109 = icmp ugt ptr %108, %scevgep576
  %scevgep580 = getelementptr i8, ptr %.0249, i64 -8
  %mul581.neg = mul i64 %105, -8
  %110 = getelementptr i8, ptr %scevgep580, i64 %mul581.neg
  %111 = icmp ugt ptr %110, %scevgep580
  %112 = or i1 %107, %109
  %113 = or i1 %112, %111
  br i1 %113, label %scalar.ph.preheader, label %vector.memcheck

vector.memcheck:                                  ; preds = %vector.scevcheck
  %114 = sub i64 %.0249584, %.0257585
  %diff.check = icmp ult i64 %114, 32
  %115 = sub i64 %.0253586, %.0257585
  %diff.check587 = icmp ult i64 %115, 32
  %conflict.rdx = or i1 %diff.check, %diff.check587
  br i1 %conflict.rdx, label %scalar.ph.preheader, label %vector.ph

vector.ph:                                        ; preds = %vector.memcheck
  %n.vec = and i64 %103, 4611686018427387900
  %116 = mul i64 %n.vec, -8
  %ind.end = getelementptr i8, ptr %.0249, i64 %116
  %117 = mul i64 %n.vec, -8
  %ind.end588 = getelementptr i8, ptr %.0253, i64 %117
  %118 = mul i64 %n.vec, -8
  %ind.end590 = getelementptr i8, ptr %.0257, i64 %118
  br label %vector.body

vector.body:                                      ; preds = %vector.body, %vector.ph
  %index = phi i64 [ 0, %vector.ph ], [ %index.next, %vector.body ]
  %offset.idx = mul i64 %index, -8
  %next.gep = getelementptr i8, ptr %.0249, i64 %offset.idx
  %offset.idx593 = mul i64 %index, -8
  %next.gep594 = getelementptr i8, ptr %.0253, i64 %offset.idx593
  %offset.idx596 = mul i64 %index, -8
  %next.gep597 = getelementptr i8, ptr %.0257, i64 %offset.idx596
  %119 = getelementptr inbounds i8, ptr %next.gep594, i64 -16
  %120 = getelementptr inbounds i8, ptr %next.gep594, i64 -32
  %wide.load = load <2 x double>, ptr %119, align 8, !tbaa !15
  %wide.load599 = load <2 x double>, ptr %120, align 8, !tbaa !15
  %121 = getelementptr inbounds i8, ptr %next.gep, i64 -16
  %122 = getelementptr inbounds i8, ptr %next.gep, i64 -32
  %wide.load601 = load <2 x double>, ptr %121, align 8, !tbaa !15
  %wide.load603 = load <2 x double>, ptr %122, align 8, !tbaa !15
  %123 = fadd <2 x double> %wide.load, %wide.load601
  %124 = fadd <2 x double> %wide.load599, %wide.load603
  %125 = getelementptr inbounds i8, ptr %next.gep597, i64 -16
  %126 = getelementptr inbounds i8, ptr %next.gep597, i64 -32
  store <2 x double> %123, ptr %125, align 8, !tbaa !15
  store <2 x double> %124, ptr %126, align 8, !tbaa !15
  %index.next = add nuw i64 %index, 4
  %127 = icmp eq i64 %index.next, %n.vec
  br i1 %127, label %middle.block, label %vector.body, !llvm.loop !42

middle.block:                                     ; preds = %vector.body
  %cmp.n = icmp eq i64 %103, %n.vec
  br i1 %cmp.n, label %.loopexit634, label %scalar.ph.preheader

scalar.ph.preheader:                              ; preds = %middle.block, %vector.memcheck, %vector.scevcheck, %97
  %.0260.ph = phi ptr [ %.0249, %vector.memcheck ], [ %.0249, %vector.scevcheck ], [ %.0249, %97 ], [ %ind.end, %middle.block ]
  %.0259.ph = phi ptr [ %.0253, %vector.memcheck ], [ %.0253, %vector.scevcheck ], [ %.0253, %97 ], [ %ind.end588, %middle.block ]
  %.1258.ph = phi ptr [ %.0257, %vector.memcheck ], [ %.0257, %vector.scevcheck ], [ %.0257, %97 ], [ %ind.end590, %middle.block ]
  br label %scalar.ph

scalar.ph:                                        ; preds = %scalar.ph.preheader, %scalar.ph
  %.0260 = phi ptr [ %129, %scalar.ph ], [ %.0260.ph, %scalar.ph.preheader ]
  %.0259 = phi ptr [ %128, %scalar.ph ], [ %.0259.ph, %scalar.ph.preheader ]
  %.1258 = phi ptr [ %130, %scalar.ph ], [ %.1258.ph, %scalar.ph.preheader ]
  %128 = getelementptr inbounds i8, ptr %.0259, i64 -8
  %129 = getelementptr inbounds i8, ptr %.0260, i64 -8
  %130 = getelementptr inbounds i8, ptr %.1258, i64 -8
  %131 = load double, ptr %128, align 8, !tbaa !15
  %132 = load double, ptr %129, align 8, !tbaa !15
  %133 = fadd double %131, %132
  store double %133, ptr %130, align 8, !tbaa !15
  %.not293 = icmp eq ptr %100, %130
  br i1 %.not293, label %.loopexit634, label %scalar.ph, !llvm.loop !43

.loopexit634:                                     ; preds = %scalar.ph, %middle.block
  %134 = icmp eq ptr %90, %100
  br i1 %134, label %197, label %.preheader336, !prof !34

.preheader336:                                    ; preds = %.loopexit634
  %135 = load ptr, ptr %3, align 16, !tbaa !30
  %136 = load ptr, ptr %94, align 8, !tbaa !32
  %137 = load ptr, ptr %95, align 8, !tbaa !29
  %138 = load ptr, ptr %96, align 8, !tbaa !29
  %139 = icmp ult ptr %137, %135
  br i1 %139, label %._crit_edge404, label %.lr.ph403, !unpredictable !36

._crit_edge404:                                   ; preds = %177, %.preheader336
  %.0269.lcssa = phi ptr [ %3, %.preheader336 ], [ %188, %177 ]
  %.0263.lcssa = phi i64 [ %98, %.preheader336 ], [ %178, %177 ]
  %.0261.lcssa = phi i64 [ %98, %.preheader336 ], [ %179, %177 ]
  %.1254.lcssa = phi ptr [ %.0253, %.preheader336 ], [ %180, %177 ]
  %.1250.lcssa = phi ptr [ %.0249, %.preheader336 ], [ %181, %177 ]
  %.lcssa360 = phi ptr [ %135, %.preheader336 ], [ %189, %177 ]
  %.lcssa356 = phi ptr [ %94, %.preheader336 ], [ %190, %177 ]
  %.lcssa352 = phi ptr [ %136, %.preheader336 ], [ %191, %177 ]
  %.lcssa348 = phi ptr [ %138, %.preheader336 ], [ %195, %177 ]
  %140 = icmp ult ptr %.lcssa348, %.lcssa352
  br i1 %140, label %141, label %152, !unpredictable !36

141:                                              ; preds = %._crit_edge404
  %142 = getelementptr inbounds i8, ptr %.lcssa360, i64 -8
  %143 = getelementptr inbounds i8, ptr %.lcssa352, i64 -8
  %144 = load i64, ptr %142, align 8, !tbaa !35
  %145 = load i64, ptr %143, align 8, !tbaa !35
  %.not294 = icmp ugt i64 %145, %144
  %146 = select i1 %.not294, ptr %.lcssa360, ptr %142
  store ptr %146, ptr %.0269.lcssa, align 8, !tbaa !30
  %147 = sub i64 0, %.0263.lcssa
  %.idx295 = select i1 %.not294, i64 0, i64 %147
  %148 = getelementptr inbounds double, ptr %.1254.lcssa, i64 %.idx295
  %.not296 = icmp ugt i64 %144, %145
  %149 = select i1 %.not296, ptr %.lcssa352, ptr %143
  store ptr %149, ptr %.lcssa356, align 8, !tbaa !32
  %150 = sub i64 0, %.0261.lcssa
  %.idx297 = select i1 %.not296, i64 0, i64 %150
  %151 = getelementptr inbounds double, ptr %.1250.lcssa, i64 %.idx297
  br label %.backedge

.backedge:                                        ; preds = %141, %152, %161
  %.0253.be = phi ptr [ %148, %141 ], [ %154, %152 ], [ %.1254401, %161 ]
  %.0249.be = phi ptr [ %151, %141 ], [ %.1250.lcssa, %152 ], [ %163, %161 ]
  br label %97

152:                                              ; preds = %._crit_edge404
  %153 = sub i64 0, %.0263.lcssa
  %154 = getelementptr inbounds double, ptr %.1254.lcssa, i64 %153
  %155 = getelementptr inbounds i8, ptr %.lcssa360, i64 -8
  store ptr %155, ptr %.0269.lcssa, align 8, !tbaa !30
  br label %.backedge

.lr.ph403:                                        ; preds = %.preheader336, %177
  %156 = phi ptr [ %195, %177 ], [ %138, %.preheader336 ]
  %157 = phi ptr [ %193, %177 ], [ %137, %.preheader336 ]
  %158 = phi ptr [ %191, %177 ], [ %136, %.preheader336 ]
  %159 = phi ptr [ %190, %177 ], [ %94, %.preheader336 ]
  %.1250402 = phi ptr [ %181, %177 ], [ %.0249, %.preheader336 ]
  %.1254401 = phi ptr [ %180, %177 ], [ %.0253, %.preheader336 ]
  %.0261400 = phi i64 [ %179, %177 ], [ %98, %.preheader336 ]
  %.0263399 = phi i64 [ %178, %177 ], [ %98, %.preheader336 ]
  %.0265398 = phi ptr [ %187, %177 ], [ %88, %.preheader336 ]
  %.0267397 = phi ptr [ %186, %177 ], [ %91, %.preheader336 ]
  %.0269396 = phi ptr [ %188, %177 ], [ %3, %.preheader336 ]
  %160 = icmp ult ptr %156, %158
  br i1 %160, label %161, label %165, !unpredictable !36

161:                                              ; preds = %.lr.ph403
  %162 = sub i64 0, %.0261400
  %163 = getelementptr inbounds double, ptr %.1250402, i64 %162
  %164 = getelementptr inbounds i8, ptr %158, i64 -8
  store ptr %164, ptr %159, align 8, !tbaa !32
  br label %.backedge

165:                                              ; preds = %.lr.ph403
  %166 = sub i64 0, %.0263399
  %167 = getelementptr inbounds double, ptr %.1254401, i64 %166
  %168 = sub i64 0, %.0261400
  %169 = getelementptr inbounds double, ptr %.1250402, i64 %168
  %170 = load i64, ptr %.0267397, align 8, !tbaa !27
  %171 = load i64, ptr %.0265398, align 8, !tbaa !27
  %172 = call noundef zeroext i1 @_ZN14NAMESPACE_MAINL15IsMultiplyErrorImEEbT_S1_(i64 noundef %.0263399, i64 noundef %170) #7
  br i1 %172, label %173, label %174

173:                                              ; preds = %165
  call void @LogAssertFailure(i64 noundef 647, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.63)
  call void @__assert_fail(ptr noundef nonnull @.str.64, ptr noundef nonnull @.str, i32 noundef 647, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

174:                                              ; preds = %165
  %175 = call noundef zeroext i1 @_ZN14NAMESPACE_MAINL15IsMultiplyErrorImEEbT_S1_(i64 noundef %.0261400, i64 noundef %171) #7
  br i1 %175, label %176, label %177

176:                                              ; preds = %174
  call void @LogAssertFailure(i64 noundef 650, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.65)
  call void @__assert_fail(ptr noundef nonnull @.str.66, ptr noundef nonnull @.str, i32 noundef 650, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

177:                                              ; preds = %174
  %178 = mul i64 %170, %.0263399
  %179 = mul i64 %171, %.0261400
  %180 = getelementptr inbounds double, ptr %167, i64 %178
  %181 = getelementptr inbounds double, ptr %169, i64 %179
  %182 = getelementptr i64, ptr %157, i64 %170
  %183 = getelementptr i8, ptr %182, i64 -8
  store ptr %183, ptr %.0269396, align 8, !tbaa !30
  %184 = getelementptr i64, ptr %156, i64 %171
  %185 = getelementptr i8, ptr %184, i64 -8
  store ptr %185, ptr %159, align 8, !tbaa !32
  %186 = getelementptr inbounds i8, ptr %.0267397, i64 24
  %187 = getelementptr inbounds i8, ptr %.0265398, i64 24
  %188 = getelementptr inbounds i8, ptr %.0269396, i64 24
  %189 = load ptr, ptr %188, align 8, !tbaa !30
  %190 = getelementptr inbounds i8, ptr %.0269396, i64 32
  %191 = load ptr, ptr %190, align 8, !tbaa !32
  %192 = getelementptr inbounds i8, ptr %.0267397, i64 32
  %193 = load ptr, ptr %192, align 8, !tbaa !29
  %194 = getelementptr inbounds i8, ptr %.0265398, i64 32
  %195 = load ptr, ptr %194, align 8, !tbaa !29
  %196 = icmp ult ptr %193, %189
  br i1 %196, label %._crit_edge404, label %.lr.ph403, !unpredictable !36

197:                                              ; preds = %.loopexit634
  %198 = load ptr, ptr %89, align 8, !tbaa !13
  %199 = icmp eq ptr %90, %198
  br i1 %199, label %201, label %200

200:                                              ; preds = %197
  call void @LogAssertFailure(i64 noundef 671, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.43)
  call void @__assert_fail(ptr noundef nonnull @.str.44, ptr noundef nonnull @.str, i32 noundef 671, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

201:                                              ; preds = %197
  %202 = getelementptr inbounds double, ptr %198, i64 %98
  %203 = icmp eq ptr %.0253, %202
  br i1 %203, label %205, label %204

204:                                              ; preds = %201
  call void @LogAssertFailure(i64 noundef 672, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.45)
  call void @__assert_fail(ptr noundef nonnull @.str.46, ptr noundef nonnull @.str, i32 noundef 672, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

205:                                              ; preds = %201
  %206 = load ptr, ptr %85, align 8, !tbaa !13
  %207 = getelementptr inbounds double, ptr %206, i64 %98
  %208 = icmp eq ptr %.0249, %207
  br i1 %208, label %.preheader, label %209

209:                                              ; preds = %205
  call void @LogAssertFailure(i64 noundef 673, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.67)
  call void @__assert_fail(ptr noundef nonnull @.str.68, ptr noundef nonnull @.str, i32 noundef 673, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

.preheader:                                       ; preds = %205, %.loopexit
  %.0239 = phi ptr [ %261, %.loopexit ], [ %3, %205 ]
  %.0237 = phi ptr [ %259, %.loopexit ], [ %91, %205 ]
  %.0235 = phi ptr [ %260, %.loopexit ], [ %88, %205 ]
  %.0233 = phi i64 [ %262, %.loopexit ], [ 0, %205 ]
  %210 = getelementptr inbounds i8, ptr %.0239, i64 16
  %211 = load i64, ptr %210, align 8, !tbaa !39
  %212 = load i64, ptr %.0237, align 8, !tbaa !27
  %213 = call noundef i32 @_ZN14NAMESPACE_MAIN6Tensor14SetCountSlicesEmm(ptr noundef nonnull align 8 dereferenceable(72) %0, i64 noundef %.0233, i64 noundef %211)
  %.not298 = icmp eq i32 %213, 0
  br i1 %.not298, label %214, label %.thread329, !prof !41

214:                                              ; preds = %.preheader
  %215 = getelementptr inbounds i8, ptr %.0237, i64 8
  %216 = load ptr, ptr %215, align 8, !tbaa !29
  %217 = getelementptr inbounds i8, ptr %.0235, i64 8
  %218 = load ptr, ptr %217, align 8, !tbaa !29
  %219 = getelementptr i64, ptr %216, i64 %211
  %220 = getelementptr i8, ptr %219, i64 -8
  %.not299414 = icmp ugt ptr %216, %220
  br i1 %.not299414, label %._crit_edge420, label %.lr.ph419

.lr.ph419:                                        ; preds = %214
  %221 = load i64, ptr %.0235, align 8, !tbaa !27
  %222 = getelementptr i64, ptr %218, i64 %221
  %223 = getelementptr i8, ptr %222, i64 -8
  %224 = getelementptr i64, ptr %216, i64 %212
  %225 = getelementptr i8, ptr %224, i64 -8
  %226 = ptrtoint ptr %218 to i64
  %227 = ptrtoint ptr %216 to i64
  br label %228

._crit_edge420:                                   ; preds = %214, %250
  call void @LogAssertFailure(i64 noundef 701, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.69)
  call void @__assert_fail(ptr noundef nonnull @.str.70, ptr noundef nonnull @.str, i32 noundef 701, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

228:                                              ; preds = %.lr.ph419, %250
  %.0228417 = phi ptr [ %220, %.lr.ph419 ], [ %258, %250 ]
  %.0229416 = phi ptr [ %223, %.lr.ph419 ], [ %256, %250 ]
  %.0230415 = phi ptr [ %225, %.lr.ph419 ], [ %255, %250 ]
  %.not300 = icmp ugt ptr %216, %.0230415
  br i1 %.not300, label %229, label %230

229:                                              ; preds = %228
  call void @LogAssertFailure(i64 noundef 702, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.71)
  call void @__assert_fail(ptr noundef nonnull @.str.72, ptr noundef nonnull @.str, i32 noundef 702, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

230:                                              ; preds = %228
  %.not301 = icmp ugt ptr %218, %.0229416
  br i1 %.not301, label %231, label %232

231:                                              ; preds = %230
  call void @LogAssertFailure(i64 noundef 703, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.73)
  call void @__assert_fail(ptr noundef nonnull @.str.74, ptr noundef nonnull @.str, i32 noundef 703, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

232:                                              ; preds = %230
  %.not302 = icmp ugt ptr %.0230415, %.0228417
  br i1 %.not302, label %233, label %234

233:                                              ; preds = %232
  call void @LogAssertFailure(i64 noundef 704, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.75)
  call void @__assert_fail(ptr noundef nonnull @.str.76, ptr noundef nonnull @.str, i32 noundef 704, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

234:                                              ; preds = %232
  %235 = ptrtoint ptr %.0229416 to i64
  %236 = sub i64 %235, %226
  %237 = ashr exact i64 %236, 3
  %238 = ptrtoint ptr %.0228417 to i64
  %239 = sub i64 %238, %227
  %240 = ashr exact i64 %239, 3
  %.not303 = icmp ugt i64 %237, %240
  br i1 %.not303, label %241, label %242

241:                                              ; preds = %234
  call void @LogAssertFailure(i64 noundef 706, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.77)
  call void @__assert_fail(ptr noundef nonnull @.str.78, ptr noundef nonnull @.str, i32 noundef 706, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

242:                                              ; preds = %234
  %243 = icmp eq ptr %.0228417, %.0230415
  br i1 %243, label %.loopexit, label %244, !prof !34

244:                                              ; preds = %242
  %245 = icmp eq i64 %240, %237
  br i1 %245, label %246, label %250, !prof !34

246:                                              ; preds = %244
  %247 = icmp ult ptr %216, %.0228417
  br i1 %247, label %249, label %248

248:                                              ; preds = %246
  call void @LogAssertFailure(i64 noundef 717, ptr noundef nonnull @.str, ptr noundef nonnull @__func__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_, ptr noundef nonnull @.str.79)
  call void @__assert_fail(ptr noundef nonnull @.str.80, ptr noundef nonnull @.str, i32 noundef 717, ptr noundef nonnull @__PRETTY_FUNCTION__._ZN14NAMESPACE_MAIN6Tensor3AddERKS0_) #8
  unreachable

249:                                              ; preds = %246
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %216, ptr align 8 %218, i64 %239, i1 false)
  br label %.loopexit

250:                                              ; preds = %244
  %251 = getelementptr inbounds i8, ptr %.0230415, i64 -8
  %252 = getelementptr inbounds i8, ptr %.0229416, i64 -8
  %253 = load i64, ptr %251, align 8, !tbaa !35
  %254 = load i64, ptr %252, align 8, !tbaa !35
  %.not304 = icmp ugt i64 %254, %253
  %255 = select i1 %.not304, ptr %.0230415, ptr %251, !unpredictable !36
  %.not305 = icmp ugt i64 %253, %254
  %256 = select i1 %.not305, ptr %.0229416, ptr %252, !unpredictable !36
  %257 = call i64 @llvm.umax.i64(i64 %253, i64 %254)
  %258 = getelementptr inbounds i8, ptr %.0228417, i64 -8
  store i64 %257, ptr %258, align 8, !tbaa !35
  %.not299 = icmp ugt ptr %216, %258
  br i1 %.not299, label %._crit_edge420, label %228, !llvm.loop !44

.loopexit:                                        ; preds = %242, %249
  %259 = getelementptr inbounds i8, ptr %.0237, i64 24
  %260 = getelementptr inbounds i8, ptr %.0235, i64 24
  %261 = getelementptr inbounds i8, ptr %.0239, i64 24
  %262 = add i64 %.0233, 1
  %263 = load i64, ptr %4, align 8, !tbaa !5
  %.not306 = icmp eq i64 %262, %263
  br i1 %.not306, label %.thread329, label %.preheader, !llvm.loop !45

.thread329:                                       ; preds = %.preheader, %.loopexit, %scalar.ph611, %middle.block610, %82
  %.4 = phi i32 [ %83, %82 ], [ 0, %middle.block610 ], [ 0, %scalar.ph611 ], [ %213, %.preheader ], [ 0, %.loopexit ]
  call void @llvm.lifetime.end.p0(i64 720, ptr nonnull %3) #7
  ret i32 %.4
}

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare i64 @llvm.umax.i64(i64, i64) #6

attributes #0 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #1 = { 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 #2 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #5 = { mustprogress nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #6 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #7 = { nounwind }
attributes #8 = { 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, !7, i64 24}
!6 = !{!"_ZTSN14NAMESPACE_MAIN6TensorE", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !10, i64 32, !11, i64 40, !8, i64 48}
!7 = !{!"long", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"any pointer", !8, i64 0}
!11 = !{!"bool", !8, i64 0}
!12 = !{!6, !7, i64 0}
!13 = !{!6, !10, i64 32}
!14 = !{!6, !7, i64 8}
!15 = !{!16, !16, i64 0}
!16 = !{!"double", !8, i64 0}
!17 = !{!18}
!18 = distinct !{!18, !19}
!19 = distinct !{!19, !"LVerDomain"}
!20 = !{!21}
!21 = distinct !{!21, !19}
!22 = distinct !{!22, !23, !24, !25}
!23 = !{!"llvm.loop.mustprogress"}
!24 = !{!"llvm.loop.isvectorized", i32 1}
!25 = !{!"llvm.loop.unroll.runtime.disable"}
!26 = distinct !{!26, !23, !24}
!27 = !{!28, !7, i64 0}
!28 = !{!"_ZTSN14NAMESPACE_MAIN6Tensor13DimensionInfoE", !7, i64 0, !10, i64 8, !7, i64 16}
!29 = !{!28, !10, i64 8}
!30 = !{!31, !10, i64 0}
!31 = !{!"_ZTSN14NAMESPACE_MAIN6Tensor18DimensionInfoStackE", !10, i64 0, !10, i64 8, !7, i64 16}
!32 = !{!31, !10, i64 8}
!33 = !{!"branch_weights", i32 1, i32 127}
!34 = !{!"branch_weights", !"expected", i32 1, i32 2000}
!35 = !{!7, !7, i64 0}
!36 = !{}
!37 = !{!"branch_weights", i32 127, i32 255873}
!38 = distinct !{!38, !23}
!39 = !{!31, !7, i64 16}
!40 = distinct !{!40, !23}
!41 = !{!"branch_weights", !"expected", i32 2000, i32 1}
!42 = distinct !{!42, !23, !24, !25}
!43 = distinct !{!43, !23, !24}
!44 = distinct !{!44, !23}
!45 = distinct !{!45, !23}


; Effective O3 passes: CorrelatedValuePropagationPass,EarlyCSEPass,GVNPass,GlobalDCEPass,GlobalOptPass,IPSCCPPass,InferAlignmentPass,InferFunctionAttrsPass,InstCombinePass,InstSimplifyPass,JumpThreadingPass,LCSSAPass,LICMPass,LoopLoadEliminationPass,LoopRotatePass,LoopSimplifyPass,LoopUnrollPass,LoopVectorizePass,LowerExpectIntrinsicPass,ReassociatePass,SROAPass,SimplifyCFGPass,TailCallElimPass