ghdl / ghdl-yosys-plugin

VHDL synthesis (based on ghdl)
GNU General Public License v3.0
304 stars 31 forks source link

Add reduce_xor support to the Yosys plugin #123

Closed rlee287 closed 4 years ago

rlee287 commented 4 years ago

This is a followup for ghdl/ghdl issue 1342.

ghdl --synth works correctly for the test_unop.vhd testcase within, but the plugin fails to properly import the $red_xor cell:

yosys> ghdl --std=08 test_unop.vhd -e test_unop
1. Executing GHDL.
Importing module test_unop.
ERROR: Unsupported(1): instance \14 of $red_xor.
ERROR: Assert `GetSize(ports) >= it.second->port_id' failed in kernel/rtlil.cc:1416.

This pull request adds to the case statements of the plugin to allow the XOR reduce operator to be imported correctly.

tgingold commented 4 years ago

Thanks!