; LLVM IR from AdaptiveCpp/AdaptiveCpp :: src/runtime/pcuda/pcuda_runtime_api.ll_ (pcudaKernelCall)

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

%"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration" = type { %struct.dim3, %struct.dim3, i64, ptr }
%struct.dim3 = type { i32, i32, i32 }
%"class.hipsycl::rt::source_location" = type <{ %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string", i32, [4 x i8] }>
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator.8" = type { i8 }
%"class.std::basic_string_view" = type { i64, ptr }
%"class.hipsycl::rt::kernel_configuration" = type { %"class.std::vector.36", %"class.std::vector.46", %"class.std::vector.51", %"class.std::vector.56", %"class.std::vector.11", %"class.std::vector.61", %"struct.std::array" }
%"class.std::vector.36" = type { %"struct.std::_Vector_base.37" }
%"struct.std::_Vector_base.37" = type { %"struct.std::_Vector_base<hipsycl::rt::kernel_build_flag, std::allocator<hipsycl::rt::kernel_build_flag>>::_Vector_impl" }
%"struct.std::_Vector_base<hipsycl::rt::kernel_build_flag, std::allocator<hipsycl::rt::kernel_build_flag>>::_Vector_impl" = type { %"struct.std::_Vector_base<hipsycl::rt::kernel_build_flag, std::allocator<hipsycl::rt::kernel_build_flag>>::_Vector_impl_data" }
%"struct.std::_Vector_base<hipsycl::rt::kernel_build_flag, std::allocator<hipsycl::rt::kernel_build_flag>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.46" = type { %"struct.std::_Vector_base.47" }
%"struct.std::_Vector_base.47" = type { %"struct.std::_Vector_base<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>, std::allocator<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>, std::allocator<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>, std::allocator<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>, std::allocator<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.51" = type { %"struct.std::_Vector_base.52" }
%"struct.std::_Vector_base.52" = type { %"struct.std::_Vector_base<std::pair<int, unsigned long>, std::allocator<std::pair<int, unsigned long>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<int, unsigned long>, std::allocator<std::pair<int, unsigned long>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<int, unsigned long>, std::allocator<std::pair<int, unsigned long>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<int, unsigned long>, std::allocator<std::pair<int, unsigned long>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.56" = type { %"struct.std::_Vector_base.57" }
%"struct.std::_Vector_base.57" = type { %"struct.std::_Vector_base<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>, std::allocator<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>>>::_Vector_impl" }
%"struct.std::_Vector_base<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>, std::allocator<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>>>::_Vector_impl" = type { %"struct.std::_Vector_base<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>, std::allocator<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>, std::allocator<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.11" = type { %"struct.std::_Vector_base.12" }
%"struct.std::_Vector_base.12" = 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 }
%"class.std::vector.61" = type { %"struct.std::_Vector_base.62" }
%"struct.std::_Vector_base.62" = type { %"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.std::array" = type { [2 x i64] }
%"class.hipsycl::rt::result" = type { %"class.std::unique_ptr" }
%"class.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.67" }
%"struct.std::_Head_base.67" = type { ptr }
%"class.hipsycl::rt::static_array" = type { %"struct.std::array.68" }
%"struct.std::array.68" = type { [3 x i64] }

@__func__.__pcudaKernelCall = external hidden unnamed_addr constant [18 x i8], align 1
@.str = external hidden unnamed_addr constant [97 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [41 x i8], align 1

; 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) #0

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

declare noundef nonnull align 8 dereferenceable(104) ptr @_ZN7hipsycl2rt5pcuda17pcuda_application3getEv() #2

declare noundef nonnull align 8 dereferenceable(96) ptr @_ZN7hipsycl2rt5pcuda17pcuda_application9tls_stateEv(ptr noundef nonnull align 8 dereferenceable(104)) #2

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

; Function Attrs: mustprogress uwtable
define dso_local i32 @__pcudaKernelCall(ptr noundef %0, ptr noundef %1, i64 noundef %2, ptr noundef %3) #3 personality ptr @__gxx_personality_v0 {
  %5 = alloca i32, align 4
  %6 = alloca ptr, align 8
  %7 = alloca ptr, align 8
  %8 = alloca i64, align 8
  %9 = alloca ptr, align 8
  %10 = alloca i32, align 4
  %11 = alloca i32, align 4
  %12 = alloca %"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration", align 8
  %13 = alloca %struct.dim3, align 4
  %14 = alloca { i64, i32 }, align 4
  %15 = alloca %struct.dim3, align 4
  %16 = alloca { i64, i32 }, align 4
  %17 = alloca %"class.hipsycl::rt::source_location", align 8
  %18 = alloca %"class.std::__cxx11::basic_string", align 8
  %19 = alloca %"class.std::allocator.8", align 1
  %20 = alloca ptr, align 8
  %21 = alloca i32, align 4
  %22 = alloca %"class.std::__cxx11::basic_string", align 8
  %23 = alloca %"class.std::allocator.8", align 1
  %24 = alloca %"class.std::__cxx11::basic_string", align 8
  %25 = alloca %"class.std::allocator.8", align 1
  %26 = alloca ptr, align 8
  %27 = alloca %"class.std::basic_string_view", align 8
  %28 = alloca ptr, align 8
  %29 = alloca %"class.std::basic_string_view", align 8
  %30 = alloca i64, align 8
  %31 = alloca %"class.hipsycl::rt::kernel_configuration", align 8
  %32 = alloca %"class.hipsycl::rt::result", align 8
  %33 = alloca %"class.std::basic_string_view", align 8
  %34 = alloca %"class.hipsycl::rt::static_array", align 8
  %35 = alloca %struct.dim3, align 4
  %36 = alloca { i64, i32 }, align 4
  %37 = alloca %"class.hipsycl::rt::static_array", align 8
  %38 = alloca %struct.dim3, align 4
  %39 = alloca { i64, i32 }, align 4
  store ptr %0, ptr %6, align 8, !tbaa !5
  store ptr %1, ptr %7, align 8, !tbaa !5
  store i64 %2, ptr %8, align 8, !tbaa !9
  store ptr %3, ptr %9, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 4, ptr %10) #6
  %40 = call noundef i32 @_ZN7hipsycl2rt5pcuda27get_most_recent_pcuda_errorEv()
  store i32 %40, ptr %10, align 4, !tbaa !11
  %41 = load i32, ptr %10, align 4, !tbaa !11
  %42 = icmp ne i32 %41, 0
  br i1 %42, label %43, label %45

43:                                               ; preds = %4
  %44 = load i32, ptr %10, align 4, !tbaa !11
  store i32 %44, ptr %5, align 4
  store i32 1, ptr %11, align 4
  br label %167

45:                                               ; preds = %4
  call void @llvm.lifetime.start.p0(i64 40, ptr %12) #6
  %46 = call noundef nonnull align 8 dereferenceable(104) ptr @_ZN7hipsycl2rt5pcuda17pcuda_application3getEv()
  %47 = call noundef nonnull align 8 dereferenceable(96) ptr @_ZN7hipsycl2rt5pcuda17pcuda_application9tls_stateEv(ptr noundef nonnull align 8 dereferenceable(104) %46)
  call void @_ZN7hipsycl2rt5pcuda18thread_local_state22pop_kernel_call_configEv(ptr dead_on_unwind writable sret(%"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration") align 8 %12, ptr noundef nonnull align 8 dereferenceable(96) %47)
  %48 = getelementptr inbounds %"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration", ptr %12, i32 0, i32 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %13, ptr align 4 %48, i64 12, i1 false), !tbaa.struct !13
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %14, ptr align 4 %13, i64 12, i1 false)
  %49 = getelementptr inbounds { i64, i32 }, ptr %14, i32 0, i32 0
  %50 = load i64, ptr %49, align 4
  %51 = getelementptr inbounds { i64, i32 }, ptr %14, i32 0, i32 1
  %52 = load i32, ptr %51, align 4
  %53 = call noundef i32 @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_19dim3_sizeE4dim3(i64 %50, i32 %52)
  %54 = icmp eq i32 %53, 0
  br i1 %54, label %63, label %55

