I attended a programmers' meet today:
One guy said:
A good program utilizes maximum processor
And according to general computing:
When task manager shows 100% utilization. It means your PC need some medications.
A program when using maximum processor will push task manager to 100%.
These 2 things are sounding so conflicting. Can someone please clarify with justifications?
This shows how silly ideas flow around the programmer community.
All the CPU utilization tells you is, very roughly, what fraction of time the program spends computing versus waiting, possibly for I/O, possibly for unrelated processing. Also, if you have a 4-core machine, 25% could mean 100% of one core.
Some programs should be I/O bound because their primary job is to read/write files or other I/O. Their CPU utilization should be low. Others should be CPU-bound. But that doesn't tell you if either one is "efficient".
A program is efficient when it does nothing unnecessary. You can easily make a program appear CPU-bound or I/O-bound just by making it do everything twice! If you see a high CPU percent, or high I/O utilization, when as far as you're concerned the computer should be idle, it means something is running, and you should be suspicious that it is not something you want.
I only know one way to make programs efficient, and that is by diagnosing what they are doing, and eliminating anything that takes time and can be removed. Example.