From 522982c9ba02c209edfcd9dca55cbc84f5169979 Mon Sep 17 00:00:00 2001 From: Ganesh Gore Date: Fri, 6 May 2022 22:40:31 -0600 Subject: [PATCH] Adde vtr_benchmarks_template for demo --- openfpga.sh | 1 + .../regression_test_scripts/basic_reg_test.sh | 1 + .../vtr_benchmarks_template/config/task.conf | 54 ++ .../k6_N10_tileable_dpram8K_dsp36_40nm.xml} | 2 +- ...ileable_adder_chain_dpram8K_dsp36_40nm.xml | 828 ++++++++++++++++++ .../vtr_benchmark_template_script.openfpga | 7 + 6 files changed, 892 insertions(+), 1 deletion(-) create mode 100644 openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/config/task.conf rename openfpga_flow/{vpr_arch/k6_N10_tileable_adder_chain_dpram8K_dsp36_40nm.xml => tasks/template_tasks/vtr_benchmarks_template/k6_N10_tileable_dpram8K_dsp36_40nm.xml} (99%) create mode 100644 openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/k6_frac_N10_tileable_adder_chain_dpram8K_dsp36_40nm.xml create mode 100644 openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/vtr_benchmark_template_script.openfpga diff --git a/openfpga.sh b/openfpga.sh index b9b424a37..e4f08cd41 100755 --- a/openfpga.sh +++ b/openfpga.sh @@ -44,6 +44,7 @@ create-task () { if [ ${#2} -ge 1 ]; then if [[ "$2" == "vpr_blif" ]]; then template="template_tasks/${2}_template/"; elif [[ "$2" == "yosys_vpr" ]]; then template="template_tasks/${2}_template/"; + elif [[ "$2" == "vtr_benchmarks" ]]; then template="template_tasks/${2}_template/"; else template="$2" fi fi diff --git a/openfpga_flow/regression_test_scripts/basic_reg_test.sh b/openfpga_flow/regression_test_scripts/basic_reg_test.sh index a4fc1d036..aefc686c8 100755 --- a/openfpga_flow/regression_test_scripts/basic_reg_test.sh +++ b/openfpga_flow/regression_test_scripts/basic_reg_test.sh @@ -181,6 +181,7 @@ run-task basic_tests/fix_pins --debug --show_thread_logs echo -e "Testing project templates"; run-task template_tasks/vpr_blif_template --debug --show_thread_logs run-task template_tasks/yosys_vpr_template --debug --show_thread_logs +run-task template_tasks/vtr_benchmarks_template --debug --show_thread_logs echo -e "Testing create tsk from template and run task" create-task _task_copy basic_tests/generate_fabric diff --git a/openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/config/task.conf b/openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/config/task.conf new file mode 100644 index 000000000..9a210a930 --- /dev/null +++ b/openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/config/task.conf @@ -0,0 +1,54 @@ +# = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +# Configuration file for running experiments +# = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = +# timeout_each_job : FPGA Task script splits fpga flow into multiple jobs +# Each job execute fpga_flow script on combination of architecture & benchmark +# timeout_each_job is timeout for each job +# = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = + +[GENERAL] +run_engine=openfpga_shell +power_tech_file = ${PATH:OPENFPGA_PATH}/openfpga_flow/tech/PTM_45nm/45nm.xml +power_analysis = false +spice_output=false +verilog_output=true +timeout_each_job = 20*60 +fpga_flow=yosys_vpr + +[OpenFPGA_SHELL] +openfpga_shell_template=${PATH:TASK_DIR}/vtr_benchmark_template_script.openfpga +openfpga_arch_file=${PATH:OPENFPGA_PATH}/openfpga_flow/openfpga_arch/k6_frac_N10_adder_chain_dpram8K_dsp36_40nm_openfpga.xml +openfpga_sim_setting_file=${PATH:OPENFPGA_PATH}/openfpga_flow/openfpga_simulation_settings/fixed_sim_openfpga.xml +# VPR parameters +# Use a fixed routing channel width to save runtime +vpr_route_chan_width=300 + +[ARCHITECTURES] +arch0=${PATH:TASK_DIR}/k6_N10_tileable_dpram8K_dsp36_40nm.xml +arch1=${PATH:TASK_DIR}/k6_frac_N10_tileable_adder_chain_dpram8K_dsp36_40nm.xml + +[BENCHMARKS] +bench1=${PATH:OPENFPGA_PATH}/openfpga_flow/benchmarks/vtr_benchmark/ch_intrinsics.v +bench2=${PATH:OPENFPGA_PATH}/openfpga_flow/benchmarks/vtr_benchmark/diffeq1.v +bench3=${PATH:OPENFPGA_PATH}/openfpga_flow/benchmarks/vtr_benchmark/diffeq2.v +bench4=${PATH:OPENFPGA_PATH}/openfpga_flow/benchmarks/vtr_benchmark/sha.v + +[SYNTHESIS_PARAM] +# Yosys script parameters +bench_yosys_cell_sim_verilog_common=${PATH:OPENFPGA_PATH}/openfpga_flow/openfpga_yosys_techlib/k6_frac_N10_tileable_adder_chain_dpram8K_dsp36_40nm_cell_sim.v +bench_yosys_bram_map_rules_common=${PATH:OPENFPGA_PATH}/openfpga_flow/openfpga_yosys_techlib/k6_frac_N10_tileable_adder_chain_dpram8K_dsp36_40nm_bram.txt +bench_yosys_bram_map_verilog_common=${PATH:OPENFPGA_PATH}/openfpga_flow/openfpga_yosys_techlib/k6_frac_N10_tileable_adder_chain_dpram8K_dsp36_40nm_bram_map.v +bench_yosys_dsp_map_verilog_common=${PATH:OPENFPGA_PATH}/openfpga_flow/openfpga_yosys_techlib/k6_frac_N10_tileable_adder_chain_dpram8K_dsp36_40nm_dsp_map.v +bench_yosys_dsp_map_parameters_common=-D DSP_A_MAXWIDTH=36 -D DSP_B_MAXWIDTH=36 -D DSP_A_MINWIDTH=2 -D DSP_B_MINWIDTH=2 -D DSP_NAME=mult_36x36 +bench_read_verilog_options_common = -nolatches +bench_yosys_common=${PATH:OPENFPGA_PATH}/openfpga_flow/misc/ys_tmpl_yosys_vpr_bram_dsp_flow.ys + +# Benchmark top_module name +bench1_top = memset +bench2_top = diffeq_paj_convert +bench3_top = diffeq_f_systemC +bench4_top = sha1 + +[SCRIPT_PARAM_MIN_ROUTE_CHAN_WIDTH] +# end_flow_with_test= +# vpr_fpga_verilog_formal_verification_top_netlist= diff --git a/openfpga_flow/vpr_arch/k6_N10_tileable_adder_chain_dpram8K_dsp36_40nm.xml b/openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/k6_N10_tileable_dpram8K_dsp36_40nm.xml similarity index 99% rename from openfpga_flow/vpr_arch/k6_N10_tileable_adder_chain_dpram8K_dsp36_40nm.xml rename to openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/k6_N10_tileable_dpram8K_dsp36_40nm.xml index 542e22590..a567346af 100644 --- a/openfpga_flow/vpr_arch/k6_N10_tileable_adder_chain_dpram8K_dsp36_40nm.xml +++ b/openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/k6_N10_tileable_dpram8K_dsp36_40nm.xml @@ -559,7 +559,7 @@ --> - + diff --git a/openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/k6_frac_N10_tileable_adder_chain_dpram8K_dsp36_40nm.xml b/openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/k6_frac_N10_tileable_adder_chain_dpram8K_dsp36_40nm.xml new file mode 100644 index 000000000..a34b29c22 --- /dev/null +++ b/openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/k6_frac_N10_tileable_adder_chain_dpram8K_dsp36_40nm.xml @@ -0,0 +1,828 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + io.outpad io.inpad + io.outpad io.inpad + io.outpad io.inpad + io.outpad io.inpad + + + + + + + + + + + + + + + + + + + clb.clk + clb.cin + clb.O[9:0] clb.I[19:0] + clb.cout clb.O[19:10] clb.I[39:20] + + + + + + + + + + + + + + + + + memory.clk + + memory.waddr[4:0] memory.raddr[4:0] memory.data_in[3:0] memory.wen memory.data_out[3:0] + memory.waddr[9:5] memory.raddr[9:5] memory.data_in[7:4] memory.ren memory.data_out[7:4] + + + + + + + + + + + + + + mult_36.b[0:9] mult_36.b[10:35] mult_36.out[36:71] + + mult_36.a[0:9] mult_36.a[10:35] mult_36.out[0:35] + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 1 1 1 1 1 + 1 1 1 1 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 235e-12 + 235e-12 + 235e-12 + 235e-12 + 235e-12 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 195e-12 + 195e-12 + 195e-12 + 195e-12 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + 261e-12 + 261e-12 + 261e-12 + 261e-12 + 261e-12 + 261e-12 + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/vtr_benchmark_template_script.openfpga b/openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/vtr_benchmark_template_script.openfpga new file mode 100644 index 000000000..ebe778df6 --- /dev/null +++ b/openfpga_flow/tasks/template_tasks/vtr_benchmarks_template/vtr_benchmark_template_script.openfpga @@ -0,0 +1,7 @@ +# Execute VPR for architecture exploration + +vpr ${VPR_ARCH_FILE} ${VPR_TESTBENCH_BLIF} \ + --route_chan_width ${VPR_ROUTE_CHAN_WIDTH} \ + --constant_net_method route + +exit \ No newline at end of file