55:                                               ; preds = %45
  %56 = getelementptr inbounds %"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration", ptr %12, i32 0, i32 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %15, ptr align 8 %56, i64 12, i1 false), !tbaa.struct !13
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %16, ptr align 4 %15, i64 12, i1 false)
  %57 = getelementptr inbounds { i64, i32 }, ptr %16, i32 0, i32 0
  %58 = load i64, ptr %57, align 4
  %59 = getelementptr inbounds { i64, i32 }, ptr %16, i32 0, i32 1
  %60 = load i32, ptr %59, align 4
  %61 = call noundef i32 @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_19dim3_sizeE4dim3(i64 %58, i32 %60)
  %62 = icmp eq i32 %61, 0
  br i1 %62, label %63, label %93

63:                                               ; preds = %55, %45
  call void @llvm.lifetime.start.p0(i64 72, ptr %17) #6
  call void @llvm.lifetime.start.p0(i64 32, ptr %18) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr %19) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %19) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %18, ptr noundef @__func__.__pcudaKernelCall, ptr noundef nonnull align 1 dereferenceable(1) %19)
          to label %64 unwind label %69

64:                                               ; preds = %63
  call void @llvm.lifetime.start.p0(i64 32, ptr %22) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr %23) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %23) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %22, ptr noundef @.str, ptr noundef nonnull align 1 dereferenceable(1) %23)
          to label %65 unwind label %73

65:                                               ; preds = %64
  invoke void @_ZN7hipsycl2rt15source_locationC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_i(ptr noundef nonnull align 8 dereferenceable(68) %17, ptr noundef nonnull align 8 dereferenceable(32) %18, ptr noundef nonnull align 8 dereferenceable(32) %22, i32 noundef 139)
          to label %66 unwind label %77

66:                                               ; preds = %65
  call void @llvm.lifetime.start.p0(i64 32, ptr %24) #6
  call void @llvm.lifetime.start.p0(i64 1, ptr %25) #6
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %25) #6
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %24, ptr noundef @.str.1, ptr noundef nonnull align 1 dereferenceable(1) %25)
          to label %67 unwind label %81

67:                                               ; preds = %66
  invoke void @_ZN7hipsycl2rt5pcuda20register_pcuda_errorERKNS0_15source_locationE10pcudaErrorRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(68) %17, i32 noundef 9, ptr noundef nonnull align 8 dereferenceable(32) %24)
          to label %68 unwind label %85

68:                                               ; preds = %67
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %24) #6
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %25) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %25) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %24) #6
  call void @_ZN7hipsycl2rt15source_locationD2Ev(ptr noundef nonnull align 8 dereferenceable(68) %17) #6
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %22) #6
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %23) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %23) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %22) #6
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %18) #6
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %19) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %19) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %18) #6
  call void @llvm.lifetime.end.p0(i64 72, ptr %17) #6
  store i32 9, ptr %5, align 4
  store i32 1, ptr %11, align 4
  br label %165

69:                                               ; preds = %63
  %70 = landingpad { ptr, i32 }
          cleanup
  %71 = extractvalue { ptr, i32 } %70, 0
  store ptr %71, ptr %20, align 8
  %72 = extractvalue { ptr, i32 } %70, 1
  store i32 %72, ptr %21, align 4
  br label %92

73:                                               ; preds = %64
  %74 = landingpad { ptr, i32 }
          cleanup
  %75 = extractvalue { ptr, i32 } %74, 0
  store ptr %75, ptr %20, align 8
  %76 = extractvalue { ptr, i32 } %74, 1
  store i32 %76, ptr %21, align 4
  br label %91

77:                                               ; preds = %65
  %78 = landingpad { ptr, i32 }
          cleanup
  %79 = extractvalue { ptr, i32 } %78, 0
  store ptr %79, ptr %20, align 8
  %80 = extractvalue { ptr, i32 } %78, 1
  store i32 %80, ptr %21, align 4
  br label %90

81:                                               ; preds = %66
  %82 = landingpad { ptr, i32 }
          cleanup
  %83 = extractvalue { ptr, i32 } %82, 0
  store ptr %83, ptr %20, align 8
  %84 = extractvalue { ptr, i32 } %82, 1
  store i32 %84, ptr %21, align 4
  br label %89

85:                                               ; preds = %67
  %86 = landingpad { ptr, i32 }
          cleanup
  %87 = extractvalue { ptr, i32 } %86, 0
  store ptr %87, ptr %20, align 8
  %88 = extractvalue { ptr, i32 } %86, 1
  store i32 %88, ptr %21, align 4
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %24) #6
  br label %89

89:                                               ; preds = %85, %81
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %25) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %25) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %24) #6
  call void @_ZN7hipsycl2rt15source_locationD2Ev(ptr noundef nonnull align 8 dereferenceable(68) %17) #6
  br label %90

90:                                               ; preds = %89, %77
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %22) #6
  br label %91

91:                                               ; preds = %90, %73
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %23) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %23) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %22) #6
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %18) #6
  br label %92

