tree-ssa-math-opts.c (find_bswap_or_nop_1): Use uint64_t type for the left shift...
authorJakub Jelinek <jakub@redhat.com>
Tue, 28 Oct 2014 13:51:28 +0000 (14:51 +0100)
committerJakub Jelinek <jakub@gcc.gnu.org>
Tue, 28 Oct 2014 13:51:28 +0000 (14:51 +0100)
* tree-ssa-math-opts.c (find_bswap_or_nop_1): Use uint64_t
type for the left shift in CASE_CONVERT case.

From-SVN: r216793

gcc/ChangeLog
gcc/tree-ssa-math-opts.c

index 4104d8da5cd664f9ce127a228228d90c943f4b7f..f57bfd8a96e25a550ca624dda39bc1473377c23a 100644 (file)
@@ -1,3 +1,8 @@
+2014-10-28  Jakub Jelinek  <jakub@redhat.com>
+
+       * tree-ssa-math-opts.c (find_bswap_or_nop_1): Use uint64_t
+       type for the left shift in CASE_CONVERT case.
+
 2014-10-28  Max Ostapenko  <m.ostapenko@partner.samsung.com>
 
        * asan.h (asan_intercepted_p): New function.
index 495a9fdb24dfc4135dc13b7b7111c59ad7e37a6d..e0f29247cdd0a04eae945744ec92ebbc3e08b6c1 100644 (file)
@@ -1926,7 +1926,7 @@ find_bswap_or_nop_1 (gimple stmt, struct symbolic_number *n, int limit)
            if (!TYPE_UNSIGNED (n->type) && type_size > old_type_size
                && HEAD_MARKER (n->n, old_type_size))
              for (i = 0; i < type_size - old_type_size; i++)
-               n->n |= MARKER_BYTE_UNKNOWN
+               n->n |= (uint64_t) MARKER_BYTE_UNKNOWN
                        << ((type_size - 1 - i) * BITS_PER_MARKER);
 
            if (type_size < 64 / BITS_PER_MARKER)