; LLVM IR from gem5/gem5 :: ext/mcpat/cacti/wire.ll (ZN4Wire10wire_modelEddPd)

; 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.TechnologyParameter = type { double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, i64, %"class.TechnologyParameter::DeviceType", %"class.TechnologyParameter::DeviceType", %"class.TechnologyParameter::DeviceType", %"class.TechnologyParameter::DeviceType", %"class.TechnologyParameter::DeviceType", %"class.TechnologyParameter::InterconnectType", %"class.TechnologyParameter::InterconnectType", %"class.TechnologyParameter::InterconnectType", %"class.TechnologyParameter::ScalingFactor", %"class.TechnologyParameter::MemoryType", %"class.TechnologyParameter::MemoryType", %"class.TechnologyParameter::MemoryType" }
%"class.TechnologyParameter::DeviceType" = type { double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double }
%"class.TechnologyParameter::InterconnectType" = type { double, double, double, double, double, double, double, double }
%"class.TechnologyParameter::ScalingFactor" = type { double, double, double }
%"class.TechnologyParameter::MemoryType" = type { double, double, double, double, double, double }
%class.powerDef = type { %class.powerComponents, %class.powerComponents, %class.powerComponents }
%class.powerComponents = type { double, double, double, double, double }
%class.Wire = type { %class.Component, i32, double, double, i32, double, double, double, double, double, i32, double, double, double, %"class.std::__cxx11::list", %class.Component, %class.Component, %class.Component, double, ptr }
%"class.std::__cxx11::list" = type { %"class.std::__cxx11::_List_base" }
%"class.std::__cxx11::_List_base" = type { %"struct.std::__cxx11::_List_base<Component, std::allocator<Component>>::_List_impl" }
%"struct.std::__cxx11::_List_base<Component, std::allocator<Component>>::_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 }
%class.Component = type { %class.Area, %class.powerDef, %class.powerDef, double, double }
%class.Area = type { double, double, double }

@g_tp = external global %class.TechnologyParameter, align 8

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

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

declare noundef double @_Z8drain_C_diiidbbb(double noundef, i32 noundef, i32 noundef, i32 noundef, double noundef, i1 noundef zeroext, i1 noundef zeroext, i1 noundef zeroext) #1

declare noundef double @_Z6gate_Cddbbb(double noundef, double noundef, i1 noundef zeroext, i1 noundef zeroext, i1 noundef zeroext) #1

declare noundef double @_Z7tr_R_ondiibbb(double noundef, i32 noundef, i32 noundef, i1 noundef zeroext, i1 noundef zeroext, i1 noundef zeroext) #1

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef double @_ZN4Wire8wire_capEdb(ptr noundef nonnull align 8 dereferenceable(1264), double noundef, i1 noundef zeroext) #2 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef double @_ZN4Wire8wire_resEd(ptr noundef nonnull align 8 dereferenceable(1264), double noundef) #2 align 2

declare noundef double @_Z21pmos_to_nmos_sz_ratiobb(i1 noundef zeroext, i1 noundef zeroext) #1

declare noundef double @_Z17cmos_Isub_leakageddi9Gate_typebbb17Half_net_topology(double noundef, double noundef, i32 noundef, i32 noundef, i1 noundef zeroext, i1 noundef zeroext, i1 noundef zeroext, i32 noundef) #1

