modified cpu usage logic