int omp_target_is_present(const void *ptr, int device_num);
Summary The omp_target_is_present routine tests whether a host pointer refers to storage that is mapped to a given device.
Constraints on Arguments The value of ptr must be a valid host pointer or NULL (or C_NULL_PTR, for Fortran). The device_num argument must be greater than or equal to zero and less than or equal to the result of omp_get_num_devices().
Binding The binding task set for an omp_target_is_present region is the encountering task.
Effect The omp_target_is_present routine returns true if device_num refers to the host device or if ptr refers to storage that has corresponding storage in the device data environment of device device_num. Otherwise, the routine returns false.
Restrictions Restrictions to the omp_target_is_present routine are as follows.