92:                                               ; preds = %91, %69
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %19) #6
  call void @llvm.lifetime.end.p0(i64 1, ptr %19) #6
  call void @llvm.lifetime.end.p0(i64 32, ptr %18) #6
  call void @llvm.lifetime.end.p0(i64 72, ptr %17) #6
  br label %166

93:                                               ; preds = %55
  call void @llvm.lifetime.start.p0(i64 8, ptr %26) #6
  %94 = getelementptr inbounds %"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration", ptr %12, i32 0, i32 3
  %95 = load ptr, ptr %94, align 8, !tbaa !16
  %96 = call noundef ptr @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_122queue_or_default_queueEPNS1_6streamE(ptr noundef %95)
  store ptr %96, ptr %26, align 8, !tbaa !5
  %97 = load ptr, ptr %26, align 8, !tbaa !5
  %98 = icmp ne ptr %97, null
  br i1 %98, label %100, label %99

99:                                               ; preds = %93
  store i32 11, ptr %5, align 4
  store i32 1, ptr %11, align 4
  br label %164

100:                                              ; preds = %93
  call void @llvm.lifetime.start.p0(i64 16, ptr %27) #6
  %101 = load ptr, ptr %6, align 8, !tbaa !5
  call void @_ZNSt17basic_string_viewIcSt11char_traitsIcEEC2EPKc(ptr noundef nonnull align 8 dereferenceable(16) %27, ptr noundef %101) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %28) #6
  %102 = load i64, ptr %8, align 8, !tbaa !9
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %29, ptr align 8 %27, i64 16, i1 false), !tbaa.struct !19
  %103 = load ptr, ptr %9, align 8, !tbaa !5
  %104 = getelementptr inbounds { i64, ptr }, ptr %29, i32 0, i32 0
  %105 = load i64, ptr %104, align 8
  %106 = getelementptr inbounds { i64, ptr }, ptr %29, i32 0, i32 1
  %107 = load ptr, ptr %106, align 8
  %108 = call noundef ptr @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_119extract_kernel_infoEmSt17basic_string_viewIcSt11char_traitsIcEEPPv(i64 noundef %102, i64 %105, ptr %107, ptr noundef %103)
  store ptr %108, ptr %28, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 8, ptr %30) #6
  %109 = load ptr, ptr %28, align 8, !tbaa !5
  %110 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7hipsycl2rt15hcf_kernel_info29get_host_side_parameter_sizesEv(ptr noundef nonnull align 8 dereferenceable(249) %109)
  %111 = call noundef i64 @_ZNKSt6vectorImSaImEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %110) #6
  store i64 %111, ptr %30, align 8, !tbaa !9
  call void @llvm.lifetime.start.p0(i64 160, ptr %31) #6
  call void @_ZN7hipsycl2rt20kernel_configurationC2Ev(ptr noundef nonnull align 8 dereferenceable(160) %31) #6
  call void @llvm.lifetime.start.p0(i64 8, ptr %32) #6
  %112 = load ptr, ptr %26, align 8, !tbaa !5
  %113 = load i64, ptr %8, align 8, !tbaa !9
  call void @llvm.memcpy.p0.p0.i64(ptr align 8 %33, ptr align 8 %27, i64 16, i1 false), !tbaa.struct !19
  %114 = load ptr, ptr %28, align 8, !tbaa !5
  call void @llvm.lifetime.start.p0(i64 24, ptr %34) #6
  %115 = getelementptr inbounds %"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration", ptr %12, i32 0, i32 0
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %35, ptr align 8 %115, i64 12, i1 false), !tbaa.struct !13
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %36, ptr align 4 %35, i64 12, i1 false)
  %116 = getelementptr inbounds { i64, i32 }, ptr %36, i32 0, i32 0
  %117 = load i64, ptr %116, align 4
  %118 = getelementptr inbounds { i64, i32 }, ptr %36, i32 0, i32 1
  %119 = load i32, ptr %118, align 4
  invoke void @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_114dim3_to_range3E4dim3(ptr dead_on_unwind writable sret(%"class.hipsycl::rt::static_array") align 8 %34, i64 %117, i32 %119)
          to label %120 unwind label %147

120:                                              ; preds = %100
  call void @llvm.lifetime.start.p0(i64 24, ptr %37) #6
  %121 = getelementptr inbounds %"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration", ptr %12, i32 0, i32 1
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %38, ptr align 4 %121, i64 12, i1 false), !tbaa.struct !13
  call void @llvm.memcpy.p0.p0.i64(ptr align 4 %39, ptr align 4 %38, i64 12, i1 false)
  %122 = getelementptr inbounds { i64, i32 }, ptr %39, i32 0, i32 0
  %123 = load i64, ptr %122, align 4
  %124 = getelementptr inbounds { i64, i32 }, ptr %39, i32 0, i32 1
  %125 = load i32, ptr %124, align 4
  invoke void @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_114dim3_to_range3E4dim3(ptr dead_on_unwind writable sret(%"class.hipsycl::rt::static_array") align 8 %37, i64 %123, i32 %125)
          to label %126 unwind label %151

126:                                              ; preds = %120
  %127 = getelementptr inbounds %"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration", ptr %12, i32 0, i32 2
  %128 = load i64, ptr %127, align 8, !tbaa !20
  %129 = trunc i64 %128 to i32
  %130 = load ptr, ptr %7, align 8, !tbaa !5
  %131 = load ptr, ptr %28, align 8, !tbaa !5
  %132 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7hipsycl2rt15hcf_kernel_info29get_host_side_parameter_sizesEv(ptr noundef nonnull align 8 dereferenceable(249) %131)
          to label %133 unwind label %151

133:                                              ; preds = %126
  %134 = call noundef ptr @_ZNKSt6vectorImSaImEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %132) #6
  %135 = load i64, ptr %30, align 8, !tbaa !9
  %136 = getelementptr inbounds { i64, ptr }, ptr %33, i32 0, i32 0
  %137 = load i64, ptr %136, align 8
  %138 = getelementptr inbounds { i64, ptr }, ptr %33, i32 0, i32 1
  %139 = load ptr, ptr %138, align 8
  %140 = load ptr, ptr %112, align 8, !tbaa !21
  %141 = getelementptr inbounds ptr, ptr %140, i64 12
  %142 = load ptr, ptr %141, align 8
  invoke void %142(ptr dead_on_unwind writable sret(%"class.hipsycl::rt::result") align 8 %32, ptr noundef nonnull align 8 dereferenceable(8) %112, i64 noundef %113, i64 %137, ptr %139, ptr noundef %114, ptr noundef nonnull align 8 dereferenceable(24) %34, ptr noundef nonnull align 8 dereferenceable(24) %37, i32 noundef %129, ptr noundef %130, ptr noundef %134, i64 noundef %135, ptr noundef nonnull align 8 dereferenceable(160) %31)
          to label %143 unwind label %151

