On Mon, 2007-03-05 at 14:51 -0800, Chris Lattner wrote:

> Interesting case.  the full code looks like this:
> 
>          if (!STO->isNullValue() && !STO->isNullValue()) {
>            uint64_t TVA = STO->getZExtValue(), FVA = SFO->getZExtValue 
> ();
>            if (isPowerOf2_64(TVA) && isPowerOf2_64(FVA)) {
> 
> The isPowerOf2_64 calls check that the argument is not zero.  As  
> such, you can drop the isNullValue checks entirely.

Yup! Even better.

Thanks,

Reid.


_______________________________________________
llvm-commits mailing list
llvm-commits@cs.uiuc.edu
http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits

Reply via email to