https://llvm.org/bugs/show_bug.cgi?id=28833

David Majnemer <david.majne...@gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|NEW                         |RESOLVED
                 CC|                            |david.majne...@gmail.com
         Resolution|---                         |INVALID

--- Comment #1 from David Majnemer <david.majne...@gmail.com> ---
It is not correct to transform ((unsigned)__builtin_strlen(s)) == 0 into *s ==
0.

The unsigned cast is masking out the high half of the strlen result.

For example, if __builtin_strlen comes out to 1ULL << 32 then
(unsigned)__builtin_strlen is zero but *s isn't 0.

-- 
You are receiving this mail because:
You are on the CC list for the bug.
_______________________________________________
llvm-bugs mailing list
llvm-bugs@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-bugs

Reply via email to