yosys/frontends/aiger
Henner Zeller 7d014902ec Fix digit-formatting calculation for small numbers.
Calling log10() on zero causes a non-sensical value to be calculated. On some
compile options, I've observed yosys crashing with an illegal
instruction (SIGILL).

To make it safe, fix the calculation to do a range check; wrap it a
decimal_digits() function, and use it where the previous ceil(log10(n)) call
was used. As a side, it also improves readability.

Signed-off-by: Henner Zeller <h.zeller@acm.org>
2021-01-21 12:20:53 -08:00
..
Makefile.inc WIP 2019-02-06 12:19:48 -08:00
aigerparse.cc Fix digit-formatting calculation for small numbers. 2021-01-21 12:20:53 -08:00
aigerparse.h aiger: -xaiger to read $_DFF_[NP]_ back with new clocks created 2020-05-14 10:33:56 -07:00