<html>
<head>
<meta content="text/html; charset=utf-8" http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<p><br>
</p>
<div class="moz-cite-prefix">On 01/20/2017 03:11 AM, Chandler
Carruth via llvm-dev wrote:<br>
</div>
<blockquote
cite="mid:CAAwGriE5xWHCQJTFMNe+KJ5nHLZ+fGp+iUe7xGv6TJTQg-DAMQ@mail.gmail.com"
type="cite">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8">
<div dir="ltr">Right now we have a healthy mixture of two ways to
respond to -Oz and -Os in LLVM:
<div><br>
</div>
<div>1) Pass this info to the PassManagerBuilder and then toggle
some flag to the pass to change thresholds.</div>
<div>2) When running over IR, inspect it for the minsize or
optsize attribute.</div>
<div><br>
</div>
<div>Regardless of the particulars of what these mean and/or how
they relate to -O2 vs -O3 for example, I'd really like to at
least get to *one* way of doing this.</div>
<div><br>
</div>
<div>The only way that is really compatible with LTO use cases
is to use the function attributes, so I'd suggest we actively
work toward that. That sound good to others? Thoughts?</div>
</div>
</blockquote>
<br>
I actually thought that (2) was already the accepted answer to this
question. Regardless, it should be (2).<br>
<br>
-Hal<br>
<br>
<blockquote
cite="mid:CAAwGriE5xWHCQJTFMNe+KJ5nHLZ+fGp+iUe7xGv6TJTQg-DAMQ@mail.gmail.com"
type="cite">
<div dir="ltr">
<div><br>
</div>
<div>If folks like this, I will attempt to update the few places
where we get this wrong. I already have some patches but
wanted to make sure everyone likes this direction.</div>
<div><br>
</div>
<div>-Chandler</div>
</div>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
LLVM Developers mailing list
<a class="moz-txt-link-abbreviated" href="mailto:llvm-dev@lists.llvm.org">llvm-dev@lists.llvm.org</a>
<a class="moz-txt-link-freetext" href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a>
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Hal Finkel
Lead, Compiler Technology and Programming Languages
Leadership Computing Facility
Argonne National Laboratory</pre>
</body>
</html>