; LLVM IR from gem5/gem5 :: src/systemc/tlm_core/2/generic_payload (gp)

; 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.tlm::tlm_generic_payload" = type <{ ptr, i64, i32, [4 x i8], ptr, i32, i32, i8, [7 x i8], ptr, i32, i32, i32, [4 x i8], %"class.tlm::tlm_array", ptr, i32, [4 x i8] }>
%"class.tlm::tlm_array" = type { %"class.std::vector", %"class.std::vector.0" }
%"class.std::vector" = type { %"struct.std::_Vector_base" }
%"struct.std::_Vector_base" = type { %"struct.std::_Vector_base<tlm::tlm_extension_base *, std::allocator<tlm::tlm_extension_base *>>::_Vector_impl" }
%"struct.std::_Vector_base<tlm::tlm_extension_base *, std::allocator<tlm::tlm_extension_base *>>::_Vector_impl" = type { %"struct.std::_Vector_base<tlm::tlm_extension_base *, std::allocator<tlm::tlm_extension_base *>>::_Vector_impl_data" }
%"struct.std::_Vector_base<tlm::tlm_extension_base *, std::allocator<tlm::tlm_extension_base *>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.0" = type { %"struct.std::_Vector_base.1" }
%"struct.std::_Vector_base.1" = type { %"struct.std::_Vector_base<unsigned long, std::allocator<unsigned long>>::_Vector_impl" }
%"struct.std::_Vector_base<unsigned long, std::allocator<unsigned long>>::_Vector_impl" = type { %"struct.std::_Vector_base<unsigned long, std::allocator<unsigned long>>::_Vector_impl_data" }
%"struct.std::_Vector_base<unsigned long, std::allocator<unsigned long>>::_Vector_impl_data" = type { ptr, ptr, ptr }

; 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

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3tlm19tlm_generic_payload14deep_copy_fromERKS0_(ptr noundef nonnull align 8 dereferenceable(132) %0, ptr noundef nonnull align 8 dereferenceable(132) %1) #1 align 2 {
  %3 = alloca ptr, align 8
  %4 = alloca ptr, align 8
  %5 = alloca i32, align 4
  %6 = alloca ptr, align 8
  store ptr %0, ptr %3, align 8, !tbaa !5
  store ptr %1, ptr %4, align 8, !tbaa !5
  %7 = load ptr, ptr %3, align 8
  %8 = load ptr, ptr %4, align 8, !tbaa !5
  %9 = call noundef i32 @_ZNK3tlm19tlm_generic_payload11get_commandEv(ptr noundef nonnull align 8 dereferenceable(132) %8)
  %10 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 2
  store i32 %9, ptr %10, align 8, !tbaa !9
  %11 = load ptr, ptr %4, align 8, !tbaa !5
  %12 = call noundef i64 @_ZNK3tlm19tlm_generic_payload11get_addressEv(ptr noundef nonnull align 8 dereferenceable(132) %11)
  %13 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 1
  store i64 %12, ptr %13, align 8, !tbaa !26
  %14 = load ptr, ptr %4, align 8, !tbaa !5
  %15 = call noundef i32 @_ZNK3tlm19tlm_generic_payload15get_data_lengthEv(ptr noundef nonnull align 8 dereferenceable(132) %14)
  %16 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 5
  store i32 %15, ptr %16, align 8, !tbaa !27
  %17 = load ptr, ptr %4, align 8, !tbaa !5
  %18 = call noundef i32 @_ZNK3tlm19tlm_generic_payload19get_response_statusEv(ptr noundef nonnull align 8 dereferenceable(132) %17)
  %19 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 6
  store i32 %18, ptr %19, align 4, !tbaa !28
  %20 = load ptr, ptr %4, align 8, !tbaa !5
  %21 = call noundef i32 @_ZNK3tlm19tlm_generic_payload22get_byte_enable_lengthEv(ptr noundef nonnull align 8 dereferenceable(132) %20)
  %22 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 10
  store i32 %21, ptr %22, align 8, !tbaa !29
  %23 = load ptr, ptr %4, align 8, !tbaa !5
  %24 = call noundef i32 @_ZNK3tlm19tlm_generic_payload19get_streaming_widthEv(ptr noundef nonnull align 8 dereferenceable(132) %23)
  %25 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 11
  store i32 %24, ptr %25, align 4, !tbaa !30
  %26 = load ptr, ptr %4, align 8, !tbaa !5
  %27 = call noundef i32 @_ZNK3tlm19tlm_generic_payload13get_gp_optionEv(ptr noundef nonnull align 8 dereferenceable(132) %26)
  %28 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 12
  store i32 %27, ptr %28, align 8, !tbaa !31
  %29 = load ptr, ptr %4, align 8, !tbaa !5
  %30 = call noundef zeroext i1 @_ZNK3tlm19tlm_generic_payload14is_dmi_allowedEv(ptr noundef nonnull align 8 dereferenceable(132) %29)
  %31 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 7
  %32 = zext i1 %30 to i8
  store i8 %32, ptr %31, align 8, !tbaa !32
  %33 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 4
  %34 = load ptr, ptr %33, align 8, !tbaa !33
  %35 = icmp ne ptr %34, null
  br i1 %35, label %36, label %50

