diff options
author | Eddie Hung <eddieh@ece.ubc.ca> | 2019-04-03 06:27:41 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-04-03 06:27:41 -0700 |
commit | ef84b434a529fc8bc76ececbd531b5ddd39a4392 (patch) | |
tree | 54e4ff55d78ed88f5735e6cd1d10e15d222ff9f0 | |
parent | 721fa1cbd87c52a3adfce260f35fc33a7ae7ac4d (diff) | |
parent | 39380c45ba6cb4d2aa3f8c5757a2f1a61f85f8eb (diff) | |
download | yosys-ef84b434a529fc8bc76ececbd531b5ddd39a4392.tar.gz yosys-ef84b434a529fc8bc76ececbd531b5ddd39a4392.tar.bz2 yosys-ef84b434a529fc8bc76ececbd531b5ddd39a4392.zip |
Merge pull request #913 from smunaut/fix_proc_mux
proc_mux: Fix crash when trying to optimize non-existant mux to shiftx
-rw-r--r-- | passes/proc/proc_mux.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/passes/proc/proc_mux.cc b/passes/proc/proc_mux.cc index 7d3d23408..bac2dc2cd 100644 --- a/passes/proc/proc_mux.cc +++ b/passes/proc/proc_mux.cc @@ -361,7 +361,7 @@ RTLIL::SigSpec signal_to_mux_tree(RTLIL::Module *mod, SnippetSwCache &swcache, d } // Transform into a $shiftx where possible - if (shiftx && last_mux_cell->type == "$pmux") { + if (shiftx && last_mux_cell && last_mux_cell->type == "$pmux") { // Create bit-blasted $shiftx-es that shifts by the address line used in the case statement auto pmux_b_port = last_mux_cell->getPort("\\B"); auto pmux_y_port = last_mux_cell->getPort("\\Y"); |