3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2026-07-25 00:22:34 +00:00

Merge pull request #6007 from YosysHQ/nella/fix-shift-fold

Fix wide shift count folded as truncated/signed negative count
This commit is contained in:
nella 2026-07-24 08:17:11 +00:00 committed by GitHub
commit 7defa51862
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 65 additions and 1 deletions

View file

@ -590,7 +590,7 @@ bool RTLIL::Const::convertible_to_int(bool is_signed) const
if (size == 32) {
if (is_signed)
return true;
return back() != State::S1;
return (*this)[size - 1] != State::S1;
}
return false;