aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNikita Orlov <nikitf-97@mail.ru>2021-03-22 13:00:02 +0300
committerNikita Orlov <nikitf-97@mail.ru>2021-03-22 13:00:02 +0300
commit9180aab5f90381b8e9fec0288b795cf197e3b420 (patch)
treeea854049b3363e36910e57a8d2aaf557dc48290c
parent433b2173acf1ed838733f58294c0a4286cdce122 (diff)
downloadsuem-9180aab5f90381b8e9fec0288b795cf197e3b420.tar
suem-9180aab5f90381b8e9fec0288b795cf197e3b420.tar.xz
suem-9180aab5f90381b8e9fec0288b795cf197e3b420.zip
UNLK fix
-rw-r--r--src/Commands.hs7
1 files changed, 2 insertions, 5 deletions
diff --git a/src/Commands.hs b/src/Commands.hs
index 87c01f6..6fce17b 100644
--- a/src/Commands.hs
+++ b/src/Commands.hs
@@ -119,11 +119,8 @@ doUNLK a = do
with pc $ \pc -> do
pcval <- readIORef pc
writeIORef pc (pcval + 2)
- isSupervisor >>= \sup -> if sup
- then with ssp $ \sp -> do
- writeIORef sp (val + 4)
- else with usp $ \sp -> do
- writeIORef sp (val + 4)
+ writeA a val
+ writeA 7 (addr + 4)
doMOVEUSP :: Int -> Int -> Emulator ()
doMOVEUSP _ _ = return ()