re PR middle-end/49489 (gcc.c-torture/execute/builtin-bitops-1.c fails on x86_64...
authorJakub Jelinek <jakub@redhat.com>
Tue, 21 Jun 2011 16:25:57 +0000 (18:25 +0200)
committerJakub Jelinek <jakub@gcc.gnu.org>
Tue, 21 Jun 2011 16:25:57 +0000 (18:25 +0200)
commit146aef0b3998e76f16c3ab8255d1caa3dcb4c870
tree9c216d752e228b140bcd643fe2591b081c4af049
parentc0503294bc105e7f0d6be22443abd3ef07d4aff1
re PR middle-end/49489 (gcc.c-torture/execute/builtin-bitops-1.c fails on x86_64-linux)

PR middle-end/49489
* builtins.c (expand_builtin_unop): Call expand_unop with 0 as
unsignedp argument instead of 1 for clrsb_optab.
(fold_builtin_bitop): Fix masking for width > HOST_BITS_PER_WIDE_INT
and < 2 * HOST_BITS_PER_WIDE_INT.  Optimize BUILT_IN_CLRSB*.
(fold_builtin_1): Call fold_builtin_binop for BUILT_IN_CLRSB*.
* optabs.c (widen_leading): Call widen_operand and expand_unop
with 0 as unsignedp argument instead of 1 for clrsb_optab.
(expand_unop): Subtract difference of mode sizes also for
clrsb_optab.

From-SVN: r175265
gcc/ChangeLog
gcc/builtins.c
gcc/optabs.c