From 006caad67d5bc651f83167ec3b9861d11a3a809f Mon Sep 17 00:00:00 2001 From: Tobias Platen Date: Thu, 28 May 2020 15:05:38 +0200 Subject: [PATCH] unittest for DataMerger --- src/soc/experiment/l0_cache.py | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/src/soc/experiment/l0_cache.py b/src/soc/experiment/l0_cache.py index 5dc0c21d..40e73a3d 100644 --- a/src/soc/experiment/l0_cache.py +++ b/src/soc/experiment/l0_cache.py @@ -520,6 +520,9 @@ def l0_cache_ldst(dut): assert data == result, "data %x != %x" % (result, data) assert data2 == result2, "data2 %x != %x" % (result2, data2) +def data_merger_merge(dut): + print("TODO") + yield def test_l0_cache(): @@ -531,6 +534,17 @@ def test_l0_cache(): run_simulation(dut, l0_cache_ldst(dut), vcd_name='test_l0_cache_basic.vcd') +def test_data_merger(): + + dut = DataMerger(8) + #vl = rtlil.convert(dut, ports=dut.ports()) + #with open("test_data_merger.il", "w") as f: + # f.write(vl) + + run_simulation(dut, data_merger_merge(dut), + vcd_name='test_data_merger.vcd') + if __name__ == '__main__': test_l0_cache() + #test_data_merger() -- 2.30.2