; LLVM IR from buresjan/optim_lbm :: nomad/src/Algos/Mads (NP1UniPollMethod)

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

%"class.NOMAD_4_3::Direction" = type { %"class.NOMAD_4_3::ArrayOfDouble" }
%"class.NOMAD_4_3::ArrayOfDouble" = type { ptr, i64, ptr }
%"class.NOMAD_4_3::Double" = type <{ ptr, double, i8, [7 x i8] }>
%"class.std::__cxx11::list" = type { %"class.std::__cxx11::_List_base" }
%"class.std::__cxx11::_List_base" = type { %"struct.std::__cxx11::_List_base<NOMAD_4_3::Direction, std::allocator<NOMAD_4_3::Direction>>::_List_impl" }
%"struct.std::__cxx11::_List_base<NOMAD_4_3::Direction, std::allocator<NOMAD_4_3::Direction>>::_List_impl" = type { %"struct.std::__detail::_List_node_header" }
%"struct.std::__detail::_List_node_header" = type { %"struct.std::__detail::_List_node_base", i64 }
%"struct.std::__detail::_List_node_base" = type { ptr, ptr }

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK9NOMAD_4_316NP1UniPollMethod26generateUnitPollDirectionsERNSt7__cxx114listINS_9DirectionESaIS3_EEEm(ptr noundef nonnull align 8 dereferenceable(496) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %2) unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca ptr, align 8
  %5 = alloca ptr, align 8
  %6 = alloca i64, align 8
  %7 = alloca %"class.NOMAD_4_3::Direction", align 8
  %8 = alloca %"class.NOMAD_4_3::Double", align 8
  %9 = alloca double, align 8
  %10 = alloca ptr, align 8
  %11 = alloca i32, align 4
  %12 = alloca ptr, align 8
  %13 = alloca %"class.std::__cxx11::list", align 8
  %14 = alloca i64, align 8
  %15 = alloca %"class.NOMAD_4_3::Direction", align 8
  %16 = alloca %"class.NOMAD_4_3::Double", align 8
  %17 = alloca double, align 8
  %18 = alloca %"class.NOMAD_4_3::Direction", align 8
  %19 = alloca %"class.NOMAD_4_3::Double", align 8
  %20 = alloca double, align 8
  %21 = alloca %"class.NOMAD_4_3::Direction", align 8
  %22 = alloca i64, align 8
  %23 = alloca %"class.NOMAD_4_3::Direction", align 8
  %24 = alloca %"class.NOMAD_4_3::ArrayOfDouble", align 8
  %25 = alloca %"class.NOMAD_4_3::Double", align 8
  %26 = alloca double, align 8
  %27 = alloca %"class.NOMAD_4_3::Double", align 8
  %28 = alloca double, align 8
  %29 = alloca i64, align 8
  %30 = alloca %"class.NOMAD_4_3::Direction", align 8
  %31 = alloca %"class.NOMAD_4_3::Double", align 8
  %32 = alloca double, align 8
  %33 = alloca %"class.NOMAD_4_3::Direction", align 8
  %34 = alloca %"class.NOMAD_4_3::ArrayOfDouble", align 8
  %35 = alloca %"class.NOMAD_4_3::Double", align 8
  %36 = alloca double, align 8
  store ptr %0, ptr %4, align 8, !tbaa !5
  store ptr %1, ptr %5, align 8, !tbaa !5
  store i64 %2, ptr %6, align 8, !tbaa !9
  %37 = load ptr, ptr %4, align 8
  %38 = load ptr, ptr %5, align 8, !tbaa !5
  call void @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE5clearEv(ptr noundef nonnull align 8 dereferenceable(24) %38) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr %7) #8
  %39 = load i64, ptr %6, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 24, ptr %8) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %9) #8
  store double 0.000000e+00, ptr %9, align 8, !tbaa !11
  call void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %8, ptr noundef nonnull align 8 dereferenceable(8) %9)
  invoke void @_ZN9NOMAD_4_39DirectionC2EmRKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %7, i64 noundef %39, ptr noundef nonnull align 8 dereferenceable(17) %8)
          to label %40 unwind label %55

40:                                               ; preds = %3
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %8) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %8) #8
  invoke void @_ZN9NOMAD_4_39Direction22computeDirOnUnitSphereERS0_(ptr noundef nonnull align 8 dereferenceable(24) %7)
          to label %41 unwind label %59

41:                                               ; preds = %40
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #8
  %42 = load i64, ptr %6, align 8, !tbaa !9
  %43 = mul i64 2, %42
  %44 = call { i64, i1 } @llvm.umul.with.overflow.i64(i64 %43, i64 8)
  %45 = extractvalue { i64, i1 } %44, 1
  %46 = extractvalue { i64, i1 } %44, 0
  %47 = select i1 %45, i64 -1, i64 %46
  %48 = invoke noalias noundef nonnull ptr @_Znam(i64 noundef %47) #9
          to label %49 unwind label %63

49:                                               ; preds = %41
  store ptr %48, ptr %12, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 24, ptr %13) #8
  call void @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #8
  store i64 0, ptr %14, align 8, !tbaa !9
  br label %50

50:                                               ; preds = %86, %49
  %51 = load i64, ptr %14, align 8, !tbaa !9
  %52 = load i64, ptr %6, align 8, !tbaa !9
  %53 = icmp ult i64 %51, %52
  br i1 %53, label %67, label %54

54:                                               ; preds = %50
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #8
  br label %118

55:                                               ; preds = %3
  %56 = landingpad { ptr, i32 }
          cleanup
  %57 = extractvalue { ptr, i32 } %56, 0
  store ptr %57, ptr %10, align 8
  %58 = extractvalue { ptr, i32 } %56, 1
  store i32 %58, ptr %11, align 4
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %8) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %9) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %8) #8
  br label %295

59:                                               ; preds = %40
  %60 = landingpad { ptr, i32 }
          cleanup
  %61 = extractvalue { ptr, i32 } %60, 0
  store ptr %61, ptr %10, align 8
  %62 = extractvalue { ptr, i32 } %60, 1
  store i32 %62, ptr %11, align 4
  br label %294

63:                                               ; preds = %41
  %64 = landingpad { ptr, i32 }
          cleanup
  %65 = extractvalue { ptr, i32 } %64, 0
  store ptr %65, ptr %10, align 8
  %66 = extractvalue { ptr, i32 } %64, 1
  store i32 %66, ptr %11, align 4
  br label %293

67:                                               ; preds = %50
  call void @llvm.lifetime.start.p0(i64 24, ptr %15) #8
  %68 = load i64, ptr %6, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 24, ptr %16) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #8
  store double 0.000000e+00, ptr %17, align 8, !tbaa !11
  invoke void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %16, ptr noundef nonnull align 8 dereferenceable(8) %17)
          to label %69 unwind label %89

