aboutsummaryrefslogtreecommitdiff
path: root/gcc
diff options
context:
space:
mode:
authorNick Clifton <nickc@redhat.com>2007-10-01 09:43:41 +0000
committerNick Clifton <nickc@redhat.com>2007-10-01 09:43:41 +0000
commit4db3a616fc697436d73616cb8037dc524a4c3f35 (patch)
tree0ab5778e98449f7e2246d8a05bb409b0447a3797 /gcc
parent8f573dd3b794a7938f026bf690646dffdf971220 (diff)
Fix test to work with 16-bit targets
git-svn-id: https://gcc.gnu.org/svn/gcc/trunk@128903 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc')
-rw-r--r--gcc/testsuite/ChangeLog5
-rw-r--r--gcc/testsuite/gcc.c-torture/execute/20060102-1.c2
2 files changed, 6 insertions, 1 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog
index 631e8a1ba7d..a346eb8b98b 100644
--- a/gcc/testsuite/ChangeLog
+++ b/gcc/testsuite/ChangeLog
@@ -1,3 +1,8 @@
+2007-10-01 Nick Clifton <nickc@redhat.com>
+
+ * gcc.c-torture/execute/20060102-1.c (f): Fix computation to work
+ for 16-bit targets.
+
2007-09-30 Diego Novillo <dnovillo@google.com>
PR 33593
diff --git a/gcc/testsuite/gcc.c-torture/execute/20060102-1.c b/gcc/testsuite/gcc.c-torture/execute/20060102-1.c
index 7b616a2484f..04b6a67d928 100644
--- a/gcc/testsuite/gcc.c-torture/execute/20060102-1.c
+++ b/gcc/testsuite/gcc.c-torture/execute/20060102-1.c
@@ -2,7 +2,7 @@ extern void abort ();
int f(int x)
{
- return (x >> 31) ? -1 : 1;
+ return (x >> (sizeof (x) * __CHAR_BIT__ - 1)) ? -1 : 1;
}
volatile int one = 1;