aboutsummaryrefslogtreecommitdiff
path: root/src/test/scala/firrtlTests/LoweringCompilersSpec.scala
diff options
context:
space:
mode:
authorSchuyler Eldridge2020-08-12 23:02:04 -0400
committerGitHub2020-08-13 03:02:04 +0000
commite1d3a0c64a48b4c9999ad59f15922db7c155c361 (patch)
treeef073449b902ffe8b729b78b1bfc828fe1aca9e6 /src/test/scala/firrtlTests/LoweringCompilersSpec.scala
parent8bcea45b66b2bc191ab2e25ace340202c0aa2aec (diff)
Cleanup Named Targets (#1311)
* Add CleanupNamedTargets Transform Adds a new transform, CleanupNamedTargets, that will convert ReferenceTargets to InstanceTargets if any ReferenceTargets are found to be actually pointing at instances. This fixes an issue where a ComponentName pointing at an instance will be converted to a ReferenceTarget. Later on, this ReferenceTarget will not be properly renamed by other transforms, e.g., EliminateTargetPaths. Signed-off-by: Schuyler Eldridge <schuyler.eldridge@ibm.com> * Update ScalaTests Co-authored-by: Jack Koenig <koenig@sifive.com> Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
Diffstat (limited to 'src/test/scala/firrtlTests/LoweringCompilersSpec.scala')
-rw-r--r--src/test/scala/firrtlTests/LoweringCompilersSpec.scala5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/test/scala/firrtlTests/LoweringCompilersSpec.scala b/src/test/scala/firrtlTests/LoweringCompilersSpec.scala
index 802596c5..e1de7e34 100644
--- a/src/test/scala/firrtlTests/LoweringCompilersSpec.scala
+++ b/src/test/scala/firrtlTests/LoweringCompilersSpec.scala
@@ -132,7 +132,10 @@ class LoweringCompilersSpec extends AnyFlatSpec with Matchers {
it should "replicate the old order" in {
val tm = new TransformManager(Forms.MinimalHighForm, Forms.ChirrtlForm)
- compare(legacyTransforms(new firrtl.ChirrtlToHighFirrtl), tm)
+ val patches = Seq(
+ Add(5, Seq(Dependency[firrtl.annotations.transforms.CleanupNamedTargets]))
+ )
+ compare(legacyTransforms(new firrtl.ChirrtlToHighFirrtl), tm, patches)
}
behavior of "IRToWorkingIR"