1. A method of operating an electronic device having a processor powered by a power source, comprising: providing a plurality of program portions individually executable by said processor for performing the same computing function, each one of said plurality of program portions causing said processor to exhibit a different instantaneous power consumption profile while performing said computing function; selecting, based on at least one characteristic of said power source, a particular one of said plurality of program portions from said plurality of program portions; and executing said particular one of said plurality of program portions on said processor to perform said computing function.