[LLVMdev] "grep -w" irregularity

Chris Lattner clattner at apple.com
Tue Dec 30 17:47:17 PST 2008


On Dec 30, 2008, at 5:24 PM, Scott Michel wrote:

> Chris:
>
> On my _local_ x86_64 Ubuntu 7.10 machine, the shift_ops.ll is an  
> unexpected success (i.e., "grep -w shlh %t1.s | count 9" succeeds.)
>
> I get the same unexpected success on my x86_64 Mac 10.4.11.
>
> On the x86_64 buildbot, the same test fails. The culprit is grep,  
> evidently. It's just that simple.

Not necessarily.  That builder could be getting a different .s file  
from LLC.

> I suspect there's not really an issue with endianness, since all the  
> test does is (a) generate code using the backend, (b) grep's for  
> certain instructions. Nothing is actually executed.

LLC is still run.  If there is a bug in the code generator, it could  
easily manifest itself this way.  32/64-bit portability issues, buffer  
overruns and other undefined behavior could easily cause this sort of  
thing.  Please ask the owner of that builder nicely to send you the .s  
file that it is producing.  If it is identical to the one you get then  
I'll believe it is a grep difference, but that doesn't sound like the  
most likely issue.

-Chris 



More information about the llvm-dev mailing list