143:                                              ; preds = %133
  call void @llvm.lifetime.end.p0(i64 24, ptr %37) #6
  call void @llvm.lifetime.end.p0(i64 24, ptr %34) #6
  %144 = invoke noundef zeroext i1 @_ZNK7hipsycl2rt6result10is_successEv(ptr noundef nonnull align 8 dereferenceable(8) %32)
          to label %145 unwind label %156

145:                                              ; preds = %143
  br i1 %144, label %146, label %160

146:                                              ; preds = %145
  store i32 0, ptr %5, align 4
  store i32 1, ptr %11, align 4
  br label %162

147:                                              ; preds = %100
  %148 = landingpad { ptr, i32 }
          cleanup
  %149 = extractvalue { ptr, i32 } %148, 0
  store ptr %149, ptr %20, align 8
  %150 = extractvalue { ptr, i32 } %148, 1
  store i32 %150, ptr %21, align 4
  br label %155

151:                                              ; preds = %133, %126, %120
  %152 = landingpad { ptr, i32 }
          cleanup
  %153 = extractvalue { ptr, i32 } %152, 0
  store ptr %153, ptr %20, align 8
  %154 = extractvalue { ptr, i32 } %152, 1
  store i32 %154, ptr %21, align 4
  call void @llvm.lifetime.end.p0(i64 24, ptr %37) #6
  br label %155

155:                                              ; preds = %151, %147
  call void @llvm.lifetime.end.p0(i64 24, ptr %34) #6
  br label %163

156:                                              ; preds = %160, %143
  %157 = landingpad { ptr, i32 }
          cleanup
  %158 = extractvalue { ptr, i32 } %157, 0
  store ptr %158, ptr %20, align 8
  %159 = extractvalue { ptr, i32 } %157, 1
  store i32 %159, ptr %21, align 4
  call void @_ZN7hipsycl2rt6resultD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %32) #6
  br label %163

160:                                              ; preds = %145
  invoke void @_ZN7hipsycl2rt5pcuda20register_pcuda_errorERKNS0_6resultE10pcudaError(ptr noundef nonnull align 8 dereferenceable(8) %32, i32 noundef 4)
          to label %161 unwind label %156

161:                                              ; preds = %160
  store i32 4, ptr %5, align 4
  store i32 1, ptr %11, align 4
  br label %162

162:                                              ; preds = %161, %146
  call void @_ZN7hipsycl2rt6resultD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %32) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #6
  call void @_ZN7hipsycl2rt20kernel_configurationD2Ev(ptr noundef nonnull align 8 dereferenceable(160) %31) #6
  call void @llvm.lifetime.end.p0(i64 160, ptr %31) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %27) #6
  br label %164

163:                                              ; preds = %156, %155
  call void @llvm.lifetime.end.p0(i64 8, ptr %32) #6
  call void @_ZN7hipsycl2rt20kernel_configurationD2Ev(ptr noundef nonnull align 8 dereferenceable(160) %31) #6
  call void @llvm.lifetime.end.p0(i64 160, ptr %31) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %30) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %28) #6
  call void @llvm.lifetime.end.p0(i64 16, ptr %27) #6
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #6
  br label %166

164:                                              ; preds = %162, %99
  call void @llvm.lifetime.end.p0(i64 8, ptr %26) #6
  br label %165

165:                                              ; preds = %164, %68
  call void @llvm.lifetime.end.p0(i64 40, ptr %12) #6
  br label %167

166:                                              ; preds = %163, %92
  call void @llvm.lifetime.end.p0(i64 40, ptr %12) #6
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  br label %169

167:                                              ; preds = %165, %43
  call void @llvm.lifetime.end.p0(i64 4, ptr %10) #6
  %168 = load i32, ptr %5, align 4
  ret i32 %168

169:                                              ; preds = %166
  %170 = load ptr, ptr %20, align 8
  %171 = load i32, ptr %21, align 4
  %172 = insertvalue { ptr, i32 } poison, ptr %170, 0
  %173 = insertvalue { ptr, i32 } %172, i32 %171, 1
  resume { ptr, i32 } %173
}

declare noundef i32 @_ZN7hipsycl2rt5pcuda27get_most_recent_pcuda_errorEv() #2

declare void @_ZN7hipsycl2rt5pcuda18thread_local_state22pop_kernel_call_configEv(ptr dead_on_unwind writable sret(%"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration") align 8, ptr noundef nonnull align 8 dereferenceable(96)) #2

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef i32 @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_19dim3_sizeE4dim3(i64, i32) #4

declare void @_ZN7hipsycl2rt5pcuda20register_pcuda_errorERKNS0_15source_locationE10pcudaErrorRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(68), i32 noundef, ptr noundef nonnull align 8 dereferenceable(32)) #2

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #4 align 2

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

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7hipsycl2rt15source_locationC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_i(ptr noundef nonnull align 8 dereferenceable(68), ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 8 dereferenceable(32), i32 noundef) unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #4 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #4 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN7hipsycl2rt15source_locationD2Ev(ptr noundef nonnull align 8 dereferenceable(68)) unnamed_addr #5 align 2

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_122queue_or_default_queueEPNS1_6streamE(ptr noundef) #3

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt17basic_string_viewIcSt11char_traitsIcEEC2EPKc(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull) unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_119extract_kernel_infoEmSt17basic_string_viewIcSt11char_traitsIcEEPPv(i64 noundef, i64, ptr, ptr noundef) #3

declare noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7hipsycl2rt15hcf_kernel_info29get_host_side_parameter_sizesEv(ptr noundef nonnull align 8 dereferenceable(249)) #2

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN7hipsycl2rt20kernel_configurationC2Ev(ptr noundef nonnull align 8 dereferenceable(160)) unnamed_addr #5 align 2

; Function Attrs: mustprogress uwtable
declare hidden void @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_114dim3_to_range3E4dim3(ptr dead_on_unwind noalias writable sret(%"class.hipsycl::rt::static_array") align 8, i64, i32) #3

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

declare noundef zeroext i1 @_ZNK7hipsycl2rt6result10is_successEv(ptr noundef nonnull align 8 dereferenceable(8)) #2

declare void @_ZN7hipsycl2rt5pcuda20register_pcuda_errorERKNS0_6resultE10pcudaError(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) #2

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN7hipsycl2rt20kernel_configurationD2Ev(ptr noundef nonnull align 8 dereferenceable(160)) unnamed_addr #5 align 2

