Avoid generating temp files in /tmp while nvcc compiling

It seems that nvcc generates unique temporary files in /tmp by pid?

Our problem have been fixed. It is caused by conflict temporary files name in /tmp. We integrate nvcc and bazel as cross compile tools. And the bazel sandbox is enabled. However, the /proc is isolated in bazel sandbox, so pid will start from zero in each sandbox (like starting in docker container). But the /tmp directory is mounted from host filesystem. So the temparory files maybe rewrite by other nvcc process in else sandboxes occasionally.

2 Likes