From a1a6de28e6acd0ff28e6ba1df5f98a9f115380d7 Mon Sep 17 00:00:00 2001 From: John McMaster Date: Fri, 10 Nov 2017 16:46:08 -0800 Subject: [PATCH] LUT5: polish Signed-off-by: John McMaster Signed-off-by: Tim 'mithro' Ansell --- fuzzers/012-lut5/Makefile | 7 ++++--- fuzzers/012-lut5/generate.py | 5 ++--- fuzzers/012-lut5/generate.sh | 2 ++ fuzzers/012-lut5/generate.tcl | 26 -------------------------- 4 files changed, 8 insertions(+), 32 deletions(-) diff --git a/fuzzers/012-lut5/Makefile b/fuzzers/012-lut5/Makefile index 90c19eeb..b3216fe6 100644 --- a/fuzzers/012-lut5/Makefile +++ b/fuzzers/012-lut5/Makefile @@ -1,11 +1,12 @@ - N := 1 SPECIMENS := $(addprefix specimen_,$(shell seq -f '%03.0f' $(N))) SPECIMENS_OK := $(addsuffix /OK,$(SPECIMENS)) database: $(SPECIMENS_OK) - #cp specimen_001/tilegrid.json tilegrid.json - true + ../../tools/segmatch -o seg_clbll.segbits \ + $(addsuffix /segdata_clbll.txt,$(SPECIMENS)) + ../../tools/segmatch -o seg_clblm.segbits \ + $(addsuffix /segdata_clblm.txt,$(SPECIMENS)) pushdb: cp tilegrid.json ../../database/$(XRAY_DATABASE)/tilegrid.json diff --git a/fuzzers/012-lut5/generate.py b/fuzzers/012-lut5/generate.py index ec3b7c8d..a891cced 100644 --- a/fuzzers/012-lut5/generate.py +++ b/fuzzers/012-lut5/generate.py @@ -24,11 +24,10 @@ with open("design.txt", "r") as f: site_lut_name = line[4] site, lut_name = site_lut_name.split('/') lut_type = line[5] - + if lut_type in ('LUT5', 'LUT6'): which = lut_name[0] - segmk.addtag(site, "%s.LUT5" % which, lut_type == 'LUT5') - #segmk.addtag(site, "%s.LUT6" % which, lut_type == 'LUT6') + segmk.addtag(site, "%cLUT5" % which, lut_type == 'LUT5') segmk.compile() segmk.write() diff --git a/fuzzers/012-lut5/generate.sh b/fuzzers/012-lut5/generate.sh index a509e83b..d40bb231 100644 --- a/fuzzers/012-lut5/generate.sh +++ b/fuzzers/012-lut5/generate.sh @@ -10,3 +10,5 @@ for x in design*.bit; do ../../../tools/bitread -F $XRAY_ROI_FRAMES -o ${x}s -zy $x done +python3 ../generate.py + diff --git a/fuzzers/012-lut5/generate.tcl b/fuzzers/012-lut5/generate.tcl index fdfafcfd..0826eded 100644 --- a/fuzzers/012-lut5/generate.tcl +++ b/fuzzers/012-lut5/generate.tcl @@ -25,15 +25,10 @@ write_checkpoint -force design.dcp write_bitstream -force design.bit - - - # Get all 6LUT and 5LUT in pblock # A6LUT, B6LUT, A5LUT, etc set luts [get_bels -of_objects [get_sites -of_objects [get_pblocks roi]] -filter {TYPE =~ LUT*} */*LUT] - - set grid_min_x -1 set grid_max_x -1 set grid_min_y -1 @@ -51,27 +46,6 @@ foreach lut $luts { if [expr $grid_max_y < 0 || $grid_y > $grid_max_y] {set grid_max_y $grid_y} } -# set tiles [get_tiles -filter "GRID_POINT_X >= $grid_min_x && GRID_POINT_X <= $grid_max_x && GRID_POINT_Y >= $grid_min_y && GRID_POINT_Y <= $grid_max_y"] -# set fp [open "tiles.txt" w] -# foreach tile $tiles { -# set type [get_property TYPE $tile] -# set grid_x [get_property GRID_POINT_X $tile] -# set grid_y [get_property GRID_POINT_Y $tile] -# set sites [get_sites -quiet -of_objects $tile] -# set typed_sites {} -# -# if [llength $sites] { -# set site_types [get_property SITE_TYPE $sites] -# foreach t $site_types s $sites { -# lappend typed_sites $t $s -# } -# } -# -# puts $fp "$type $tile $grid_x $grid_y $typed_sites" -# } -# close $fp - - set fp [open "design.txt" w] foreach lut $luts { set tile [get_tile -of_objects $lut]