attributes #0 = { nocallback nofree nounwind willreturn memory(argmem: readwrite) }
attributes #1 = { nocallback nofree nosync nounwind willreturn memory(argmem: readwrite) }
attributes #2 = { "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #4 = { mustprogress 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 #5 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #6 = { 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 = !{!"_ZTS10pcudaError", !7, i64 0}
!13 = !{i64 0, i64 4, !14, i64 4, i64 4, !14, i64 8, i64 4, !14}
!14 = !{!15, !15, i64 0}
!15 = !{!"int", !7, i64 0}
!16 = !{!17, !6, i64 32}
!17 = !{!"_ZTSN7hipsycl2rt5pcuda18thread_local_state25kernel_call_configurationE", !18, i64 0, !18, i64 12, !10, i64 24, !6, i64 32}
!18 = !{!"_ZTS4dim3", !15, i64 0, !15, i64 4, !15, i64 8}
!19 = !{i64 0, i64 8, !9, i64 8, i64 8, !5}
!20 = !{!17, !10, i64 24}
!21 = !{!22, !22, i64 0}
!22 = !{!"vtable pointer", !8, i64 0}


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

%"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration" = type { %struct.dim3, %struct.dim3, i64, ptr }
%struct.dim3 = type { i32, i32, i32 }
%"class.hipsycl::rt::source_location" = type <{ %"class.std::__cxx11::basic_string", %"class.std::__cxx11::basic_string", i32, [4 x i8] }>
%"class.std::__cxx11::basic_string" = type { %"struct.std::__cxx11::basic_string<char>::_Alloc_hider", i64, %union.anon }
%"struct.std::__cxx11::basic_string<char>::_Alloc_hider" = type { ptr }
%union.anon = type { i64, [8 x i8] }
%"class.std::allocator.8" = type { i8 }
%"class.std::basic_string_view" = type { i64, ptr }
%"class.hipsycl::rt::kernel_configuration" = type { %"class.std::vector.36", %"class.std::vector.46", %"class.std::vector.51", %"class.std::vector.56", %"class.std::vector.11", %"class.std::vector.61", %"struct.std::array" }
%"class.std::vector.36" = type { %"struct.std::_Vector_base.37" }
%"struct.std::_Vector_base.37" = type { %"struct.std::_Vector_base<hipsycl::rt::kernel_build_flag, std::allocator<hipsycl::rt::kernel_build_flag>>::_Vector_impl" }
%"struct.std::_Vector_base<hipsycl::rt::kernel_build_flag, std::allocator<hipsycl::rt::kernel_build_flag>>::_Vector_impl" = type { %"struct.std::_Vector_base<hipsycl::rt::kernel_build_flag, std::allocator<hipsycl::rt::kernel_build_flag>>::_Vector_impl_data" }
%"struct.std::_Vector_base<hipsycl::rt::kernel_build_flag, std::allocator<hipsycl::rt::kernel_build_flag>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.46" = type { %"struct.std::_Vector_base.47" }
%"struct.std::_Vector_base.47" = type { %"struct.std::_Vector_base<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>, std::allocator<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>, std::allocator<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>, std::allocator<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>, std::allocator<std::pair<hipsycl::rt::kernel_build_option, hipsycl::rt::kernel_configuration::int_or_string>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.51" = type { %"struct.std::_Vector_base.52" }
%"struct.std::_Vector_base.52" = type { %"struct.std::_Vector_base<std::pair<int, unsigned long>, std::allocator<std::pair<int, unsigned long>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<int, unsigned long>, std::allocator<std::pair<int, unsigned long>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<int, unsigned long>, std::allocator<std::pair<int, unsigned long>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<int, unsigned long>, std::allocator<std::pair<int, unsigned long>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.56" = type { %"struct.std::_Vector_base.57" }
%"struct.std::_Vector_base.57" = type { %"struct.std::_Vector_base<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>, std::allocator<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>>>::_Vector_impl" }
%"struct.std::_Vector_base<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>, std::allocator<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>>>::_Vector_impl" = type { %"struct.std::_Vector_base<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>, std::allocator<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>, std::allocator<hipsycl::glue::sscp::__acpp_sscp_emit_param_type_annotation_fcall_specialized_config<const hipsycl::glue::sscp::fcall_specialized_config *>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"class.std::vector.11" = type { %"struct.std::_Vector_base.12" }
%"struct.std::_Vector_base.12" = 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 }
%"class.std::vector.61" = type { %"struct.std::_Vector_base.62" }
%"struct.std::_Vector_base.62" = type { %"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl" }
%"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl" = type { %"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl_data" }
%"struct.std::_Vector_base<std::pair<int, int>, std::allocator<std::pair<int, int>>>::_Vector_impl_data" = type { ptr, ptr, ptr }
%"struct.std::array" = type { [2 x i64] }
%"class.hipsycl::rt::result" = type { %"class.std::unique_ptr" }
%"class.std::unique_ptr" = type { %"struct.std::__uniq_ptr_data" }
%"struct.std::__uniq_ptr_data" = type { %"class.std::__uniq_ptr_impl" }
%"class.std::__uniq_ptr_impl" = type { %"class.std::tuple" }
%"class.std::tuple" = type { %"struct.std::_Tuple_impl" }
%"struct.std::_Tuple_impl" = type { %"struct.std::_Head_base.67" }
%"struct.std::_Head_base.67" = type { ptr }
%"class.hipsycl::rt::static_array" = type { %"struct.std::array.68" }
%"struct.std::array.68" = type { [3 x i64] }

@__func__.__pcudaKernelCall = external hidden unnamed_addr constant [18 x i8], align 1
@.str = external hidden unnamed_addr constant [97 x i8], align 1
@.str.1 = external hidden unnamed_addr constant [41 x i8], align 1

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

declare noundef nonnull align 8 dereferenceable(104) ptr @_ZN7hipsycl2rt5pcuda17pcuda_application3getEv() local_unnamed_addr #1

declare noundef nonnull align 8 dereferenceable(96) ptr @_ZN7hipsycl2rt5pcuda17pcuda_application9tls_stateEv(ptr noundef nonnull align 8 dereferenceable(104)) local_unnamed_addr #1

; 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 noundef i32 @__pcudaKernelCall(ptr noundef %0, ptr noundef %1, i64 noundef %2, ptr noundef %3) local_unnamed_addr #2 personality ptr @__gxx_personality_v0 {
  %5 = alloca %"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration", align 8
  %6 = alloca %"class.hipsycl::rt::source_location", align 8
  %7 = alloca %"class.std::__cxx11::basic_string", align 8
  %8 = alloca %"class.std::allocator.8", align 1
  %9 = alloca %"class.std::__cxx11::basic_string", align 8
  %10 = alloca %"class.std::allocator.8", align 1
  %11 = alloca %"class.std::__cxx11::basic_string", align 8
  %12 = alloca %"class.std::allocator.8", align 1
  %13 = alloca %"class.std::basic_string_view", align 8
  %14 = alloca %"class.hipsycl::rt::kernel_configuration", align 8
  %15 = alloca %"class.hipsycl::rt::result", align 8
  %16 = alloca %"class.hipsycl::rt::static_array", align 8
  %17 = alloca %"class.hipsycl::rt::static_array", align 8
  %18 = tail call noundef i32 @_ZN7hipsycl2rt5pcuda27get_most_recent_pcuda_errorEv()
  %.not = icmp eq i32 %18, 0
  br i1 %.not, label %19, label %82

19:                                               ; preds = %4
  call void @llvm.lifetime.start.p0(i64 40, ptr nonnull %5) #5
  %20 = tail call noundef nonnull align 8 dereferenceable(104) ptr @_ZN7hipsycl2rt5pcuda17pcuda_application3getEv()
  %21 = tail call noundef nonnull align 8 dereferenceable(96) ptr @_ZN7hipsycl2rt5pcuda17pcuda_application9tls_stateEv(ptr noundef nonnull align 8 dereferenceable(104) %20)
  call void @_ZN7hipsycl2rt5pcuda18thread_local_state22pop_kernel_call_configEv(ptr dead_on_unwind nonnull writable sret(%"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration") align 8 %5, ptr noundef nonnull align 8 dereferenceable(96) %21)
  %22 = getelementptr inbounds i8, ptr %5, i64 12
  %.sroa.023.0.copyload = load i64, ptr %22, align 4
  %.sroa.224.0..sroa_idx = getelementptr inbounds i8, ptr %5, i64 20
  %.sroa.224.0.copyload = load i32, ptr %.sroa.224.0..sroa_idx, align 4, !tbaa !5
  %23 = call noundef i32 @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_19dim3_sizeE4dim3(i64 %.sroa.023.0.copyload, i32 %.sroa.224.0.copyload)
  %24 = icmp eq i32 %23, 0
  br i1 %24, label %28, label %25

25:                                               ; preds = %19
  %.sroa.019.0.copyload = load i64, ptr %5, align 8
  %.sroa.220.0..sroa_idx = getelementptr inbounds i8, ptr %5, i64 8
  %.sroa.220.0.copyload = load i32, ptr %.sroa.220.0..sroa_idx, align 8, !tbaa !5
  %26 = call noundef i32 @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_19dim3_sizeE4dim3(i64 %.sroa.019.0.copyload, i32 %.sroa.220.0.copyload)
  %27 = icmp eq i32 %26, 0
  br i1 %27, label %28, label %48

28:                                               ; preds = %25, %19
  call void @llvm.lifetime.start.p0(i64 72, ptr nonnull %6) #5
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %7) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %8) #5
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %8) #5
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %7, ptr noundef nonnull @__func__.__pcudaKernelCall, ptr noundef nonnull align 1 dereferenceable(1) %8)
          to label %29 unwind label %34

