Mercurial > hg > Members > Moririn
diff src/parallel_execution/context.h @ 316:54d203daf06b
CUDAtwice.cbc is called.
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Wed, 15 Feb 2017 16:25:23 +0900 |
parents | 8c2123bb577b |
children | f730761bb044 |
line wrap: on
line diff
--- a/src/parallel_execution/context.h Wed Feb 15 12:34:19 2017 +0900 +++ b/src/parallel_execution/context.h Wed Feb 15 16:25:23 2017 +0900 @@ -102,7 +102,7 @@ int i; } LoopCounter; struct TaskManager { - union Data* taskManager; + volatile union Data* taskManager; enum Code createTask; // create NEW contexts for execution & argument enum Code spawn; // start NEW context on the worker enum Code shutdown; @@ -141,14 +141,14 @@ } CPUWorker; #ifdef USE_CUDAWorker struct CUDAWorker { + CUdevice device; + CUcontext cuCtx; pthread_t thread; struct Context* context; int id; struct Queue* tasks; int runFlag; enum Code next; - CUdevice device; - CUcontext cuCtx; int num_stream; CUstream *stream; } CUDAWorker;