diff --git a/paddle/legacy/cuda/src/hl_cuda_device.cc b/paddle/legacy/cuda/src/hl_cuda_device.cc index a6e27a37ffef9828de80613facc737dee816f5ce..66bb06374ca17c583c8dda42be84d7637894a5b3 100644 --- a/paddle/legacy/cuda/src/hl_cuda_device.cc +++ b/paddle/legacy/cuda/src/hl_cuda_device.cc @@ -137,10 +137,10 @@ inline pid_t gettid() { #define __NR_gettid 224 #endif pid_t tid = syscall(__NR_gettid); -#endif -#else // _WIN32 +#else // _WIN32 pid_t tid = _getpid(); -#endif // _WIN32 +#endif // _WIN32 +#endif CHECK_NE((int)tid, -1); return tid; }