fhdl/tools: BUGFIX: fix group_by_target grouping
authorDavid Carne <davidcarne@gmail.com>
Wed, 17 Jul 2013 07:40:46 +0000 (00:40 -0700)
committerSebastien Bourdeauducq <sebastien@milkymist.org>
Wed, 17 Jul 2013 08:14:39 +0000 (10:14 +0200)
commit16ebe41028257839455596aba58989df170c36de
tree0a8d0ddc67d0a8e3539c8ed8054460b85640dd5f
parent5b36f688ea5319fc927e1f5ce410a5c7fbeca7e4
fhdl/tools: BUGFIX: fix group_by_target grouping

group_by_target does not properly combine target groups if statements
are presented in the order:

 ({A}, statement1)
 ({B}, statement2)
 ({A, B}, statement3)

which returns groups:

 ({A, B}, [statement1, statement3])
 ({B}, [statement2])

This patch fixes group_by_target such that the resulting group is:

 ({A, B}, [statement1, statement2, statement3])
migen/fhdl/tools.py