annotate src/parallel_execution/taskManager.c @ 269:5170539348ec

rename TaskManagerImpl.cbc
author mir3636
date Sun, 29 Jan 2017 22:15:32 +0900
parents cd3486e4ba70
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
1 #include "context.h"
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
2 #include "stack.h"
182
57a11c15ff4c Add queue_test
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 178
diff changeset
3 #include "queue.h"
237
mir3636
parents: 236
diff changeset
4 #include "worker.h"
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
5 #include "origin_cs.h"
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
6 #include <stdio.h>
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
7
257
cd3486e4ba70 fix make error of twice
mir3636
parents: 248
diff changeset
8 void createWorkers(struct Context* context, TaskManager* taskManeger, TaskManagerImpl* taskManagerImpl);
237
mir3636
parents: 236
diff changeset
9
233
06133afb3b5b create worker start_code
mir3636
parents: 231
diff changeset
10 union Data* createTaskManager(struct Context* context, int numCPU, int numGPU, int numIO) {
209
5708390a9d88 fix compile errors
mir3636
parents: 184
diff changeset
11 struct TaskManager* taskManager = &ALLOCATE(context, TaskManager)->TaskManager;
233
06133afb3b5b create worker start_code
mir3636
parents: 231
diff changeset
12 // 0...numIO-1 IOProcessor
06133afb3b5b create worker start_code
mir3636
parents: 231
diff changeset
13 // numIO...numIO+numGPU-1 GPUProcessor
06133afb3b5b create worker start_code
mir3636
parents: 231
diff changeset
14 // numIO+numGPU...numIO+numGPU+numCPU-1 CPUProcessor
06133afb3b5b create worker start_code
mir3636
parents: 231
diff changeset
15 taskManager->io = 0;
06133afb3b5b create worker start_code
mir3636
parents: 231
diff changeset
16 taskManager->gpu = numIO;
235
05e61405cc88 fix worker compile error
mir3636
parents: 234
diff changeset
17 taskManager->cpu = numIO+numGPU;
236
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
18 taskManager->maxCPU = numIO+numGPU+numCPU;
234
47588c28f189 TaskManager
mir3636
parents: 233
diff changeset
19 taskManager->createTask = C_createTask;
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
20 taskManager->spawn = C_spawnTaskManager;
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
21 taskManager->shutdown = C_shutdownTaskManager;
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
22 struct TaskManagerImpl* taskManagerImpl = &ALLOCATE(context, TaskManagerImpl)->TaskManagerImpl;
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
23 taskManager->taskManager = (union Data*)taskManagerImpl;
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
24 taskManagerImpl -> activeQueue = &createSingleLinkedQueue(context)->Queue;
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
25 taskManagerImpl -> taskQueue = &createSingleLinkedQueue(context)->Queue;
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
26 taskManagerImpl -> numWorker = taskManager->maxCPU;
247
ce262b2c1daf Fix createTask for main
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 244
diff changeset
27 createWorkers(context, taskManager, taskManagerImpl);
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
28 return (union Data*)(taskManager);
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
29 }
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
30
257
cd3486e4ba70 fix make error of twice
mir3636
parents: 248
diff changeset
31 void createWorkers(struct Context* context, TaskManager* taskManager, TaskManagerImpl* taskManagerImpl) {
236
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
32 int i = 0;
244
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
33 taskManagerImpl->workers = (Worker**)ALLOC_ARRAY(context, Worker, taskManager->maxCPU);
240
864bb372f37f Add spawnTask1
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
34 for (;i<taskManager->gpu;i++) {
236
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
35 Queue* queue = &createSynchronizedQueue(context)->Queue;
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
36 taskManagerImpl->workers[i] = (Worker*)createCPUWorker(context, i, queue);
236
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
37 }
240
864bb372f37f Add spawnTask1
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
38 for (;i<taskManager->cpu;i++) {
236
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
39 #ifdef USE_CUDA
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
40 #else
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
41 Queue* queue = &createSynchronizedQueue(context)->Queue;
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
42 taskManagerImpl->workers[i] = (Worker*)createCPUWorker(context, i, queue);
236
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
43 #endif
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
44 }
240
864bb372f37f Add spawnTask1
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
45 for (;i<taskManager->maxCPU;i++) {
236
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
46 Queue* queue = &createSynchronizedQueue(context)->Queue;
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
47 taskManagerImpl->workers[i] = (Worker*)createCPUWorker(context, i, queue);
236
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
48 }
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
49 }
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
50
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
51 __code createTask(struct Context* context, TaskManager* taskManager) {
236
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
52 taskManager->context = NEW(struct Context);
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
53 initContext(taskManager->context);
247
ce262b2c1daf Fix createTask for main
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 244
diff changeset
54 goto meta(context, C_setWorker);
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
55 }
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
56
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
57 __code createTask_stub(struct Context* context) {
247
ce262b2c1daf Fix createTask for main
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 244
diff changeset
58 goto createTask(context, Gearef(context,TaskManager));
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
59 }
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
60
257
cd3486e4ba70 fix make error of twice
mir3636
parents: 248
diff changeset
61 __code setWorker(struct Context* context, TaskManagerImpl* taskManager, struct Context* task, enum Code next) {
244
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
62 task->workerId = taskManager->sendWorkerIndex;
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
63 if(++taskManager->sendWorkerIndex >= taskManager->numWorker) {
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
64 taskManager->sendWorkerIndex = 0;
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
65 }
236
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
66 goto meta(context, next);
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
67 }
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
68
247
ce262b2c1daf Fix createTask for main
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 244
diff changeset
69 __code setWorker_stub(struct Context* context) {
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
70 TaskManagerImpl* taskManager = (TaskManagerImpl*)GearImpl(context, TaskManager, taskManager);
247
ce262b2c1daf Fix createTask for main
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 244
diff changeset
71 goto setWorker(context, taskManager, Gearef(context, TaskManager)->context, Gearef(context, TaskManager)->next);
236
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
72 }
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
73
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
74 __code spawnTaskManager(struct Context* context, struct TaskManagerImpl* taskManager, struct Queue* queue, struct Context* task, enum Code next) {
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
75 if (task->idgCount == 0) {
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
76 // enqueue activeQueue
218
d8a59b727f65 Fix spawnTaskManager
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 209
diff changeset
77 queue->queue = (union Data*)taskManager->activeQueue;
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
78 } else {
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
79 // enqueue waitQueue
218
d8a59b727f65 Fix spawnTaskManager
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 209
diff changeset
80 queue->queue = (union Data*)taskManager->taskQueue;
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
81 }
218
d8a59b727f65 Fix spawnTaskManager
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 209
diff changeset
82 queue->data = (union Data*)task;
240
864bb372f37f Add spawnTask1
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
83 queue->next = C_spawnTaskManager1;
209
5708390a9d88 fix compile errors
mir3636
parents: 184
diff changeset
84 goto meta(context, queue->queue->Queue.put);
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
85 }
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
86
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
87 __code spawnTaskManager_stub(struct Context* context) {
239
mir3636
parents: 237
diff changeset
88 TaskManagerImpl* taskManager = (TaskManagerImpl*)GearImpl(context, TaskManager, taskManager);
mir3636
parents: 237
diff changeset
89 pthread_mutex_lock(&taskManager->mutex);
209
5708390a9d88 fix compile errors
mir3636
parents: 184
diff changeset
90 goto spawnTaskManager(context,
239
mir3636
parents: 237
diff changeset
91 taskManager,
236
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
92 Gearef(context, Queue),
865179a0a56d fix taskManager
ikkun
parents: 235
diff changeset
93 Gearef(context, TaskManager)->context,
240
864bb372f37f Add spawnTask1
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
94 Gearef(context, TaskManager)->next);
864bb372f37f Add spawnTask1
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
95 }
864bb372f37f Add spawnTask1
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
96
864bb372f37f Add spawnTask1
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
97
247
ce262b2c1daf Fix createTask for main
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 244
diff changeset
98 __code spawnTaskManager1(struct Context* context, struct TaskManagerImpl* taskManager) {
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
99 pthread_mutex_unlock(&taskManager->mutex);
247
ce262b2c1daf Fix createTask for main
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 244
diff changeset
100 goto meta(context, C_taskSend);
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
101 }
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
102
240
864bb372f37f Add spawnTask1
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 237
diff changeset
103 __code spawnTaskManager1_stub(struct Context* context) {
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
104 TaskManagerImpl* taskManager = (TaskManagerImpl*)GearImpl(context, TaskManager, taskManager);
244
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
105 goto spawnTaskManager1(context,
247
ce262b2c1daf Fix createTask for main
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 244
diff changeset
106 taskManager);
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
107 }
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
108
244
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
109 __code taskSend(struct Context* context, TaskManagerImpl* taskManager, Queue* queue) {
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
110 queue->queue = (union Data*)taskManager->activeQueue;
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
111 queue->next = C_taskSend1;
248
1ede5390cda2 Fix segmentation fault but not multi thread running
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 247
diff changeset
112 goto meta(context, taskManager->activeQueue->take);
239
mir3636
parents: 237
diff changeset
113 }
mir3636
parents: 237
diff changeset
114
mir3636
parents: 237
diff changeset
115 __code taskSend_stub(struct Context* context) {
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
116 TaskManagerImpl* taskManager = (TaskManagerImpl*)GearImpl(context, TaskManager, taskManager);
244
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
117 goto taskSend(context, taskManager, Gearef(context, Queue));
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
118 }
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
119
244
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
120 __code taskSend1(struct Context* context, TaskManagerImpl* taskManager, Queue* queue, struct Context* task, enum Code next) {
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
121 struct Queue* tasks = taskManager->workers[task->workerId]->tasks;
244
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
122 queue->queue = (union Data*)tasks;
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
123 queue->data = (union Data*)task;
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
124 queue->next = next;
244
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
125 pthread_cond_signal(&taskManager->workers[task->workerId]->worker->CPUWorker.cond);
242
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
126 goto meta(context, tasks->put);
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
127 }
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
128
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
129 __code taskSend1_stub(struct Context* context) {
9f3f8ed6ed9f Add sendTask
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 241
diff changeset
130 TaskManagerImpl* taskManager = (TaskManagerImpl*)GearImpl(context, TaskManager, taskManager);
244
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
131 goto taskSend1(context, taskManager, Gearef(context, Queue), Gearef(context, TaskManager)->context, Gearef(context, TaskManager)->next);
222
77faa28128b4 Add taskSend for TaskManager
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 221
diff changeset
132 }
231
mir3636
parents: 230
diff changeset
133
248
1ede5390cda2 Fix segmentation fault but not multi thread running
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 247
diff changeset
134 __code shutdownTaskManager(struct Context* context, struct LoopCounter* loopCounter, TaskManager* taskManager, TaskManagerImpl* taskManagerImpl, Queue* queue, enum Code next) {
230
a1fb3f2d1a36 fix worker
ikkun
parents: 223
diff changeset
135 int i = loopCounter->i;
244
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
136 if (taskManager->cpu <= i && i < taskManager->maxCPU) {
248
1ede5390cda2 Fix segmentation fault but not multi thread running
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 247
diff changeset
137 struct Queue* tasks = taskManagerImpl->workers[i]->tasks;
1ede5390cda2 Fix segmentation fault but not multi thread running
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 247
diff changeset
138 queue->queue = (union Data*)tasks;
1ede5390cda2 Fix segmentation fault but not multi thread running
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 247
diff changeset
139 queue->data = NULL;
1ede5390cda2 Fix segmentation fault but not multi thread running
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 247
diff changeset
140 queue->next = next;
1ede5390cda2 Fix segmentation fault but not multi thread running
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 247
diff changeset
141 goto meta(context, tasks->put);
244
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
142 pthread_join(taskManagerImpl->workers[i]->worker->CPUWorker.thread, NULL);
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
143 loopCounter->i++;
231
mir3636
parents: 230
diff changeset
144 goto meta(context, C_shutdownTaskManager);
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
145 }
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
146
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
147 loopCounter->i = 0;
223
8d2519c3a36e Add input data gear example
one
parents: 222
diff changeset
148 goto meta(context, taskManager->next);
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
149 }
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
150
182
57a11c15ff4c Add queue_test
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 178
diff changeset
151 __code shutdownTaskManager_stub(struct Context* context) {
244
d1567718f12c Fix error
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 242
diff changeset
152 TaskManagerImpl* taskManagerImpl = (TaskManagerImpl*)GearImpl(context, TaskManager, taskManager);
248
1ede5390cda2 Fix segmentation fault but not multi thread running
Tatsuki IHA <e125716@ie.u-ryukyu.ac.jp>
parents: 247
diff changeset
153 goto shutdownTaskManager(context, Gearef(context, LoopCounter), Gearef(context, TaskManager), taskManagerImpl, Gearef(context, Queue), Gearef(context, TaskManager)->next);
178
5077cf9bf54e add TaskManager.c
mir3636
parents:
diff changeset
154 }