From 18fe722ecaad6f1bf0de121567f4fb7596d8ae13 Mon Sep 17 00:00:00 2001 From: lkcl Date: Fri, 14 Jun 2019 15:01:43 +0100 Subject: [PATCH] --- isa_conflict_resolution/isamux_isans.mdwn | 29 +++++++---------------- 1 file changed, 9 insertions(+), 20 deletions(-) diff --git a/isa_conflict_resolution/isamux_isans.mdwn b/isa_conflict_resolution/isamux_isans.mdwn index 759439374..d3f3d43c1 100644 --- a/isa_conflict_resolution/isamux_isans.mdwn +++ b/isa_conflict_resolution/isamux_isans.mdwn @@ -118,22 +118,17 @@ MISANS, MTRAPISANS, MLASTISANS and so on):
 trap_entry()
 {
-    if (ISANS != TRAP_ISANS) // musn't change if already there
-    {
-        LAST-ISANS = ISANS // record the old NS
-        ISANS = TRAP_ISANS // traps are executed in "trap" NS
-    }
+
+    LAST-ISANS = ISANS // record the old NS
+    ISANS = TRAP_ISANS // traps are executed in "trap" NS
 }
 
 and trap_exit:
 
 trap_exit():
 {
-    if (LAST-ISANS != TRAP_ISANS)
-    {
-        ISANS = LAST-ISANS
-        LAST-ISANS = TRAP_ISANS
-    }
+    ISANS = LAST-ISANS
+    LAST-ISANS = TRAP_ISANS
 }
 
@@ -151,22 +146,16 @@ Open question: see trap_entry(x_cause) { -    if (ISANS != TRAP_ISANS[xcause]) // musn't change if already there -    { -        LAST-ISANS = ISANS // record the old NS -        ISANS = TRAP_ISANS[xcause] // traps are executed in "trap" NS -    } +    LAST-ISANS = ISANS // record the old NS +    ISANS = TRAP_ISANS[xcause] // traps are executed in "trap" NS } and trap_exit: trap_exit(x_cause): { -    if (LAST-ISANS != TRAP_ISANS[x_cause]) -    { -        ISANS = LAST-ISANS -        LAST-ISANS = TRAP_ISANS[x_cause] -    } +    ISANS = LAST-ISANS +    LAST-ISANS = TRAP_ISANS[x_cause] } -- 2.30.2