When compiling with llvm's -fsanitize=bounds -fsanitize=integer flags, I get runtime warnings
Issue #17
resolved
This seems kind of serious and probably easy to fix. If I compile CryptoMiniSat with the above flags and llvm, I get:
/usr/local/include/m4ri/mzd.h:655:3: runtime error: negation of 1 cannot be represented in type 'word' (aka 'unsigned long'). The line at mzd.h for me is:
static inline void mzd_write_bit(mzd_t *M, rci_t const row, rci_t const col, BIT const value) { __M4RI_WRITE_BIT(M->rows[row][(col + M->offset) / m4ri_radix], (col + M->offset) % m4ri_radix, value); }
Since this is a runtime checker, it usually indicates real bugs.
Cheers and thanks for M4RI!
Comments (3)
-
repo owner -
reporter Ooops, sorry, I did file to the wrong place. Also, you are right, it's correct. Sorry!
Thanks again for M4RI!
Mate
-
reporter - changed status to resolved
Not an issue.
- Log in to comment
This seems to complain about the negation of a word value (unsigned long), which I believe is defined,
cf. http://stackoverflow.com/questions/1700713/in-c-how-to-get-calculate-the-negative-of-an-unsigned-quantity
Also, I think you opened this bug report against the wrong project: this is M4RIE not M4RI (?)