aboutsummaryrefslogtreecommitdiffstats
path: root/src/VeriFuzz/XST.hs
diff options
context:
space:
mode:
authorYann Herklotz <ymherklotz@gmail.com>2019-02-02 22:13:57 +0000
committerYann Herklotz <ymherklotz@gmail.com>2019-02-02 22:13:57 +0000
commit94082601ca31c079065c494cc24020471e0d3e31 (patch)
tree2333eb05bb616827e3f7792a94e71dba0296d119 /src/VeriFuzz/XST.hs
parent686bc953c50cf23b96dba4f182e8005289e71b98 (diff)
downloadverismith-94082601ca31c079065c494cc24020471e0d3e31.tar.gz
verismith-94082601ca31c079065c494cc24020471e0d3e31.zip
Try to add logging
Diffstat (limited to 'src/VeriFuzz/XST.hs')
-rw-r--r--src/VeriFuzz/XST.hs12
1 files changed, 7 insertions, 5 deletions
diff --git a/src/VeriFuzz/XST.hs b/src/VeriFuzz/XST.hs
index 3d745fe..b72d975 100644
--- a/src/VeriFuzz/XST.hs
+++ b/src/VeriFuzz/XST.hs
@@ -39,16 +39,18 @@ defaultXst =
runSynthXst :: Xst -> ModDecl -> FilePath -> Sh ()
runSynthXst sim m outf = do
+ dir <- pwd
writefile xstFile $ xstSynthConfig m
writefile prjFile [st|verilog work "rtl.v"|]
writefile "rtl.v" $ genSource m
- echoP "Run xst"
- noPrint $ timeout_ (xstPath sim) ["-ifn", toTextIgnore xstFile]
- echoP "Run netgen"
- noPrint $ run_ (netgenPath sim)
+ echoP "XST: run"
+ _ <- logger dir "xst" $ timeout (xstPath sim) ["-ifn", toTextIgnore xstFile]
+ echoP "XST: netgen"
+ _ <- logger dir "netgen" $ run (netgenPath sim)
["-w", "-ofmt", "verilog", toTextIgnore $ modFile <.> "ngc", toTextIgnore outf]
- echoP "Clean synthesized file"
+ echoP "XST: clean"
noPrint $ run_ "sed" ["-i", "/^`ifndef/,/^`endif/ d; s/ *Timestamp: .*//;", toTextIgnore outf]
+ echoP "XST: done"
where
modFile = fromText $ modName m
xstFile = modFile <.> "xst"