<?xml version="1.0" encoding="utf-8" standalone="yes"?><rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:content="http://purl.org/rss/1.0/modules/content/"><channel><title>Gcc on File Descriptor Two</title><link>https://peter0x44.github.io/tags/gcc/</link><description>Recent content in Gcc on File Descriptor Two</description><generator>Hugo -- 0.148.1</generator><language>en-us</language><copyright>2025 Peter0x44</copyright><lastBuildDate>Fri, 22 May 2026 00:00:00 +0000</lastBuildDate><atom:link href="https://peter0x44.github.io/tags/gcc/index.xml" rel="self" type="application/rss+xml"/><item><title>Building a Host-Tuned GCC to Make GCC Compile Faster</title><link>https://peter0x44.github.io/posts/super-gcc/</link><pubDate>Fri, 22 May 2026 00:00:00 +0000</pubDate><guid>https://peter0x44.github.io/posts/super-gcc/</guid><description>&lt;p>A while ago, I became interested in reducing my compile times, and examined various methods for this.&lt;/p>
&lt;p>This blog post is about enabling all compiler options that I believe can make gcc faster when compiling code, and measuring the gains I got as a result.&lt;/p>
&lt;h2 id="how-to-build-it">How to Build It&lt;/h2>
&lt;div class="highlight">&lt;pre tabindex="0" style="color:#f8f8f2;background-color:#272822;-moz-tab-size:4;-o-tab-size:4;tab-size:4;">&lt;code class="language-bash" data-lang="bash">&lt;span style="display:flex;">&lt;span>mkdir build-gcc16
&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>cd build-gcc16
&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>
&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>../gcc-16.1.0/configure &lt;span style="color:#ae81ff">\
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#ae81ff">&lt;/span> --prefix&lt;span style="color:#f92672">=&lt;/span>&lt;span style="color:#e6db74">&amp;#34;&lt;/span>$HOME&lt;span style="color:#e6db74">/opt/gcc16-super&amp;#34;&lt;/span> &lt;span style="color:#ae81ff">\
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#ae81ff">&lt;/span> --program-prefix&lt;span style="color:#f92672">=&lt;/span>super- &lt;span style="color:#ae81ff">\
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#ae81ff">&lt;/span> --enable-languages&lt;span style="color:#f92672">=&lt;/span>c,c++ &lt;span style="color:#ae81ff">\
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#ae81ff">&lt;/span> --disable-multilib &lt;span style="color:#ae81ff">\
&lt;/span>&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>&lt;span style="color:#ae81ff">&lt;/span> --with-build-config&lt;span style="color:#f92672">=&lt;/span>&lt;span style="color:#e6db74">&amp;#39;bootstrap-native bootstrap-lto bootstrap-O3&amp;#39;&lt;/span>
&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>
&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>make profiledbootstrap -j&lt;span style="color:#66d9ef">$(&lt;/span>nproc&lt;span style="color:#66d9ef">)&lt;/span>
&lt;/span>&lt;/span>&lt;span style="display:flex;">&lt;span>make install-strip
&lt;/span>&lt;/span>&lt;/code>&lt;/pre>&lt;/div>&lt;p>Expect to be waiting for a while on &lt;code>make profiledbootstrap&lt;/code>.
It took 72 minutes of wall time on my laptop (AMD Ryzen AI MAX+ PRO 395, 16c/32t, &lt;code>-j32&lt;/code>).&lt;/p></description></item></channel></rss>