Fixed idlecores accounting bug and added accounting for total cores