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

Function disjoint

ir/memory.cpp:187–195  ·  view source on GitHub ↗

Assumes that both begin + len don't overflow

Source from the content-addressed store, hash-verified

185
186// Assumes that both begin + len don't overflow
187static expr disjoint(const expr &begin1, const expr &len1, const expr &align1,
188 const expr &begin2, const expr &len2, const expr &align2) {
189 // if blocks have the same alignment they can't start in the middle of
190 // each other. We just need to ensure they have a different addr.
191 if (align1.eq(align2) && align_ge_size(align1, len1) &&
192 align_ge_size(align2, len2))
193 return begin1 != begin2;
194 return begin1.uge(begin2 + len2) || begin2.uge(begin1 + len1);
195}
196
197static expr load_bv(const expr &var, const expr &idx0) {
198 auto bw = var.bits();

Callers 2

mkAxiomsMethod · 0.70
disjoint_local_blocksFunction · 0.70

Calls 3

align_ge_sizeFunction · 0.85
ugeMethod · 0.80
eqMethod · 0.45

Tested by

no test coverage detected