<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Mar 5, 2015 at 3:00 PM, Pete Cooper <span dir="ltr"><<a href="mailto:peter_cooper@apple.com" target="_blank">peter_cooper@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><span class=""><blockquote type="cite"><div>On Mar 5, 2015, at 2:56 PM, Chandler Carruth <<a href="mailto:chandlerc@google.com" target="_blank">chandlerc@google.com</a>> wrote:</div><br><div><div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Mar 5, 2015 at 2:51 PM, Pete Cooper <span dir="ltr"><<a href="mailto:peter_cooper@apple.com" target="_blank">peter_cooper@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><span><blockquote type="cite"><div>On Mar 5, 2015, at 2:47 PM, Chandler Carruth <<a href="mailto:chandlerc@google.com" target="_blank">chandlerc@google.com</a>> wrote:</div><br><div><div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Mar 5, 2015 at 2:46 PM, Pete Cooper <span dir="ltr"><<a href="mailto:peter_cooper@apple.com" target="_blank">peter_cooper@apple.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div>Yeah, I agree that layering is an issue.</div><div><br></div><div>The current pass code is in lib/IR, which I think is libCore.  There’s no fundamental reason why your code couldn’t also live there right now.  Its linked against everything you mentioned already.</div></blockquote><div><br></div><div>Wait, you've lost me.</div></div></div></div></div></blockquote></span>I’m talking about what if you didn’t create a new library.  I think you’re talking about the relationship between the new libPasses and other libraries.  Otherwise i’m lost too :)</div><div><br></div><div>I was saying that if you didn’t create a new library, then I assumed the new PM code could live in libCore next to the current PM code.  And then everything just depends on libCore as they currently do.</div></blockquote></div><br></div><div class="gmail_extra">No no, that's the problem. Everything depends on libCore. Including libTransforms, libTarget, etc.</div><div class="gmail_extra"><br></div><div class="gmail_extra">the code i've got in Passes right now depends on code in the target library and in the transforms and analysis library. It can't do that from libCore without creating a cycle.</div></div></div></blockquote></span>Ah, i see.  Ouch!<span class=""><br><blockquote type="cite"><div><div dir="ltr"><div class="gmail_extra"><br></div><div class="gmail_extra">So we have:</div><div class="gmail_extra"><br></div><div class="gmail_extra">parsePassPipeline -> SROA (libTransforms) -> PassManager (IR / Core)</div><div class="gmail_extra"><br></div><div class="gmail_extra">If we put parsePassPipeline in Core, we form a cycle.</div></div>
</div></blockquote></span>Gotcha.</div><div><br></div><div>So how much of this is going to be optional?  If I create a dylib, can I opt out of parsePassPipeline (export list probably), and therefore not have to link all the passes?  I don’t want to have to carry around passes I know I don’t need.</div></blockquote></div><br>All of this is optional.</div><div class="gmail_extra"><br></div><div class="gmail_extra">The Passes library contains code to aggregate passes in a useful way. If you define your pass pipeline, you shouldn't need this at all.</div></div>