FileVault Performance

With Lion sporting a more usable version of FileVault I was curious about its performance impact. I'd enabled FileVault on my personal machine and subjectively felt a performance impact, but I needed to quantify it. I put together a number of tests to do just that.

For all of these tests my test platform is a 15-inch MacBook Pro with a 2.2GHz Sandy Bridge Core i7 from early 2011 with an Apple branded 256GB SSD. In these tests I was primarily concerned with two things: how performance is affected, and what sort of extra load FileVault encryption places on the CPU.

Our first test is a simple file copy. I've got a directory of 2200MB worth of RAW files from a Nikon D700. I copy the folder from the SSD to the same SSD and report performance in MB/s:

FileVault Performance - 2200MB File Copy (MB/s)

With FileVault enabled we take a 24% performance hit, hardly insignificant. Average CPU utilization during the file transfer actually dropped with FileVault enabled from 8.5% to 4.5%. I suspect the reason for the drop was the slower overall transfer rate. It would appear that FileVault, at least on a quad-core Sandy Bridge CPU has absolutely no overhead here. Given that Apple near-universally uses AES for symmetrical encryption, it's reasonable to assume here that FileVault is taking advantage of the AES-NI instructions on Intel's Core-i series of processors.

Our next test tested one of Lion's new features: threaded conversations in Mail. We timed how long it took to launch Mail and open a single email thread with 42 replies. If you've used OS X Mail in the past you'll know that CPU utilization goes insane if you're working on a thread with dozens of replies. The same is definitely true for threaded conversations in Lion.

FileVault Performance - Open 42 Reply Email Thread - Time in Seconds

Thanks to the MacBook Pro's SSD both setups complete this task pretty quickly. There is a penalty associated with FileVault though - around 9% in this case. Peak CPU utilization was similar on both systems, 100% of four threads on the eight thread Core i7.

I grabbed a screenshot of the CPU utilization graph in Activity Monitor during this test for both setups:


CPU Utilization: No Encryption (left) vs. FileVault Enabled (right)

While the two vary slightly, you can see that overall CPU utilization appears to be similar regardless of whether or not encryption is enabled.

Our third test is actually one of our standard OS X CPU benchmarks - we time the import of 203 RAW images into iPhoto. This task is impacted by both CPU and I/O performance:

FileVault Performance - iPhoto Import - Pictures per Minute

Despite the I/O dependency, there's virtually no performance impact to enabling FileVault here.

Our final tests are raw I/O tests using Quickbench. I focused on 4KB and 8KB random read/write since those are the most common transfer sizes for random file access. And for sequential operations I focused on 128KB transfers, again optimizing for common sizes.

FileVault Performance - Quickbench 4KB Random Read (MB/s)

FileVault Performance - Quickbench 4KB Random Write (MB/s)

FileVault Performance - Quickbench 8KB Random Read (MB/s)

FileVault Performance - Quickbench 8KB Random Write (MB/s)

FileVault Performance - Quickbench 128KB Sequential Read (MB/s)

FileVault Performance - Quickbench 128KB Sequential Write (MB/s)

Overall the hit on pure I/O performance is in the 20 - 30% range. It's noticeable but not big enough to outweigh the benefits of full disk encryption. Note that under OS X there's still no way to take advantage of SSD controllers with FDE like the SF-1000/2000 series and the Intel SSD 320.

FileVault Safari, iChat, TextEdit, Preview, QuickTime X
POST A COMMENT

112 Comments

