Dynamic power management for QoS-aware applications