<div dir="ltr"><br><div class="gmail_extra"><br><br><div class="gmail_quote">On Tue, Mar 12, 2013 at 11:39 AM, Adrian Prantl <span dir="ltr"><<a href="mailto:aprantl@apple.com" target="_blank">aprantl@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 class="im"><br>
On Mar 6, 2013, at 1:15 PM, Eric Christopher <<a href="mailto:echristo@gmail.com">echristo@gmail.com</a>> wrote:<br>
> Sorry for the delay, I'm wondering if there's a way to look at the location in the backend - even without the column information to make a determination here. I'll probably look into it before putting this in though.<br>

<br>
</div>To summarize the problem:<br>
LexicalScopes::getOrCreateInlinedScope() uses the DebugLoc as an index into InlinedLexicalScopeMap.<br>
DebugLoc::getFromDILocation(MDNode *N) builds a new DebugLoc from LineNumber, ColumnNumber, Scope, and OrigLocation of InlinedAt. In my test case, Line, Scope and OrigLocation are all identical for two inlined calls to the same function at the same line.<br>

<br></blockquote><div><br></div><div style>This is what I was hoping wasn't the case. :(</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
Based on this I think (but I may be wrong) that we need to emit a distinct location already in the frontend (in CodeGenFunction::EmitCallExpr). The backend relies on the DebugLoc to create the lexical scope.<br>
<br>
Do you see another way that you would prefer?<br></blockquote><div><br></div><div style>Unfortunately not at the moment. I guess go ahead then.</div><div style><br></div><div style>Thanks for looking into it.</div><div style>
<br></div><div style>-eric </div></div></div></div>