declare noundef double @_Z15cmos_Ig_leakageddi9Gate_typebbb17Half_net_topology(double noundef, double noundef, i32 noundef, i32 noundef, i1 noundef zeroext, i1 noundef zeroext, i1 noundef zeroext, i32 noundef) #1

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN8powerDefC2Ev(ptr noundef nonnull align 8 dereferenceable(120)) unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN4Wire10wire_modelEddPd(ptr dead_on_unwind noalias writable sret(%class.powerDef) align 8 %0, ptr noundef nonnull align 8 dereferenceable(1264) %1, double noundef %2, double noundef %3, ptr noundef %4) #4 align 2 {
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca double, align 8
  %9 = alloca double, align 8
  %10 = alloca ptr, align 8
  %11 = alloca double, align 8
  %12 = alloca double, align 8
  %13 = alloca double, align 8
  %14 = alloca double, align 8
  %15 = alloca double, align 8
  %16 = alloca double, align 8
  %17 = alloca double, align 8
  %18 = alloca double, align 8
  %19 = alloca double, align 8
  %20 = alloca double, align 8
  store ptr %0, ptr %6, align 8
  store ptr %1, ptr %7, align 8, !tbaa !5
  store double %2, ptr %8, align 8, !tbaa !9
  store double %3, ptr %9, align 8, !tbaa !9
  store ptr %4, ptr %10, align 8, !tbaa !5
  %21 = load ptr, ptr %7, align 8
  call void @_ZN8powerDefC2Ev(ptr noundef nonnull align 8 dereferenceable(120) %0)
  call void @llvm.lifetime.start.p0(i64 8, ptr %11) #5
  store double 1.000000e+00, ptr %11, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %12) #5
  %22 = call noundef double @_Z21pmos_to_nmos_sz_ratiobb(i1 noundef zeroext false, i1 noundef zeroext false)
  store double %22, ptr %12, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %13) #5
  store double 0.000000e+00, ptr %13, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %14) #5
  store double 0.000000e+00, ptr %14, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %15) #5
  store double 0.000000e+00, ptr %15, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %16) #5
  %23 = load double, ptr getelementptr inbounds (%class.TechnologyParameter, ptr @g_tp, i32 0, i32 1), align 8, !tbaa !11
  %24 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 18
  %25 = load double, ptr %24, align 8, !tbaa !18
  %26 = fadd double %23, %25
  %27 = call noundef double @_Z6gate_Cddbbb(double noundef %26, double noundef 0.000000e+00, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false)
  store double %27, ptr %16, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %17) #5
  %28 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 18
  %29 = load double, ptr %28, align 8, !tbaa !18
  %30 = load double, ptr getelementptr inbounds (%class.TechnologyParameter, ptr @g_tp, i32 0, i32 39), align 8, !tbaa !32
  %31 = call noundef double @_Z8drain_C_diiidbbb(double noundef %29, i32 noundef 0, i32 noundef 1, i32 noundef 1, double noundef %30, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false)
  %32 = load double, ptr getelementptr inbounds (%class.TechnologyParameter, ptr @g_tp, i32 0, i32 1), align 8, !tbaa !11
  %33 = load double, ptr getelementptr inbounds (%class.TechnologyParameter, ptr @g_tp, i32 0, i32 39), align 8, !tbaa !32
  %34 = call noundef double @_Z8drain_C_diiidbbb(double noundef %32, i32 noundef 1, i32 noundef 1, i32 noundef 1, double noundef %33, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false)
  %35 = fadd double %31, %34
  store double %35, ptr %17, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %18) #5
  %36 = load double, ptr getelementptr inbounds (%class.TechnologyParameter, ptr @g_tp, i32 0, i32 1), align 8, !tbaa !11
  %37 = call noundef double @_Z7tr_R_ondiibbb(double noundef %36, i32 noundef 1, i32 noundef 1, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false)
  %38 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 18
  %39 = load double, ptr %38, align 8, !tbaa !18
  %40 = call noundef double @_Z7tr_R_ondiibbb(double noundef %39, i32 noundef 0, i32 noundef 1, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false)
  %41 = fadd double %37, %40
  %42 = fdiv double %41, 2.000000e+00
  store double %42, ptr %18, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %19) #5
  %43 = load double, ptr %11, align 8, !tbaa !9
  %44 = call noundef double @_ZN4Wire8wire_resEd(ptr noundef nonnull align 8 dereferenceable(1264) %21, double noundef %43)
  store double %44, ptr %19, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 8, ptr %20) #5
  %45 = load double, ptr %11, align 8, !tbaa !9
  %46 = call noundef double @_ZN4Wire8wire_capEdb(ptr noundef nonnull align 8 dereferenceable(1264) %21, double noundef %45, i1 noundef zeroext false)
  store double %46, ptr %20, align 8, !tbaa !9
  %47 = load double, ptr %8, align 8, !tbaa !9
  %48 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 6
  store double %47, ptr %48, align 8, !tbaa !33
  %49 = load double, ptr %9, align 8, !tbaa !9
  %50 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 5
  store double %49, ptr %50, align 8, !tbaa !34
  %51 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 5
  %52 = load double, ptr %51, align 8, !tbaa !34
  %53 = load double, ptr %16, align 8, !tbaa !9
  %54 = load double, ptr %17, align 8, !tbaa !9
  %55 = fadd double %53, %54
  %56 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 6
  %57 = load double, ptr %56, align 8, !tbaa !33
  %58 = load double, ptr %20, align 8, !tbaa !9
  %59 = load double, ptr %11, align 8, !tbaa !9
  %60 = fdiv double %58, %59
  %61 = fmul double %57, %60
  %62 = call double @llvm.fmuladd.f64(double %52, double %55, double %61)
  %63 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 19
  %64 = load ptr, ptr %63, align 8, !tbaa !35
  %65 = getelementptr inbounds %"class.TechnologyParameter::DeviceType", ptr %64, i32 0, i32 9
  %66 = load double, ptr %65, align 8, !tbaa !36
  %67 = fmul double %62, %66
  %68 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 19
  %69 = load ptr, ptr %68, align 8, !tbaa !35
  %70 = getelementptr inbounds %"class.TechnologyParameter::DeviceType", ptr %69, i32 0, i32 9
  %71 = load double, ptr %70, align 8, !tbaa !36
  %72 = fmul double %67, %71
  store double %72, ptr %13, align 8, !tbaa !9
  %73 = load double, ptr %18, align 8, !tbaa !9
  %74 = load double, ptr %16, align 8, !tbaa !9
  %75 = load double, ptr %17, align 8, !tbaa !9
  %76 = fadd double %74, %75
  %77 = load double, ptr %18, align 8, !tbaa !9
  %78 = load double, ptr %20, align 8, !tbaa !9
  %79 = fmul double %77, %78
  %80 = load double, ptr %11, align 8, !tbaa !9
  %81 = fdiv double %79, %80
  %82 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 6
  %83 = load double, ptr %82, align 8, !tbaa !33
  %84 = fmul double %81, %83
  %85 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 5
  %86 = load double, ptr %85, align 8, !tbaa !34
  %87 = fdiv double %84, %86
  %88 = call double @llvm.fmuladd.f64(double %73, double %76, double %87)
  %89 = load double, ptr %19, align 8, !tbaa !9
  %90 = load double, ptr %11, align 8, !tbaa !9
  %91 = fdiv double %89, %90
  %92 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 6
  %93 = load double, ptr %92, align 8, !tbaa !33
  %94 = fmul double %91, %93
  %95 = load double, ptr %17, align 8, !tbaa !9
  %96 = fmul double %94, %95
  %97 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 5
  %98 = load double, ptr %97, align 8, !tbaa !34
  %99 = call double @llvm.fmuladd.f64(double %96, double %98, double %88)
  %100 = load double, ptr %19, align 8, !tbaa !9
  %101 = load double, ptr %11, align 8, !tbaa !9
  %102 = fdiv double %100, %101
  %103 = fmul double 5.000000e-01, %102
  %104 = load double, ptr %20, align 8, !tbaa !9
  %105 = load double, ptr %11, align 8, !tbaa !9
  %106 = fdiv double %104, %105
  %107 = fmul double %103, %106
  %108 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 6
  %109 = load double, ptr %108, align 8, !tbaa !33
  %110 = fmul double %107, %109
  %111 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 6
  %112 = load double, ptr %111, align 8, !tbaa !33
  %113 = call double @llvm.fmuladd.f64(double %110, double %112, double %99)
  store double %113, ptr %15, align 8, !tbaa !9
  %114 = load double, ptr %15, align 8, !tbaa !9
  %115 = fmul double 6.930000e-01, %114
  %116 = load double, ptr %11, align 8, !tbaa !9
  %117 = fmul double %115, %116
  %118 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 6
  %119 = load double, ptr %118, align 8, !tbaa !33
  %120 = fdiv double %117, %119
  %121 = load ptr, ptr %10, align 8, !tbaa !5
  store double %120, ptr %121, align 8, !tbaa !9
  %122 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 19
  %123 = load ptr, ptr %122, align 8, !tbaa !35
  %124 = getelementptr inbounds %"class.TechnologyParameter::DeviceType", ptr %123, i32 0, i32 9
  %125 = load double, ptr %124, align 8, !tbaa !36
  %126 = load double, ptr getelementptr inbounds (%class.TechnologyParameter, ptr @g_tp, i32 0, i32 1), align 8, !tbaa !11
  %127 = fmul double %125, %126
  %128 = fmul double %127, 6.500000e-05
  %129 = fmul double %128, 1.098600e+00
  %130 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 5
  %131 = load double, ptr %130, align 8, !tbaa !34
  %132 = fmul double %129, %131
  %133 = load double, ptr %15, align 8, !tbaa !9
  %134 = fmul double %132, %133
  store double %134, ptr %14, align 8, !tbaa !9
  %135 = load double, ptr %11, align 8, !tbaa !9
  %136 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 6
  %137 = load double, ptr %136, align 8, !tbaa !33
  %138 = fdiv double %135, %137
  %139 = load double, ptr %13, align 8, !tbaa !9
  %140 = load double, ptr %14, align 8, !tbaa !9
  %141 = fadd double %139, %140
  %142 = fmul double %138, %141
  %143 = getelementptr inbounds %class.powerDef, ptr %0, i32 0, i32 0
  %144 = getelementptr inbounds %class.powerComponents, ptr %143, i32 0, i32 0
  store double %142, ptr %144, align 8, !tbaa !37
  %145 = load double, ptr %11, align 8, !tbaa !9
  %146 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 6
  %147 = load double, ptr %146, align 8, !tbaa !33
  %148 = fdiv double %145, %147
  %149 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 19
  %150 = load ptr, ptr %149, align 8, !tbaa !35
  %151 = getelementptr inbounds %"class.TechnologyParameter::DeviceType", ptr %150, i32 0, i32 9
  %152 = load double, ptr %151, align 8, !tbaa !36
  %153 = fmul double %148, %152
  %154 = load double, ptr getelementptr inbounds (%class.TechnologyParameter, ptr @g_tp, i32 0, i32 1), align 8, !tbaa !11
  %155 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 5
  %156 = load double, ptr %155, align 8, !tbaa !34
  %157 = fmul double %154, %156
  %158 = load double, ptr %12, align 8, !tbaa !9
  %159 = load double, ptr getelementptr inbounds (%class.TechnologyParameter, ptr @g_tp, i32 0, i32 1), align 8, !tbaa !11
  %160 = fmul double %158, %159
  %161 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 5
  %162 = load double, ptr %161, align 8, !tbaa !34
  %163 = fmul double %160, %162
  %164 = call noundef double @_Z17cmos_Isub_leakageddi9Gate_typebbb17Half_net_topology(double noundef %157, double noundef %163, i32 noundef 1, i32 noundef 2, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false, i32 noundef 1)
  %165 = fmul double %153, %164
  %166 = getelementptr inbounds %class.powerDef, ptr %0, i32 0, i32 0
  %167 = getelementptr inbounds %class.powerComponents, ptr %166, i32 0, i32 1
  store double %165, ptr %167, align 8, !tbaa !38
  %168 = load double, ptr %11, align 8, !tbaa !9
  %169 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 6
  %170 = load double, ptr %169, align 8, !tbaa !33
  %171 = fdiv double %168, %170
  %172 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 19
  %173 = load ptr, ptr %172, align 8, !tbaa !35
  %174 = getelementptr inbounds %"class.TechnologyParameter::DeviceType", ptr %173, i32 0, i32 9
  %175 = load double, ptr %174, align 8, !tbaa !36
  %176 = fmul double %171, %175
  %177 = load double, ptr getelementptr inbounds (%class.TechnologyParameter, ptr @g_tp, i32 0, i32 1), align 8, !tbaa !11
  %178 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 5
  %179 = load double, ptr %178, align 8, !tbaa !34
  %180 = fmul double %177, %179
  %181 = load double, ptr %12, align 8, !tbaa !9
  %182 = load double, ptr getelementptr inbounds (%class.TechnologyParameter, ptr @g_tp, i32 0, i32 1), align 8, !tbaa !11
  %183 = fmul double %181, %182
  %184 = getelementptr inbounds %class.Wire, ptr %21, i32 0, i32 5
  %185 = load double, ptr %184, align 8, !tbaa !34
  %186 = fmul double %183, %185
  %187 = call noundef double @_Z15cmos_Ig_leakageddi9Gate_typebbb17Half_net_topology(double noundef %180, double noundef %186, i32 noundef 1, i32 noundef 2, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false, i32 noundef 1)
  %188 = fmul double %176, %187
  %189 = getelementptr inbounds %class.powerDef, ptr %0, i32 0, i32 0
  %190 = getelementptr inbounds %class.powerComponents, ptr %189, i32 0, i32 2
  store double %188, ptr %190, align 8, !tbaa !39
  call void @llvm.lifetime.end.p0(i64 8, ptr %20) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %19) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %18) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %17) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %16) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %15) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %14) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %13) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %12) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr %11) #5
  ret void
}

