#define max(x, y) x - ((xy) & ((xy) >> 31))
This assumes x and y are 32 bits.
This works because the most significant bit of a negative integer is 1.
Thus, if xy is negative (y is greater than x), then x - (x - y) = y.
If xy is positive, then x is greater than y, the most significant bit is zero, and therefore x - 0 = x.
31 represents the total number of bits of the variable - 1. (thus, the most significant bit).
I guess this is what they are looking for since it does not use comparisons.
source share