36:                                               ; preds = %2
  %37 = load ptr, ptr %4, align 8, !tbaa !5
  %38 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %37, i32 0, i32 4
  %39 = load ptr, ptr %38, align 8, !tbaa !33
  %40 = icmp ne ptr %39, null
  br i1 %40, label %41, label %50

41:                                               ; preds = %36
  %42 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 4
  %43 = load ptr, ptr %42, align 8, !tbaa !33
  %44 = load ptr, ptr %4, align 8, !tbaa !5
  %45 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %44, i32 0, i32 4
  %46 = load ptr, ptr %45, align 8, !tbaa !33
  %47 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 5
  %48 = load i32, ptr %47, align 8, !tbaa !27
  %49 = zext i32 %48 to i64
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 %43, ptr align 1 %46, i64 %49, i1 false)
  br label %50

50:                                               ; preds = %41, %36, %2
  %51 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 9
  %52 = load ptr, ptr %51, align 8, !tbaa !34
  %53 = icmp ne ptr %52, null
  br i1 %53, label %54, label %68

54:                                               ; preds = %50
  %55 = load ptr, ptr %4, align 8, !tbaa !5
  %56 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %55, i32 0, i32 9
  %57 = load ptr, ptr %56, align 8, !tbaa !34
  %58 = icmp ne ptr %57, null
  br i1 %58, label %59, label %68

59:                                               ; preds = %54
  %60 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 9
  %61 = load ptr, ptr %60, align 8, !tbaa !34
  %62 = load ptr, ptr %4, align 8, !tbaa !5
  %63 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %62, i32 0, i32 9
  %64 = load ptr, ptr %63, align 8, !tbaa !34
  %65 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 10
  %66 = load i32, ptr %65, align 8, !tbaa !29
  %67 = zext i32 %66 to i64
  call void @llvm.memcpy.p0.p0.i64(ptr align 1 %61, ptr align 1 %64, i64 %67, i1 false)
  br label %68

68:                                               ; preds = %59, %54, %50
  %69 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 14
  %70 = call noundef i64 @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %69) #4
  %71 = load ptr, ptr %4, align 8, !tbaa !5
  %72 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %71, i32 0, i32 14
  %73 = call noundef i64 @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %72) #4
  %74 = icmp ult i64 %70, %73
  br i1 %74, label %75, label %80

75:                                               ; preds = %68
  %76 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 14
  %77 = load ptr, ptr %4, align 8, !tbaa !5
  %78 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %77, i32 0, i32 14
  %79 = call noundef i64 @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %78) #4
  call void @_ZN3tlm9tlm_arrayIPNS_18tlm_extension_baseEE6expandEm(ptr noundef nonnull align 8 dereferenceable(48) %76, i64 noundef %79)
  br label %80

80:                                               ; preds = %75, %68
  call void @llvm.lifetime.start.p0(i64 4, ptr %5) #4
  store i32 0, ptr %5, align 4, !tbaa !35
  br label %81

