Ancient CS 61 Content Warning!!!!!1!!!
This is not the current version of the class.
This site was automatically translated from a wiki. The translation may have introduced mistakes (and the content might have been wrong to begin with).

Here is the assembly produced:

   1. movl    (%eax), %eax
   2. movl    (%eax), %edx
   3. addl    $1, %edx
   4. movl    %edx, (%eax)

What if a thread gets descheduled between instructions 2 and 3?