43 use,
intrinsic :: iso_c_binding
134#if defined(HAVE_HIP) || defined(HAVE_CUDA) || defined(HAVE_OPENCL)
150 call neko_error(
'Only one device is supported per MPI rank')
156#if defined(HAVE_HIP) || defined(HAVE_CUDA) || defined(HAVE_OPENCL)
172 character(len=*),
intent(inout) :: name
198 type(c_ptr),
intent(inout) :: x_d
199 integer(c_size_t) :: s
209 call neko_error(
'Memory allocation on device failed')
213 call neko_error(
'Memory allocation on device failed')
218 call neko_error(
'Memory allocation on device failed')
225 type(c_ptr),
intent(inout) :: x_d
228 call neko_error(
'Memory deallocation on device failed')
232 call neko_error(
'Memory deallocation on device failed')
236 call neko_error(
'Memory deallocation on device failed')
244 type(c_ptr),
intent(inout) :: x_d
245 integer(c_int),
target,
value :: v
246 integer(c_size_t),
intent(in) :: s
247 logical,
optional :: sync
248 type(c_ptr),
optional :: strm
249 type(c_ptr) :: stream
250 logical :: sync_device
252 if (
present(sync))
then
255 sync_device = .false.
258 if (
present(strm))
then
274 s, 0, c_null_ptr, c_null_ptr) .ne.
cl_success)
then
279 if (sync_device)
then
287 integer,
intent(in) :: n
288 class(*),
intent(inout),
target :: x(:)
289 type(c_ptr),
intent(inout) :: x_d
290 integer,
intent(in),
value :: dir
292 type(c_ptr),
optional :: strm
293 type(c_ptr) :: ptr_h, copy_stream
294 integer(c_size_t) :: s
296 if (
present(strm))
then
304 s = n * int(4, c_size_t)
306 type is (
integer(i8))
307 s = n * int(8, c_size_t)
310 s = n * int(4, c_size_t)
312 type is (double precision)
313 s = n * int(8, c_size_t)
325 integer,
intent(in) :: n
326 class(*),
intent(inout),
target :: x(:,:)
327 type(c_ptr),
intent(inout) :: x_d
328 integer,
intent(in),
value :: dir
330 type(c_ptr),
optional :: strm
331 type(c_ptr) :: ptr_h, copy_stream
332 integer(c_size_t) :: s
334 if (
present(strm))
then
342 s = n * int(4, c_size_t)
344 type is (
integer(i8))
345 s = n * int(8, c_size_t)
348 s = n * int(4, c_size_t)
350 type is (double precision)
351 s = n * int(8, c_size_t)
363 integer,
intent(in) :: n
364 class(*),
intent(inout),
target :: x(:,:,:)
365 type(c_ptr),
intent(inout) :: x_d
366 integer,
intent(in),
value :: dir
368 type(c_ptr),
optional :: strm
369 type(c_ptr) :: ptr_h, copy_stream
370 integer(c_size_t) :: s
372 if (
present(strm))
then
380 s = n * int(4, c_size_t)
382 type is (
integer(i8))
383 s = n * int(8, c_size_t)
386 s = n * int(4, c_size_t)
388 type is (double precision)
389 s = n * int(8, c_size_t)
401 integer,
intent(in) :: n
402 class(*),
intent(inout),
target :: x(:,:,:,:)
403 type(c_ptr),
intent(inout) :: x_d
404 integer,
intent(in),
value :: dir
406 type(c_ptr),
optional :: strm
407 type(c_ptr) :: ptr_h, copy_stream
408 integer(c_size_t) :: s
410 if (
present(strm))
then
418 s = n * int(4, c_size_t)
420 type is (
integer(i8))
421 s = n * int(8, c_size_t)
424 s = n * int(4, c_size_t)
426 type is (double precision)
427 s = n * int(8, c_size_t)
441 type(c_ptr),
intent(inout) :: dst
442 type(c_ptr),
intent(inout) :: src
443 integer(c_size_t),
intent(in) :: s
444 integer,
intent(in),
value :: dir
445 logical,
optional :: sync
446 type(c_ptr),
optional :: strm
447 type(c_ptr) :: copy_stream
448 logical :: sync_device
450 if (
present(sync))
then
453 sync_device = .false.
456 if (
present(strm))
then
470 type(c_ptr),
intent(inout) :: ptr_h
471 type(c_ptr),
intent(inout) :: x_d
472 integer(c_size_t),
intent(in) :: s
473 integer,
intent(in),
value :: dir
474 logical,
intent(in) :: sync_device
475 type(c_ptr),
intent(inout) :: stream
478 if (sync_device)
then
488 call neko_error(
'Device memcpy async (host-to-device) failed')
493 call neko_error(
'Device memcpy async (device-to-host) failed')
498 call neko_error(
'Device memcpy async (device-to-device) failed')
501 call neko_error(
'Device memcpy failed (invalid direction')
503 if (sync_device)
then
510 call neko_error(
'Device memcpy async (host-to-device) failed')
515 call neko_error(
'Device memcpy async (device-to-host) failed')
520 call neko_error(
'Device memcpy async (device-to-device) failed')
523 call neko_error(
'Device memcpy failed (invalid direction')
525 if (sync_device)
then
529 if (sync_device)
then
532 ptr_h, 0, c_null_ptr, c_null_ptr) &
534 call neko_error(
'Device memcpy (host-to-device) failed')
538 0, c_null_ptr, c_null_ptr) &
540 call neko_error(
'Device memcpy (device-to-host) failed')
544 0, c_null_ptr, c_null_ptr) &
546 call neko_error(
'Device memcpy (device-to-device) failed')
549 call neko_error(
'Device memcpy failed (invalid direction')
554 ptr_h, 0, c_null_ptr, c_null_ptr) &
556 call neko_error(
'Device memcpy (host-to-device) failed')
560 0, c_null_ptr, c_null_ptr) &
562 call neko_error(
'Device memcpy (device-to-host) failed')
566 0, c_null_ptr, c_null_ptr) &
568 call neko_error(
'Device memcpy (device-to-device) failed')
571 call neko_error(
'Device memcpy failed (invalid direction')
579 class(*),
intent(inout),
target :: x(:)
580 type(c_ptr),
intent(inout) :: x_d
581 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
585 htbl_ptr_h%ptr = c_loc(x)
586 type is (
integer(i8))
587 htbl_ptr_h%ptr = c_loc(x)
589 htbl_ptr_h%ptr = c_loc(x)
590 type is (double precision)
591 htbl_ptr_h%ptr = c_loc(x)
604 class(*),
intent(inout),
target :: x(:,:)
605 type(c_ptr),
intent(inout) :: x_d
606 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
610 htbl_ptr_h%ptr = c_loc(x)
611 type is (
integer(i8))
612 htbl_ptr_h%ptr = c_loc(x)
614 htbl_ptr_h%ptr = c_loc(x)
615 type is (double precision)
616 htbl_ptr_h%ptr = c_loc(x)
629 class(*),
intent(inout),
target :: x(:,:,:)
630 type(c_ptr),
intent(inout) :: x_d
631 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
635 htbl_ptr_h%ptr = c_loc(x)
636 type is (
integer(i8))
637 htbl_ptr_h%ptr = c_loc(x)
639 htbl_ptr_h%ptr = c_loc(x)
640 type is (double precision)
641 htbl_ptr_h%ptr = c_loc(x)
654 class(*),
intent(inout),
target :: x(:,:,:,:)
655 type(c_ptr),
intent(inout) :: x_d
656 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
660 htbl_ptr_h%ptr = c_loc(x)
661 type is (
integer(i8))
662 htbl_ptr_h%ptr = c_loc(x)
664 htbl_ptr_h%ptr = c_loc(x)
665 type is (double precision)
666 htbl_ptr_h%ptr = c_loc(x)
679 class(*),
intent(inout),
target :: x(:)
680 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
684 htbl_ptr_h%ptr = c_loc(x)
685 type is (
integer(i8))
686 htbl_ptr_h%ptr = c_loc(x)
688 htbl_ptr_h%ptr = c_loc(x)
689 type is (double precision)
690 htbl_ptr_h%ptr = c_loc(x)
703 class(*),
intent(inout),
target :: x(:,:)
704 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
708 htbl_ptr_h%ptr = c_loc(x)
709 type is (
integer(i8))
710 htbl_ptr_h%ptr = c_loc(x)
712 htbl_ptr_h%ptr = c_loc(x)
713 type is (double precision)
714 htbl_ptr_h%ptr = c_loc(x)
727 class(*),
intent(inout),
target :: x(:,:,:)
728 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
732 htbl_ptr_h%ptr = c_loc(x)
733 type is (
integer(i8))
734 htbl_ptr_h%ptr = c_loc(x)
736 htbl_ptr_h%ptr = c_loc(x)
737 type is (double precision)
738 htbl_ptr_h%ptr = c_loc(x)
751 class(*),
intent(inout),
target :: x(:,:,:,:)
752 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
756 htbl_ptr_h%ptr = c_loc(x)
757 type is (
integer(i8))
758 htbl_ptr_h%ptr = c_loc(x)
760 htbl_ptr_h%ptr = c_loc(x)
761 type is (double precision)
762 htbl_ptr_h%ptr = c_loc(x)
775 integer,
intent(in) :: n
776 class(*),
intent(inout),
target :: x(:)
777 type(c_ptr),
intent(inout) :: x_d
778 integer(c_size_t) :: s
780 if (c_associated(x_d))
then
781 call neko_error(
'Device pointer already associated')
786 s = n * int(4, c_size_t)
787 type is (
integer(i8))
788 s = n * int(8, c_size_t)
790 s = n * int(4, c_size_t)
791 type is (double precision)
792 s = n * int(8, c_size_t)
804 integer,
intent(in) :: n
805 class(*),
intent(inout),
target :: x(:,:)
806 type(c_ptr),
intent(inout) :: x_d
807 integer(c_size_t) :: s
809 if (c_associated(x_d))
then
810 call neko_error(
'Device pointer already associated')
815 s = n * int(4, c_size_t)
816 type is (
integer(i8))
817 s = n * int(8, c_size_t)
819 s = n * int(4, c_size_t)
820 type is (double precision)
821 s = n * int(8, c_size_t)
833 integer,
intent(in) :: n
834 class(*),
intent(inout),
target :: x(:,:,:)
835 type(c_ptr),
intent(inout) :: x_d
836 integer(c_size_t) :: s
838 if (c_associated(x_d))
then
839 call neko_error(
'Device pointer already associated')
844 s = n * int(4, c_size_t)
845 type is (
integer(i8))
846 s = n * int(8, c_size_t)
848 s = n * int(4, c_size_t)
849 type is (double precision)
850 s = n * int(8, c_size_t)
862 integer,
intent(in) :: n
863 class(*),
intent(inout),
target :: x(:,:,:,:)
864 type(c_ptr),
intent(inout) :: x_d
865 integer(c_size_t) :: s
867 if (c_associated(x_d))
then
868 call neko_error(
'Device pointer already associated')
873 s = n * int(4, c_size_t)
874 type is (
integer(i8))
875 s = n * int(8, c_size_t)
877 s = n * int(4, c_size_t)
878 type is (double precision)
879 s = n * int(8, c_size_t)
891 class(*),
intent(inout),
target :: x(:)
892 type(c_ptr),
intent(inout) :: x_d
900 if ((.not. mapped) .and. (.not. c_associated(x_d)))
then
915 if ((.not. mapped) .or. (.not. c_associated(x_d)) .or. &
916 (.not. c_associated(dev, x_d)))
then
917 call neko_error(
'Inconsistent host/device mapping state in ' // &
928 class(*),
intent(inout),
target :: x(:,:)
929 type(c_ptr),
intent(inout) :: x_d
937 if ((.not. mapped) .and. (.not. c_associated(x_d)))
then
952 if ((.not. mapped) .or. (.not. c_associated(x_d)) .or. &
953 (.not. c_associated(dev, x_d)))
then
954 call neko_error(
'Inconsistent host/device mapping state in ' // &
965 class(*),
intent(inout),
target :: x(:,:,:)
966 type(c_ptr),
intent(inout) :: x_d
974 if ((.not. mapped) .and. (.not. c_associated(x_d)))
then
989 if ((.not. mapped) .or. (.not. c_associated(x_d)) .or. &
990 (.not. c_associated(dev, x_d)))
then
991 call neko_error(
'Inconsistent host/device mapping state in ' // &
1002 class(*),
intent(inout),
target :: x(:,:,:,:)
1003 type(c_ptr),
intent(inout) :: x_d
1011 if ((.not. mapped) .and. (.not. c_associated(x_d)))
then
1026 if ((.not. mapped) .or. (.not. c_associated(x_d)) .or. &
1027 (.not. c_associated(dev, x_d)))
then
1028 call neko_error(
'Inconsistent host/device mapping state in ' // &
1039 class(*),
intent(inout),
target :: x(:)
1040 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
1045 htbl_ptr_h%ptr = c_loc(x)
1046 type is (
integer(
i8))
1047 htbl_ptr_h%ptr = c_loc(x)
1049 htbl_ptr_h%ptr = c_loc(x)
1050 type is (double precision)
1051 htbl_ptr_h%ptr = c_loc(x)
1066 class(*),
intent(inout),
target :: x(:,:)
1067 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
1072 htbl_ptr_h%ptr = c_loc(x)
1073 type is (
integer(
i8))
1074 htbl_ptr_h%ptr = c_loc(x)
1076 htbl_ptr_h%ptr = c_loc(x)
1077 type is (double precision)
1078 htbl_ptr_h%ptr = c_loc(x)
1093 class(*),
intent(inout),
target :: x(:,:,:)
1094 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
1099 htbl_ptr_h%ptr = c_loc(x)
1100 type is (
integer(
i8))
1101 htbl_ptr_h%ptr = c_loc(x)
1103 htbl_ptr_h%ptr = c_loc(x)
1104 type is (double precision)
1105 htbl_ptr_h%ptr = c_loc(x)
1120 class(*),
intent(inout),
target :: x(:,:,:,:)
1121 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
1126 htbl_ptr_h%ptr = c_loc(x)
1127 type is (
integer(
i8))
1128 htbl_ptr_h%ptr = c_loc(x)
1130 htbl_ptr_h%ptr = c_loc(x)
1131 type is (double precision)
1132 htbl_ptr_h%ptr = c_loc(x)
1147 class(*),
intent(in),
target :: x(:)
1148 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
1155 htbl_ptr_h%ptr = c_loc(x)
1156 type is (
integer(
i8))
1157 htbl_ptr_h%ptr = c_loc(x)
1159 htbl_ptr_h%ptr = c_loc(x)
1160 type is (double precision)
1161 htbl_ptr_h%ptr = c_loc(x)
1169 call neko_error(
'Array not associated with device')
1175 class(*),
intent(in),
target :: x(:,:)
1176 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
1183 htbl_ptr_h%ptr = c_loc(x)
1184 type is (
integer(
i8))
1185 htbl_ptr_h%ptr = c_loc(x)
1187 htbl_ptr_h%ptr = c_loc(x)
1188 type is (double precision)
1189 htbl_ptr_h%ptr = c_loc(x)
1197 call neko_error(
'Array not associated with device')
1203 class(*),
intent(in),
target :: x(:,:,:)
1204 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
1211 htbl_ptr_h%ptr = c_loc(x)
1212 type is (
integer(
i8))
1213 htbl_ptr_h%ptr = c_loc(x)
1215 htbl_ptr_h%ptr = c_loc(x)
1216 type is (double precision)
1217 htbl_ptr_h%ptr = c_loc(x)
1225 call neko_error(
'Array not associated with device')
1231 class(*),
intent(in),
target :: x(:,:,:,:)
1232 type(
h_cptr_t) :: htbl_ptr_h, htbl_ptr_d
1239 htbl_ptr_h%ptr = c_loc(x)
1240 type is (
integer(
i8))
1241 htbl_ptr_h%ptr = c_loc(x)
1243 htbl_ptr_h%ptr = c_loc(x)
1244 type is (double precision)
1245 htbl_ptr_h%ptr = c_loc(x)
1253 call neko_error(
'Array not associated with device')
1276 type(c_ptr),
intent(in) :: stream
1294 type(c_ptr),
intent(inout) :: stream
1295 integer,
optional :: flags
1298 if (
present(flags))
then
1300 call neko_error(
'Error during stream create (w. flags)')
1304 call neko_error(
'Error during stream create')
1308 if (
present(flags))
then
1310 call neko_error(
'Error during stream create (w. flags)')
1314 call neko_error(
'Error during stream create')
1320 call neko_error(
'Error during stream create')
1327 type(c_ptr),
intent(inout) :: stream
1328 integer,
intent(in) :: flags, prio
1331 call neko_error(
'Error during stream create (w. priority)')
1335 call neko_error(
'Error during stream create (w. priority)')
1344 type(c_ptr),
intent(inout) :: stream
1347 call neko_error(
'Error during stream destroy')
1351 call neko_error(
'Error during stream destroy')
1355 call neko_error(
'Error during stream destroy')
1362 type(c_ptr),
intent(in) :: stream
1363 type(c_ptr),
target,
intent(in) :: event
1403 type(c_ptr),
intent(inout) :: event
1404 integer,
optional :: flags
1407 if (
present(flags))
then
1409 call neko_error(
'Error during event create (w. flags)')
1417 if (
present(flags))
then
1419 call neko_error(
'Error during event create (w. flags)')
1433 type(c_ptr),
intent(inout) :: event
1436 call neko_error(
'Error during event destroy')
1440 call neko_error(
'Error during event destroy')
1449 type(c_ptr),
target,
intent(in) :: event
1450 type(c_ptr),
intent(in) :: stream
1468 type(c_ptr),
target,
intent(in) :: event
1478 if (c_associated(event))
then
Associate a Fortran array to a (allocated) device pointer.
Check if a Fortran array is assoicated with a device pointer.
Deassociate a Fortran array from a device pointer.
Return the device pointer for an associated Fortran array.
Map a Fortran array to a device (allocate and associate)
Copy data between host and device (or device and device)
Synchronize a device or stream.
Unmap a Fortran array from a device (deassociate and free)
subroutine cuda_device_name(name)
subroutine cuda_finalize(glb_cmd_queue, aux_cmd_queue)
@ cudamemcpydevicetodevice
integer function cuda_device_count()
Return the number of avaialble CUDA devices.
subroutine cuda_init(glb_cmd_queue, aux_cmd_queue, strm_high_prio, strm_low_prio)
Device abstraction, common interface for various accelerators.
subroutine, public device_event_record(event, stream)
Record a device event.
subroutine, public device_event_sync(event)
Synchronize an event.
subroutine device_associate_r2(x, x_d)
Associate a Fortran rank 2 array to a (allocated) device pointer.
subroutine, public device_finalize
integer, parameter, public device_to_device
type(c_ptr) function device_get_ptr_r4(x)
Return the device pointer for an associated Fortran rank 4 array.
type(c_ptr) function device_get_ptr_r1(x)
Return the device pointer for an associated Fortran rank 1 array.
integer, public strm_low_prio
Low priority stream setting.
integer, parameter, public host_to_device
subroutine device_map_r3(x, x_d, n)
Map a Fortran rank 3 array to a device (allocate and associate)
type(c_ptr), bind(C), public prf_cmd_queue
Profiling command queue.
subroutine, private device_memcpy_common(ptr_h, x_d, s, dir, sync_device, stream)
Copy data between host and device.
logical function device_associated_r3(x)
Check if a Fortran rank 3 array is assoicated with a device pointer.
subroutine device_unmap_r4(x, x_d)
Unmap a Fortran rank 4 array from a device (deassociate and free)
type(htable_cptr_t), private device_addrtbl
Table of host to device address mappings.
subroutine, public device_profiler_stop()
Stop device profiling.
subroutine device_deassociate_r3(x)
Deassociate a Fortran rank 3 array from a device pointer.
subroutine, public device_sync_stream(stream)
Synchronize a device stream.
type(c_ptr) function device_get_ptr_r3(x)
Return the device pointer for an associated Fortran rank 3 array.
subroutine device_unmap_r2(x, x_d)
Unmap a Fortran rank 2 array from a device (deassociate and free)
subroutine, public device_profiler_start()
Start device profiling.
subroutine device_map_r2(x, x_d, n)
Map a Fortran rank 2 array to a device (allocate and associate)
subroutine device_memcpy_r2(x, x_d, n, dir, sync, strm)
Copy data between host and device (rank 2 arrays)
subroutine device_map_r4(x, x_d, n)
Map a Fortran rank 4 array to a device (allocate and associate)
subroutine, public device_free(x_d)
Deallocate memory on the device.
integer, parameter, public device_to_host
subroutine device_memcpy_cptr(dst, src, s, dir, sync, strm)
Copy data between host and device (or device and device) (c-pointers)
subroutine, public device_event_destroy(event)
Destroy a device event.
subroutine, public device_alloc(x_d, s)
Allocate memory on the device.
subroutine, public device_stream_create_with_priority(stream, flags, prio)
Create a device stream/command queue with priority.
subroutine, public device_stream_create(stream, flags)
Create a device stream/command queue.
subroutine device_deassociate_r4(x)
Deassociate a Fortran rank 4 array from a device pointer.
subroutine device_sync_device()
Synchronize the device.
subroutine device_associate_r1(x, x_d)
Associate a Fortran rank 1 array to a (allocated) device pointer.
subroutine device_memcpy_r4(x, x_d, n, dir, sync, strm)
Copy data between host and device (rank 4 arrays)
subroutine, public device_stream_wait_event(stream, event, flags)
Synchronize a device stream with an event.
subroutine device_map_r1(x, x_d, n)
Map a Fortran rank 1 array to a device (allocate and associate)
subroutine device_unmap_r1(x, x_d)
Unmap a Fortran rank 1 array from a device (deassociate and free)
subroutine device_memcpy_r1(x, x_d, n, dir, sync, strm)
Copy data between host and device (rank 1 arrays)
type(c_ptr), bind(C), public glb_cmd_queue
Global command queue.
subroutine, public device_event_create(event, flags)
Create a device event queue.
integer function, public device_count()
Return the number of available devices.
subroutine, public device_name(name)
logical function device_associated_r4(x)
Check if a Fortran rank 4 array is assoicated with a device pointer.
logical function device_associated_r2(x)
Check if a Fortran rank 2 array is assoicated with a device pointer.
integer, public strm_high_prio
High priority stream setting.
type(c_ptr), bind(C), public aux_cmd_queue
Aux command queue.
type(c_ptr) function device_get_ptr_r2(x)
Return the device pointer for an associated Fortran rank 2 array.
subroutine device_associate_r4(x, x_d)
Associate a Fortran rank 4 array to a (allocated) device pointer.
subroutine device_unmap_r3(x, x_d)
Unmap a Fortran rank 3 array from a device (deassociate and free)
subroutine device_deassociate_r1(x)
Deassociate a Fortran rank 1 array from a device pointer.
type(c_ptr), bind(C), public glb_cmd_event
Event for the global command queue.
subroutine device_deassociate_r2(x)
Deassociate a Fortran rank 2 array from a device pointer.
subroutine, public device_init
subroutine device_associate_r3(x, x_d)
Associate a Fortran rank 3 array to a (allocated) device pointer.
logical function device_associated_r1(x)
Check if a Fortran rank 1 array is assoicated with a device pointer.
subroutine, public device_memset(x_d, v, s, sync, strm)
Set memory on the device to a value.
subroutine device_memcpy_r3(x, x_d, n, dir, sync, strm)
Copy data between host and device (rank 3 arrays)
subroutine, public device_stream_destroy(stream)
Destroy a device stream/command queue.
subroutine hip_device_name(name)
@ hipmemcpydevicetodevice
subroutine hip_init(glb_cmd_queue, aux_cmd_queue, strm_high_prio, strm_low_prio)
subroutine hip_finalize(glb_cmd_queue, aux_cmd_queue)
integer function hip_device_count()
Return the number of available HIP devices.
Implements a hash table ADT.
integer, parameter neko_bcknd_device
integer, parameter, public i8
Fortran OpenCL interface.
subroutine opencl_device_name(name)
subroutine opencl_finalize(glb_cmd_queue, aux_cmd_queue, prf_cmd_queue)
integer function opencl_device_count()
Return the number of OpenCL devices.
subroutine opencl_init(glb_cmd_queue, aux_cmd_queue, prf_cmd_queue)
OpenCL JIT program library.
subroutine, public opencl_prgm_lib_release
C pointer based hash table.