81:                                               ; preds = %146, %80
  %82 = load i32, ptr %5, align 4, !tbaa !35
  %83 = zext i32 %82 to i64
  %84 = load ptr, ptr %4, align 8, !tbaa !5
  %85 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %84, i32 0, i32 14
  %86 = call noundef i64 @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %85) #4
  %87 = icmp ult i64 %83, %86
  br i1 %87, label %89, label %88

88:                                               ; preds = %81
  call void @llvm.lifetime.end.p0(i64 4, ptr %5) #4
  br label %149

89:                                               ; preds = %81
  %90 = load ptr, ptr %4, align 8, !tbaa !5
  %91 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %90, i32 0, i32 14
  %92 = load i32, ptr %5, align 4, !tbaa !35
  %93 = zext i32 %92 to i64
  %94 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %91, i64 noundef %93) #4
  %95 = load ptr, ptr %94, align 8, !tbaa !5
  %96 = icmp ne ptr %95, null
  br i1 %96, label %97, label %145

97:                                               ; preds = %89
  %98 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 14
  %99 = load i32, ptr %5, align 4, !tbaa !35
  %100 = zext i32 %99 to i64
  %101 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %98, i64 noundef %100) #4
  %102 = load ptr, ptr %101, align 8, !tbaa !5
  %103 = icmp ne ptr %102, null
  br i1 %103, label %129, label %104

104:                                              ; preds = %97
  call void @llvm.lifetime.start.p0(i64 8, ptr %6) #4
  %105 = load ptr, ptr %4, align 8, !tbaa !5
  %106 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %105, i32 0, i32 14
  %107 = load i32, ptr %5, align 4, !tbaa !35
  %108 = zext i32 %107 to i64
  %109 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %106, i64 noundef %108) #4
  %110 = load ptr, ptr %109, align 8, !tbaa !5
  %111 = load ptr, ptr %110, align 8, !tbaa !36
  %112 = getelementptr inbounds ptr, ptr %111, i64 0
  %113 = load ptr, ptr %112, align 8
  %114 = call noundef ptr %113(ptr noundef nonnull align 8 dereferenceable(8) %110)
  store ptr %114, ptr %6, align 8, !tbaa !5
  %115 = load ptr, ptr %6, align 8, !tbaa !5
  %116 = icmp ne ptr %115, null
  br i1 %116, label %117, label %128

117:                                              ; preds = %104
  %118 = call noundef zeroext i1 @_ZNK3tlm19tlm_generic_payload6has_mmEv(ptr noundef nonnull align 8 dereferenceable(132) %7)
  br i1 %118, label %119, label %123

119:                                              ; preds = %117
  %120 = load i32, ptr %5, align 4, !tbaa !35
  %121 = load ptr, ptr %6, align 8, !tbaa !5
  %122 = call noundef ptr @_ZN3tlm19tlm_generic_payload18set_auto_extensionEjPNS_18tlm_extension_baseE(ptr noundef nonnull align 8 dereferenceable(132) %7, i32 noundef %120, ptr noundef %121)
  br label %127

123:                                              ; preds = %117
  %124 = load i32, ptr %5, align 4, !tbaa !35
  %125 = load ptr, ptr %6, align 8, !tbaa !5
  %126 = call noundef ptr @_ZN3tlm19tlm_generic_payload13set_extensionEjPNS_18tlm_extension_baseE(ptr noundef nonnull align 8 dereferenceable(132) %7, i32 noundef %124, ptr noundef %125)
  br label %127

127:                                              ; preds = %123, %119
  br label %128

128:                                              ; preds = %127, %104
  call void @llvm.lifetime.end.p0(i64 8, ptr %6) #4
  br label %144