29:                                               ; preds = %28
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %9) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %10) #5
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #5
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %9, ptr noundef nonnull @.str, ptr noundef nonnull align 1 dereferenceable(1) %10)
          to label %30 unwind label %36

30:                                               ; preds = %29
  invoke void @_ZN7hipsycl2rt15source_locationC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_i(ptr noundef nonnull align 8 dereferenceable(68) %6, ptr noundef nonnull align 8 dereferenceable(32) %7, ptr noundef nonnull align 8 dereferenceable(32) %9, i32 noundef 139)
          to label %31 unwind label %38

31:                                               ; preds = %30
  call void @llvm.lifetime.start.p0(i64 32, ptr nonnull %11) #5
  call void @llvm.lifetime.start.p0(i64 1, ptr nonnull %12) #5
  call void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #5
  invoke void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEC2IS3_EEPKcRKS3_(ptr noundef nonnull align 8 dereferenceable(32) %11, ptr noundef nonnull @.str.1, ptr noundef nonnull align 1 dereferenceable(1) %12)
          to label %32 unwind label %40

32:                                               ; preds = %31
  invoke void @_ZN7hipsycl2rt5pcuda20register_pcuda_errorERKNS0_15source_locationE10pcudaErrorRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(68) %6, i32 noundef 9, ptr noundef nonnull align 8 dereferenceable(32) %11)
          to label %33 unwind label %42

33:                                               ; preds = %32
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %11) #5
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %12) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %11) #5
  call void @_ZN7hipsycl2rt15source_locationD2Ev(ptr noundef nonnull align 8 dereferenceable(68) %6) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %9) #5
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %9) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %7) #5
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %8) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %8) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %7) #5
  call void @llvm.lifetime.end.p0(i64 72, ptr nonnull %6) #5
  br label %80

34:                                               ; preds = %28
  %35 = landingpad { ptr, i32 }
          cleanup
  br label %47

36:                                               ; preds = %29
  %37 = landingpad { ptr, i32 }
          cleanup
  br label %46

38:                                               ; preds = %30
  %39 = landingpad { ptr, i32 }
          cleanup
  br label %45

40:                                               ; preds = %31
  %41 = landingpad { ptr, i32 }
          cleanup
  br label %44

42:                                               ; preds = %32
  %43 = landingpad { ptr, i32 }
          cleanup
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %11) #5
  br label %44

44:                                               ; preds = %42, %40
  %.pn50 = phi { ptr, i32 } [ %43, %42 ], [ %41, %40 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %12) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %12) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %11) #5
  call void @_ZN7hipsycl2rt15source_locationD2Ev(ptr noundef nonnull align 8 dereferenceable(68) %6) #5
  br label %45

45:                                               ; preds = %44, %38
  %.pn50.pn = phi { ptr, i32 } [ %.pn50, %44 ], [ %39, %38 ]
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %9) #5
  br label %46

46:                                               ; preds = %45, %36
  %.pn50.pn.pn = phi { ptr, i32 } [ %.pn50.pn, %45 ], [ %37, %36 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %10) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %10) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %9) #5
  call void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32) %7) #5
  br label %47

47:                                               ; preds = %46, %34
  %.pn50.pn.pn.pn = phi { ptr, i32 } [ %.pn50.pn.pn, %46 ], [ %35, %34 ]
  call void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1) %8) #5
  call void @llvm.lifetime.end.p0(i64 1, ptr nonnull %8) #5
  call void @llvm.lifetime.end.p0(i64 32, ptr nonnull %7) #5
  call void @llvm.lifetime.end.p0(i64 72, ptr nonnull %6) #5
  br label %81

