diff options
author | John David Anglin <danglin@gcc.gnu.org> | 2015-09-13 15:05:57 +0000 |
---|---|---|
committer | John David Anglin <danglin@gcc.gnu.org> | 2015-09-13 15:05:57 +0000 |
commit | 7a84bf7192780875adc0faab6df1b49bbaa926cb (patch) | |
tree | 6cb294ef5622dcf9d73cbe7678406c1701259f9d /libgcc | |
parent | 7b5dccb554c86b99ea941007bc4338db9eca792a (diff) | |
download | gcc-7a84bf7192780875adc0faab6df1b49bbaa926cb.zip gcc-7a84bf7192780875adc0faab6df1b49bbaa926cb.tar.gz gcc-7a84bf7192780875adc0faab6df1b49bbaa926cb.tar.bz2 |
fptr.c (SIGN_EXTEND): Cast -1 to unsigned.
* config/pa/fptr.c (SIGN_EXTEND): Cast -1 to unsigned.
From-SVN: r227717
Diffstat (limited to 'libgcc')
-rw-r--r-- | libgcc/ChangeLog | 4 | ||||
-rw-r--r-- | libgcc/config/pa/fptr.c | 2 |
2 files changed, 5 insertions, 1 deletions
diff --git a/libgcc/ChangeLog b/libgcc/ChangeLog index bca8328..10fd462 100644 --- a/libgcc/ChangeLog +++ b/libgcc/ChangeLog @@ -1,3 +1,7 @@ +2015-09-13 John David Anglin <danglin@gcc.gnu.org> + + * config/pa/fptr.c (SIGN_EXTEND): Cast -1 to unsigned. + 2015-09-03 Sebastian Huber <sebastian.huber@embedded-brains.de> * config/gthr-rtems.h (__GTHREADS_CXX0X): New. diff --git a/libgcc/config/pa/fptr.c b/libgcc/config/pa/fptr.c index 3036727..e81dcab 100644 --- a/libgcc/config/pa/fptr.c +++ b/libgcc/config/pa/fptr.c @@ -45,7 +45,7 @@ static int fixup_branch_offset[NOFFSETS] = { 32, -4 }; #define GET_FIELD(X, FROM, TO) \ ((X) >> (31 - (TO)) & ((1 << ((TO) - (FROM) + 1)) - 1)) #define SIGN_EXTEND(VAL,BITS) \ - ((int) ((VAL) >> ((BITS) - 1) ? (-1 << (BITS)) | (VAL) : (VAL))) + ((int) ((VAL) >> ((BITS) - 1) ? ((unsigned)(-1) << (BITS)) | (VAL) : (VAL))) struct link_map; typedef int (*fptr_t) (void); |