Merge pull request #21 from SymbiFlow/next-clifford

Various improvements in PIP fuzzing and htmlgen
This commit is contained in:
Clifford Wolf 2017-12-23 22:31:24 +01:00 committed by GitHub
commit f602ed79d8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
18 changed files with 67 additions and 28 deletions

View File

@ -24,8 +24,11 @@ $(SPECIMENS_OK):
bash generate.sh $(subst /OK,,$@)
touch $@
run:
+set -ex; make clean; make; make pushdb
clean:
rm -rf specimen_[0-9][0-9][0-9]/ seg_int_[lr].segbits mask_clbl[lm]_[lr].segbits
.PHONY: database pushdb clean
.PHONY: database pushdb run clean

View File

@ -20,10 +20,13 @@ todo.txt:
vivado -mode batch -source piplist.tcl
python3 maketodo.py > todo.txt
run:
+set -ex; while make clean; make todo.txt; test -s todo.txt; do make; make pushdb; done; true
clean:
rm -rf .Xil/ .cache/ filtered_seg_int_[lr].segbits
rm -rf todo.txt vivado* piplist/ piplist.dcp pattern_[lr].txt pips_int_[lr].txt
rm -rf specimen_[0-9][0-9][0-9]/ seg_int_[lr].segbits mask_clbl[lm]_[lr].segbits
.PHONY: database pushdb clean
.PHONY: database pushdb run clean

View File

@ -2,5 +2,5 @@
Fuzzer for INT LOGIC\_OUTS -> IMUX PIPs
---------------------------------------
Run this fuzzer a few times until it produces an empty todo.txt file.
Run this fuzzer a few times until it produces an empty todo.txt file (`make run` will run this loop).

View File

@ -1,6 +1,6 @@
#!/usr/bin/env python3
import sys, re
import sys, re, os
sys.path.append("../../../utils/")
from segmaker import segmaker
@ -62,11 +62,11 @@ for tile, pips_srcs_dsts in tiledata.items():
segmk.addtag(tile, "%s.%s" % (dst, src), 0)
def bitfilter(frame_idx, bit_idx):
assert os.getenv("XRAY_DATABASE") == "artix7"
assert os.getenv("XRAY_DATABASE") in ["artix7", "kintex7"]
if frame_idx in [30, 31]:
return False
return True
segmk.compile()
segmk.compile(bitfilter=bitfilter)
segmk.write()

View File

@ -20,10 +20,13 @@ todo.txt:
vivado -mode batch -source piplist.tcl
python3 maketodo.py | sort -R | head -n10 > todo.txt
run:
+set -ex; while make clean; make todo.txt; test -s todo.txt; do make; make pushdb; done; true
clean:
rm -rf .Xil/ .cache/ filtered_seg_int_[lr].segbits
rm -rf todo.txt vivado* piplist/ piplist.dcp pattern_[lr].txt pips_int_[lr].txt
rm -rf specimen_[0-9][0-9][0-9]/ seg_int_[lr].segbits mask_clbl[lm]_[lr].segbits
.PHONY: database pushdb clean
.PHONY: database pushdb run clean

View File

@ -2,5 +2,5 @@
Fuzzer for INT PIPs driving the CLK wires
-----------------------------------------
Run this fuzzer a few times until it produces an empty todo.txt file.
Run this fuzzer a few times until it produces an empty todo.txt file (`make run` will run this loop).

View File

@ -20,10 +20,13 @@ todo.txt:
vivado -mode batch -source piplist.tcl
python3 maketodo.py | sort -R | head -n10 > todo.txt
run:
+set -ex; while make clean; make todo.txt; test -s todo.txt; do make; make pushdb; done; true
clean:
rm -rf .Xil/ .cache/ filtered_seg_int_[lr].segbits
rm -rf todo.txt vivado* piplist/ piplist.dcp pattern_[lr].txt pips_int_[lr].txt
rm -rf specimen_[0-9][0-9][0-9]/ seg_int_[lr].segbits mask_clbl[lm]_[lr].segbits
.PHONY: database pushdb clean
.PHONY: database pushdb run clean

View File

@ -2,5 +2,5 @@
Fuzzer for INT PIPs driving the CTRL wires
------------------------------------------
Run this fuzzer a few times until it produces an empty todo.txt file.
Run this fuzzer a few times until it produces an empty todo.txt file (`make run` will run this loop).

View File

@ -20,10 +20,13 @@ todo.txt:
vivado -mode batch -source piplist.tcl
python3 maketodo.py | sort -R | head -n10 > todo.txt
run:
+set -ex; while make clean; make todo.txt; test -s todo.txt; do make; make pushdb; done; true
clean:
rm -rf .Xil/ .cache/ filtered_seg_int_[lr].segbits
rm -rf todo.txt vivado* piplist/ piplist.dcp pattern_[lr].txt pips_int_[lr].txt
rm -rf specimen_[0-9][0-9][0-9]/ seg_int_[lr].segbits mask_clbl[lm]_[lr].segbits
.PHONY: database pushdb clean
.PHONY: database pushdb run clean

View File

@ -2,5 +2,5 @@
Fuzzer for INT PIPs driving the GFAN wires
------------------------------------------
Run this fuzzer a few times until it produces an empty todo.txt file.
Run this fuzzer a few times until it produces an empty todo.txt file (`make run` will run this loop).

View File

