D | bcmutils.h | 685 #define MODDEC(x, bound) MUX((x) == 0, (bound) - 1, (x) - 1) argument 686 #define MODINC(x, bound) MUX((x) == (bound) - 1, 0, (x) + 1) argument 689 #define MODDEC_POW2(x, bound) (((x) - 1) & ((bound) - 1)) argument 690 #define MODINC_POW2(x, bound) (((x) + 1) & ((bound) - 1)) argument 693 #define MODADD(x, y, bound) \ argument 694 MUX((x) + (y) >= (bound), (x) + (y) - (bound), (x) + (y)) 695 #define MODSUB(x, y, bound) \ argument 696 MUX(((int)(x)) - ((int)(y)) < 0, (x) - (y) + (bound), (x) - (y)) 699 #define MODADD_POW2(x, y, bound) (((x) + (y)) & ((bound) - 1)) argument 700 #define MODSUB_POW2(x, y, bound) (((x) - (y)) & ((bound) - 1)) argument
|