UINT instead of INT
big optimization patch
tests