From f859c54ecfee75bfc7347fe4291f85484d95497d Mon Sep 17 00:00:00 2001 From: Luke Kenneth Casson Leighton Date: Wed, 10 Apr 2019 05:19:49 +0100 Subject: [PATCH] add the truth tables for SimpleHandshake and UnbufferedPipeline part of investigation into http://bugs.libre-riscv.org/show_bug.cgi?id=57#c6 --- src/add/singlepipe.py | 61 +++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 61 insertions(+) diff --git a/src/add/singlepipe.py b/src/add/singlepipe.py index bd0d6eda..2cfa139a 100644 --- a/src/add/singlepipe.py +++ b/src/add/singlepipe.py @@ -661,6 +661,35 @@ class SimpleHandshake(ControlBase): stage-1 p.i_data >>in stage n.o_data out>> stage+1 | | +--process->--^ + Truth Table + + Inputs Temporary Output + ------- ---------- ----- + P P N N PiV& ~NiV& N P + i o i o PoR NoV o o + V R R V V R + + ------- - - - - + 0 0 0 0 0 0 >0 0 + 0 0 0 1 0 1 >1 0 + 0 0 1 0 0 0 0 1 + 0 0 1 1 0 0 0 1 + ------- - - - - + 0 1 0 0 0 0 >0 0 + 0 1 0 1 0 1 >1 0 + 0 1 1 0 0 0 0 1 + 0 1 1 1 0 0 0 1 + ------- - - - - + 1 0 0 0 0 0 >0 0 + 1 0 0 1 0 1 >1 0 + 1 0 1 0 0 0 0 1 + 1 0 1 1 0 0 0 1 + ------- - - - - + 1 1 0 0 1 0 1 0 + 1 1 0 1 1 1 1 0 + 1 1 1 0 1 0 1 1 + 1 1 1 1 1 0 1 1 + ------- - - - - """ def elaborate(self, platform): @@ -735,6 +764,38 @@ class UnbufferedPipeline(ControlBase): result: output_shape according to ospec The output of the combinatorial logic. it is updated COMBINATORIALLY (no clock dependence). + + Truth Table + + Inputs Temp Output + ------- - ----- + P P N N ~NiR& N P + i o i o NoV o o + V R R V V R + + ------- - - - + 0 0 0 0 0 0 1 + 0 0 0 1 1 1 0 + 0 0 1 0 0 0 1 + 0 0 1 1 0 0 1 + ------- - - - + 0 1 0 0 0 0 1 + 0 1 0 1 1 1 0 + 0 1 1 0 0 0 1 + 0 1 1 1 0 0 1 + ------- - - - + 1 0 0 0 0 1 1 + 1 0 0 1 1 1 0 + 1 0 1 0 0 1 1 + 1 0 1 1 0 1 1 + ------- - - - + 1 1 0 0 0 1 1 + 1 1 0 1 1 1 0 + 1 1 1 0 0 1 1 + 1 1 1 1 0 1 1 + ------- - - - + + Note: PoR is *NOT* involved in the above decision-making. """ def elaborate(self, platform): -- 2.30.2