[llvm-commits] Patch for handling multiple values in ExpandIntegerOperand

Duncan Sands baldrick at free.fr
Sat Nov 8 02:26:14 PST 2008


Hi Sanjiv,

> > Yes, but as you point out that is not reliable.  This also means that
> > the ReplaceNodeResults (target lowering) routines are potentially broken.
> > I think that means that target lowering needs access to ReplaceValueWith,
> > and that ReplaceNodeWith should probably be removed.
> 
> Our target needs this.  I can take this up if we make a decision on
> precisely what needs to be done.

I now think that target lowering might as well get access to all of the
main LegalizeTypes facilities, such as GetPromotedInteger etc, as well
as ReplaceValueWith.  The simplest way to do this is to add a new
parameter to the target lowering methods, which passes a
DAGTypeLegalizer&.  One thing to be careful about is whether the
LegalizeTypes header can reasonably be included in TargetLowering.h,
due to dependency problems and keeping a clean header hierarchy.

Ciao,

Duncan.



More information about the llvm-commits mailing list