[LLVMdev] some thoughts on the semantics of !fpmath

Hal Finkel hfinkel at anl.gov
Tue Apr 17 12:29:50 PDT 2012


On Tue, 17 Apr 2012 15:07:48 -0400
Rafael Espíndola <rafael.espindola at gmail.com> wrote:

> > For a transformation pass, should we do this only if the pass
> > actually changed something?
> 
> In the pass manager? That is interesting. What I had in mind was just
> changing the passes to only copy the metadata info they know about.
> The problem is that in examples like the one Dan created. The pass
> would have to delete metadata in an instruction it reasoned about but
> didn't otherwise modify, which is fairly error prone.

My thought was that if the pass manager is going to go through every
instruction in the block/loop/function, etc. and remove metadata
incompatible with the pass, then I think the effect is same if the pass
manager does this before the pass runs or after (so long as the pass
does not retain state like an analysis pass). If I'm correct, then it
seems unnecessarily conservative to remove the metadata even if the
pass made no changes.

 -Hal

> 
> >  -Hal
> 
> Cheers,
> Rafael



-- 
Hal Finkel
Postdoctoral Appointee
Leadership Computing Facility
Argonne National Laboratory




More information about the llvm-dev mailing list