69:                                               ; preds = %67
  invoke void @_ZN9NOMAD_4_39DirectionC2EmRKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %15, i64 noundef %68, ptr noundef nonnull align 8 dereferenceable(17) %16)
          to label %70 unwind label %93

70:                                               ; preds = %69
  invoke void @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE9push_backEOS2_(ptr noundef nonnull align 8 dereferenceable(24) %13, ptr noundef nonnull align 8 dereferenceable(24) %15)
          to label %71 unwind label %97

71:                                               ; preds = %70
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #8
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %16) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %16) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %15) #8
  %72 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #8
  %73 = load ptr, ptr %12, align 8, !tbaa !5
  %74 = load i64, ptr %14, align 8, !tbaa !9
  %75 = getelementptr inbounds ptr, ptr %73, i64 %74
  store ptr %72, ptr %75, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 24, ptr %18) #8
  %76 = load i64, ptr %6, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 24, ptr %19) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #8
  store double 0.000000e+00, ptr %20, align 8, !tbaa !11
  invoke void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %19, ptr noundef nonnull align 8 dereferenceable(8) %20)
          to label %77 unwind label %103

77:                                               ; preds = %71
  invoke void @_ZN9NOMAD_4_39DirectionC2EmRKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %18, i64 noundef %76, ptr noundef nonnull align 8 dereferenceable(17) %19)
          to label %78 unwind label %107

78:                                               ; preds = %77
  invoke void @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE9push_backEOS2_(ptr noundef nonnull align 8 dereferenceable(24) %13, ptr noundef nonnull align 8 dereferenceable(24) %18)
          to label %79 unwind label %111

79:                                               ; preds = %78
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %18) #8
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %19) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %19) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %18) #8
  %80 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %13) #8
  %81 = load ptr, ptr %12, align 8, !tbaa !5
  %82 = load i64, ptr %14, align 8, !tbaa !9
  %83 = load i64, ptr %6, align 8, !tbaa !9
  %84 = add i64 %82, %83
  %85 = getelementptr inbounds ptr, ptr %81, i64 %84
  store ptr %80, ptr %85, align 8, !tbaa !5
  br label %86

86:                                               ; preds = %79
  %87 = load i64, ptr %14, align 8, !tbaa !9
  %88 = add i64 %87, 1
  store i64 %88, ptr %14, align 8, !tbaa !9
  br label %50, !llvm.loop !13

89:                                               ; preds = %67
  %90 = landingpad { ptr, i32 }
          cleanup
  %91 = extractvalue { ptr, i32 } %90, 0
  store ptr %91, ptr %10, align 8
  %92 = extractvalue { ptr, i32 } %90, 1
  store i32 %92, ptr %11, align 4
  br label %102

93:                                               ; preds = %69
  %94 = landingpad { ptr, i32 }
          cleanup
  %95 = extractvalue { ptr, i32 } %94, 0
  store ptr %95, ptr %10, align 8
  %96 = extractvalue { ptr, i32 } %94, 1
  store i32 %96, ptr %11, align 4
  br label %101

97:                                               ; preds = %70
  %98 = landingpad { ptr, i32 }
          cleanup
  %99 = extractvalue { ptr, i32 } %98, 0
  store ptr %99, ptr %10, align 8
  %100 = extractvalue { ptr, i32 } %98, 1
  store i32 %100, ptr %11, align 4
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #8
  br label %101

101:                                              ; preds = %97, %93
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %16) #8
  br label %102

102:                                              ; preds = %101, %89
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %16) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %15) #8
  br label %117

103:                                              ; preds = %71
  %104 = landingpad { ptr, i32 }
          cleanup
  %105 = extractvalue { ptr, i32 } %104, 0
  store ptr %105, ptr %10, align 8
  %106 = extractvalue { ptr, i32 } %104, 1
  store i32 %106, ptr %11, align 4
  br label %116

107:                                              ; preds = %77
  %108 = landingpad { ptr, i32 }
          cleanup
  %109 = extractvalue { ptr, i32 } %108, 0
  store ptr %109, ptr %10, align 8
  %110 = extractvalue { ptr, i32 } %108, 1
  store i32 %110, ptr %11, align 4
  br label %115

111:                                              ; preds = %78
  %112 = landingpad { ptr, i32 }
          cleanup
  %113 = extractvalue { ptr, i32 } %112, 0
  store ptr %113, ptr %10, align 8
  %114 = extractvalue { ptr, i32 } %112, 1
  store i32 %114, ptr %11, align 4
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %18) #8
  br label %115

115:                                              ; preds = %111, %107
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %19) #8
  br label %116

116:                                              ; preds = %115, %103
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %19) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %18) #8
  br label %117

117:                                              ; preds = %116, %102
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #8
  br label %292

118:                                              ; preds = %54
  %119 = load ptr, ptr %12, align 8, !tbaa !5
  invoke void @_ZN9NOMAD_4_39Direction11householderERKS0_bPPS0_(ptr noundef nonnull align 8 dereferenceable(24) %7, i1 noundef zeroext true, ptr noundef %119)
          to label %120 unwind label %130

120:                                              ; preds = %118
  call void @llvm.lifetime.start.p0(i64 24, ptr %21) #8
  %121 = load ptr, ptr %12, align 8, !tbaa !5
  %122 = getelementptr inbounds ptr, ptr %121, i64 0
  %123 = load ptr, ptr %122, align 8, !tbaa !5
  invoke void @_ZN9NOMAD_4_39DirectionC2ERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %21, ptr noundef nonnull align 8 dereferenceable(24) %123)
          to label %124 unwind label %134

124:                                              ; preds = %120
  call void @llvm.lifetime.start.p0(i64 8, ptr %22) #8
  store i64 1, ptr %22, align 8, !tbaa !9
  br label %125

125:                                              ; preds = %147, %124
  %126 = load i64, ptr %22, align 8, !tbaa !9
  %127 = load i64, ptr %6, align 8, !tbaa !9
  %128 = icmp ult i64 %126, %127
  br i1 %128, label %138, label %129

129:                                              ; preds = %125
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #8
  br label %164

130:                                              ; preds = %118
  %131 = landingpad { ptr, i32 }
          cleanup
  %132 = extractvalue { ptr, i32 } %131, 0
  store ptr %132, ptr %10, align 8
  %133 = extractvalue { ptr, i32 } %131, 1
  store i32 %133, ptr %11, align 4
  br label %292

134:                                              ; preds = %120
  %135 = landingpad { ptr, i32 }
          cleanup
  %136 = extractvalue { ptr, i32 } %135, 0
  store ptr %136, ptr %10, align 8
  %137 = extractvalue { ptr, i32 } %135, 1
  store i32 %137, ptr %11, align 4
  br label %291

