Busy-waiting = ??? - Printable Version +- Cuberite Forum (https://forum.cuberite.org) +-- Forum: Off Topic (https://forum.cuberite.org/forum-9.html) +--- Forum: Off Topic Discussion (https://forum.cuberite.org/forum-10.html) +--- Thread: Busy-waiting = ??? (/thread-220.html) |
Busy-waiting = ??? - rs2k - 11-10-2011 From another forum: Member: Quote:Would this be ok? Moderator: Quote:No. That is not ok. That's called "busy-waiting", and is the programming equivalent of burping into someone else's dinner. It will use 100% of CPU time, spinning wildly, until the wait is over. The sleep() function is in C for a reason: It allows you to wait without taking up all the computer's time doing it. I LOL'd. RE: Busy-waiting = ??? - FakeTruth - 11-10-2011 It works though |