From b7677b7e64a6f4989a272b5abe7add44abef8cc9 Mon Sep 17 00:00:00 2001 From: Cole Poirier Date: Mon, 24 Aug 2020 18:01:36 -0700 Subject: [PATCH] dcache.py move Reservation RecordObject to top of file --- src/soc/experiment/dcache.py | 24 +++++++++--------------- 1 file changed, 9 insertions(+), 15 deletions(-) diff --git a/src/soc/experiment/dcache.py b/src/soc/experiment/dcache.py index 95130adc..3abbac42 100644 --- a/src/soc/experiment/dcache.py +++ b/src/soc/experiment/dcache.py @@ -168,6 +168,15 @@ class RegStage1(RecordObject): self.stcx_fail = Signal() +# Reservation information +class Reservation(RecordObject): + def __init__(self): + super().__init__() + valid = Signal() + # TODO LINE_OFF_BITS is 6 + addr = Signal(63 downto LINE_OFF_BITS) + + # Set associative dcache write-through # # TODO (in no specific order): @@ -446,21 +455,6 @@ class Dcache(Elaboratable): # signal r1 : reg_stage_1_t; r1 = RegStage1() -# -- Reservation information -# -- -# type reservation_t is record -# valid : std_ulogic; -# addr : std_ulogic_vector(63 downto LINE_OFF_BITS); -# end record; -# Reservation information - - class Reservation(RecordObject): - def __init__(self): - super().__init__() - valid = Signal() - # TODO LINE_OFF_BITS is 6 - addr = Signal(63 downto LINE_OFF_BITS) - # signal reservation : reservation_t; reservation = Reservation() -- 2.30.2