[LLVMdev] Traditional Dataflow Algorithm

Andrew Trick atrick at apple.com
Thu Apr 18 10:11:48 PDT 2013


On Apr 18, 2013, at 7:55 AM, dag at cray.com wrote:

> Andrew Trick <atrick at apple.com> writes:
> 
>> David was asking for a post-register-rewrite analysis, which I think
>> is a totally different problem and best implemented separately by each
>> target.  The target knows best which register units are overwritten or
>> preserved by an operation. We try to fake it with
>> undef/implicit-use/implicit-def, but it isn't reliable. Reaching defs
>> just can't be reliably rediscovered in a generic way after we drop
>> explicit subregister information.
> 
> I don't see why not.  All of the subregister information is exposed in a
> generic way through TargetRegisterInfo.
> 
> Your statement that undef/implicit-use/implicit-def isn't reliable is

It may currently work well for your target. But it's easy for other targets to add a pass that breaks these guarantees but still generates correct code. 

The last example I remember from the mailing list was copying an ARM S register using two neon VEXTs.

> news to me.  It seems unsafe to even provide it if it's incorrect.


I completely agree which is exactly why I think they should be eliminated and would discourage a generic postRA data flow framework based on them.

-Andy
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20130418/c894ecf1/attachment.html>


More information about the llvm-dev mailing list