News for hackers. Stuff that matters.
Re:Chasing a Bug in a SAT Solver by pfdietz on Friday June 21, 2024 @09:55AM (#40749681)
A problem with test case reduction occurs when your test generator also ensures the test input satisfies some properties. This means naive reduction can produce invalid inputs for which "failure" doesn't represent a bug. An example is in testing C compilers where the C code must not exhibit any of the many undefined behaviors described in the C standard. Creduce goes to some lengths to work around this problem.

A solution to this is doing the reduction on a tree of random numbers provided to the test generator, so the output is always a legitimate test input. The Hypothesis testing system takes this approach.

Re:Chasing a Bug in a SAT Solver by kragen on Saturday June 22, 2024 @11:14PM (#40764470)
i think hypothesis uses a string of random numbers rather than a tree?
Re:Chasing a Bug in a SAT Solver by pfdietz on Saturday June 22, 2024 @11:57PM (#40764666)
It partitions the string into an implicit tree and uses that structure to reduce the string, if I understand correctly. The partitioning is obtained from the stack's structure during generation.