diff --git a/passes/pmgen/peepopt_muxadd.pmg b/passes/pmgen/peepopt_muxadd.pmg index 421b89366..7f114c93e 100644 --- a/passes/pmgen/peepopt_muxadd.pmg +++ b/passes/pmgen/peepopt_muxadd.pmg @@ -10,6 +10,13 @@ state add_a add_b add_y match add // Select adder select add->type == $add + choice A {\A, \B} + define B (A == \A ? \B : \A) + set add_y port(add, \Y) + set add_a port(add, A) + set add_b port(add, B) + set add_a_signed param(add, (A == \A) ? \A_SIGNED : \B_SIGNED)) + set add_a_id A endmatch code add_y add_a add_b