危険な領域 (Critical Section)

  • 複数の処理が同時に実行されると破綻する部分
  • Problem caused if executed by multiple processes at the same time
  • 上の例では「count += 1」
  • この部分をアトミック実行する必要あり
  • Should be executed atomically