Skip to main content
Code Review

Return to Answer

replaced http://codereview.stackexchange.com/ with https://codereview.stackexchange.com/
Source Link
  1. Op's code has a possible race condition race condition between the lock and compare.

     "lock xadd %[lock], %[gate]\n" 
     "cmp %[lock], %[open]\n" 
    
  2. OP identified OP identified: lock is not certainly made a shared variable.

  1. Op's code has a possible race condition between the lock and compare.

     "lock xadd %[lock], %[gate]\n" 
     "cmp %[lock], %[open]\n" 
    
  2. OP identified: lock is not certainly made a shared variable.

  1. Op's code has a possible race condition between the lock and compare.

     "lock xadd %[lock], %[gate]\n" 
     "cmp %[lock], %[open]\n" 
    
  2. OP identified: lock is not certainly made a shared variable.

Source Link
chux
  • 36.1k
  • 2
  • 43
  • 96
  1. Op's code has a possible race condition between the lock and compare.

     "lock xadd %[lock], %[gate]\n" 
     "cmp %[lock], %[open]\n" 
    
  2. OP identified: lock is not certainly made a shared variable.

default

AltStyle によって変換されたページ (->オリジナル) /