aboutsummaryrefslogtreecommitdiffstats
path: root/icetime/mktest.py
diff options
context:
space:
mode:
authorClifford Wolf <clifford@clifford.at>2015-10-26 23:33:53 +0100
committerClifford Wolf <clifford@clifford.at>2015-10-26 23:33:53 +0100
commit1a99f955077f461a609511a04d95acc317c001ec (patch)
tree06346a3114ccba896f3b14cccdb9627d93a4c3c8 /icetime/mktest.py
parentb53f442b86dcfc32c097c258d5632917404f2bb9 (diff)
downloadicestorm-1a99f955077f461a609511a04d95acc317c001ec.tar.gz
icestorm-1a99f955077f461a609511a04d95acc317c001ec.tar.bz2
icestorm-1a99f955077f461a609511a04d95acc317c001ec.zip
icetime progress
Diffstat (limited to 'icetime/mktest.py')
-rw-r--r--icetime/mktest.py84
1 files changed, 42 insertions, 42 deletions
diff --git a/icetime/mktest.py b/icetime/mktest.py
index cf1046e..b7f4b2e 100644
--- a/icetime/mktest.py
+++ b/icetime/mktest.py
@@ -55,48 +55,48 @@ os.rename("%s.v" % sys.argv[1], "%s_in.v" % sys.argv[1])
with open("%s_ref.v" % sys.argv[1], "w") as f:
for line in open("%s.vsb" % sys.argv[1], "r"):
- zspan = True
-
- line = line.replace(" Span4Mux_s0_h ", " Span4Mux_h0 " if zspan else " Span4Mux_h0 ")
- line = line.replace(" Span4Mux_s1_h ", " Span4Mux_h0 " if zspan else " Span4Mux_h1 ")
- line = line.replace(" Span4Mux_s2_h ", " Span4Mux_h0 " if zspan else " Span4Mux_h2 ")
- line = line.replace(" Span4Mux_s3_h ", " Span4Mux_h0 " if zspan else " Span4Mux_h3 ")
- line = line.replace(" Span4Mux_h ", " Span4Mux_h0 " if zspan else " Span4Mux_h4 ")
-
- line = line.replace(" Span4Mux_s0_v ", " Span4Mux_v0 " if zspan else " Span4Mux_v0 ")
- line = line.replace(" Span4Mux_s1_v ", " Span4Mux_v0 " if zspan else " Span4Mux_v1 ")
- line = line.replace(" Span4Mux_s2_v ", " Span4Mux_v0 " if zspan else " Span4Mux_v2 ")
- line = line.replace(" Span4Mux_s3_v ", " Span4Mux_v0 " if zspan else " Span4Mux_v3 ")
- line = line.replace(" Span4Mux_v ", " Span4Mux_v0 " if zspan else " Span4Mux_v4 ")
- line = line.replace(" Span4Mux ", " Span4Mux_v0 " if zspan else " Span4Mux_v4 ")
-
- line = line.replace(" Span12Mux_s0_h ", " Span12Mux_h0 " if zspan else " Span12Mux_h0 ")
- line = line.replace(" Span12Mux_s1_h ", " Span12Mux_h0 " if zspan else " Span12Mux_h1 ")
- line = line.replace(" Span12Mux_s2_h ", " Span12Mux_h0 " if zspan else " Span12Mux_h2 ")
- line = line.replace(" Span12Mux_s3_h ", " Span12Mux_h0 " if zspan else " Span12Mux_h3 ")
- line = line.replace(" Span12Mux_s4_h ", " Span12Mux_h0 " if zspan else " Span12Mux_h4 ")
- line = line.replace(" Span12Mux_s5_h ", " Span12Mux_h0 " if zspan else " Span12Mux_h5 ")
- line = line.replace(" Span12Mux_s6_h ", " Span12Mux_h0 " if zspan else " Span12Mux_h6 ")
- line = line.replace(" Span12Mux_s7_h ", " Span12Mux_h0 " if zspan else " Span12Mux_h7 ")
- line = line.replace(" Span12Mux_s8_h ", " Span12Mux_h0 " if zspan else " Span12Mux_h8 ")
- line = line.replace(" Span12Mux_s9_h ", " Span12Mux_h0 " if zspan else " Span12Mux_h9 ")
- line = line.replace(" Span12Mux_s10_h ", " Span12Mux_h0 " if zspan else " Span12Mux_h10 ")
- line = line.replace(" Span12Mux_s11_h ", " Span12Mux_h0 " if zspan else " Span12Mux_h11 ")
- line = line.replace(" Span12Mux ", " Span12Mux_h0 " if zspan else " Span12Mux_h12 ")
-
- line = line.replace(" Span12Mux_s0_v ", " Span12Mux_v0 " if zspan else " Span12Mux_v0 ")
- line = line.replace(" Span12Mux_s1_v ", " Span12Mux_v0 " if zspan else " Span12Mux_v1 ")
- line = line.replace(" Span12Mux_s2_v ", " Span12Mux_v0 " if zspan else " Span12Mux_v2 ")
- line = line.replace(" Span12Mux_s3_v ", " Span12Mux_v0 " if zspan else " Span12Mux_v3 ")
- line = line.replace(" Span12Mux_s4_v ", " Span12Mux_v0 " if zspan else " Span12Mux_v4 ")
- line = line.replace(" Span12Mux_s5_v ", " Span12Mux_v0 " if zspan else " Span12Mux_v5 ")
- line = line.replace(" Span12Mux_s6_v ", " Span12Mux_v0 " if zspan else " Span12Mux_v6 ")
- line = line.replace(" Span12Mux_s7_v ", " Span12Mux_v0 " if zspan else " Span12Mux_v7 ")
- line = line.replace(" Span12Mux_s8_v ", " Span12Mux_v0 " if zspan else " Span12Mux_v8 ")
- line = line.replace(" Span12Mux_s9_v ", " Span12Mux_v0 " if zspan else " Span12Mux_v9 ")
- line = line.replace(" Span12Mux_s10_v ", " Span12Mux_v0 " if zspan else " Span12Mux_v10 ")
- line = line.replace(" Span12Mux_s11_v ", " Span12Mux_v0 " if zspan else " Span12Mux_v11 ")
- line = line.replace(" Span12Mux_v ", " Span12Mux_v0 " if zspan else " Span12Mux_v12 ")
+ zspan_hack = True
+
+ line = line.replace(" Span4Mux_s0_h ", " Span4Mux_h0 " if zspan_hack else " Span4Mux_h0 ")
+ line = line.replace(" Span4Mux_s1_h ", " Span4Mux_h0 " if zspan_hack else " Span4Mux_h1 ")
+ line = line.replace(" Span4Mux_s2_h ", " Span4Mux_h0 " if zspan_hack else " Span4Mux_h2 ")
+ line = line.replace(" Span4Mux_s3_h ", " Span4Mux_h0 " if zspan_hack else " Span4Mux_h3 ")
+ line = line.replace(" Span4Mux_h ", " Span4Mux_h0 " if zspan_hack else " Span4Mux_h4 ")
+
+ line = line.replace(" Span4Mux_s0_v ", " Span4Mux_v0 " if zspan_hack else " Span4Mux_v0 ")
+ line = line.replace(" Span4Mux_s1_v ", " Span4Mux_v0 " if zspan_hack else " Span4Mux_v1 ")
+ line = line.replace(" Span4Mux_s2_v ", " Span4Mux_v0 " if zspan_hack else " Span4Mux_v2 ")
+ line = line.replace(" Span4Mux_s3_v ", " Span4Mux_v0 " if zspan_hack else " Span4Mux_v3 ")
+ line = line.replace(" Span4Mux_v ", " Span4Mux_v0 " if zspan_hack else " Span4Mux_v4 ")
+ line = line.replace(" Span4Mux ", " Span4Mux_v0 " if zspan_hack else " Span4Mux_v4 ")
+
+ line = line.replace(" Span12Mux_s0_h ", " Span12Mux_h0 " if zspan_hack else " Span12Mux_h0 ")
+ line = line.replace(" Span12Mux_s1_h ", " Span12Mux_h0 " if zspan_hack else " Span12Mux_h1 ")
+ line = line.replace(" Span12Mux_s2_h ", " Span12Mux_h0 " if zspan_hack else " Span12Mux_h2 ")
+ line = line.replace(" Span12Mux_s3_h ", " Span12Mux_h0 " if zspan_hack else " Span12Mux_h3 ")
+ line = line.replace(" Span12Mux_s4_h ", " Span12Mux_h0 " if zspan_hack else " Span12Mux_h4 ")
+ line = line.replace(" Span12Mux_s5_h ", " Span12Mux_h0 " if zspan_hack else " Span12Mux_h5 ")
+ line = line.replace(" Span12Mux_s6_h ", " Span12Mux_h0 " if zspan_hack else " Span12Mux_h6 ")
+ line = line.replace(" Span12Mux_s7_h ", " Span12Mux_h0 " if zspan_hack else " Span12Mux_h7 ")
+ line = line.replace(" Span12Mux_s8_h ", " Span12Mux_h0 " if zspan_hack else " Span12Mux_h8 ")
+ line = line.replace(" Span12Mux_s9_h ", " Span12Mux_h0 " if zspan_hack else " Span12Mux_h9 ")
+ line = line.replace(" Span12Mux_s10_h ", " Span12Mux_h0 " if zspan_hack else " Span12Mux_h10 ")
+ line = line.replace(" Span12Mux_s11_h ", " Span12Mux_h0 " if zspan_hack else " Span12Mux_h11 ")
+ line = line.replace(" Span12Mux ", " Span12Mux_h0 " if zspan_hack else " Span12Mux_h12 ")
+
+ line = line.replace(" Span12Mux_s0_v ", " Span12Mux_v0 " if zspan_hack else " Span12Mux_v0 ")
+ line = line.replace(" Span12Mux_s1_v ", " Span12Mux_v0 " if zspan_hack else " Span12Mux_v1 ")
+ line = line.replace(" Span12Mux_s2_v ", " Span12Mux_v0 " if zspan_hack else " Span12Mux_v2 ")
+ line = line.replace(" Span12Mux_s3_v ", " Span12Mux_v0 " if zspan_hack else " Span12Mux_v3 ")
+ line = line.replace(" Span12Mux_s4_v ", " Span12Mux_v0 " if zspan_hack else " Span12Mux_v4 ")
+ line = line.replace(" Span12Mux_s5_v ", " Span12Mux_v0 " if zspan_hack else " Span12Mux_v5 ")
+ line = line.replace(" Span12Mux_s6_v ", " Span12Mux_v0 " if zspan_hack else " Span12Mux_v6 ")
+ line = line.replace(" Span12Mux_s7_v ", " Span12Mux_v0 " if zspan_hack else " Span12Mux_v7 ")
+ line = line.replace(" Span12Mux_s8_v ", " Span12Mux_v0 " if zspan_hack else " Span12Mux_v8 ")
+ line = line.replace(" Span12Mux_s9_v ", " Span12Mux_v0 " if zspan_hack else " Span12Mux_v9 ")
+ line = line.replace(" Span12Mux_s10_v ", " Span12Mux_v0 " if zspan_hack else " Span12Mux_v10 ")
+ line = line.replace(" Span12Mux_s11_v ", " Span12Mux_v0 " if zspan_hack else " Span12Mux_v11 ")
+ line = line.replace(" Span12Mux_v ", " Span12Mux_v0 " if zspan_hack else " Span12Mux_v12 ")
f.write(line)