summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2014-05-02 15:35:33 +0000
committerrsandifo <rsandifo@138bc75d-0d04-0410-961f-82ee72b054a4>2014-05-02 15:35:33 +0000
commit2f40fa7eb018b9a2edff806bdfdca396c0795f1d (patch)
tree1e20604d7401139710c7f1d3907543c6e9bf0b3d
parent51590909f730ca7c7147aa6c3a7741a6f338d546 (diff)
downloadgcc-2f40fa7eb018b9a2edff806bdfdca396c0795f1d.tar.gz
gcc/
* hwint.h (zext_hwi): Fix signed overflow for prec == 63. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@210006 138bc75d-0d04-0410-961f-82ee72b054a4
-rw-r--r--gcc/ChangeLog4
-rw-r--r--gcc/hwint.h2
2 files changed, 5 insertions, 1 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index 69342ebbb91..738dee31511 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,7 @@
+2014-05-02 Richard Sandiford <rsandifo@linux.vnet.ibm.com>
+
+ * hwint.h (zext_hwi): Fix signed overflow for prec == 63.
+
2014-05-02 Alan Lawrence <alan.lawrence@arm.com>
* config/aarch64/aarch64.c (aarch64_expand_vec_perm_1): Tidy bit-flip
diff --git a/gcc/hwint.h b/gcc/hwint.h
index 229fb94b565..ac9c9a295b4 100644
--- a/gcc/hwint.h
+++ b/gcc/hwint.h
@@ -344,7 +344,7 @@ zext_hwi (unsigned HOST_WIDE_INT src, unsigned int prec)
else
{
gcc_checking_assert (prec < HOST_BITS_PER_WIDE_INT);
- return src & (((HOST_WIDE_INT) 1 << prec) - 1);
+ return src & (((unsigned HOST_WIDE_INT) 1 << prec) - 1);
}
}