Lines Matching refs:pp
42 struct pushpull pp;
47 static inline void init_pushpull(struct pushpull *pp, char *buf,
51 pp->buf = buf;
52 pp->buflen = buflen;
53 pp->ofs = ofs;
54 pp->reserve = reserve;
57 static inline int pushbit(struct pushpull *pp, int bit, int use_reserved)
59 if (pp->ofs >= pp->buflen - (use_reserved?0:pp->reserve))
63 pp->buf[pp->ofs >> 3] |= (1<<(7-(pp->ofs & 7)));
65 pp->buf[pp->ofs >> 3] &= ~(1<<(7-(pp->ofs & 7)));
67 pp->ofs++;
72 static inline int pushedbits(struct pushpull *pp)
74 return pp->ofs;
77 static inline int pullbit(struct pushpull *pp)
81 bit = (pp->buf[pp->ofs >> 3] >> (7-(pp->ofs & 7))) & 1;
83 pp->ofs++;
112 ret = pushbit(&rs->pp, (rs->q & UPPER_BIT_RUBIN) ? 1 : 0, 0);
144 pushbit(&rs->pp, (UPPER_BIT_RUBIN & rs->q) ? 1 : 0, 1);
159 rs->rec_q = rs->rec_q * 2 + (long) (pullbit(&rs->pp)))
192 c = pullbit(&rs->pp);
270 init_pushpull(&rs.pp, cpage_out, *dstlen * 8, 0, 32);
282 outpos = (pushedbits(&rs.pp)+7)/8;
371 init_pushpull(&rs.pp, cdata_in, srclen, 0, 0);