We are developing plug-ins for various image editors, including Apple Aperture. Our plug-in utilizes CUDA driver API to accelerate computations.
Here is a short description of the problem.
Setup:
- Mac OSX 10.8.3 (latest);
- an NVIDIA GPU with the latest CUDA driver (5.0.59) installed;
- an OSX-sandboxed host application (like Aperture 3.4.3 or Photoshop Elements 11, obtained from Apple AppStore);
- a plug-in for the host application, which loads the CUDA driver (/usr/local/cuda/lib/libcuda.dylib) to enable CUDA-based image processing;
Process:
- we start Aperture, open the plug-in and check if a CUDA GPU is available (by calling cuInit);
Expected results:
- cuInit returns CUDA_SUCCESS;
Actual results:
-
cuInit fails as nvcuda.dylib is not accessible;
-
the System Log of OSX shows the following note:
“5/20/13 9:01:44.281 PM sandboxd: ([58134]) Aperture(58134) deny iokit-open NVDAUser”
(Or when repeating the test with Photoshop Elements 11:
“5/20/13 9:03:32.851 PM sandboxd: ([58165]) Adobe Photoshop (58165) deny iokit-open NVDAUser
5/20/13 8:22:19.687 PM sandboxd: ([57791]) Adobe Photoshop (57791) deny file-read-data /usr/local/cuda/lib/libcuda.dylib”)
Notes:
- in earlier versions of Aperture (those were not yet sandboxed by Apple), the problem did not arise and the plug-in could load the CUDA driver just fine
It looks like any plug-in of any sandboxed application in Mac OSX is currently not able to load and use the CUDA driver because of that problem. The problem seems to be systemic (doesn’t matter
which host application or which plug-in it is), so it needs to be addressed on the level of OSX-to-CUDA interactions. Perhaps it can be resolved by adding the CUDA driver in the exclusion lists
of the OSX Sandbox.
Is it a known issue? Is there a fix or a workaround available?