From: Cesar Strauss Date: Sat, 23 May 2020 22:52:08 +0000 (-0300) Subject: Add a few test cases with zero_a set, in combination with imm_ok X-Git-Tag: div_pipeline~896 X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=260625df9309f8f35541207cab431dd8dba90c5a;p=soc.git Add a few test cases with zero_a set, in combination with imm_ok --- diff --git a/src/soc/experiment/compalu_multi.py b/src/soc/experiment/compalu_multi.py index 23652c45..d2952acc 100644 --- a/src/soc/experiment/compalu_multi.py +++ b/src/soc/experiment/compalu_multi.py @@ -389,6 +389,13 @@ def scoreboard_sim(dut): result = yield from op_sim(dut, 5, 2, InternalOp.OP_ADD, inv_a=1) assert result == 65532 + result = yield from op_sim(dut, 5, 2, InternalOp.OP_ADD, zero_a=1, + imm=8, imm_ok=1) + assert result == 8 + + result = yield from op_sim(dut, 5, 2, InternalOp.OP_ADD, zero_a=1) + assert result == 2 + def test_compunit(): from alu_hier import ALU