Closed Dandford closed 4 years ago
Seems like source of this bug is because NextBip table is used for one known synonym, but there is no way to tell between different calls with the NextBip table
This is a small test program that demonstrates the bug:
procedure a {
a = a;
call called;
b = b;
}
procedure b {
b = b;
call called;
a = a;
}
procedure called {
if (a < b) then {
a = a + b;
} else {
b = a + b;
}
}
Fix would be to run the affectsSearch every time. This can be forced in the current version by adding a placeholder clause to populate the cache:
Query returns: stmt s1, s2, s3, s4; variable v; constant c; Select such that AffectsBip(s1,42)
Expected Answer: 39, 60
Actual Answer: 39, 60, 64, 75
Procedures proc2NestingIfWhile and proc2NestingWhileIf aren't called anywhere else in the program