<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<style type="text/css" style="display:none;"> P {margin-top:0;margin-bottom:0;} </style>
</head>
<body dir="ltr">
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
> I emailed llvm-dev a while ago suggesting that we at least turn on LTO. <br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Ah, sorry, missed that. Otherwise I would have replied to/revived that thread.<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
> I really didn't get much feedback on that unfortunately, I think most people get clang via their distro or compile it themselves.</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Well, that's what I was wondering, wasn't sure if it is worth doing....but I guess we upload these binaries for a reason and guess these binaries are picked up by some people? Even if not, it would be good to set an example (and for testing)?</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
> I think the most complicated part is that the release testers are the one responsible for building the final binaries and there is a lot of different systems that might require some tweaking.</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Oh yeah, definitely. I see that it's easy to suggest this, and that it's a lot of work for the people who have to do this.</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
<br>
</div>
<div style="font-family: Calibri, Arial, Helvetica, sans-serif; font-size: 12pt; color: rgb(0, 0, 0);">
Cheers.<br>
</div>
<div id="appendonsend"></div>
<hr style="display:inline-block;width:98%" tabindex="-1">
<div id="divRplyFwdMsg" dir="ltr"><font face="Calibri, sans-serif" style="font-size:11pt" color="#000000"><b>From:</b> Tobias Hieta <tobias@plexapp.com><br>
<b>Sent:</b> 07 September 2020 14:56<br>
<b>To:</b> Sjoerd Meijer <Sjoerd.Meijer@arm.com><br>
<b>Cc:</b> llvm-dev <llvm-dev@lists.llvm.org><br>
<b>Subject:</b> Re: [llvm-dev] LTO'd / PGO'd Pre-built Release Binary</font>
<div> </div>
</div>
<div>
<div dir="auto">Sjoerd,
<div dir="auto"><br>
</div>
<div dir="auto">I emailed llvm-dev a while ago suggesting that we at least turn on LTO. I really didn't get much feedback on that unfortunately, I think most people get clang via their distro or compile it themselves.</div>
<div dir="auto"><br>
</div>
<div dir="auto">I did look into what's needed: the release script need to build the first and second stage as it does now but for the final stage we would need to adapt it to send in a compatible linker (gold or lld) and fix ranlib/ar invocations. </div>
<div dir="auto"><br>
</div>
<div dir="auto">I think the most complicated part is that the release testers are the one responsible for building the final binaries and there is a lot of different systems that might require some tweaking.</div>
<div dir="auto"><br>
</div>
<div dir="auto">I have had a dream of some CI service being able to build PGO/LTO optimized binaries (at least for Linux, windows and Mac) for each release - but I think we would need a cloud vendor sponsoring that CPU time (as a reference our toolchain build
 takes ~5 hrs for something similar).</div>
<div dir="auto"><br>
</div>
<div dir="auto">Thanks,</div>
<div dir="auto">Tobias</div>
</div>
<br>
<div class="x_gmail_quote">
<div dir="ltr" class="x_gmail_attr">On Mon, Sep 7, 2020, 14:50 Sjoerd Meijer via llvm-dev <<a href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a>> wrote:<br>
</div>
<blockquote class="x_gmail_quote" style="margin:0 0 0 .8ex; border-left:1px #ccc solid; padding-left:1ex">
<div dir="ltr">
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
A compiler built with LTO / PGO can significantly improve build times. Locally I see ~10% reduction in compilation times of Debug or Release versions of clang/llvm using an LTO'd clang compiler. This is not really news of course (e.g. recently also reconfirmed
 in <a href="https://linuxplumbersconf.org/event/7/contributions/802/" id="x_m_-8627283007291592925LPlnk" target="_blank" rel="noreferrer">
https://linuxplumbersconf.org/event/7/contributions/802/</a>), but that made me curious if we can and/or should enable LTO and/or PGO to create our prebuilt binaries?</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
The disadvantage for our release people will be obvious: that will take a lot more time and resources. But would it be worth to make this investment?
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Cheers,</div>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
Sjoerd.<br>
</div>
<div></div>
<br>
<div style="font-family:Calibri,Arial,Helvetica,sans-serif; font-size:12pt; color:rgb(0,0,0)">
<br>
</div>
</div>
_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org" target="_blank" rel="noreferrer">llvm-dev@lists.llvm.org</a><br>
<a href="https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer noreferrer" target="_blank">https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
</blockquote>
</div>
</div>
</body>
</html>