[llvm-commits] [llvm] r49795 - in /llvm/trunk: include/llvm/CodeGen/ScheduleDAG.h include/llvm/CodeGen/SelectionDAG.h include/llvm/CodeGen/SelectionDAGNodes.h lib/CodeGen/SelectionDAG/DAGCombiner.cpp lib/CodeGen/SelectionDAG/LegalizeDAG.cpp lib/C

Roman Levenstein romix.llvm at googlemail.com
Thu Apr 17 12:56:27 PDT 2008


2008/4/17, Dan Gohman <gohman at apple.com>:
>
>  On Apr 17, 2008, at 7:14 AM, Roman Levenstein wrote:
>  >
>  > So,  we should have iterators that iterate only over the users of a
>  > specific value. Do you mean something like providing a constructor
>  > parameter with the specific value number and then having the iterator
>  > pointing only to the uses of this value and skipping everything not
>  > matching this value?
>  >
>  > I attach a possible patch implementing this. Please have a look and
>  > tell me if this is what you mean.
>
>
> I think so. I don't have time at the moment to look at it in detail,
>  but if you can rewrite hasAnyUseOfValue using this, then it's quite
>  likely a good direction :-).

I agree that this appraoch provides a more elegant and simpler way to
express some things. But it does not provide any performance wins, as
far as I can see (unless we link all the uses of the same SDNode
result together for faster iteration over them).
So, what is the aim of doing it this way? Only the elegance of the
code? Or do you have something else in mind?

-Roman



More information about the llvm-commits mailing list