[llvm-commits] [llvm] r153452 - in /llvm/trunk: lib/Analysis/InstructionSimplify.cpp lib/Analysis/ValueTracking.cpp test/Transforms/InstSimplify/pr12251.ll

Chad Rosier mcrosier at apple.com
Mon Mar 26 21:15:39 PDT 2012


On Mar 26, 2012, at 9:10 PM, Rafael EspĂ­ndola wrote:

>> Is it possible the test has undefined behavior?
> 
> I think that is the case. Chad, can you try the attached patch? 

Certainly, but I'll have to do so tomorrow morning when I get into the office.  For some reason, I'm unable to ssh into my work machine (and thus the tester) at the moment.

 Chad

> The problem is that the optimizer is seeing:
> 
> rnd = (nsw operations) & 0x7fffffff
> rnd = (nsw operations) & 0x7fffffff
> 
> And concluding it can remove the last 'and' since none of the nsw
> operations could have changed the sign bit.
> 
>> -Chris
> 
> Cheers,
> Rafael
> <t.patch>





More information about the llvm-commits mailing list