View All Comments

  • quiksilvr - Wednesday, July 20, 2011 - link

    $29 is indeed a solid improvement. However, given the Mac Store now being out there, their desktop OS should follow the formula of their mobile OS: Free to upgrade. These features are nice but I can't help shake the feeling that these are Service Packs (because they are). And with their "app" store available on the OS and the means of most of their cash inflow, it makes more sense to make this a free upgrade for everyone instead of a $29 upgrade. Reply
  • xype - Wednesday, July 20, 2011 - link

    Service packs? Are you serious? Read up on the changes and try to come up with one service pack that changed as much.

    Some people…
    Reply
  • danielkza - Wednesday, July 20, 2011 - link

    XP SP3 would be a good candidate, but yes, 10.7 is a bit beyond what one could reasonably call a Service Pack. Reply
  • Taft12 - Wednesday, July 20, 2011 - link

    You're thinking of XP SP2, and if you have to go back 7 years to come up with a comparable "service pack", it's certainly fair to say OSX 10.7 is more than a service pack. Reply
  • AfroPhysics - Friday, July 22, 2011 - link

    I fail to see how the age of the service pack matters. Xype asked for an example and qualified nothing. Reply
  • ltcommanderdata - Wednesday, July 20, 2011 - link

    Are we really going through the tired argument that every 10.x update to OS X is just a service pack and should be free? Then at what point should Apple try to recoup costs for OS development, because even if individual point updates are evolutionary, going from the original 10.0 to 10.7 has got to be a major change in anyones eyes. And the same questions could be raised about Windows NT 6.1 aka Windows 7 where the server version is bluntly labeled Windows 2008 R2 and Windows NT 6.0 aka Vista/2008 or Windows NT 5.1 aka XP and Windows NT 5.0 aka 2000.

    Besides, even if you discount the user facing changes, Lion has seem some major security infrastructure changes. Both the 32-bit and 64-bit kernel have been rewritten with full NX-bit and ALSR support as in place in Windows Vista/7 addressing the major security complaint Charlie Miller had with OS X. Application sandboxing frameworks are now available and soon to be mandatory for Lion apps in the Mac App Store which I believe is a security feature that even Windows isn't pushing yet. With the dropping of the Core Duo, the Lion has also be rewritten to make more use of SSSE3 instead of just SSE3 as pointed out by the Hackintosh community. Lion isn't just Snow Leopard with a few features added on top, but the entire OS has seem updates at a low level even if the user might not necessary see all the differences.
    Reply
  • ltcommanderdata - Wednesday, July 20, 2011 - link

    And about the App Store being a major source of income for Apple, Apple has consistently said they aim to run their stores as a break even venture.

    http://www.macrumors.com/2011/07/19/apple-reports-...

    I'm not clear if the iTunes Store in the graphic in the above link includes the App Store, but at the very least as an example of Apple's digital store, the revenue stream really hasn't increased in the last 2 years. Apple's sales growth is clearly from their hardware, iPhone, iPad, and even Mac.
    Reply
  • GotThumbs - Wednesday, July 20, 2011 - link

    $1,634,000,000 in revenue from Other Music Related Products and Services (3)

    (3) Includes sales from the iTunes Store, App Store, and iBookstore in addition to sales of iPod services and Apple-branded and third-party iPod accessories

    I'd say their goal of a break even venture is not an accurate description of their stores. Hence the creation of the MAC Store. It sounds like a nice thought, but Apple is in business to make money and it seems their VERY good at it. Perhaps their projection analysis was a bit off.

    Hey, this is good news for the investors and I understand that they are a business. Lets not be too naive and just don't drink the cool-aid.
    Reply
  • ltcommanderdata - Wednesday, July 20, 2011 - link

    Perhaps my finance terms are wrong, but I'd hope the Apps Store is taking in revenue. But if Apple should be offering some of their other products like OS X updates for free, shouldn't we be concerned with whether the App Store is making major profits, such that there is money to spare to pay for OS development? Reply
  • solipsism - Wednesday, July 20, 2011 - link

    Revenue ≠ Profit

    They've paid billions to both developers, and music and video cotent owners. They've also spent money on the infrastructure to support their stores. I'm sure they're making a profit as all good for-profit companies should, but it's not the cash cow you've attempted to present here.
    Reply

Log in

Don't have an account? Sign up now