[llvm-commits] [llvm] r59847 - in /llvm/trunk/lib/CodeGen/SelectionDAG: DAGCombiner.cpp LegalizeDAG.cpp LegalizeIntegerTypes.cpp LegalizeTypes.h

Bill Wendling isanbard at gmail.com
Fri Nov 21 23:23:58 PST 2008


On Nov 21, 2008, at 8:14 PM, Duncan Sands wrote:

>> Yeah. The i1 was causing failures. I'm probably horribly abusing your
>> legalizing types code. If you have any suggestions, please send them
>> my way as I've never worked on this code before.
>
> what do you think of the attached patch?  It simplifies the type
> legalization part a bit, and produces better code by teaching
> SelectionDAG about the extra bits in an i8 SADDO/UADDO node.  In
> essence, I spontaneously decided that on x86 this i8 boolean result
> would be either 0 or 1, and on other platforms 0/1 or 0/-1, depending
> on whether the platform likes it's boolean zero extended or sign
> extended.  Hopefully that's ok.  You can see the better code on the
> add-with-overflow testcase.
>
This looks good. I'll apply it. Thank you for the help! :-)

-bw




More information about the llvm-commits mailing list