48:                                               ; preds = %25
  %49 = getelementptr inbounds i8, ptr %5, i64 32
  %50 = load ptr, ptr %49, align 8, !tbaa !9
  %51 = call noundef ptr @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_122queue_or_default_queueEPNS1_6streamE(ptr noundef %50)
  %.not46 = icmp eq ptr %51, null
  br i1 %.not46, label %80, label %52

52:                                               ; preds = %48
  call void @llvm.lifetime.start.p0(i64 16, ptr nonnull %13) #5
  call void @_ZNSt17basic_string_viewIcSt11char_traitsIcEEC2EPKc(ptr noundef nonnull align 8 dereferenceable(16) %13, ptr noundef %0) #5
  %.sroa.09.0.copyload = load i64, ptr %13, align 8, !tbaa !14
  %.sroa.210.0..sroa_idx = getelementptr inbounds i8, ptr %13, i64 8
  %.sroa.210.0.copyload = load ptr, ptr %.sroa.210.0..sroa_idx, align 8, !tbaa !15
  %53 = call noundef ptr @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_119extract_kernel_infoEmSt17basic_string_viewIcSt11char_traitsIcEEPPv(i64 noundef %2, i64 %.sroa.09.0.copyload, ptr %.sroa.210.0.copyload, ptr noundef %3)
  %54 = call noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7hipsycl2rt15hcf_kernel_info29get_host_side_parameter_sizesEv(ptr noundef nonnull align 8 dereferenceable(249) %53)
  %55 = call noundef i64 @_ZNKSt6vectorImSaImEE4sizeEv(ptr noundef nonnull align 8 dereferenceable(24) %54) #5
  call void @llvm.lifetime.start.p0(i64 160, ptr nonnull %14) #5
  call void @_ZN7hipsycl2rt20kernel_configurationC2Ev(ptr noundef nonnull align 8 dereferenceable(160) %14) #5
  call void @llvm.lifetime.start.p0(i64 8, ptr nonnull %15) #5
  %.sroa.07.0.copyload = load i64, ptr %13, align 8, !tbaa !14
  %.sroa.28.0.copyload = load ptr, ptr %.sroa.210.0..sroa_idx, align 8, !tbaa !15
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %16) #5
  %.sroa.05.0.copyload = load i64, ptr %5, align 8
  %.sroa.26.0.copyload = load i32, ptr %.sroa.220.0..sroa_idx, align 8, !tbaa !5
  invoke void @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_114dim3_to_range3E4dim3(ptr dead_on_unwind nonnull writable sret(%"class.hipsycl::rt::static_array") align 8 %16, i64 %.sroa.05.0.copyload, i32 %.sroa.26.0.copyload)
          to label %56 unwind label %70

56:                                               ; preds = %52
  call void @llvm.lifetime.start.p0(i64 24, ptr nonnull %17) #5
  %.sroa.01.0.copyload = load i64, ptr %22, align 4
  %.sroa.22.0.copyload = load i32, ptr %.sroa.224.0..sroa_idx, align 4, !tbaa !5
  invoke void @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_114dim3_to_range3E4dim3(ptr dead_on_unwind nonnull writable sret(%"class.hipsycl::rt::static_array") align 8 %17, i64 %.sroa.01.0.copyload, i32 %.sroa.22.0.copyload)
          to label %57 unwind label %72

57:                                               ; preds = %56
  %58 = getelementptr inbounds i8, ptr %5, i64 24
  %59 = load i64, ptr %58, align 8, !tbaa !16
  %60 = invoke noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7hipsycl2rt15hcf_kernel_info29get_host_side_parameter_sizesEv(ptr noundef nonnull align 8 dereferenceable(249) %53)
          to label %61 unwind label %72

61:                                               ; preds = %57
  %62 = trunc i64 %59 to i32
  %63 = call noundef ptr @_ZNKSt6vectorImSaImEE4dataEv(ptr noundef nonnull align 8 dereferenceable(24) %60) #5
  %64 = load ptr, ptr %51, align 8, !tbaa !17
  %65 = getelementptr inbounds i8, ptr %64, i64 96
  %66 = load ptr, ptr %65, align 8
  invoke void %66(ptr dead_on_unwind nonnull writable sret(%"class.hipsycl::rt::result") align 8 %15, ptr noundef nonnull align 8 dereferenceable(8) %51, i64 noundef %2, i64 %.sroa.07.0.copyload, ptr %.sroa.28.0.copyload, ptr noundef nonnull %53, ptr noundef nonnull align 8 dereferenceable(24) %16, ptr noundef nonnull align 8 dereferenceable(24) %17, i32 noundef %62, ptr noundef %1, ptr noundef %63, i64 noundef %55, ptr noundef nonnull align 8 dereferenceable(160) %14)
          to label %67 unwind label %72

67:                                               ; preds = %61
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %17) #5
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %16) #5
  %68 = invoke noundef zeroext i1 @_ZNK7hipsycl2rt6result10is_successEv(ptr noundef nonnull align 8 dereferenceable(8) %15)
          to label %69 unwind label %75

69:                                               ; preds = %67
  br i1 %68, label %78, label %77

70:                                               ; preds = %52
  %71 = landingpad { ptr, i32 }
          cleanup
  br label %74

72:                                               ; preds = %61, %57, %56
  %73 = landingpad { ptr, i32 }
          cleanup
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %17) #5
  br label %74

74:                                               ; preds = %72, %70
  %.pn = phi { ptr, i32 } [ %73, %72 ], [ %71, %70 ]
  call void @llvm.lifetime.end.p0(i64 24, ptr nonnull %16) #5
  br label %79

75:                                               ; preds = %77, %67
  %76 = landingpad { ptr, i32 }
          cleanup
  call void @_ZN7hipsycl2rt6resultD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %15) #5
  br label %79

77:                                               ; preds = %69
  invoke void @_ZN7hipsycl2rt5pcuda20register_pcuda_errorERKNS0_6resultE10pcudaError(ptr noundef nonnull align 8 dereferenceable(8) %15, i32 noundef 4)
          to label %78 unwind label %75

78:                                               ; preds = %77, %69
  %.0 = phi i32 [ 0, %69 ], [ 4, %77 ]
  call void @_ZN7hipsycl2rt6resultD2Ev(ptr noundef nonnull align 8 dereferenceable(8) %15) #5
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #5
  call void @_ZN7hipsycl2rt20kernel_configurationD2Ev(ptr noundef nonnull align 8 dereferenceable(160) %14) #5
  call void @llvm.lifetime.end.p0(i64 160, ptr nonnull %14) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %13) #5
  br label %80