138:                                              ; preds = %125
  call void @llvm.lifetime.start.p0(i64 24, ptr %23) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr %24) #8
  %139 = load ptr, ptr %12, align 8, !tbaa !5
  %140 = load i64, ptr %22, align 8, !tbaa !9
  %141 = getelementptr inbounds ptr, ptr %139, i64 %140
  %142 = load ptr, ptr %141, align 8, !tbaa !5
  invoke void @_ZNK9NOMAD_4_313ArrayOfDoubleplERKS0_(ptr dead_on_unwind writable sret(%"class.NOMAD_4_3::ArrayOfDouble") align 8 %24, ptr noundef nonnull align 8 dereferenceable(24) %21, ptr noundef nonnull align 8 dereferenceable(24) %142)
          to label %143 unwind label %150

143:                                              ; preds = %138
  invoke void @_ZN9NOMAD_4_39DirectionC2ERKNS_13ArrayOfDoubleE(ptr noundef nonnull align 8 dereferenceable(24) %23, ptr noundef nonnull align 8 dereferenceable(24) %24)
          to label %144 unwind label %154

144:                                              ; preds = %143
  %145 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_39DirectionaSERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %21, ptr noundef nonnull align 8 dereferenceable(24) %23)
          to label %146 unwind label %158

146:                                              ; preds = %144
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #8
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %24) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %24) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %23) #8
  br label %147

147:                                              ; preds = %146
  %148 = load i64, ptr %22, align 8, !tbaa !9
  %149 = add i64 %148, 1
  store i64 %149, ptr %22, align 8, !tbaa !9
  br label %125, !llvm.loop !15

150:                                              ; preds = %138
  %151 = landingpad { ptr, i32 }
          cleanup
  %152 = extractvalue { ptr, i32 } %151, 0
  store ptr %152, ptr %10, align 8
  %153 = extractvalue { ptr, i32 } %151, 1
  store i32 %153, ptr %11, align 4
  br label %163

154:                                              ; preds = %143
  %155 = landingpad { ptr, i32 }
          cleanup
  %156 = extractvalue { ptr, i32 } %155, 0
  store ptr %156, ptr %10, align 8
  %157 = extractvalue { ptr, i32 } %155, 1
  store i32 %157, ptr %11, align 4
  br label %162

158:                                              ; preds = %144
  %159 = landingpad { ptr, i32 }
          cleanup
  %160 = extractvalue { ptr, i32 } %159, 0
  store ptr %160, ptr %10, align 8
  %161 = extractvalue { ptr, i32 } %159, 1
  store i32 %161, ptr %11, align 4
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %23) #8
  br label %162

162:                                              ; preds = %158, %154
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %24) #8
  br label %163

163:                                              ; preds = %162, %150
  call void @llvm.lifetime.end.p0(i64 24, ptr %24) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %23) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %22) #8
  br label %290

164:                                              ; preds = %129
  call void @llvm.lifetime.start.p0(i64 24, ptr %25) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #8
  %165 = load i64, ptr %6, align 8, !tbaa !9
  %166 = uitofp i64 %165 to double
  %167 = call double @sqrt(double noundef %166) #8
  %168 = fdiv double -1.000000e+00, %167
  store double %168, ptr %26, align 8, !tbaa !11
  invoke void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %25, ptr noundef nonnull align 8 dereferenceable(8) %26)
          to label %169 unwind label %191

169:                                              ; preds = %164
  %170 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_313ArrayOfDoublemLERKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %21, ptr noundef nonnull align 8 dereferenceable(17) %25)
          to label %171 unwind label %195

171:                                              ; preds = %169
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %25) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %25) #8
  %172 = load ptr, ptr %5, align 8, !tbaa !5
  invoke void @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE9push_backERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %172, ptr noundef nonnull align 8 dereferenceable(24) %21)
          to label %173 unwind label %200

173:                                              ; preds = %171
  call void @llvm.lifetime.start.p0(i64 24, ptr %27) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #8
  %174 = load i64, ptr %6, align 8, !tbaa !9
  %175 = uitofp i64 %174 to double
  %176 = fadd double %175, 1.000000e+00
  %177 = call double @sqrt(double noundef %176) #8
  %178 = fsub double %177, 1.000000e+00
  %179 = load i64, ptr %6, align 8, !tbaa !9
  %180 = uitofp i64 %179 to double
  %181 = call double @sqrt(double noundef %180) #8
  %182 = fdiv double %178, %181
  store double %182, ptr %28, align 8, !tbaa !11
  invoke void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %27, ptr noundef nonnull align 8 dereferenceable(8) %28)
          to label %183 unwind label %204

183:                                              ; preds = %173
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #8
  %184 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_313ArrayOfDoublemLERKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %21, ptr noundef nonnull align 8 dereferenceable(17) %27)
          to label %185 unwind label %208

185:                                              ; preds = %183
  call void @llvm.lifetime.start.p0(i64 8, ptr %29) #8
  store i64 0, ptr %29, align 8, !tbaa !9
  br label %186

186:                                              ; preds = %238, %185
  %187 = load i64, ptr %29, align 8, !tbaa !9
  %188 = load i64, ptr %6, align 8, !tbaa !9
  %189 = icmp ult i64 %187, %188
  br i1 %189, label %212, label %190

190:                                              ; preds = %186
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #8
  br label %283

191:                                              ; preds = %164
  %192 = landingpad { ptr, i32 }
          cleanup
  %193 = extractvalue { ptr, i32 } %192, 0
  store ptr %193, ptr %10, align 8
  %194 = extractvalue { ptr, i32 } %192, 1
  store i32 %194, ptr %11, align 4
  br label %199

195:                                              ; preds = %169
  %196 = landingpad { ptr, i32 }
          cleanup
  %197 = extractvalue { ptr, i32 } %196, 0
  store ptr %197, ptr %10, align 8
  %198 = extractvalue { ptr, i32 } %196, 1
  store i32 %198, ptr %11, align 4
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %25) #8
  br label %199

199:                                              ; preds = %195, %191
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %25) #8
  br label %290

200:                                              ; preds = %171
  %201 = landingpad { ptr, i32 }
          cleanup
  %202 = extractvalue { ptr, i32 } %201, 0
  store ptr %202, ptr %10, align 8
  %203 = extractvalue { ptr, i32 } %201, 1
  store i32 %203, ptr %11, align 4
  br label %290

204:                                              ; preds = %173
  %205 = landingpad { ptr, i32 }
          cleanup
  %206 = extractvalue { ptr, i32 } %205, 0
  store ptr %206, ptr %10, align 8
  %207 = extractvalue { ptr, i32 } %205, 1
  store i32 %207, ptr %11, align 4
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #8
  br label %289

208:                                              ; preds = %183
  %209 = landingpad { ptr, i32 }
          cleanup
  %210 = extractvalue { ptr, i32 } %209, 0
  store ptr %210, ptr %10, align 8
  %211 = extractvalue { ptr, i32 } %209, 1
  store i32 %211, ptr %11, align 4
  br label %288

