Skip to content

Commit

Permalink
back.rtlil: fix emitting ROMs
Browse files Browse the repository at this point in the history
  • Loading branch information
wanda-phi authored and whitequark committed Jan 18, 2024
1 parent 6211eca commit 9e97903
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion amaranth/back/rtlil.py
Original file line number Diff line number Diff line change
Expand Up @@ -949,7 +949,7 @@ def _convert_fragment(builder, fragment, name_map, hierarchy):
if not isinstance(subfragment, (ir.Instance, mem.MemoryInstance)):
for signal in value._rhs_signals():
compiler_state.resolve_curr(signal, prefix=sub_name)
if len(value) > 0:
if len(value) > 0 or sub_type == "$mem_v2":
sub_ports[port] = rhs_compiler(value)

if isinstance(subfragment, ir.Instance):
Expand Down

0 comments on commit 9e97903

Please # to comment.