math: handle bitwise AND better (fix upper limit)
commit7bd0d83b68675a72ce70f5f747bcee1cb63abcaa
authorDan Carpenter <dan.carpenter@oracle.com>
Tue, 23 Dec 2014 08:12:30 +0000 (23 11:12 +0300)
committerDan Carpenter <dan.carpenter@oracle.com>
Tue, 23 Dec 2014 08:12:30 +0000 (23 11:12 +0300)
tree9ebba7b22ebf02dd2267b3b95c5f3025efc1ae49
parent2f2b857a58df579eb6c124907a2692ae95650c71
math: handle bitwise AND better (fix upper limit)

Example code:

foo = (x + 63) & ~63;

Assume that "x is 0-1024".  The old code trimmed took "0-1024 + 63" and
trimmed away the lower 1-63 values giving "0,64-1087" but we can trim away
from the top as well so the new code says, "0,64-1024".

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
smatch_math.c