129:                                              ; preds = %97
  %130 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %7, i32 0, i32 14
  %131 = load i32, ptr %5, align 4, !tbaa !35
  %132 = zext i32 %131 to i64
  %133 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %130, i64 noundef %132) #4
  %134 = load ptr, ptr %133, align 8, !tbaa !5
  %135 = load ptr, ptr %4, align 8, !tbaa !5
  %136 = getelementptr inbounds %"class.tlm::tlm_generic_payload", ptr %135, i32 0, i32 14
  %137 = load i32, ptr %5, align 4, !tbaa !35
  %138 = zext i32 %137 to i64
  %139 = call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %136, i64 noundef %138) #4
  %140 = load ptr, ptr %139, align 8, !tbaa !5
  %141 = load ptr, ptr %134, align 8, !tbaa !36
  %142 = getelementptr inbounds ptr, ptr %141, i64 2
  %143 = load ptr, ptr %142, align 8
  call void %143(ptr noundef nonnull align 8 dereferenceable(8) %134, ptr noundef nonnull align 8 dereferenceable(8) %140)
  br label %144

144:                                              ; preds = %129, %128
  br label %145

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

146:                                              ; preds = %145
  %147 = load i32, ptr %5, align 4, !tbaa !35
  %148 = add i32 %147, 1
  store i32 %148, ptr %5, align 4, !tbaa !35
  br label %81, !llvm.loop !38

