<div dir="ltr">For some reason your comments aren't showing up on Phabricator, so replying via email - hope everybody sees it.<br><div class="gmail_extra"><br><div class="gmail_quote"><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">If SPs are now all finalized early - I'm assuming there's some other code that finalizes SPs that's no longer needed?<br></div></blockquote><div><br></div><div>Not all of them, just the one before cloning. I wanted to make the minimal change possible here, since this already seems like a bit of a hack to work around the fact that we can't properly forward variadic function calls at the IR level.</div><div> </div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div dir="ltr">Also - this seems like a layering/separation issue - does other code call into the DI as casually/explicitly as this code being added to CGVTables? (Or should the callback go through some more generic entry point in CGDebugInfo to delegate/handle that?) & is there nothing in CGDebugInfo that is already called back in a timely fashion to handle this? I'm guessing what's needed is a "IR has finished being generated for this function, opt/codegen is about to start"? That seems like a good generic callback & probably shouldn't be coming from something called CGVTables? (presuming there's a more general place to put that)</div></blockquote><div><br></div><div>I suppose there's CGDebugInfo::EmitFunctionEnd, so if we did want to finalize every SP as soon as we're done with it, we could put an explicit call to that extent there. Frankly though I don't really know the clang code too well, I just want to unbreak LLVM ;).</div></div></div></div>