From: David Given Date: Fri, 28 Jun 2013 23:35:07 +0000 (+0100) Subject: Fix incorrect offset encoding in lea (sp) instructions. X-Git-Tag: release-6-0-pre-5~10^2~3^2 X-Git-Url: https://git.ndcode.org/public/gitweb.cgi?a=commitdiff_plain;h=8b6951dac002428c8a8585137418754cfeae1a56;p=ack.git Fix incorrect offset encoding in lea (sp) instructions. --HG-- branch : dtrg-videocore --- diff --git a/mach/vc4/as/mach5.c b/mach/vc4/as/mach5.c index e98f67594..5f10facf0 100644 --- a/mach/vc4/as/mach5.c +++ b/mach/vc4/as/mach5.c @@ -457,6 +457,7 @@ void lea_stack_instr(int rd, long va, int rs) if (rs != 25) serror("source register must be sp"); + va /= 4; if (!fitx(va, 6)) serror("offset too big to encode in instruction"); va = maskx(va, 6);