149:                                              ; preds = %88
  ret void
}

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

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

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

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

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

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

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_ZN3tlm19tlm_generic_payload13set_extensionEjPNS_18tlm_extension_baseE(ptr noundef nonnull align 8 dereferenceable(132), i32 noundef, ptr noundef) #1 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 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #4 = { 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, !12, i64 16}
!10 = !{!"_ZTSN3tlm19tlm_generic_payloadE", !11, i64 8, !12, i64 16, !6, i64 24, !13, i64 32, !14, i64 36, !15, i64 40, !6, i64 48, !13, i64 56, !13, i64 60, !16, i64 64, !17, i64 72, !6, i64 120, !13, i64 128}
!11 = !{!"long long", !7, i64 0}
!12 = !{!"_ZTSN3tlm11tlm_commandE", !7, i64 0}
!13 = !{!"int", !7, i64 0}
!14 = !{!"_ZTSN3tlm19tlm_response_statusE", !7, i64 0}
!15 = !{!"bool", !7, i64 0}
!16 = !{!"_ZTSN3tlm13tlm_gp_optionE", !7, i64 0}
!17 = !{!"_ZTSN3tlm9tlm_arrayIPNS_18tlm_extension_baseEEE", !18, i64 0, !22, i64 24}
!18 = !{!"_ZTSSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EE", !19, i64 0}
!19 = !{!"_ZTSSt12_Vector_baseIPN3tlm18tlm_extension_baseESaIS2_EE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseIPN3tlm18tlm_extension_baseESaIS2_EE12_Vector_implE", !21, i64 0}
!21 = !{!"_ZTSNSt12_Vector_baseIPN3tlm18tlm_extension_baseESaIS2_EE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!22 = !{!"_ZTSSt6vectorImSaImEE", !23, i64 0}
!23 = !{!"_ZTSSt12_Vector_baseImSaImEE", !24, i64 0}
!24 = !{!"_ZTSNSt12_Vector_baseImSaImEE12_Vector_implE", !25, i64 0}
!25 = !{!"_ZTSNSt12_Vector_baseImSaImEE17_Vector_impl_dataE", !6, i64 0, !6, i64 8, !6, i64 16}
!26 = !{!10, !11, i64 8}
!27 = !{!10, !13, i64 32}
!28 = !{!10, !14, i64 36}
!29 = !{!10, !13, i64 56}
!30 = !{!10, !13, i64 60}
!31 = !{!10, !16, i64 64}
!32 = !{!10, !15, i64 40}
!33 = !{!10, !6, i64 24}
!34 = !{!10, !6, i64 48}
!35 = !{!13, !13, i64 0}
!36 = !{!37, !37, i64 0}
!37 = !{!"vtable pointer", !8, i64 0}
!38 = distinct !{!38, !39}
!39 = !{!"llvm.loop.mustprogress"}


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

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

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

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

; Function Attrs: mustprogress uwtable
define dso_local void @_ZN3tlm19tlm_generic_payload14deep_copy_fromERKS0_(ptr noundef nonnull align 8 dereferenceable(132) %0, ptr noundef nonnull align 8 dereferenceable(132) %1) local_unnamed_addr #0 align 2 {
  %3 = tail call noundef i32 @_ZNK3tlm19tlm_generic_payload11get_commandEv(ptr noundef nonnull align 8 dereferenceable(132) %1)
  %4 = getelementptr inbounds i8, ptr %0, i64 16
  store i32 %3, ptr %4, align 8, !tbaa !5
  %5 = tail call noundef i64 @_ZNK3tlm19tlm_generic_payload11get_addressEv(ptr noundef nonnull align 8 dereferenceable(132) %1)
  %6 = getelementptr inbounds i8, ptr %0, i64 8
  store i64 %5, ptr %6, align 8, !tbaa !25
  %7 = tail call noundef i32 @_ZNK3tlm19tlm_generic_payload15get_data_lengthEv(ptr noundef nonnull align 8 dereferenceable(132) %1)
  %8 = getelementptr inbounds i8, ptr %0, i64 32
  store i32 %7, ptr %8, align 8, !tbaa !26
  %9 = tail call noundef i32 @_ZNK3tlm19tlm_generic_payload19get_response_statusEv(ptr noundef nonnull align 8 dereferenceable(132) %1)
  %10 = getelementptr inbounds i8, ptr %0, i64 36
  store i32 %9, ptr %10, align 4, !tbaa !27
  %11 = tail call noundef i32 @_ZNK3tlm19tlm_generic_payload22get_byte_enable_lengthEv(ptr noundef nonnull align 8 dereferenceable(132) %1)
  %12 = getelementptr inbounds i8, ptr %0, i64 56
  store i32 %11, ptr %12, align 8, !tbaa !28
  %13 = tail call noundef i32 @_ZNK3tlm19tlm_generic_payload19get_streaming_widthEv(ptr noundef nonnull align 8 dereferenceable(132) %1)
  %14 = getelementptr inbounds i8, ptr %0, i64 60
  store i32 %13, ptr %14, align 4, !tbaa !29
  %15 = tail call noundef i32 @_ZNK3tlm19tlm_generic_payload13get_gp_optionEv(ptr noundef nonnull align 8 dereferenceable(132) %1)
  %16 = getelementptr inbounds i8, ptr %0, i64 64
  store i32 %15, ptr %16, align 8, !tbaa !30
  %17 = tail call noundef zeroext i1 @_ZNK3tlm19tlm_generic_payload14is_dmi_allowedEv(ptr noundef nonnull align 8 dereferenceable(132) %1)
  %18 = getelementptr inbounds i8, ptr %0, i64 40
  %19 = zext i1 %17 to i8
  store i8 %19, ptr %18, align 8, !tbaa !31
  %20 = getelementptr inbounds i8, ptr %0, i64 24
  %21 = load ptr, ptr %20, align 8, !tbaa !32
  %.not = icmp eq ptr %21, null
  br i1 %.not, label %28, label %22

22:                                               ; preds = %2
  %23 = getelementptr inbounds i8, ptr %1, i64 24
  %24 = load ptr, ptr %23, align 8, !tbaa !32
  %.not36 = icmp eq ptr %24, null
  br i1 %.not36, label %28, label %25

25:                                               ; preds = %22
  %26 = load i32, ptr %8, align 8, !tbaa !26
  %27 = zext i32 %26 to i64
  tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 1 %21, ptr nonnull align 1 %24, i64 %27, i1 false)
  br label %28

28:                                               ; preds = %25, %22, %2
  %29 = getelementptr inbounds i8, ptr %0, i64 48
  %30 = load ptr, ptr %29, align 8, !tbaa !33
  %.not37 = icmp eq ptr %30, null
  br i1 %.not37, label %37, label %31

31:                                               ; preds = %28
  %32 = getelementptr inbounds i8, ptr %1, i64 48
  %33 = load ptr, ptr %32, align 8, !tbaa !33
  %.not38 = icmp eq ptr %33, null
  br i1 %.not38, label %37, label %34

