Unverified Commit b1a968bd authored by mergify[bot]'s avatar mergify[bot] Committed by GitHub
Browse files

Fix dshl zero-width shift behavior (backport #2339) (#2340)



* Fix dshl zero-width shift behavior (#2339)

* Fix dshl zero-width shift behavior

Add a special case for dshl handling in the ZeroWidths pass.  If one
expression is shifted by a second, zero-width expression, just return
the first expression.  This prevents a bug where the width will
incorrectly expand due to zero-widths introducing a 1-bit zero
expression.

Signed-off-by: default avatarSchuyler Eldridge <schuyler.eldridge@sifive.com>

* fixup! Fix dshl zero-width shift behavior

(cherry picked from commit cc80c631

)

# Conflicts:
#	src/main/scala/firrtl/passes/ZeroWidth.scala

* fixup! Fix dshl zero-width shift behavior (#2339)

Co-authored-by: default avatarSchuyler Eldridge <schuyler.eldridge@sifive.com>
parent 13aac7f5
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment