comparison src/parallel_execution/context.h @ 441:5a737c3df91c

Add AtomicReference Implements of Atomic Interface
author Tatsuki IHA <innparusu@cr.ie.u-ryukyu.ac.jp>
date Tue, 21 Nov 2017 04:28:36 +0900
parents 7679093bdd72
children 0c024ea61601
comparison
equal deleted inserted replaced
440:55db2a339958 441:5a737c3df91c
126 struct Meta { 126 struct Meta {
127 enum DataType type; 127 enum DataType type;
128 long size; 128 long size;
129 long len; 129 long len;
130 struct Queue* wait; // tasks waiting this dataGear 130 struct Queue* wait; // tasks waiting this dataGear
131 } meta; 131 } Meta;
132 struct Context Context; 132 struct Context Context;
133 struct Time { 133 struct Time {
134 union Data* time; 134 union Data* time;
135 enum Code start; 135 enum Code start;
136 enum Code end; 136 enum Code end;
299 enum Color { 299 enum Color {
300 Red, 300 Red,
301 Black, 301 Black,
302 } color; 302 } color;
303 } Node; 303 } Node;
304 struct Atomic {
305 union Data* atomic;
306 union Data* data;
307 enum Code checkAndSet;
308 enum Code next;
309 enum Code fail;
310 } Atomic;
311 struct AtomicReference {
312 union Data* data;
313 } AtomicReference;
304 struct Semaphore { 314 struct Semaphore {
305 union Data* semaphore; 315 union Data* semaphore;
306 enum Code p; 316 enum Code p;
307 enum Code v; 317 enum Code v;
308 enum Code next; 318 enum Code next;