<html>
    <head>
      <base href="https://bugs.freedesktop.org/">
    </head>
    <body>
      <p>
        <div>
            <b><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - GCC memory starvation caused by flatten attribute with LTO"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=77580#c5">Comment # 5</a>
              on <a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - GCC memory starvation caused by flatten attribute with LTO"
   href="https://bugs.freedesktop.org/show_bug.cgi?id=77580">bug 77580</a>
              from <span class="vcard"><a class="email" href="mailto:doctorwhoguy@gmail.com" title="Patrick McMunn <doctorwhoguy@gmail.com>"> <span class="fn">Patrick McMunn</span></a>
</span></b>
        <pre>Created <span class=""><a href="attachment.cgi?id=125089" name="attach_125089" title="Patch to allow LTO optmization of xf86-video-intel">attachment 125089</a> <a href="attachment.cgi?id=125089&action=edit" title="Patch to allow LTO optmization of xf86-video-intel">[details]</a></span> <a href='page.cgi?id=splinter.html&bug=77580&attachment=125089'>[review]</a>
Patch to allow LTO optmization of xf86-video-intel

I'm attaching a patch that takes a somewhat simpler approach to disabling
"flatten" and "force_inline" which cause problems with LTO.

I used glxgears to measure FPS. The system was a Pentium 4 with an integrated
845G graphics chip, so it's pretty underpowered hardware, hence the low FPS.
Without LTO, I got ~19.5 FPS running glxgears at fullscreen at 1680x1050
resolution. With LTO, I got about 22.5 FPS. That may not seem like much, but
that's a 10% performance improvement! Except for the LTO-related flags, I used
the same compiler and linker flags during compilation.

flags used during compilation:

CFLAGS="-O2 -march=pentium4 -pipe -fdevirtualize-speculatively ${LTO}"
CXXFLAGS="${CFLAGS}"
LDFLAGS="-Wl,-O1 -Wl,--as-needed -Wl,--enable-new-dtags -Wl,--sort-common
-Wl,--sort-section=name -Wl,-Bsymbolic-functions -Wl,-z,combreloc ${CXXFLAGS}"</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are the QA Contact for the bug.</li>
      </ul>
    </body>
</html>