attributes #0 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #2 = { 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 speculatable willreturn memory(none) }
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 = { 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 = !{!"double", !7, i64 0}
!11 = !{!12, !10, i64 8}
!12 = !{!"_ZTS19TechnologyParameter", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !10, i64 72, !10, i64 80, !10, i64 88, !10, i64 96, !10, i64 104, !10, i64 112, !10, i64 120, !10, i64 128, !10, i64 136, !10, i64 144, !10, i64 152, !10, i64 160, !10, i64 168, !10, i64 176, !10, i64 184, !10, i64 192, !10, i64 200, !10, i64 208, !10, i64 216, !10, i64 224, !10, i64 232, !10, i64 240, !10, i64 248, !10, i64 256, !10, i64 264, !10, i64 272, !10, i64 280, !10, i64 288, !10, i64 296, !10, i64 304, !10, i64 312, !10, i64 320, !10, i64 328, !10, i64 336, !10, i64 344, !13, i64 352, !14, i64 360, !14, i64 528, !14, i64 696, !14, i64 864, !14, i64 1032, !15, i64 1200, !15, i64 1264, !15, i64 1328, !16, i64 1392, !17, i64 1416, !17, i64 1464, !17, i64 1512}
!13 = !{!"long", !7, i64 0}
!14 = !{!"_ZTSN19TechnologyParameter10DeviceTypeE", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56, !10, i64 64, !10, i64 72, !10, i64 80, !10, i64 88, !10, i64 96, !10, i64 104, !10, i64 112, !10, i64 120, !10, i64 128, !10, i64 136, !10, i64 144, !10, i64 152, !10, i64 160}
!15 = !{!"_ZTSN19TechnologyParameter16InterconnectTypeE", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40, !10, i64 48, !10, i64 56}
!16 = !{!"_ZTSN19TechnologyParameter13ScalingFactorE", !10, i64 0, !10, i64 8, !10, i64 16}
!17 = !{!"_ZTSN19TechnologyParameter10MemoryTypeE", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32, !10, i64 40}
!18 = !{!19, !10, i64 1248}
!19 = !{!"_ZTS4Wire", !20, i64 0, !24, i64 280, !10, i64 288, !10, i64 296, !25, i64 304, !10, i64 312, !10, i64 320, !10, i64 328, !10, i64 336, !10, i64 344, !26, i64 352, !10, i64 360, !10, i64 368, !10, i64 376, !27, i64 384, !20, i64 408, !20, i64 688, !20, i64 968, !10, i64 1248, !6, i64 1256}
!20 = !{!"_ZTS9Component", !21, i64 0, !22, i64 24, !22, i64 144, !10, i64 264, !10, i64 272}
!21 = !{!"_ZTS4Area", !10, i64 0, !10, i64 8, !10, i64 16}
!22 = !{!"_ZTS8powerDef", !23, i64 0, !23, i64 40, !23, i64 80}
!23 = !{!"_ZTS15powerComponents", !10, i64 0, !10, i64 8, !10, i64 16, !10, i64 24, !10, i64 32}
!24 = !{!"_ZTS9Wire_type", !7, i64 0}
!25 = !{!"_ZTS14Wire_placement", !7, i64 0}
!26 = !{!"int", !7, i64 0}
!27 = !{!"_ZTSNSt7__cxx114listI9ComponentSaIS1_EEE", !28, i64 0}
!28 = !{!"_ZTSNSt7__cxx1110_List_baseI9ComponentSaIS1_EEE", !29, i64 0}
!29 = !{!"_ZTSNSt7__cxx1110_List_baseI9ComponentSaIS1_EE10_List_implE", !30, i64 0}
!30 = !{!"_ZTSNSt8__detail17_List_node_headerE", !31, i64 0, !13, i64 16}
!31 = !{!"_ZTSNSt8__detail15_List_node_baseE", !6, i64 0, !6, i64 8}
!32 = !{!12, !10, i64 312}
!33 = !{!19, !10, i64 320}
!34 = !{!19, !10, i64 312}
!35 = !{!19, !6, i64 1256}
!36 = !{!14, !10, i64 72}
!37 = !{!22, !10, i64 0}
!38 = !{!22, !10, i64 8}
!39 = !{!22, !10, i64 16}


; 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.TechnologyParameter = type { double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, i64, %"class.TechnologyParameter::DeviceType", %"class.TechnologyParameter::DeviceType", %"class.TechnologyParameter::DeviceType", %"class.TechnologyParameter::DeviceType", %"class.TechnologyParameter::DeviceType", %"class.TechnologyParameter::InterconnectType", %"class.TechnologyParameter::InterconnectType", %"class.TechnologyParameter::InterconnectType", %"class.TechnologyParameter::ScalingFactor", %"class.TechnologyParameter::MemoryType", %"class.TechnologyParameter::MemoryType", %"class.TechnologyParameter::MemoryType" }
%"class.TechnologyParameter::DeviceType" = type { double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double, double }
%"class.TechnologyParameter::InterconnectType" = type { double, double, double, double, double, double, double, double }
%"class.TechnologyParameter::ScalingFactor" = type { double, double, double }
%"class.TechnologyParameter::MemoryType" = type { double, double, double, double, double, double }
%class.powerDef = type { %class.powerComponents, %class.powerComponents, %class.powerComponents }
%class.powerComponents = type { double, double, double, double, double }

@g_tp = external local_unnamed_addr global %class.TechnologyParameter, align 8

declare noundef double @_Z8drain_C_diiidbbb(double noundef, i32 noundef, i32 noundef, i32 noundef, double noundef, i1 noundef zeroext, i1 noundef zeroext, i1 noundef zeroext) local_unnamed_addr #0

declare noundef double @_Z6gate_Cddbbb(double noundef, double noundef, i1 noundef zeroext, i1 noundef zeroext, i1 noundef zeroext) local_unnamed_addr #0

declare noundef double @_Z7tr_R_ondiibbb(double noundef, i32 noundef, i32 noundef, i1 noundef zeroext, i1 noundef zeroext, i1 noundef zeroext) local_unnamed_addr #0

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef double @_ZN4Wire8wire_capEdb(ptr noundef nonnull align 8 dereferenceable(1264), double noundef, i1 noundef zeroext) local_unnamed_addr #1 align 2

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

; Function Attrs: mustprogress nounwind uwtable
declare dso_local noundef double @_ZN4Wire8wire_resEd(ptr noundef nonnull align 8 dereferenceable(1264), double noundef) local_unnamed_addr #1 align 2

declare noundef double @_Z21pmos_to_nmos_sz_ratiobb(i1 noundef zeroext, i1 noundef zeroext) local_unnamed_addr #0

declare noundef double @_Z17cmos_Isub_leakageddi9Gate_typebbb17Half_net_topology(double noundef, double noundef, i32 noundef, i32 noundef, i1 noundef zeroext, i1 noundef zeroext, i1 noundef zeroext, i32 noundef) local_unnamed_addr #0

declare noundef double @_Z15cmos_Ig_leakageddi9Gate_typebbb17Half_net_topology(double noundef, double noundef, i32 noundef, i32 noundef, i1 noundef zeroext, i1 noundef zeroext, i1 noundef zeroext, i32 noundef) local_unnamed_addr #0

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN8powerDefC2Ev(ptr noundef nonnull align 8 dereferenceable(120)) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN4Wire10wire_modelEddPd(ptr dead_on_unwind noalias nonnull writable sret(%class.powerDef) align 8 %0, ptr noundef nonnull align 8 dereferenceable(1264) %1, double noundef %2, double noundef %3, ptr nocapture noundef writeonly %4) local_unnamed_addr #3 align 2 {
  tail call void @_ZN8powerDefC2Ev(ptr noundef nonnull align 8 dereferenceable(120) %0)
  %6 = tail call noundef double @_Z21pmos_to_nmos_sz_ratiobb(i1 noundef zeroext false, i1 noundef zeroext false)
  %7 = load double, ptr getelementptr inbounds (i8, ptr @g_tp, i64 8), align 8, !tbaa !5
  %8 = getelementptr inbounds i8, ptr %1, i64 1248
  %9 = load double, ptr %8, align 8, !tbaa !15
  %10 = fadd double %7, %9
  %11 = tail call noundef double @_Z6gate_Cddbbb(double noundef %10, double noundef 0.000000e+00, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false)
  %12 = load double, ptr %8, align 8, !tbaa !15
  %13 = load double, ptr getelementptr inbounds (i8, ptr @g_tp, i64 312), align 8, !tbaa !30
  %14 = tail call noundef double @_Z8drain_C_diiidbbb(double noundef %12, i32 noundef 0, i32 noundef 1, i32 noundef 1, double noundef %13, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false)
  %15 = load double, ptr getelementptr inbounds (i8, ptr @g_tp, i64 8), align 8, !tbaa !5
  %16 = load double, ptr getelementptr inbounds (i8, ptr @g_tp, i64 312), align 8, !tbaa !30
  %17 = tail call noundef double @_Z8drain_C_diiidbbb(double noundef %15, i32 noundef 1, i32 noundef 1, i32 noundef 1, double noundef %16, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false)
  %18 = fadd double %14, %17
  %19 = load double, ptr getelementptr inbounds (i8, ptr @g_tp, i64 8), align 8, !tbaa !5
  %20 = tail call noundef double @_Z7tr_R_ondiibbb(double noundef %19, i32 noundef 1, i32 noundef 1, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false)
  %21 = load double, ptr %8, align 8, !tbaa !15
  %22 = tail call noundef double @_Z7tr_R_ondiibbb(double noundef %21, i32 noundef 0, i32 noundef 1, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false)
  %23 = fadd double %20, %22
  %24 = fmul double %23, 5.000000e-01
  %25 = tail call noundef double @_ZN4Wire8wire_resEd(ptr noundef nonnull align 8 dereferenceable(1264) %1, double noundef 1.000000e+00)
  %26 = tail call noundef double @_ZN4Wire8wire_capEdb(ptr noundef nonnull align 8 dereferenceable(1264) %1, double noundef 1.000000e+00, i1 noundef zeroext false)
  %27 = getelementptr inbounds i8, ptr %1, i64 320
  store double %2, ptr %27, align 8, !tbaa !31
  %28 = getelementptr inbounds i8, ptr %1, i64 312
  store double %3, ptr %28, align 8, !tbaa !32
  %29 = fadd double %11, %18
  %30 = fmul double %26, %2
  %31 = tail call double @llvm.fmuladd.f64(double %3, double %29, double %30)
  %32 = getelementptr inbounds i8, ptr %1, i64 1256
  %33 = load ptr, ptr %32, align 8, !tbaa !33
  %34 = getelementptr inbounds i8, ptr %33, i64 72
  %35 = load double, ptr %34, align 8, !tbaa !34
  %36 = fmul double %31, %35
  %37 = fmul double %35, %36
  %38 = fmul double %24, %26
  %39 = fmul double %38, %2
  %40 = fdiv double %39, %3
  %41 = tail call double @llvm.fmuladd.f64(double %24, double %29, double %40)
  %42 = fmul double %25, %2
  %43 = fmul double %18, %42
  %44 = tail call double @llvm.fmuladd.f64(double %43, double %3, double %41)
  %45 = fmul double %25, 5.000000e-01
  %46 = fmul double %45, %26
  %47 = fmul double %46, %2
  %48 = tail call double @llvm.fmuladd.f64(double %47, double %2, double %44)
  %49 = fmul double %48, 6.930000e-01
  %50 = fdiv double %49, %2
  store double %50, ptr %4, align 8, !tbaa !35
  %51 = load double, ptr %34, align 8, !tbaa !34
  %52 = load double, ptr getelementptr inbounds (i8, ptr @g_tp, i64 8), align 8, !tbaa !5
  %53 = fmul double %51, %52
  %54 = fmul double %53, 6.500000e-05
  %55 = fmul double %54, 1.098600e+00
  %56 = load double, ptr %28, align 8, !tbaa !32
  %57 = fmul double %56, %55
  %58 = fmul double %48, %57
  %59 = load double, ptr %27, align 8, !tbaa !31
  %60 = fdiv double 1.000000e+00, %59
  %61 = fadd double %37, %58
  %62 = fmul double %60, %61
  store double %62, ptr %0, align 8, !tbaa !36
  %63 = fmul double %51, %60
  %64 = fmul double %52, %56
  %65 = fmul double %6, %52
  %66 = fmul double %65, %56
  %67 = tail call noundef double @_Z17cmos_Isub_leakageddi9Gate_typebbb17Half_net_topology(double noundef %64, double noundef %66, i32 noundef 1, i32 noundef 2, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false, i32 noundef 1)
  %68 = fmul double %63, %67
  %69 = getelementptr inbounds i8, ptr %0, i64 8
  store double %68, ptr %69, align 8, !tbaa !37
  %70 = load double, ptr %27, align 8, !tbaa !31
  %71 = fdiv double 1.000000e+00, %70
  %72 = load ptr, ptr %32, align 8, !tbaa !33
  %73 = getelementptr inbounds i8, ptr %72, i64 72
  %74 = load double, ptr %73, align 8, !tbaa !34
  %75 = fmul double %71, %74
  %76 = load double, ptr getelementptr inbounds (i8, ptr @g_tp, i64 8), align 8, !tbaa !5
  %77 = load double, ptr %28, align 8, !tbaa !32
  %78 = fmul double %76, %77
  %79 = fmul double %6, %76
  %80 = fmul double %79, %77
  %81 = tail call noundef double @_Z15cmos_Ig_leakageddi9Gate_typebbb17Half_net_topology(double noundef %78, double noundef %80, i32 noundef 1, i32 noundef 2, i1 noundef zeroext false, i1 noundef zeroext false, i1 noundef zeroext false, i32 noundef 1)
  %82 = fmul double %75, %81
  %83 = getelementptr inbounds i8, ptr %0, i64 16
  store double %82, ptr %83, align 8, !tbaa !38
  ret void
}

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

