From 96069aeb66cebd81dd0bf8dfe349aa4534a2c930 Mon Sep 17 00:00:00 2001 From: Warren Toomey Date: Fri, 3 Feb 2017 11:35:28 +1000 Subject: [PATCH] Ragge sent in another patch to a7out for the lrs instruction. --- tools/a7out | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tools/a7out b/tools/a7out index e0ed6fe..a8becaf 100755 --- a/tools/a7out +++ b/tools/a7out @@ -680,10 +680,12 @@ sub eae { return; } # lrs: long right shift - if ( ($maskedinstr == 0640500) || ($maskedinstr == 0641500) ) { + if (($maskedinstr & 0766777) == 0640500) { dprintf( "lrs step %d\n", $step ); # Clear AC if the 01000 bit is set - $AC=0 if ($maskedinstr == 0641500); + $AC=0 if ($maskedinstr & 01000); + # Clear MQ if the 010000 bit is set + $MQ=0 if ($maskedinstr & 010000); foreach my $i ( 1 .. $step ) { my $MQmsb = ( $AC & 1 ) ? 0400000 : 0; $AC = ( ( $AC >> 1 ) | ( ($LINK) ? 0400000 : 0 ) ) & MAXINT;