Tech —

Retina MacBook Pro: maximizing battery life with gfxCardStatus

Easily get 8 hours of use—or more—by forcing OS X to use integrated graphics.

gfxCardStatus puts control of Apple's graphics switching in the hands of the user, making it possible to maximize battery life when needed.
Enlarge / gfxCardStatus puts control of Apple's graphics switching in the hands of the user, making it possible to maximize battery life when needed.
Chris Foresman

The Retina MacBook Pro eschews spinning mechanical drives—both optical and magnetic varieties—for solid state flash and tons of extra battery. Despite the larger battery, though, we were a little disappointed in the battery life we experienced while reviewing it, which was a half hour or more shy of Apple's promised 7 hours. But we've been using the Retina MacBook Pro a little more since our review published a couple of weeks ago, and have discovered that the massive 95Whr battery is actually capable of lasting at least 8 hours or more. To achieve this, we overrode Apple's automatic graphics switching using the donation-ware app gfxCardStatus to force OS X to rely solely on Intel's integrated HD4000 GPU.

The issues we ran into that caused our less-than-stellar battery life the first time around were actually nothing new. It was merely a side effect of Apple's implementation of automatic switching between integrated graphics and the discrete NVIDIA GeForce GT 650M GPU.

Why it works

When Apple first introduced automatic switching with the Sandy Bridge-based MacBook Pros in 2010, users discovered that some apps that shouldn't require the power of a discrete GPU were in fact causing OS X to switch anyway. The reason is that Apple's system automatically switches to the higher-powered GPU when apps use certain graphics-related frameworks, like CoreAnimation. Other frameworks that cause an automatic switch include OpenGL, OpenCL, Quartz Composer, and CoreGraphics. These frameworks rely on GPU acceleration and gain a performance advantage from running on better hardware.

But running the discrete GPU also consumes considerably more power. And seemingly innocuous apps, including Twitter, Reeder, Transmit, PathFinder, Skype, Delicious Library, Drive Genius, and NetNewsWire, among others, could cause the discrete GPU to power on and run as long as they are open. So instead of 7 hours of continuous operation, the Retina MacBook Pro running any of these apps might instead only last 6 to 6.5 hours under similar conditions.

Of course, the battery life hit isn't that much below Apple's stated rating, especially considering the difference in performance. The Retina Macbook Pro's NVIDIA GT 650M scored 35 fps in Cinebench's OpenGL test. The same test run on the Intel HD4000 turned in a score just over 19 fps. Clearly, the tradeoff gives better graphics performance, and apps like 3D compositing, video editing, and even the latest version of Photoshop can all benefit from the extra power.

On the other hand, if your needs are much less demanding, you might instead prefer to get the full 7 hours promised by Apple. Our testing shows that it's possible to actually get much more—consistently more than 8 hours, and almost 10 under some circumstances.

The magic behind all this is gfxCardStatus, a small app originally developed by a high school student named Cody Krieger. The first version of the app used system APIs to determine which GPU was currently active in dual-GPU system, and which apps caused the discrete GPU to activate. Krieger later enhanced the app to allow users to force either discrete or integrated graphics by clicking a menu.

Quickly switch between integrated, discrete, or dynamically switching graphics.
Quickly switch between integrated, discrete, or dynamically switching graphics.

Krieger, now majoring in software engineering at the Rochester Institute of Technology, has continually updated the app, enhancing it to work with all 15" and 17" MacBook Pros that have graphics switching capabilities. The latest version, 2.2.1, was released just days after our original review published on June 23, adding support for the Retina MacBook Pro.

The app uses a menu bar icon to display an "i" when using integrated graphics, or a "d" when using the discrete GPU. An option will also display an "n" for NDIVIA or "a" for AMD/ATI depending on the GPU included in your machine.

Clicking the icon shows more about the active GPU, a list of any apps that activate the automated switching, and offers an option to force OS X to use either integrated or discrete graphics.

Preferences allow Growl to display GPU change notifications, force gfxCardStatus to load at startup, and automatically check for updates. An advanced tab reveals our favorite feature: power source-based switching (something we've long argued Apple should consider as a power user option). Here you can set gfxCardStatus to force integrated graphics when on battery power, and automated switching when plugged in, among other combinations.

Advanced options let you automatically switch among GPU settings based on the power source of your Retina MacBook Pro.
Advanced options let you automatically switch among GPU settings based on the power source of your Retina MacBook Pro.

Battery tests

I used gfxCardStatus to force OS X to use integrated graphics only, and re-ran our non-scientific "real world use" battery test using the same set of active applications I keep running on a daily basis. This includes Safari, Chrome, Twitter, iChat, Colloquy, TextEdit, Photoshop, Skitch, Mail, and Outlook, among others. I used the machine repeatedly for my daily workload, chatting with editors, writing articles (including this one!), editing photos, watching YouTube, and generally getting things done. Screen brightness was set to half, as in previous testing.

I was consistently able to get between 8 and 8.5 hours of continuous use from the Retina MacBook Pro when running integrated graphics only. Turning down screen brightness to just two "dots," a technique I often use to maximize battery life when using a MacBook Air during conferences, caused OS X to report potential battery life as high as 10 hours. I simply didn't have the stamina to test that claim, but I did make one nine-hour run with OS X reporting a nine percent remaining battery capacity.

The takeaway here is that it appears to be possible to use the Retina MacBook Pro for a full day's work on battery power alone—as long as your work doesn't require using Final Cut Pro with a bus-powered RAID for 8 hours straight. If your needs are light enough—e-mail, Web browsing, word processing, spreadsheet, "office" work—you may be able to get even more.

And while the HD4000 isn't the world's fastest GPU, I still found it to be quite useable. I used it with Apple's iLife apps, including iPhoto, GarageBand, and iMovie, all of which normally activate graphics switching. Performance was perfectly acceptable, with no noticeable hiccups in functionality. I did notice perceptible differences in UI smoothness, but nothing that impeded actually using the apps to get things done.

The performance difference will matter more for professional apps like Photoshop CS6, Final Cut Pro X, Aperture, and others, especially as they are updated to take advantage of the Retina display's higher resolution. But if pressed, the HD4000 can get the job done; we wouldn't say the same for the previous generation HD3000 included in Sandy Bridge processors.

In short, if you're concerned that opting for a Retina MacBook Pro means giving up significant battery life, rest assured that isn't necessarily the case—especially with gfxCardStatus. If you want or need more graphics power, however, a quick click can easily switch on the discrete NVIDIA GT 650M when needed.

Channel Ars Technica