Software (in-)Correctness Analysis
Lecture-3
Ganesh Gopalakrishnan
Today's Topic: Concurrency Verification
It turned out to be a very simple problem. Like so many other aspects of Photoshop, it had to do with the fact that the app was written first for the Macintosh and then moved over to Windows. On the Macintosh, the set file position call is atomic—a single call—whereas on Windows, it's a pair of calls. The person who put that in there didn't think about the fact that the pair of calls has to be made atomic whenever you're sharing the file position across threads.
COLE Now, of course, you can look back and say that's obvious.
WILLIAMS In fact, the person who originally put that bug in the code was walking down the hallway one of the many times we set off looking for that thing, smacked his forehead, and realized what the problem was—10 years after the fact.
Concurrency Verification Challenges
What I'll do / emphasize
A PThread Program: Does it bomb?
A PThread Program
modeled
for exploration
by the
LazyCseq tool (later):
A PThread Program
modeled in Promela
for exploration
by SPIN
A PThread Program
modeled in Promela
for exploration
by SPIN: Contrast of reality vs modeling
A PThread Program
modeled in Promela
for exploration
by SPIN: Contrast of reality vs modeling
Demos, followed by study of Promela