34:                                               ; preds = %31
  %35 = load i32, ptr %12, align 8, !tbaa !28
  %36 = zext i32 %35 to i64
  tail call void @llvm.memcpy.p0.p0.i64(ptr nonnull align 1 %30, ptr nonnull align 1 %33, i64 %36, i1 false)
  br label %37

37:                                               ; preds = %34, %31, %28
  %38 = getelementptr inbounds i8, ptr %0, i64 72
  %39 = tail call noundef i64 @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %38) #3
  %40 = getelementptr inbounds i8, ptr %1, i64 72
  %41 = tail call noundef i64 @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %40) #3
  %42 = icmp ult i64 %39, %41
  br i1 %42, label %43, label %45

43:                                               ; preds = %37
  %44 = tail call noundef i64 @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %40) #3
  tail call void @_ZN3tlm9tlm_arrayIPNS_18tlm_extension_baseEE6expandEm(ptr noundef nonnull align 8 dereferenceable(48) %38, i64 noundef %44)
  br label %45

45:                                               ; preds = %43, %37
  %46 = tail call noundef i64 @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %40) #3
  %.not43 = icmp eq i64 %46, 0
  br i1 %.not43, label %._crit_edge, label %.lr.ph

._crit_edge:                                      ; preds = %73, %45
  ret void

.lr.ph:                                           ; preds = %45, %73
  %47 = phi i64 [ %75, %73 ], [ 0, %45 ]
  %.042 = phi i32 [ %74, %73 ], [ 0, %45 ]
  %48 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %40, i64 noundef %47) #3
  %49 = load ptr, ptr %48, align 8, !tbaa !34
  %.not39 = icmp eq ptr %49, null
  br i1 %.not39, label %73, label %50

50:                                               ; preds = %.lr.ph
  %51 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %38, i64 noundef %47) #3
  %52 = load ptr, ptr %51, align 8, !tbaa !34
  %.not40 = icmp eq ptr %52, null
  br i1 %.not40, label %53, label %65

53:                                               ; preds = %50
  %54 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %40, i64 noundef %47) #3
  %55 = load ptr, ptr %54, align 8, !tbaa !34
  %56 = load ptr, ptr %55, align 8, !tbaa !35
  %57 = load ptr, ptr %56, align 8
  %58 = tail call noundef ptr %57(ptr noundef nonnull align 8 dereferenceable(8) %55)
  %.not41 = icmp eq ptr %58, null
  br i1 %.not41, label %73, label %59

59:                                               ; preds = %53
  %60 = tail call noundef zeroext i1 @_ZNK3tlm19tlm_generic_payload6has_mmEv(ptr noundef nonnull align 8 dereferenceable(132) %0)
  br i1 %60, label %61, label %63

61:                                               ; preds = %59
  %62 = tail call noundef ptr @_ZN3tlm19tlm_generic_payload18set_auto_extensionEjPNS_18tlm_extension_baseE(ptr noundef nonnull align 8 dereferenceable(132) %0, i32 noundef %.042, ptr noundef nonnull %58)
  br label %73

63:                                               ; preds = %59
  %64 = tail call noundef ptr @_ZN3tlm19tlm_generic_payload13set_extensionEjPNS_18tlm_extension_baseE(ptr noundef nonnull align 8 dereferenceable(132) %0, i32 noundef %.042, ptr noundef nonnull %58)
  br label %73

65:                                               ; preds = %50
  %66 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %38, i64 noundef %47) #3
  %67 = load ptr, ptr %66, align 8, !tbaa !34
  %68 = tail call noundef nonnull align 8 dereferenceable(8) ptr @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EEixEm(ptr noundef nonnull align 8 dereferenceable(24) %40, i64 noundef %47) #3
  %69 = load ptr, ptr %68, align 8, !tbaa !34
  %70 = load ptr, ptr %67, align 8, !tbaa !35
  %71 = getelementptr inbounds i8, ptr %70, i64 16
  %72 = load ptr, ptr %71, align 8
  tail call void %72(ptr noundef nonnull align 8 dereferenceable(8) %67, ptr noundef nonnull align 8 dereferenceable(8) %69)
  br label %73

