Using the sleep thing also didnt help me.....the cpu usage still exceeds 95%....do i have another alternative to using while(1)....
Type: Posts; User: Anubhav
Using the sleep thing also didnt help me.....the cpu usage still exceeds 95%....do i have another alternative to using while(1)....
Actually its doing some calculation in each thread.....using a few array and global variables...its on linux...
i m using four threads in a c program.each thread runs in an infinite while loop but that leads to nearly 95% cpu usage.The program requirement forbids me to use sleep to pause a thread.All the...