212:                                              ; preds = %186
  call void @llvm.lifetime.start.p0(i64 24, ptr %30) #8
  %213 = load ptr, ptr %12, align 8, !tbaa !5
  %214 = load i64, ptr %29, align 8, !tbaa !9
  %215 = getelementptr inbounds ptr, ptr %213, i64 %214
  %216 = load ptr, ptr %215, align 8, !tbaa !5
  invoke void @_ZN9NOMAD_4_39DirectionC2ERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %30, ptr noundef nonnull align 8 dereferenceable(24) %216)
          to label %217 unwind label %241

217:                                              ; preds = %212
  call void @llvm.lifetime.start.p0(i64 24, ptr %31) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #8
  %218 = load i64, ptr %6, align 8, !tbaa !9
  %219 = add i64 %218, 1
  %220 = uitofp i64 %219 to double
  %221 = call double @sqrt(double noundef %220) #8
  store double %221, ptr %32, align 8, !tbaa !11
  invoke void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %31, ptr noundef nonnull align 8 dereferenceable(8) %32)
          to label %222 unwind label %245

222:                                              ; preds = %217
  %223 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_313ArrayOfDoublemLERKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %30, ptr noundef nonnull align 8 dereferenceable(17) %31)
          to label %224 unwind label %249

224:                                              ; preds = %222
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %31) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %31) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr %33) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr %34) #8
  invoke void @_ZNK9NOMAD_4_313ArrayOfDoubleplERKS0_(ptr dead_on_unwind writable sret(%"class.NOMAD_4_3::ArrayOfDouble") align 8 %34, ptr noundef nonnull align 8 dereferenceable(24) %30, ptr noundef nonnull align 8 dereferenceable(24) %21)
          to label %225 unwind label %254

225:                                              ; preds = %224
  invoke void @_ZN9NOMAD_4_39DirectionC2ERKNS_13ArrayOfDoubleE(ptr noundef nonnull align 8 dereferenceable(24) %33, ptr noundef nonnull align 8 dereferenceable(24) %34)
          to label %226 unwind label %258

226:                                              ; preds = %225
  %227 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_39DirectionaSERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %30, ptr noundef nonnull align 8 dereferenceable(24) %33)
          to label %228 unwind label %262

228:                                              ; preds = %226
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %33) #8
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %34) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %34) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %33) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr %35) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr %36) #8
  %229 = load i64, ptr %6, align 8, !tbaa !9
  %230 = uitofp i64 %229 to double
  %231 = call double @sqrt(double noundef %230) #8
  %232 = fdiv double 1.000000e+00, %231
  store double %232, ptr %36, align 8, !tbaa !11
  invoke void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %35, ptr noundef nonnull align 8 dereferenceable(8) %36)
          to label %233 unwind label %268

233:                                              ; preds = %228
  %234 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_313ArrayOfDoublemLERKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %30, ptr noundef nonnull align 8 dereferenceable(17) %35)
          to label %235 unwind label %272

235:                                              ; preds = %233
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %35) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %36) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %35) #8
  %236 = load ptr, ptr %5, align 8, !tbaa !5
  invoke void @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE9push_backERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %236, ptr noundef nonnull align 8 dereferenceable(24) %30)
          to label %237 unwind label %277

237:                                              ; preds = %235
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %30) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %30) #8
  br label %238

238:                                              ; preds = %237
  %239 = load i64, ptr %29, align 8, !tbaa !9
  %240 = add i64 %239, 1
  store i64 %240, ptr %29, align 8, !tbaa !9
  br label %186, !llvm.loop !16

241:                                              ; preds = %212
  %242 = landingpad { ptr, i32 }
          cleanup
  %243 = extractvalue { ptr, i32 } %242, 0
  store ptr %243, ptr %10, align 8
  %244 = extractvalue { ptr, i32 } %242, 1
  store i32 %244, ptr %11, align 4
  br label %282

245:                                              ; preds = %217
  %246 = landingpad { ptr, i32 }
          cleanup
  %247 = extractvalue { ptr, i32 } %246, 0
  store ptr %247, ptr %10, align 8
  %248 = extractvalue { ptr, i32 } %246, 1
  store i32 %248, ptr %11, align 4
  br label %253

249:                                              ; preds = %222
  %250 = landingpad { ptr, i32 }
          cleanup
  %251 = extractvalue { ptr, i32 } %250, 0
  store ptr %251, ptr %10, align 8
  %252 = extractvalue { ptr, i32 } %250, 1
  store i32 %252, ptr %11, align 4
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %31) #8
  br label %253

253:                                              ; preds = %249, %245
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %31) #8
  br label %281

254:                                              ; preds = %224
  %255 = landingpad { ptr, i32 }
          cleanup
  %256 = extractvalue { ptr, i32 } %255, 0
  store ptr %256, ptr %10, align 8
  %257 = extractvalue { ptr, i32 } %255, 1
  store i32 %257, ptr %11, align 4
  br label %267

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

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

266:                                              ; preds = %262, %258
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %34) #8
  br label %267

267:                                              ; preds = %266, %254
  call void @llvm.lifetime.end.p0(i64 24, ptr %34) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %33) #8
  br label %281

268:                                              ; preds = %228
  %269 = landingpad { ptr, i32 }
          cleanup
  %270 = extractvalue { ptr, i32 } %269, 0
  store ptr %270, ptr %10, align 8
  %271 = extractvalue { ptr, i32 } %269, 1
  store i32 %271, ptr %11, align 4
  br label %276

272:                                              ; preds = %233
  %273 = landingpad { ptr, i32 }
          cleanup
  %274 = extractvalue { ptr, i32 } %273, 0
  store ptr %274, ptr %10, align 8
  %275 = extractvalue { ptr, i32 } %273, 1
  store i32 %275, ptr %11, align 4
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %35) #8
  br label %276

276:                                              ; preds = %272, %268
  call void @llvm.lifetime.end.p0(i64 8, ptr %36) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %35) #8
  br label %281

277:                                              ; preds = %235
  %278 = landingpad { ptr, i32 }
          cleanup
  %279 = extractvalue { ptr, i32 } %278, 0
  store ptr %279, ptr %10, align 8
  %280 = extractvalue { ptr, i32 } %278, 1
  store i32 %280, ptr %11, align 4
  br label %281

281:                                              ; preds = %277, %276, %267, %253
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %30) #8
  br label %282

282:                                              ; preds = %281, %241
  call void @llvm.lifetime.end.p0(i64 24, ptr %30) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %29) #8
  br label %288

283:                                              ; preds = %190
  %284 = load ptr, ptr %12, align 8, !tbaa !5
  %285 = icmp eq ptr %284, null
  br i1 %285, label %287, label %286

