MCPcopy Create free account
hub / github.com/AliveToolkit/alive2 / add_no_usoverflow

Method add_no_usoverflow

smt/expr.cpp:880–885  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

878}
879
880expr expr::add_no_usoverflow(const expr &rhs) const {
881 if (min_leading_zeros() >= 1 && rhs.min_leading_zeros() >= 1)
882 return true;
883
884 return (zext(1) + rhs.sext(1)).sign() == 0;
885}
886
887expr expr::sub_no_soverflow(const expr &rhs) const {
888 if (min_leading_zeros() >= 1 && rhs.min_leading_zeros() >= 1)

Callers 1

addNoUSOverflowMethod · 0.80

Calls 3

min_leading_zerosMethod · 0.80
signMethod · 0.80
sextMethod · 0.80

Tested by

no test coverage detected