!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 8}
!6 = !{!"_ZTS19TechnologyParameter", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !7, i64 48, !7, i64 56, !7, i64 64, !7, i64 72, !7, i64 80, !7, i64 88, !7, i64 96, !7, i64 104, !7, i64 112, !7, i64 120, !7, i64 128, !7, i64 136, !7, i64 144, !7, i64 152, !7, i64 160, !7, i64 168, !7, i64 176, !7, i64 184, !7, i64 192, !7, i64 200, !7, i64 208, !7, i64 216, !7, i64 224, !7, i64 232, !7, i64 240, !7, i64 248, !7, i64 256, !7, i64 264, !7, i64 272, !7, i64 280, !7, i64 288, !7, i64 296, !7, i64 304, !7, i64 312, !7, i64 320, !7, i64 328, !7, i64 336, !7, i64 344, !10, i64 352, !11, i64 360, !11, i64 528, !11, i64 696, !11, i64 864, !11, i64 1032, !12, i64 1200, !12, i64 1264, !12, i64 1328, !13, i64 1392, !14, i64 1416, !14, i64 1464, !14, i64 1512}
!7 = !{!"double", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"long", !8, i64 0}
!11 = !{!"_ZTSN19TechnologyParameter10DeviceTypeE", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !7, i64 48, !7, i64 56, !7, i64 64, !7, i64 72, !7, i64 80, !7, i64 88, !7, i64 96, !7, i64 104, !7, i64 112, !7, i64 120, !7, i64 128, !7, i64 136, !7, i64 144, !7, i64 152, !7, i64 160}
!12 = !{!"_ZTSN19TechnologyParameter16InterconnectTypeE", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40, !7, i64 48, !7, i64 56}
!13 = !{!"_ZTSN19TechnologyParameter13ScalingFactorE", !7, i64 0, !7, i64 8, !7, i64 16}
!14 = !{!"_ZTSN19TechnologyParameter10MemoryTypeE", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32, !7, i64 40}
!15 = !{!16, !7, i64 1248}
!16 = !{!"_ZTS4Wire", !17, i64 0, !21, i64 280, !7, i64 288, !7, i64 296, !22, i64 304, !7, i64 312, !7, i64 320, !7, i64 328, !7, i64 336, !7, i64 344, !23, i64 352, !7, i64 360, !7, i64 368, !7, i64 376, !24, i64 384, !17, i64 408, !17, i64 688, !17, i64 968, !7, i64 1248, !29, i64 1256}
!17 = !{!"_ZTS9Component", !18, i64 0, !19, i64 24, !19, i64 144, !7, i64 264, !7, i64 272}
!18 = !{!"_ZTS4Area", !7, i64 0, !7, i64 8, !7, i64 16}
!19 = !{!"_ZTS8powerDef", !20, i64 0, !20, i64 40, !20, i64 80}
!20 = !{!"_ZTS15powerComponents", !7, i64 0, !7, i64 8, !7, i64 16, !7, i64 24, !7, i64 32}
!21 = !{!"_ZTS9Wire_type", !8, i64 0}
!22 = !{!"_ZTS14Wire_placement", !8, i64 0}
!23 = !{!"int", !8, i64 0}
!24 = !{!"_ZTSNSt7__cxx114listI9ComponentSaIS1_EEE", !25, i64 0}
!25 = !{!"_ZTSNSt7__cxx1110_List_baseI9ComponentSaIS1_EEE", !26, i64 0}
!26 = !{!"_ZTSNSt7__cxx1110_List_baseI9ComponentSaIS1_EE10_List_implE", !27, i64 0}
!27 = !{!"_ZTSNSt8__detail17_List_node_headerE", !28, i64 0, !10, i64 16}
!28 = !{!"_ZTSNSt8__detail15_List_node_baseE", !29, i64 0, !29, i64 8}
!29 = !{!"any pointer", !8, i64 0}
!30 = !{!6, !7, i64 312}
!31 = !{!16, !7, i64 320}
!32 = !{!16, !7, i64 312}
!33 = !{!16, !29, i64 1256}
!34 = !{!11, !7, i64 72}
!35 = !{!7, !7, i64 0}
!36 = !{!19, !7, i64 0}
!37 = !{!19, !7, i64 8}
!38 = !{!19, !7, i64 16}


; Effective O3 passes: EarlyCSEPass,GlobalOptPass,InferFunctionAttrsPass,InstCombinePass,PostOrderFunctionAttrsPass,ReassociatePass,SROAPass,TailCallElimPass