286:                                              ; preds = %283
  call void @_ZdaPv(ptr noundef %284) #10
  br label %287

287:                                              ; preds = %286, %283
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %27) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %27) #8
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %21) #8
  call void @_ZNSt7__cxx1110_List_baseIN9NOMAD_4_39DirectionESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %13) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #8
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %7) #8
  ret void

288:                                              ; preds = %282, %208
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %27) #8
  br label %289

289:                                              ; preds = %288, %204
  call void @llvm.lifetime.end.p0(i64 24, ptr %27) #8
  br label %290

290:                                              ; preds = %289, %200, %199, %163
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #8
  br label %291

291:                                              ; preds = %290, %134
  call void @llvm.lifetime.end.p0(i64 24, ptr %21) #8
  br label %292

292:                                              ; preds = %291, %130, %117
  call void @_ZNSt7__cxx1110_List_baseIN9NOMAD_4_39DirectionESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %13) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr %13) #8
  br label %293

293:                                              ; preds = %292, %63
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #8
  br label %294

294:                                              ; preds = %293, %59
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #8
  br label %295

295:                                              ; preds = %294, %55
  call void @llvm.lifetime.end.p0(i64 24, ptr %7) #8
  br label %296

296:                                              ; preds = %295
  %297 = load ptr, ptr %10, align 8
  %298 = load i32, ptr %11, align 4
  %299 = insertvalue { ptr, i32 } poison, ptr %297, 0
  %300 = insertvalue { ptr, i32 } %299, i32 %298, 1
  resume { ptr, i32 } %300
}

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

declare void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17), ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #3

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

; Function Attrs: nounwind
declare void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17)) unnamed_addr #4

declare void @_ZN9NOMAD_4_39Direction22computeDirOnUnitSphereERS0_(ptr noundef nonnull align 8 dereferenceable(24)) #3

; Function Attrs: nocallback nofree nosync nounwind speculatable willreturn memory(none)
declare { i64, i1 } @llvm.umul.with.overflow.i64(i64, i64) #5

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) #6

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

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

; Function Attrs: nounwind
declare void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #4

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

declare void @_ZN9NOMAD_4_39Direction11householderERKS0_bPPS0_(ptr noundef nonnull align 8 dereferenceable(24), i1 noundef zeroext, ptr noundef) #3

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

declare void @_ZNK9NOMAD_4_313ArrayOfDoubleplERKS0_(ptr dead_on_unwind writable sret(%"class.NOMAD_4_3::ArrayOfDouble") align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) #3

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

declare noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_39DirectionaSERKS0_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) #3

; Function Attrs: nounwind
declare void @_ZN9NOMAD_4_313ArrayOfDoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #4

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

declare noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_313ArrayOfDoublemLERKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(17)) #3

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

; Function Attrs: nobuiltin nounwind
declare void @_ZdaPv(ptr noundef) #7

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

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { 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 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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 #5 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #6 = { nobuiltin allocsize(0) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #7 = { nobuiltin 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 #8 = { nounwind }
attributes #9 = { builtin allocsize(0) }
attributes #10 = { builtin 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, !10, i64 0}
!10 = !{!"long", !7, i64 0}
!11 = !{!12, !12, i64 0}
!12 = !{!"double", !7, i64 0}
!13 = distinct !{!13, !14}
!14 = !{!"llvm.loop.mustprogress"}
!15 = distinct !{!15, !14}
!16 = distinct !{!16, !14}


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

%"class.NOMAD_4_3::Direction" = type { %"class.NOMAD_4_3::ArrayOfDouble" }
%"class.NOMAD_4_3::ArrayOfDouble" = type { ptr, i64, ptr }
%"class.NOMAD_4_3::Double" = type <{ ptr, double, i8, [7 x i8] }>
%"class.std::__cxx11::list" = type { %"class.std::__cxx11::_List_base" }
%"class.std::__cxx11::_List_base" = type { %"struct.std::__cxx11::_List_base<NOMAD_4_3::Direction, std::allocator<NOMAD_4_3::Direction>>::_List_impl" }
%"struct.std::__cxx11::_List_base<NOMAD_4_3::Direction, std::allocator<NOMAD_4_3::Direction>>::_List_impl" = type { %"struct.std::__detail::_List_node_header" }
%"struct.std::__detail::_List_node_header" = type { %"struct.std::__detail::_List_node_base", i64 }
%"struct.std::__detail::_List_node_base" = type { ptr, ptr }

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

declare i32 @__gxx_personality_v0(...)

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZNK9NOMAD_4_316NP1UniPollMethod26generateUnitPollDirectionsERNSt7__cxx114listINS_9DirectionESaIS3_EEEm(ptr nocapture noundef nonnull readnone align 8 dereferenceable(496) %0, ptr noundef nonnull align 8 dereferenceable(24) %1, i64 noundef %2) unnamed_addr #1 align 2 personality ptr @__gxx_personality_v0 {
  %4 = alloca %"class.NOMAD_4_3::Direction", align 8
  %5 = alloca %"class.NOMAD_4_3::Double", align 8
  %6 = alloca double, align 8
  %7 = alloca %"class.std::__cxx11::list", align 8
  %8 = alloca %"class.NOMAD_4_3::Direction", align 8
  %9 = alloca %"class.NOMAD_4_3::Double", align 8
  %10 = alloca double, align 8
  %11 = alloca %"class.NOMAD_4_3::Direction", align 8
  %12 = alloca %"class.NOMAD_4_3::Double", align 8
  %13 = alloca double, align 8
  %14 = alloca %"class.NOMAD_4_3::Direction", align 8
  %15 = alloca %"class.NOMAD_4_3::Direction", align 8
  %16 = alloca %"class.NOMAD_4_3::ArrayOfDouble", align 8
  %17 = alloca %"class.NOMAD_4_3::Double", align 8
  %18 = alloca double, align 8
  %19 = alloca %"class.NOMAD_4_3::Double", align 8
  %20 = alloca double, align 8
  %21 = alloca %"class.NOMAD_4_3::Direction", align 8
  %22 = alloca %"class.NOMAD_4_3::Double", align 8
  %23 = alloca double, align 8
  %24 = alloca %"class.NOMAD_4_3::Direction", align 8
  %25 = alloca %"class.NOMAD_4_3::ArrayOfDouble", align 8
  %26 = alloca %"class.NOMAD_4_3::Double", align 8
  %27 = alloca double, align 8
  tail call void @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE5clearEv(ptr noundef nonnull align 8 dereferenceable(24) %1) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %4) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %5) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %6) #8
  store double 0.000000e+00, ptr %6, align 8, !tbaa !5
  call void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %5, ptr noundef nonnull align 8 dereferenceable(8) %6)
  invoke void @_ZN9NOMAD_4_39DirectionC2EmRKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %4, i64 noundef %2, ptr noundef nonnull align 8 dereferenceable(17) %5)
          to label %28 unwind label %35

