Mercurial > hg > GearsTemplate
comparison src/parallel_execution/context.h @ 91:1e074c3878c7
modify tree
author | Shohei KOKUBO <e105744@ie.u-ryukyu.ac.jp> |
---|---|
date | Tue, 26 Jan 2016 07:46:26 +0900 |
parents | 4b5bf5b40970 |
children | 851da1107223 |
comparison
equal
deleted
inserted
replaced
90:4b5bf5b40970 | 91:1e074c3878c7 |
---|---|
53 CreateTask2, | 53 CreateTask2, |
54 PutQueue1, | 54 PutQueue1, |
55 PutQueue2, | 55 PutQueue2, |
56 PutQueue3, | 56 PutQueue3, |
57 PutQueue4, | 57 PutQueue4, |
58 GetQueue, | |
58 Exit, | 59 Exit, |
59 }; | 60 }; |
60 | 61 |
61 enum Relational { | 62 enum Relational { |
62 EQ, | 63 EQ, |
66 | 67 |
67 enum UniqueData { | 68 enum UniqueData { |
68 Worker, | 69 Worker, |
69 Allocate, | 70 Allocate, |
70 Tree, | 71 Tree, |
72 Traverse, | |
71 Node, | 73 Node, |
72 LoopCounter, | 74 LoopCounter, |
73 Element, | 75 Element, |
74 ActiveQueue, | 76 ActiveQueue, |
75 }; | 77 }; |
84 pthread_t thread; | 86 pthread_t thread; |
85 stack_ptr code_stack; | 87 stack_ptr code_stack; |
86 stack_ptr node_stack; | 88 stack_ptr node_stack; |
87 int dataNum; | 89 int dataNum; |
88 union Data **data; | 90 union Data **data; |
89 struct Queue* activeQueue; | |
90 struct Tree* tree; | |
91 }; | 91 }; |
92 | 92 |
93 union Data { | 93 union Data { |
94 struct LoopCounter { | 94 struct LoopCounter { |
95 int i; | 95 int i; |
114 struct Array { | 114 struct Array { |
115 int index; | 115 int index; |
116 int* array; | 116 int* array; |
117 } array; | 117 } array; |
118 struct Tree { | 118 struct Tree { |
119 enum Code next; | |
120 struct Node* root; | 119 struct Node* root; |
120 } tree; | |
121 struct Traverse { | |
121 struct Node* current; | 122 struct Node* current; |
122 int result; | 123 int result; |
123 } tree; | 124 } traverse; |
124 struct Node { | 125 struct Node { |
125 // need to tree | 126 // need to tree |
126 enum Code next; | 127 enum Code next; |
127 int key; // comparable data segment | 128 int key; // comparable data segment |
128 union Data* value; | 129 union Data* value; |