@ -22,10 +22,13 @@ todo.txt:
echo "INT_R.GFAN0.GND_WIRE" >> todo.txt
echo "INT_R.GFAN1.GND_WIRE" >> todo.txt
run:
+set -ex; make clean; make; make pushdb
clean:
rm -rf .Xil/ .cache/ filtered_seg_int_[lr].segbits
rm -rf todo.txt vivado* piplist/ piplist.dcp pattern_[lr].txt pips_int_[lr].txt
rm -rf specimen_[0-9][0-9][0-9]/ seg_int_[lr].segbits mask_clbl[lm]_[lr].segbits
.PHONY: database pushdb clean
.PHONY: database pushdb run clean

View File

@ -20,10 +20,13 @@ todo.txt:
vivado -mode batch -source piplist.tcl
python3 maketodo.py | sort -R | head -n10 > todo.txt
run:
+set -ex; while make clean; make todo.txt; test -s todo.txt; do if make; then make pushdb; fi; done; true
clean:
rm -rf .Xil/ .cache/ filtered_seg_int_[lr].segbits
rm -rf todo.txt vivado* piplist/ piplist.dcp pattern_[lr].txt pips_int_[lr].txt
rm -rf specimen_[0-9][0-9][0-9]/ seg_int_[lr].segbits
.PHONY: database pushdb clean
.PHONY: database pushdb run clean

View File

@ -2,5 +2,9 @@
Fuzzer for the remaining INT PIPs
---------------------------------
Run this fuzzer a few times until it produces an empty todo.txt file.
Run this fuzzer a few times until it produces an empty todo.txt file (`make run` will run this loop).
This fuzzer occationally fails (depending on some random variables). Just restart it if you encounter
this issue. The script behind `make run` automatically handles errors by re-starting a run if an error
occurs.

View File

@ -20,10 +20,13 @@ todo.txt:
vivado -mode batch -source bipiplist.tcl
python3 maketodo.py | sort -R | head -n5 > todo.txt
run:
+set -ex; while make clean; make todo.txt; test -s todo.txt; do make; make pushdb; done; true
clean:
rm -rf .Xil/ .cache/ vivado* todo.txt
rm -rf bipiplist/ bipiplist.dcp bipips_int_[lr].txt
rm -rf specimen_[0-9][0-9][0-9]/ seg_int_[lr].segbits
.PHONY: database pushdb clean
.PHONY: database pushdb run clean

View File

@ -2,5 +2,5 @@
Fuzzer for bidirectional INT PIPs
---------------------------------
Run this fuzzer a few times until it produces an empty todo.txt file.
Run this fuzzer a few times until it produces an empty todo.txt file (`make run` will run this loop).

View File

@ -24,8 +24,11 @@ $(SPECIMENS_OK):
bash generate.sh $(subst /OK,,$@)
touch $@
run:
+set -ex; make clean; make; make pushdb
clean:
rm -rf specimen_[0-9][0-9][0-9]/ seg_hclk_[lr].segbits mask_hclk_[lr].segbits ppips_hclk_[lr].txt
.PHONY: database pushdb clean
.PHONY: database pushdb run clean

View File

@ -27,7 +27,10 @@ proc write_clb_ppips_db {filename tile} {
foreach pip [get_pips -of_objects $tile] {
set dst_wire [get_wires -downhill -of_objects $pip]
if {[get_pips -uphill -of_objects [get_nodes -of_objects $dst_wire]] == $pip} {
if {[get_property IS_PSEUDO $pip]} {
set src_wire [get_wires -uphill -of_objects $pip]
puts $fp "${tile_type}.[regsub {.*/} $dst_wire ""].[regsub {.*/} $src_wire ""] hint"
} elseif {[get_pips -uphill -of_objects [get_nodes -of_objects $dst_wire]] == $pip} {
set src_wire [get_wires -uphill -of_objects $pip]
puts $fp "${tile_type}.[regsub {.*/} $dst_wire ""].[regsub {.*/} $src_wire ""] always"
}

View File

@ -481,21 +481,26 @@ function oml() {
bgcolor = "#0000ff"
label = "R"
for bn in sorted(routebits[segtype][bit_pos]):
if re.match("^INT_[LR].[SNWE][SNWE]", bn):
bgcolor = "#aa88ff"
label = "SNWE"
if re.match("^INT_[LR].[SNWE][SNWERL]", bn):
if bn[8] == "1":
bgcolor = "#4466bb"
elif bn[8] == "2":
bgcolor = "#aa88ff"
elif bn[6:9] in "SS6 SE6 NN6 NW6".split():
bgcolor = "#7755ff"
else:
bgcolor = "#88aaff"
label = bn[6:9]
elif re.match("^INT_[LR].IMUX", bn):
m = re.match("^INT_[LR].IMUX(_L)?(\d+)", bn)
bgcolor = "#88aaff"
label = "IMUX"
label = "IM" + m.group(2)
elif re.match("^INT_[LR].BYP_ALT", bn):
bgcolor = "#7755ff"
label = "BALT"
label = "BA" + bn[13]
elif re.match("^INT_[LR].FAN_ALT", bn):
bgcolor = "#4466bb"
label = "FALT"
elif re.match("^INT_[LR].[SNWE][RL]", bn):
bgcolor = "#4466bb"
label = "RL"
label = "FA" + bn[13]
elif re.match("^INT_[LR].CLK", bn):
bgcolor = "#4466bb"
label = "CLK"