28:                                               ; preds = %3
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %5) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #8
  invoke void @_ZN9NOMAD_4_39Direction22computeDirOnUnitSphereERS0_(ptr noundef nonnull align 8 dereferenceable(24) %4)
          to label %29 unwind label %37

29:                                               ; preds = %28
  %30 = and i64 %2, 8070450532247928832
  %.not = icmp eq i64 %30, 0
  %31 = shl i64 %2, 4
  %32 = select i1 %.not, i64 %31, i64 -1
  %33 = invoke noalias noundef nonnull ptr @_Znam(i64 noundef %32) #9
          to label %34 unwind label %39

34:                                               ; preds = %29
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %7) #8
  call void @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EEC2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #8
  %.not103 = icmp eq i64 %2, 0
  br i1 %.not103, label %._crit_edge, label %.lr.ph

._crit_edge:                                      ; preds = %48, %34
  invoke void @_ZN9NOMAD_4_39Direction11householderERKS0_bPPS0_(ptr noundef nonnull align 8 dereferenceable(24) %4, i1 noundef zeroext true, ptr noundef nonnull %33)
          to label %68 unwind label %73

35:                                               ; preds = %3
  %36 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %5) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %6) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %5) #8
  br label %161

37:                                               ; preds = %28
  %38 = landingpad { ptr, i32 }
          cleanup
  br label %160

39:                                               ; preds = %29
  %40 = landingpad { ptr, i32 }
          cleanup
  br label %160

.lr.ph:                                           ; preds = %34, %48
  %.03696 = phi i64 [ %51, %48 ], [ 0, %34 ]
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %8) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %9) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %10) #8
  store double 0.000000e+00, ptr %10, align 8, !tbaa !5
  invoke void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %9, ptr noundef nonnull align 8 dereferenceable(8) %10)
          to label %41 unwind label %52

41:                                               ; preds = %.lr.ph
  invoke void @_ZN9NOMAD_4_39DirectionC2EmRKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %8, i64 noundef %2, ptr noundef nonnull align 8 dereferenceable(17) %9)
          to label %42 unwind label %54

42:                                               ; preds = %41
  invoke void @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE9push_backEOS2_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(24) %8)
          to label %43 unwind label %56

43:                                               ; preds = %42
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #8
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %9) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #8
  %44 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #8
  %45 = getelementptr inbounds ptr, ptr %33, i64 %.03696
  store ptr %44, ptr %45, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %11) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %12) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %13) #8
  store double 0.000000e+00, ptr %13, align 8, !tbaa !5
  invoke void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %12, ptr noundef nonnull align 8 dereferenceable(8) %13)
          to label %46 unwind label %60

46:                                               ; preds = %43
  invoke void @_ZN9NOMAD_4_39DirectionC2EmRKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %11, i64 noundef %2, ptr noundef nonnull align 8 dereferenceable(17) %12)
          to label %47 unwind label %62

47:                                               ; preds = %46
  invoke void @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE9push_backEOS2_(ptr noundef nonnull align 8 dereferenceable(24) %7, ptr noundef nonnull align 8 dereferenceable(24) %11)
          to label %48 unwind label %64

48:                                               ; preds = %47
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %11) #8
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %12) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %12) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %11) #8
  %49 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE4backEv(ptr noundef nonnull align 8 dereferenceable(24) %7) #8
  %50 = getelementptr ptr, ptr %45, i64 %2
  store ptr %49, ptr %50, align 8, !tbaa !9
  %51 = add nuw i64 %.03696, 1
  %exitcond.not = icmp eq i64 %51, %2
  br i1 %exitcond.not, label %._crit_edge, label %.lr.ph, !llvm.loop !11

52:                                               ; preds = %.lr.ph
  %53 = landingpad { ptr, i32 }
          cleanup
  br label %59

54:                                               ; preds = %41
  %55 = landingpad { ptr, i32 }
          cleanup
  br label %58

56:                                               ; preds = %42
  %57 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %8) #8
  br label %58

58:                                               ; preds = %56, %54
  %.pn80 = phi { ptr, i32 } [ %57, %56 ], [ %55, %54 ]
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %9) #8
  br label %59

59:                                               ; preds = %58, %52
  %.pn80.pn = phi { ptr, i32 } [ %.pn80, %58 ], [ %53, %52 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %10) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %9) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %8) #8
  br label %159

60:                                               ; preds = %43
  %61 = landingpad { ptr, i32 }
          cleanup
  br label %67

62:                                               ; preds = %46
  %63 = landingpad { ptr, i32 }
          cleanup
  br label %66

64:                                               ; preds = %47
  %65 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %11) #8
  br label %66

66:                                               ; preds = %64, %62
  %.pn83 = phi { ptr, i32 } [ %65, %64 ], [ %63, %62 ]
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %12) #8
  br label %67

67:                                               ; preds = %66, %60
  %.pn83.pn = phi { ptr, i32 } [ %.pn83, %66 ], [ %61, %60 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %13) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %12) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %11) #8
  br label %159

68:                                               ; preds = %._crit_edge
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %14) #8
  %69 = load ptr, ptr %33, align 8, !tbaa !9
  invoke void @_ZN9NOMAD_4_39DirectionC2ERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %14, ptr noundef nonnull align 8 dereferenceable(24) %69)
          to label %.preheader95 unwind label %75

.preheader95:                                     ; preds = %68
  %70 = icmp ugt i64 %2, 1
  br i1 %70, label %.lr.ph98, label %._crit_edge99

._crit_edge99:                                    ; preds = %82, %.preheader95
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %17) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %18) #8
  %71 = uitofp i64 %2 to double
  %sqrt = call double @llvm.sqrt.f64(double %71)
  %72 = fdiv double -1.000000e+00, %sqrt
  store double %72, ptr %18, align 8, !tbaa !5
  invoke void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %17, ptr noundef nonnull align 8 dereferenceable(8) %18)
          to label %92 unwind label %104

73:                                               ; preds = %._crit_edge
  %74 = landingpad { ptr, i32 }
          cleanup
  br label %159

75:                                               ; preds = %68
  %76 = landingpad { ptr, i32 }
          cleanup
  br label %158

.lr.ph98:                                         ; preds = %.preheader95, %82
  %.03597 = phi i64 [ %83, %82 ], [ 1, %.preheader95 ]
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %15) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %16) #8
  %77 = getelementptr inbounds ptr, ptr %33, i64 %.03597
  %78 = load ptr, ptr %77, align 8, !tbaa !9
  invoke void @_ZNK9NOMAD_4_313ArrayOfDoubleplERKS0_(ptr dead_on_unwind nonnull writable sret(%"class.NOMAD_4_3::ArrayOfDouble") align 8 %16, ptr noundef nonnull align 8 dereferenceable(24) %14, ptr noundef nonnull align 8 dereferenceable(24) %78)
          to label %79 unwind label %84

