diff options
author | Rask Ingemann Lambertsen <rask@sygehus.dk> | 2007-07-27 19:35:01 +0200 |
---|---|---|
committer | Rask Ingemann Lambertsen <rask@gcc.gnu.org> | 2007-07-27 17:35:01 +0000 |
commit | 8a67955f0815ecf2892c635ca4128a5f414eb507 (patch) | |
tree | c12d9038f7ff8e721d8b4aafb325744fe7a94f02 /gcc | |
parent | f017014e0923f9f9a3ccbd00be2c24f91dafd6ac (diff) | |
download | gcc-8a67955f0815ecf2892c635ca4128a5f414eb507.zip gcc-8a67955f0815ecf2892c635ca4128a5f414eb507.tar.gz gcc-8a67955f0815ecf2892c635ca4128a5f414eb507.tar.bz2 |
pr27743.c (bar): Use an integer of exactly 32 bits because the test relies on bit 31 to be the...
* gcc.dg/torture/pr27743.c (bar): Use an integer of exactly 32 bits
because the test relies on bit 31 to be the sign bit.
From-SVN: r126990
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/testsuite/ChangeLog | 5 | ||||
-rw-r--r-- | gcc/testsuite/gcc.dg/torture/pr27743.c | 7 |
2 files changed, 9 insertions, 3 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 8249df8..9b75942 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,5 +1,10 @@ 2007-07-27 Rask Ingemann Lambertsen <rask@sygehus.dk> + * gcc.dg/torture/pr27743.c (bar): Use an integer of exactly 32 bits + because the test relies on bit 31 to be the sign bit. + +2007-07-27 Rask Ingemann Lambertsen <rask@sygehus.dk> + * gcc.c-torture/execute/pr28651.c (main): Use INT_MAX instead of assuming it is 0x7fffffff. * gcc.dg/tree-ssa/vrp29.c (decCompare)(main): Likewise. diff --git a/gcc/testsuite/gcc.dg/torture/pr27743.c b/gcc/testsuite/gcc.dg/torture/pr27743.c index ee9144a..47d7045 100644 --- a/gcc/testsuite/gcc.dg/torture/pr27743.c +++ b/gcc/testsuite/gcc.dg/torture/pr27743.c @@ -1,10 +1,11 @@ -/* { dg-do run } */ +/* { dg-do run { target { stdint_types } } } */ +#include <stdint.h> extern void abort(void); -int bar(int a) +int32_t bar (int32_t a) { - return ((unsigned) ((a) >> 2)) >> 15; + return ((uint32_t) ((a) >> 2)) >> 15; } int main() |