<div dir="ltr">Thank you Michael and Tom for the quick reply.<div><br></div><div>According to your experience and comments, CodeExtractor is buggy only works for special cases but not general enough for most usages. Then do we have other outlining solution in llvm? Or I have to repeat what Michel done before?</div><div><br></div><div>Best regards,</div><div>Ming-Hwa</div></div><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Apr 12, 2016 at 1:48 PM, Michael Kuperstein <span dir="ltr"><<a href="mailto:michael.kuperstein@gmail.com" target="_blank">michael.kuperstein@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>CodeExtractor sort of does this.</div><div><br></div><div>First, it's a utility, not a pass - you'd still need to wrap it up with pass that actually causes it to outlines what you want it to outline.</div><div><br></div><div>Second, it's a bit buggy. There are, as far as I know, two in-tree users of this utility: bugpoint, and partial inlining. Both of them are fairly specialized use-cases, and don't actually exercise the full generality of outlining an arbitrary region. And since a lot of cases are in practice untested - they don't quite work.</div><div>I've had some fixes for this internally, but never actually upstreamed them, and no longer have access to that codebase. So, you'll probably run into the same issues if you try to do anything untrivial with it.</div><span class="HOEnZb"><font color="#888888"><div><br></div><div>Michael</div><div><br></div><div><br></div></font></span></div><div class="HOEnZb"><div class="h5"><div class="gmail_extra"><br><div class="gmail_quote">On 12 April 2016 at 13:24, Tom Chen via llvm-dev <span dir="ltr"><<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr">Does this do what you want <a href="http://llvm.org/docs/doxygen/html/classllvm_1_1CodeExtractor.html" target="_blank">http://llvm.org/docs/doxygen/html/classllvm_1_1CodeExtractor.html</a>?</div><div class="gmail_extra"><br><div class="gmail_quote"><div><div>2016-04-12 14:58 GMT-05:00 Minghwa Wang via llvm-dev <span dir="ltr"><<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a>></span>:<br></div></div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div><div dir="ltr">Is there any support for outlining in llvm?<div><br></div><div>As we know outlining is the opposite of inlining and while refactoring, if we can outlining common code into functions, then function merge (supported by llvm) can be more efficient in reducing code size.</div><div><br></div><div>If llvm support outlining, how to use it? Any documentation for it?</div><div><br></div><div>Thanks,</div><div>Ming-Hwa</div><div><br></div></div>
<br></div></div>_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
<br></blockquote></div><br></div>
<br>_______________________________________________<br>
LLVM Developers mailing list<br>
<a href="mailto:llvm-dev@lists.llvm.org" target="_blank">llvm-dev@lists.llvm.org</a><br>
<a href="http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev" rel="noreferrer" target="_blank">http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev</a><br>
<br></blockquote></div><br></div>
</div></div></blockquote></div><br></div>