79:                                               ; preds = %75, %74
  %.pn48 = phi { ptr, i32 } [ %76, %75 ], [ %.pn, %74 ]
  call void @llvm.lifetime.end.p0(i64 8, ptr nonnull %15) #5
  call void @_ZN7hipsycl2rt20kernel_configurationD2Ev(ptr noundef nonnull align 8 dereferenceable(160) %14) #5
  call void @llvm.lifetime.end.p0(i64 160, ptr nonnull %14) #5
  call void @llvm.lifetime.end.p0(i64 16, ptr nonnull %13) #5
  br label %81

80:                                               ; preds = %78, %48, %33
  %.2 = phi i32 [ 9, %33 ], [ %.0, %78 ], [ 11, %48 ]
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %5) #5
  br label %82

81:                                               ; preds = %79, %47
  %.pn50.pn.pn.pn.pn = phi { ptr, i32 } [ %.pn50.pn.pn.pn, %47 ], [ %.pn48, %79 ]
  call void @llvm.lifetime.end.p0(i64 40, ptr nonnull %5) #5
  resume { ptr, i32 } %.pn50.pn.pn.pn.pn

82:                                               ; preds = %4, %80
  %.3 = phi i32 [ %.2, %80 ], [ %18, %4 ]
  ret i32 %.3
}

declare noundef i32 @_ZN7hipsycl2rt5pcuda27get_most_recent_pcuda_errorEv() local_unnamed_addr #1

declare void @_ZN7hipsycl2rt5pcuda18thread_local_state22pop_kernel_call_configEv(ptr dead_on_unwind writable sret(%"struct.hipsycl::rt::pcuda::thread_local_state::kernel_call_configuration") align 8, ptr noundef nonnull align 8 dereferenceable(96)) local_unnamed_addr #1

; Function Attrs: mustprogress nounwind uwtable
declare hidden noundef i32 @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_19dim3_sizeE4dim3(i64, i32) local_unnamed_addr #3

declare void @_ZN7hipsycl2rt5pcuda20register_pcuda_errorERKNS0_15source_locationE10pcudaErrorRKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE(ptr noundef nonnull align 8 dereferenceable(68), i32 noundef, ptr noundef nonnull align 8 dereferenceable(32)) local_unnamed_addr #1

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSaIcEC2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #3 align 2

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

declare i32 @__gxx_personality_v0(...)

; Function Attrs: mustprogress uwtable
declare dso_local void @_ZN7hipsycl2rt15source_locationC2ERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEES9_i(ptr noundef nonnull align 8 dereferenceable(68), ptr noundef nonnull align 8 dereferenceable(32), ptr noundef nonnull align 8 dereferenceable(32), i32 noundef) unnamed_addr #2 align 2

; Function Attrs: mustprogress nounwind uwtable
declare void @_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEED2Ev(ptr noundef nonnull align 8 dereferenceable(32)) unnamed_addr #3 align 2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt15__new_allocatorIcED2Ev(ptr noundef nonnull align 1 dereferenceable(1)) unnamed_addr #3 align 2

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN7hipsycl2rt15source_locationD2Ev(ptr noundef nonnull align 8 dereferenceable(68)) unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_122queue_or_default_queueEPNS1_6streamE(ptr noundef) local_unnamed_addr #2

; Function Attrs: mustprogress nounwind uwtable
declare dso_local void @_ZNSt17basic_string_viewIcSt11char_traitsIcEEC2EPKc(ptr noundef nonnull align 8 dereferenceable(16), ptr noundef nonnull) unnamed_addr #3 align 2

; Function Attrs: mustprogress uwtable
declare hidden noundef ptr @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_119extract_kernel_infoEmSt17basic_string_viewIcSt11char_traitsIcEEPPv(i64 noundef, i64, ptr, ptr noundef) local_unnamed_addr #2

declare noundef nonnull align 8 dereferenceable(24) ptr @_ZNK7hipsycl2rt15hcf_kernel_info29get_host_side_parameter_sizesEv(ptr noundef nonnull align 8 dereferenceable(249)) local_unnamed_addr #1

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN7hipsycl2rt20kernel_configurationC2Ev(ptr noundef nonnull align 8 dereferenceable(160)) unnamed_addr #4 align 2

; Function Attrs: mustprogress uwtable
declare hidden void @_ZN7hipsycl2rt5pcuda12_GLOBAL__N_114dim3_to_range3E4dim3(ptr dead_on_unwind noalias writable sret(%"class.hipsycl::rt::static_array") align 8, i64, i32) local_unnamed_addr #2

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

declare noundef zeroext i1 @_ZNK7hipsycl2rt6result10is_successEv(ptr noundef nonnull align 8 dereferenceable(8)) local_unnamed_addr #1

declare void @_ZN7hipsycl2rt5pcuda20register_pcuda_errorERKNS0_6resultE10pcudaError(ptr noundef nonnull align 8 dereferenceable(8), i32 noundef) local_unnamed_addr #1

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

; Function Attrs: inlinehint mustprogress nounwind uwtable
declare dso_local void @_ZN7hipsycl2rt20kernel_configurationD2Ev(ptr noundef nonnull align 8 dereferenceable(160)) unnamed_addr #4 align 2

attributes #0 = { mustprogress 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 uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #3 = { mustprogress 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 #4 = { inlinehint mustprogress nounwind uwtable "min-legal-vector-width"="0" "no-trapping-math"="true" "stack-protector-buffer-size"="8" "target-cpu"="x86-64" "target-features"="+cmov,+cx8,+fxsr,+mmx,+sse,+sse2,+x87" "tune-cpu"="generic" }
attributes #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 = !{!"int", !7, i64 0}
!7 = !{!"omnipotent char", !8, i64 0}
!8 = !{!"Simple C++ TBAA"}
!9 = !{!10, !13, i64 32}
!10 = !{!"_ZTSN7hipsycl2rt5pcuda18thread_local_state25kernel_call_configurationE", !11, i64 0, !11, i64 12, !12, i64 24, !13, i64 32}
!11 = !{!"_ZTS4dim3", !6, i64 0, !6, i64 4, !6, i64 8}
!12 = !{!"long", !7, i64 0}
!13 = !{!"any pointer", !7, i64 0}
!14 = !{!12, !12, i64 0}
!15 = !{!13, !13, i64 0}
!16 = !{!10, !12, i64 24}
!17 = !{!18, !18, i64 0}
!18 = !{!"vtable pointer", !8, i64 0}


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