79:                                               ; preds = %.lr.ph98
  invoke void @_ZN9NOMAD_4_39DirectionC2ERKNS_13ArrayOfDoubleE(ptr noundef nonnull align 8 dereferenceable(24) %15, ptr noundef nonnull align 8 dereferenceable(24) %16)
          to label %80 unwind label %86

80:                                               ; preds = %79
  %81 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_39DirectionaSERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %14, ptr noundef nonnull align 8 dereferenceable(24) %15)
          to label %82 unwind label %88

82:                                               ; preds = %80
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #8
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %16) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %16) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %15) #8
  %83 = add nuw i64 %.03597, 1
  %exitcond105.not = icmp eq i64 %83, %2
  br i1 %exitcond105.not, label %._crit_edge99, label %.lr.ph98, !llvm.loop !13

84:                                               ; preds = %.lr.ph98
  %85 = landingpad { ptr, i32 }
          cleanup
  br label %91

86:                                               ; preds = %79
  %87 = landingpad { ptr, i32 }
          cleanup
  br label %90

88:                                               ; preds = %80
  %89 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %15) #8
  br label %90

90:                                               ; preds = %88, %86
  %.pn75 = phi { ptr, i32 } [ %89, %88 ], [ %87, %86 ]
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %16) #8
  br label %91

91:                                               ; preds = %90, %84
  %.pn75.pn = phi { ptr, i32 } [ %.pn75, %90 ], [ %85, %84 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %16) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %15) #8
  br label %157

92:                                               ; preds = %._crit_edge99
  %93 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_313ArrayOfDoublemLERKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %14, ptr noundef nonnull align 8 dereferenceable(17) %17)
          to label %94 unwind label %106

94:                                               ; preds = %92
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %17) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %18) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %17) #8
  invoke void @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE9push_backERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(24) %14)
          to label %95 unwind label %109

95:                                               ; preds = %94
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %19) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %20) #8
  %96 = fadd double %71, 1.000000e+00
  %sqrt92 = call double @llvm.sqrt.f64(double %96)
  %97 = fadd double %sqrt92, -1.000000e+00
  %98 = fdiv double %97, %sqrt
  store double %98, ptr %20, align 8, !tbaa !5
  invoke void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %19, ptr noundef nonnull align 8 dereferenceable(8) %20)
          to label %99 unwind label %111

99:                                               ; preds = %95
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %20) #8
  %100 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_313ArrayOfDoublemLERKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %14, ptr noundef nonnull align 8 dereferenceable(17) %19)
          to label %.preheader unwind label %113

.preheader:                                       ; preds = %99
  br i1 %.not103, label %._crit_edge102, label %.lr.ph101

.lr.ph101:                                        ; preds = %.preheader
  %101 = add i64 %2, 1
  %102 = uitofp i64 %101 to double
  %sqrt93 = call double @llvm.sqrt.f64(double %102)
  %103 = fdiv double 1.000000e+00, %sqrt
  br label %115

104:                                              ; preds = %._crit_edge99
  %105 = landingpad { ptr, i32 }
          cleanup
  br label %108

106:                                              ; preds = %92
  %107 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %17) #8
  br label %108

108:                                              ; preds = %106, %104
  %.pn = phi { ptr, i32 } [ %107, %106 ], [ %105, %104 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %18) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %17) #8
  br label %157

109:                                              ; preds = %94
  %110 = landingpad { ptr, i32 }
          cleanup
  br label %157

111:                                              ; preds = %95
  %112 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %20) #8
  br label %156

113:                                              ; preds = %99
  %114 = landingpad { ptr, i32 }
          cleanup
  br label %155

115:                                              ; preds = %.lr.ph101, %129
  %.0100 = phi i64 [ 0, %.lr.ph101 ], [ %130, %129 ]
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %21) #8
  %116 = getelementptr inbounds ptr, ptr %33, i64 %.0100
  %117 = load ptr, ptr %116, align 8, !tbaa !9
  invoke void @_ZN9NOMAD_4_39DirectionC2ERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %21, ptr noundef nonnull align 8 dereferenceable(24) %117)
          to label %118 unwind label %131

118:                                              ; preds = %115
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %22) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %23) #8
  store double %sqrt93, ptr %23, align 8, !tbaa !5
  invoke void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %22, ptr noundef nonnull align 8 dereferenceable(8) %23)
          to label %119 unwind label %133

119:                                              ; preds = %118
  %120 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_313ArrayOfDoublemLERKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %21, ptr noundef nonnull align 8 dereferenceable(17) %22)
          to label %121 unwind label %135

121:                                              ; preds = %119
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %22) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %23) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %22) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %24) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %25) #8
  invoke void @_ZNK9NOMAD_4_313ArrayOfDoubleplERKS0_(ptr dead_on_unwind nonnull writable sret(%"class.NOMAD_4_3::ArrayOfDouble") align 8 %25, ptr noundef nonnull align 8 dereferenceable(24) %21, ptr noundef nonnull align 8 dereferenceable(24) %14)
          to label %122 unwind label %138

122:                                              ; preds = %121
  invoke void @_ZN9NOMAD_4_39DirectionC2ERKNS_13ArrayOfDoubleE(ptr noundef nonnull align 8 dereferenceable(24) %24, ptr noundef nonnull align 8 dereferenceable(24) %25)
          to label %123 unwind label %140

123:                                              ; preds = %122
  %124 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_39DirectionaSERKS0_(ptr noundef nonnull align 8 dereferenceable(24) %21, ptr noundef nonnull align 8 dereferenceable(24) %24)
          to label %125 unwind label %142

125:                                              ; preds = %123
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %24) #8
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %25) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %25) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %24) #8
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %26) #8
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %27) #8
  store double %103, ptr %27, align 8, !tbaa !5
  invoke void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17) %26, ptr noundef nonnull align 8 dereferenceable(8) %27)
          to label %126 unwind label %146

126:                                              ; preds = %125
  %127 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_313ArrayOfDoublemLERKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24) %21, ptr noundef nonnull align 8 dereferenceable(17) %26)
          to label %128 unwind label %148

128:                                              ; preds = %126
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %26) #8
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %27) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %26) #8
  invoke void @_ZNSt7__cxx114listIN9NOMAD_4_39DirectionESaIS2_EE9push_backERKS2_(ptr noundef nonnull align 8 dereferenceable(24) %1, ptr noundef nonnull align 8 dereferenceable(24) %21)
          to label %129 unwind label %151

129:                                              ; preds = %128
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %21) #8
  %130 = add nuw i64 %.0100, 1
  %exitcond106.not = icmp eq i64 %130, %2
  br i1 %exitcond106.not, label %._crit_edge102, label %115, !llvm.loop !14

