Improve memory dump output

This commit is contained in:
Joscha 2019-11-06 18:23:47 +00:00
parent 1c895add5a
commit f07b825313
2 changed files with 17 additions and 9 deletions

View file

@ -79,12 +79,12 @@ main = do
let s = initialState mem
s' <- if norun settings then pure s else runMima settings s
T.putStrLn $ "IP: " <> addrToHexDec (msIp s') <> " "
<> "Acc: " <> wordToHexDec (msAcc s')
unless (quiet settings) $ do
putStrLn "Dump of memory:"
putStrLn "\nDump of memory:"
T.putStrLn $ "IP: " <> addrToHexDec (msIp s') <> " "
<> "Acc: " <> wordToHexDec (msAcc s')
T.putStrLn $ memoryToText (sparse settings) (msMemory s')
putStrLn ""
forM_ (memoryDump settings) $ \path -> do
putStrLn $ "Saving memdump at " ++ path