[LLVMdev] RFC - Profile Guided Optimization in LLVM

Eric Christopher echristo at gmail.com
Tue Jun 18 15:41:20 PDT 2013


> The main issue is that I want precise begin/end source locations for each statement.  Debug info doesn't do that.  Even if we enable column information, debug info just gives you one source location for each statement.  That's not a problem with debug info -- it's just not what it was intended to be used for.
>

True... somewhat. Precise begin/end source locations exist and the
debug info will map them back to regions of code that are associated
with a particular line and column - this should also change when the
statement changes. Anything else should probably be a bug? The only
difference I can see is that there's no concrete "done with this
statement" in the code. It might take some processing work to get "all
statements that executed between these source ranges" because of code
motion effects, but you should be able to get a concrete range.

> There's also the issue that I want PGO instrumentation to work the same regardless of the debug info setting.

Basically it's going to be "line-tables-only" :)

Of course, I'm also not signing up to do the work, just curious what
the limitations are in the infrastructure here.

>
>>
>> Even a comment?
>
> Yes.  Obviously you could do that, but it would add significant complexity and little real value.

Mmm.. I think you're underestimating the amount of usefulness here,
but we can revisit when there's some code. :)

-eric




More information about the llvm-dev mailing list