mirror of
https://github.com/NVIDIA/cuda-samples.git
synced 2026-10-23 21:28:17 +08:00
Changelog updates
This commit is contained in:
@@ -113,6 +113,10 @@ ifeq (,$(filter $(TARGET_OS),linux darwin qnx android))
|
||||
endif
|
||||
|
||||
# host compiler
|
||||
ifdef HOST_COMPILER
|
||||
CUSTOM_HOST_COMPILER = 1
|
||||
endif
|
||||
|
||||
ifeq ($(TARGET_OS),darwin)
|
||||
ifeq ($(shell expr `xcodebuild -version | grep -i xcode | awk '{print $$2}' | cut -d'.' -f1` \>= 5),1)
|
||||
HOST_COMPILER ?= clang++
|
||||
|
||||
@@ -30,7 +30,7 @@ cudaDeviceGetAttribute, cudaMemPoolImportFromShareableHandle, cudaSetDevice, cud
|
||||
|
||||
## Prerequisites
|
||||
|
||||
Download and install the [CUDA Toolkit 12.1](https://developer.nvidia.com/cuda-downloads) for your corresponding platform.
|
||||
Download and install the [CUDA Toolkit 12.2](https://developer.nvidia.com/cuda-downloads) for your corresponding platform.
|
||||
|
||||
## Build and Run
|
||||
|
||||
|
||||
@@ -368,8 +368,11 @@ static void parentProcess(char *app) {
|
||||
checkCudaErrors(cudaMemPoolExportToShareableHandle(
|
||||
&shareableHandles[i], pools[i], handleType, 0));
|
||||
|
||||
// Get the opaque ‘bag-of-bits’ representing the allocation
|
||||
// Memset handle to 0 to make sure call to `cudaMemPoolImportPointer` in
|
||||
// childProcess will fail if the following call to
|
||||
// `cudaMemPoolExportPointer` fails.
|
||||
memset((void *)&shm->exportPtrData[i], 0, sizeof(cudaMemPoolPtrExportData));
|
||||
// Get the opaque ‘bag-of-bits’ representing the allocation
|
||||
checkCudaErrors(cudaMemPoolExportPointer(
|
||||
(cudaMemPoolPtrExportData *)&shm->exportPtrData[i], ptr));
|
||||
ptrs.push_back(ptr);
|
||||
|
||||
Reference in New Issue
Block a user