Skip to content

Commit

Permalink
release the logic bomb benchmark
Browse files Browse the repository at this point in the history
  • Loading branch information
HNYuuu committed Apr 15, 2022
1 parent f6b3f78 commit dfad6cf
Showing 1 changed file with 10 additions and 2 deletions.
12 changes: 10 additions & 2 deletions eunomia/arch/wasm/memory.py
Original file line number Diff line number Diff line change
Expand Up @@ -104,8 +104,16 @@ def _big_construct_ite(symbolic_memory, dest, length):
try:
while True:
k, v = symbolic_memory.popitem()
if length <= (k[1] - k[0]):
break
l, h = k[0], k[1]
if isinstance(l, int) and isinstance(h, int):
if length <= (h - l):
break
else:
s = SMTSolver(Configuration.get_solver())
s.add(length <= (h - l))
if sat == s.check():
break

except KeyError:
return BitVec("invalid-memory", length * 8)

Expand Down

0 comments on commit dfad6cf

Please sign in to comment.