Energy efficient execution of heterogeneous applications