unittest: simplify bitshift test code

Use macros to reduce massive code duplication.  We also get better
debugging information for failed tests this way, including the input,
output, and expected output.
bitshift: faster arithmetic right shifts

Provide special handling for 15 and 16 bit shifts, which are identical
and copy the sign bit into all bits.  For smaller shifts of at least 8
bits, the fastest method still seems to be to use CBW on AL.