From 36353060f02aec6cc97765b703724cd5b9ac761f Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Fri, 19 Apr 2019 02:42:20 +0100 Subject: [PATCH] experimenting with PTW --- TLB/src/ariane/test_ptw.py | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/TLB/src/ariane/test_ptw.py b/TLB/src/ariane/test_ptw.py index 35581bdb..fd5fc0ac 100644 --- a/TLB/src/ariane/test_ptw.py +++ b/TLB/src/ariane/test_ptw.py @@ -44,6 +44,41 @@ def testbench(dut): yield yield + addr = 0x4000000 + yield dut.dtlb_vaddr_i.eq(addr) + yield dut.mxr_i.eq(0x1) + yield dut.req_port_i.data_gnt.eq(1) + yield dut.req_port_i.data_rvalid.eq(1) + yield dut.req_port_i.data_rdata.eq(0x82<<56 | addr<<2)#pte.flatten()) + + yield dut.en_ld_st_translation_i.eq(1) + yield dut.asid_i.eq(1) + + yield dut.dtlb_access_i.eq(1) + yield dut.dtlb_hit_i.eq(0) + yield dut.dtlb_vaddr_i.eq(addr) + + yield + yield + yield + yield + yield + yield + yield + yield + + yield dut.req_port_i.data_gnt.eq(0) + yield dut.dtlb_access_i.eq(1) + yield dut.dtlb_hit_i.eq(0) + yield dut.dtlb_vaddr_i.eq(0x400000011) + + yield + yield dut.req_port_i.data_gnt.eq(1) + yield + yield + yield + yield + yield -- 2.30.2