From 975376dd6c7f7791125bd7d3ef45c05fa9435460 Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Sat, 12 Sep 2020 09:36:13 +0100 Subject: [PATCH] set bytesel in dcache store --- src/soc/experiment/dcache.py | 15 +++++---------- 1 file changed, 5 insertions(+), 10 deletions(-) diff --git a/src/soc/experiment/dcache.py b/src/soc/experiment/dcache.py index 00c83795..2d5f6692 100644 --- a/src/soc/experiment/dcache.py +++ b/src/soc/experiment/dcache.py @@ -1665,10 +1665,12 @@ def dcache_store(dut, addr, data, nc=0): yield dut.d_in.load.eq(0) yield dut.d_in.nc.eq(nc) yield dut.d_in.data.eq(data) + yield dut.d_in.byte_sel.eq(~0) yield dut.d_in.addr.eq(addr) yield dut.d_in.valid.eq(1) yield yield dut.d_in.valid.eq(0) + yield dut.d_in.byte_sel.eq(0) yield while not (yield dut.d_out.valid): yield @@ -1716,17 +1718,10 @@ def dcache_sim(dut): f"data @%x=%x expected 0000004100000040" % (addr, data) # Store at address 30 - yield from dcache_store(dut, 0x30, 0x12345678) - - yield - yield - yield - yield + yield from dcache_store(dut, 0x30, 0x121) - yield - yield - yield - yield + # Store at address 30 + yield from dcache_store(dut, 0x30, 0x12345678) # 3nd Cacheable read of address 30 data = yield from dcache_load(dut, 0x30) -- 2.30.2