FLAC is a cross-platform codec, but when it comes to Windows, one has a pretty wide range of compiles. Some are more optimized than others.
I first got the idea for this benchmark when I stumbled upon a native 64-bit FLAC executable for Windows. Curious, I did a quick and dirty test against the canonical build for Windows and found that while encoding times were similar, decoding times were considerably faster.
To figure out why this is so (the 64-bitness or something else), I quickly pulled some some additional compiles and benchmarked them against a few different samples.
I have three different samples I used, ripped in WAV format as single files:
- Lateralus, by Tool
- Californication, by the Red Hot Chili Peppers
- Bruckner’s 9th Symphony, by Giulini/Vienna Philharmonic, 1989
I’ve included a table for each sample, split into encode/decode times and compilation.
The builds I included were:
- The canonical build from the official FLAC website
- MSVC8 (Microsoft) compile from RareWares
- ICL 9.1 (Intel) compile from RareWares
- 64-bit compile (MSVC?) from HardwareHacks 2000
My test system is a Intel Core 2 Quad Q6600, with 4GB of RAM, running Windows Vista x64 SP1, with all available patches. The timer used was by Igor Pavlov (the developer of 7-zip). Reported times are global (as opposed to kernel, user, or process times).
It turns out that the x64’s advantage when it comes to decoding isn’t due to its 64-bitness, but probably because it includes some extra optimizations (SSE?) that are inherent ot a 64-bit compilation.
The clear winner in both encoding and decoding is the ICL9.1 compile (I wonder if a 10.1 compile would be even better); at least, it is so on my machine. The x64 compile was sometimes better, sometimes worse than the canonical compile. Clearly, there’s an early benefit from some optimization (probably SSE routines), along with a small margin of benefit from using Intel’s superior compiler. 64-bitness is beneficial for FLAC processes only insofar as it necessarily encompasses these routines as part of its instruction set.
If you’re looking to use a particular build of FLAC, I suggest you mosey on over to RareWares and john33’s ICL build: the resulting files are a few KB larger, but the processes itself is noticeably faster.