Generate ld rd, (rs) instructions properly.
authorDavid Given <dg@cowlark.com>
Wed, 22 May 2013 10:02:46 +0000 (11:02 +0100)
committerDavid Given <dg@cowlark.com>
Wed, 22 May 2013 10:02:46 +0000 (11:02 +0100)
--HG--
branch : dtrg-videocore

mach/vc4/as/mach5.c

index f3671bf..53ec346 100644 (file)
@@ -254,7 +254,7 @@ void mem_instr(quad opcode, int cc, int rd, long offset, int rs)
 
                if ((rs < 0x10) && (rd < 0x10) && (offset == 0))
                {
-                       emit2(B16(00001000,00000000) | (opcode<<8) | (rs<<4) | (rd<<4));
+                       emit2(B16(00001000,00000000) | (opcode<<8) | (rs<<4) | (rd<<0));
                        return;
                }