diff options
author | Clifford Wolf <clifford@clifford.at> | 2013-07-09 18:59:59 +0200 |
---|---|---|
committer | Clifford Wolf <clifford@clifford.at> | 2013-07-09 18:59:59 +0200 |
commit | 7daeee340a7edad3f4450e1392f8bad8d8b9cb7c (patch) | |
tree | 42106533b2f4b23bfcc594a2ac73301895faf182 /kernel | |
parent | e8da3ea7b647f2c1eeba8a84590df7b05ca4e046 (diff) | |
download | yosys-7daeee340a7edad3f4450e1392f8bad8d8b9cb7c.tar.gz yosys-7daeee340a7edad3f4450e1392f8bad8d8b9cb7c.tar.bz2 yosys-7daeee340a7edad3f4450e1392f8bad8d8b9cb7c.zip |
Fixed shift ops with large right hand side
Diffstat (limited to 'kernel')
-rw-r--r-- | kernel/satgen.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/satgen.h b/kernel/satgen.h index 991853c2c..26e3fd7ec 100644 --- a/kernel/satgen.h +++ b/kernel/satgen.h @@ -241,7 +241,7 @@ struct SatGen { std::vector<int> tmp_shifted(tmp.size()); for (size_t j = 0; j < tmp.size(); j++) { - int idx = j + (1 << i) * (shift_left ? -1 : +1); + int idx = j + (1 << (i > 30 ? 30 : i)) * (shift_left ? -1 : +1); tmp_shifted.at(j) = (0 <= idx && idx < int(tmp.size())) ? tmp.at(idx) : sign_extend ? tmp.back() : ez->FALSE; } tmp = ez->vec_ite(b.at(i), tmp_shifted, tmp); |