Fixed some signed/unsigned errors in the CPU