From: Cesar Strauss Date: Tue, 17 Aug 2021 10:13:04 +0000 (-0300) Subject: Fix activation of cancel signal X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=fa266e2d2b5f4e84b10df1572dff4c946cd104d9;p=soc.git Fix activation of cancel signal As an active low signal, the conditions to cancel must be ANDed together. Being active high, exc_o.happened must be inverted. --- diff --git a/src/soc/experiment/compldst_multi.py b/src/soc/experiment/compldst_multi.py index d47572b4..d7fcb89b 100644 --- a/src/soc/experiment/compldst_multi.py +++ b/src/soc/experiment/compldst_multi.py @@ -455,8 +455,10 @@ class LDSTCompUnit(RegSpecAPI, Elaboratable): comb += self.adr_rel_o.eq(alu_valid & adr_l.q & busy_o) # the write/store (etc) all must be cancelled if an exception occurs + # note: cancel is active low, like shadown_i, + # while exc_o.happpened is active high cancel = Signal(reset_less=True) - comb += cancel.eq(self.exc_o.happened | self.shadown_i) + comb += cancel.eq(~self.exc_o.happened & self.shadown_i) # store release when st ready *and* all operands read (and no shadow) comb += self.st.rel_o.eq(sto_l.q & busy_o & rd_done & op_is_st &