<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet type="text/xsl" href="../assets/xml/rss.xsl" media="all"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Blosc Home Page  (Posts about windows)</title><link>https://blosc.org/</link><description></description><atom:link href="https://blosc.org/categories/windows.xml" rel="self" type="application/rss+xml"></atom:link><language>en</language><copyright>Contents © 2026 &lt;a href="mailto:blosc@blosc.org"&gt;The Blosc Developers&lt;/a&gt; </copyright><lastBuildDate>Mon, 30 Mar 2026 10:58:24 GMT</lastBuildDate><generator>Nikola (getnikola.com)</generator><docs>http://blogs.law.harvard.edu/tech/rss</docs><item><title>Hairy situation of Microsoft Windows compilers</title><link>https://blosc.org/posts/hairy-msvc-situation.rst/</link><dc:creator>Francesc Alted</dc:creator><description>&lt;p&gt;Recently -- and to the requirement of a customer who recently
&lt;a class="reference external" href="http://blosc.org/blog/seeking-sponsoship.html"&gt;sponsorized us&lt;/a&gt; -- I
struggled a lot trying to get the maximum performance out of Visual
Studio compilers.  Here there are some quick benchmarks to show you an
overview of the kind of performance that C-Blosc can reach on Windows.&lt;/p&gt;
&lt;p&gt;First, let's use Visual Studio 2008 32-bit (extremely common platform
because Python 2 still requires this compiler) and see how C-Blosc
performs for decompressing on my laptop with Windows 7 Pro (64-bit)
with an Intel i5-3380M @ 2.90GHz:&lt;/p&gt;
&lt;img alt="/images/vs2008-32bit-decompress.png" src="https://blosc.org/images/vs2008-32bit-decompress.png"&gt;
&lt;p&gt;Now, let us see how the same benchmark performs with Visual Studio
2013:&lt;/p&gt;
&lt;img alt="/images/vs2013-64bit-decompress.png" src="https://blosc.org/images/vs2013-64bit-decompress.png"&gt;
&lt;p&gt;Well, there is an important boost in speed, not only because a native
64-bit compiler has been used, but also because natural improvements
in compiler technology.&lt;/p&gt;
&lt;p&gt;At this point I wondered whether Visual Studio 2013 is doing just a
decent job or if there is still some performance that can still be
squeezed.  So what kind of performance other compilers for Windows are
reaching?  For checking this, I tested the excellent &lt;a class="reference external" href="https://sourceforge.net/projects/mingw-w64"&gt;MinGW-w64&lt;/a&gt; compiler (thanks to
Jack Pappas for suggesting this!).  Here it is the result:&lt;/p&gt;
&lt;img alt="/images/mingw-w64-64bit-decompress.png" src="https://blosc.org/images/mingw-w64-64bit-decompress.png"&gt;
&lt;p&gt;So, one can be seen that GCC 4.9 (included in latest Mingw-w64) can
reach a performance that is still far beyond of what you can reach
with modern Microsoft compilers (specially for lower compression
levels, which is an important scenario when maximum speed is
required), and very close to what I get on Linux.&lt;/p&gt;
&lt;p&gt;Possibly the newest Visual Studio 2015 would allow more performance,
but IMO, there is still some time until this is more spread, whereas
GCC 4.9 (with GCC 5.1 starting to show up) is already shipping in many
distributions, Windows and Mac OSX, which gives GCC a lot of advantage
with respect to Visual Studio.&lt;/p&gt;
&lt;p&gt;With regards the reason on why GCC shows that much performance for
C-Blosc is probably a consequence of how it has been developed.  It
turns out that C-Blosc main development platform was (and still is)
Linux/GCC, and after many profile/optimize cycles, this tends to favor
that combination respect to others.&lt;/p&gt;
&lt;p&gt;Provided this, and regarding the original request to reach optimal
performance on Windows / Visual Studio 2013 64-bit environments, I
ended implementing an example where existing Visual Studio
applications can dynamically link a C-Blosc DLL that is in the PATH.
You can see how this technique works at:
&lt;a class="reference external" href="https://github.com/Blosc/c-blosc/blob/master/examples/win-dynamic-linking.c"&gt;https://github.com/Blosc/c-blosc/blob/master/examples/win-dynamic-linking.c&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;This is quite interesting because at compilation time you don't need
to make reference to the C-Blosc DLL &lt;em&gt;at all&lt;/em&gt;.  I.e. the next is
enough for compiling the example above:&lt;/p&gt;
&lt;pre class="literal-block"&gt;cl /Ox /Fewin-dynamic-linking.exe /I..\blosc win-dynamic-linking.c&lt;/pre&gt;
&lt;p&gt;And that's all.  After that, you only need to place the C-Blosc DLL
anywhere in your PATH and it will be dynamically detected.  I have
tested that with different combinations of compilers (e.g. Visual
Studio for the app, and MinGW-w64 for the DLL library) and it works
beautifully.  I think this is quite powerful and certainly I don't
know an equivalent technique for Unix (although it probably exists
also), allowing to use top-performance DLLs in your apps using
different compilers in a quite easy way.&lt;/p&gt;
&lt;p&gt;In case you have more hints on how to get better performance on
Windows, please tell us.&lt;/p&gt;</description><category>blosc</category><category>compilers</category><category>windows</category><guid>https://blosc.org/posts/hairy-msvc-situation.rst/</guid><pubDate>Mon, 06 Jul 2015 10:04:20 GMT</pubDate></item></channel></rss>