-
- UPDATE_CACHE(re, &s->gb)
-
- if ((int32_t)GET_CACHE(re,&s->gb)<0) { //MSB=1
- level = NEG_USR32( GET_CACHE(re,&s->gb),code);
- } else {
- level = - NEG_USR32(~GET_CACHE(re,&s->gb),code);
+ if(code > MIN_CACHE_BITS - 16){
+ UPDATE_CACHE(re, &s->gb)
+ }
+ {
+ int cache=GET_CACHE(re,&s->gb);
+ int sign=(~cache)>>31;
+ level = (NEG_USR32(sign ^ cache,code) ^ sign) - sign;