-1

Can Anyone give the detailed explanation about the difference busy waiting and spin lock in OS (operating system) ?

Please give the explanation in layman language

Aditya Aggarwal
  • 159
  • 1
  • 9

1 Answers1

0

Simply put:

Busy waiting is a technique in which a process repeatedly checks to see if a condition is true (from Wikipedia).

Spinlock uses the above technique for the purpose of checking if a lock is available.

These 2 SO answers explain nicely what is a spinlock and when one should use it: https://stackoverflow.com/a/1957464/6098812

https://stackoverflow.com/a/1456261/6098812

bentz123
  • 1,081
  • 7
  • 16