uint32 dataqsiz; // size of the circular q
uint32 qcount; // total data in the q
uint32 eo; // vararg of element
- uint32 po; // vararg of present bool
+ uint32 po1; // vararg of present bool in next structure
+ uint32 po2; // vararg of present bool in same structure
Alg* elemalg; // interface for element type
Link* senddataq; // pointer for sender
Link* recvdataq; // pointer for receiver
// these calculations are compiler dependent
c->eo = rnd(sizeof(c), elemsize);
- c->po = rnd(c->eo+elemsize, 1);
+ c->po1 = rnd(c->eo+elemsize, 8); // next structure
+ c->po2 = rnd(c->eo+elemsize, 1); // same structure
ret = c;
FLUSH(&ret);
sys·printint(c->dataqsiz);
prints("\n");
}
-
}
// chansend1(hchan *chan any, elem any);
G *gr;
ae = (byte*)&c + c->eo;
- ap = (byte*)&c + c->po;
+ ap = (byte*)&c + c->po1;
+
if(debug) {
prints("chansend: chan=");
sys·printpointer(c);
G *gs;
ae = (byte*)&c + c->eo;
- ap = (byte*)&c + c->po;
+ ap = (byte*)&c + c->po2;
+
if(debug) {
prints("chanrecv2: chan=");
sys·printpointer(c);