131:                                              ; preds = %115
  %132 = landingpad { ptr, i32 }
          cleanup
  br label %154

133:                                              ; preds = %118
  %134 = landingpad { ptr, i32 }
          cleanup
  br label %137

135:                                              ; preds = %119
  %136 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %22) #8
  br label %137

137:                                              ; preds = %135, %133
  %.pn63 = phi { ptr, i32 } [ %136, %135 ], [ %134, %133 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %23) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %22) #8
  br label %153

138:                                              ; preds = %121
  %139 = landingpad { ptr, i32 }
          cleanup
  br label %145

140:                                              ; preds = %122
  %141 = landingpad { ptr, i32 }
          cleanup
  br label %144

142:                                              ; preds = %123
  %143 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %24) #8
  br label %144

144:                                              ; preds = %142, %140
  %.pn65 = phi { ptr, i32 } [ %143, %142 ], [ %141, %140 ]
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(24) %25) #8
  br label %145

145:                                              ; preds = %144, %138
  %.pn65.pn = phi { ptr, i32 } [ %.pn65, %144 ], [ %139, %138 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %25) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %24) #8
  br label %153

146:                                              ; preds = %125
  %147 = landingpad { ptr, i32 }
          cleanup
  br label %150

148:                                              ; preds = %126
  %149 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %26) #8
  br label %150

150:                                              ; preds = %148, %146
  %.pn68 = phi { ptr, i32 } [ %149, %148 ], [ %147, %146 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %27) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %26) #8
  br label %153

151:                                              ; preds = %128
  %152 = landingpad { ptr, i32 }
          cleanup
  br label %153

153:                                              ; preds = %151, %150, %145, %137
  %.pn70 = phi { ptr, i32 } [ %152, %151 ], [ %.pn68, %150 ], [ %.pn65.pn, %145 ], [ %.pn63, %137 ]
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %21) #8
  br label %154

154:                                              ; preds = %153, %131
  %.pn70.pn = phi { ptr, i32 } [ %.pn70, %153 ], [ %132, %131 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %21) #8
  br label %155

._crit_edge102:                                   ; preds = %129, %.preheader
  call void @_ZdaPv(ptr noundef nonnull %33) #10
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %19) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %19) #8
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %14) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %14) #8
  call void @_ZNSt7__cxx1110_List_baseIN9NOMAD_4_39DirectionESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #8
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #8
  ret void

155:                                              ; preds = %154, %113
  %.pn70.pn.pn = phi { ptr, i32 } [ %.pn70.pn, %154 ], [ %114, %113 ]
  call void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17) %19) #8
  br label %156

156:                                              ; preds = %155, %111
  %.pn70.pn.pn.pn = phi { ptr, i32 } [ %.pn70.pn.pn, %155 ], [ %112, %111 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %19) #8
  br label %157

157:                                              ; preds = %156, %109, %108, %91
  %.pn75.pn.pn = phi { ptr, i32 } [ %.pn75.pn, %91 ], [ %.pn70.pn.pn.pn, %156 ], [ %110, %109 ], [ %.pn, %108 ]
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %14) #8
  br label %158

158:                                              ; preds = %157, %75
  %.pn75.pn.pn.pn = phi { ptr, i32 } [ %.pn75.pn.pn, %157 ], [ %76, %75 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %14) #8
  br label %159

159:                                              ; preds = %59, %67, %158, %73
  %.pn83.pn.pn.pn = phi { ptr, i32 } [ %.pn75.pn.pn.pn, %158 ], [ %74, %73 ], [ %.pn83.pn, %67 ], [ %.pn80.pn, %59 ]
  call void @_ZNSt7__cxx1110_List_baseIN9NOMAD_4_39DirectionESaIS2_EED2Ev(ptr noundef nonnull align 8 dereferenceable(24) %7) #8
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %7) #8
  br label %160

160:                                              ; preds = %39, %159, %37
  %.pn83.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %38, %37 ], [ %.pn83.pn.pn.pn, %159 ], [ %40, %39 ]
  call void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24) %4) #8
  br label %161

161:                                              ; preds = %160, %35
  %.pn83.pn.pn.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn83.pn.pn.pn.pn.pn, %160 ], [ %36, %35 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %4) #8
  resume { ptr, i32 } %.pn83.pn.pn.pn.pn.pn.pn
}

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

declare void @_ZN9NOMAD_4_36DoubleC1ERKd(ptr noundef nonnull align 8 dereferenceable(17), ptr noundef nonnull align 8 dereferenceable(8)) unnamed_addr #3

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

; Function Attrs: nounwind
declare void @_ZN9NOMAD_4_36DoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(17)) unnamed_addr #4

declare void @_ZN9NOMAD_4_39Direction22computeDirOnUnitSphereERS0_(ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #3

; Function Attrs: nobuiltin allocsize(0)
declare noundef nonnull ptr @_Znam(i64 noundef) local_unnamed_addr #5

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

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

; Function Attrs: nounwind
declare void @_ZN9NOMAD_4_313ArrayOfDoubleD2Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #4

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

declare void @_ZN9NOMAD_4_39Direction11householderERKS0_bPPS0_(ptr noundef nonnull align 8 dereferenceable(24), i1 noundef zeroext, ptr noundef) local_unnamed_addr #3

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

declare void @_ZNK9NOMAD_4_313ArrayOfDoubleplERKS0_(ptr dead_on_unwind writable sret(%"class.NOMAD_4_3::ArrayOfDouble") align 8, ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #3

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

declare noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_39DirectionaSERKS0_(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(24)) local_unnamed_addr #3

; Function Attrs: nounwind
declare void @_ZN9NOMAD_4_313ArrayOfDoubleD1Ev(ptr noundef nonnull align 8 dereferenceable(24)) unnamed_addr #4

declare noundef nonnull align 8 dereferenceable(24) ptr @_ZN9NOMAD_4_313ArrayOfDoublemLERKNS_6DoubleE(ptr noundef nonnull align 8 dereferenceable(24), ptr noundef nonnull align 8 dereferenceable(17)) local_unnamed_addr #3

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

; Function Attrs: nobuiltin nounwind
declare void @_ZdaPv(ptr noundef) local_unnamed_addr #6

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

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

attributes #0 = { mustprogress nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { 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 #2 = { 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 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { 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 #5 = { nobuiltin allocsize(0) "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { nobuiltin 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 #7 = { nocallback nofree nosync nounwind speculatable willreturn memory(none) }
attributes #8 = { nounwind }
attributes #9 = { builtin allocsize(0) }
attributes #10 = { builtin 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 = !{!"double", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !10, i64 0}
!10 = !{!"any pointer", !7, i64 0}
!11 = distinct !{!11, !12}
!12 = !{!"llvm.loop.mustprogress"}
!13 = distinct !{!13, !12}
!14 = distinct !{!14, !12}


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