73:                                               ; preds = %53, %63, %61, %.lr.ph, %65
  %74 = add i32 %.042, 1
  %75 = zext i32 %74 to i64
  %76 = tail call noundef i64 @_ZNKSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %40) #3
  %77 = icmp ugt i64 %76, %75
  br i1 %77, label %.lr.ph, label %._crit_edge, !llvm.loop !37
}

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

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

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

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

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

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

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

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

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

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

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

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_ZN3tlm19tlm_generic_payload18set_auto_extensionEjPNS_18tlm_extension_baseE(ptr noundef nonnull align 8 dereferenceable(132), i32 noundef, ptr noundef) local_unnamed_addr #0 align 2

; Function Attrs: mustprogress uwtable
declare dso_local noundef ptr @_ZN3tlm19tlm_generic_payload13set_extensionEjPNS_18tlm_extension_baseE(ptr noundef nonnull align 8 dereferenceable(132), i32 noundef, ptr noundef) local_unnamed_addr #0 align 2

attributes #0 = { 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 #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 nounwind willreturn memory(argmem: readwrite) }
attributes #3 = { 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, !10, i64 16}
!6 = !{!"_ZTSN3tlm19tlm_generic_payloadE", !7, i64 8, !10, i64 16, !11, i64 24, !12, i64 32, !13, i64 36, !14, i64 40, !11, i64 48, !12, i64 56, !12, i64 60, !15, i64 64, !16, i64 72, !11, i64 120, !12, i64 128}
!7 = !{!"long long", !8, i64 0}
!8 = !{!"omnipotent char", !9, i64 0}
!9 = !{!"Simple C++ TBAA"}
!10 = !{!"_ZTSN3tlm11tlm_commandE", !8, i64 0}
!11 = !{!"any pointer", !8, i64 0}
!12 = !{!"int", !8, i64 0}
!13 = !{!"_ZTSN3tlm19tlm_response_statusE", !8, i64 0}
!14 = !{!"bool", !8, i64 0}
!15 = !{!"_ZTSN3tlm13tlm_gp_optionE", !8, i64 0}
!16 = !{!"_ZTSN3tlm9tlm_arrayIPNS_18tlm_extension_baseEEE", !17, i64 0, !21, i64 24}
!17 = !{!"_ZTSSt6vectorIPN3tlm18tlm_extension_baseESaIS2_EE", !18, i64 0}
!18 = !{!"_ZTSSt12_Vector_baseIPN3tlm18tlm_extension_baseESaIS2_EE", !19, i64 0}
!19 = !{!"_ZTSNSt12_Vector_baseIPN3tlm18tlm_extension_baseESaIS2_EE12_Vector_implE", !20, i64 0}
!20 = !{!"_ZTSNSt12_Vector_baseIPN3tlm18tlm_extension_baseESaIS2_EE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!21 = !{!"_ZTSSt6vectorImSaImEE", !22, i64 0}
!22 = !{!"_ZTSSt12_Vector_baseImSaImEE", !23, i64 0}
!23 = !{!"_ZTSNSt12_Vector_baseImSaImEE12_Vector_implE", !24, i64 0}
!24 = !{!"_ZTSNSt12_Vector_baseImSaImEE17_Vector_impl_dataE", !11, i64 0, !11, i64 8, !11, i64 16}
!25 = !{!6, !7, i64 8}
!26 = !{!6, !12, i64 32}
!27 = !{!6, !13, i64 36}
!28 = !{!6, !12, i64 56}
!29 = !{!6, !12, i64 60}
!30 = !{!6, !15, i64 64}
!31 = !{!6, !14, i64 40}
!32 = !{!6, !11, i64 24}
!33 = !{!6, !11, i64 48}
!34 = !{!11, !11, i64 0}
!35 = !{!36, !36, i64 0}
!36 = !{!"vtable pointer", !9, i64 0}
!37 = distinct !{!37, !38}
!38 = !{!"llvm.loop.mustprogress"}


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