thirdparty/cuda/api/memory.hpp
inline void free_region_pair_of(void* ptr)
{
	cudaPointerAttributes attributes;
	auto result = cudaPointerGetAttributes(&attributes, ptr);
	cuda::throw_if_error(result,
		"Could not obtain the properties for the pointer"
		", being necessary for freeing the region pair it's (supposedly) "
		"associated with.");
	cudaFreeHost(attributes.hostPointer);
}
/**
 * Free a pair of mapped memory regions using just one of them
 *
 * @param ptr a pointer to one of the mapped regions (can be either
 * the device-side or the host-side)
 */
Free a pair of mapped memory regions using just one of them
@param ptr a pointer to one of the mapped regions (can be either
the device-side or the host-side)
Free a pair of mapped memory regions using just one of them @param ptr a pointer to one of the mapped regions ( can be either the device - side or the host - side )
inline void free_region_pair_of(void* ptr)
{
	cudaPointerAttributes attributes;
	auto result = cudaPointerGetAttributes(&attributes, ptr);
	cuda::throw_if_error(result,
		"Could not obtain the properties for the pointer"
		", being necessary for freeing the region pair it's (supposedly) "
		"associated with.");
	cudaFreeHost(attributes.hostPointer);
}
inline void free_region_pair_of ( void * ptr ) { cudaPointerAttributes attributes ; auto result = cudaPointerGetAttributes ( & attributes , ptr ) ; cuda :: throw_if_error ( result , " " " " " " ) ; cudaFreeHost ( attributes . hostPointer ) ; }
Free a pair of mapped memory regions using just one of them
 @param ptr a pointer to one of the mapped regions (can be either
 the device-side or the host-side)
Free a pair of mapped memory regions using just one of them @param ptr a pointer to one of the mapped regions ( can be either the device - side or the host - side )