diff options
author | Georg-Johann Lay <avr@gjlay.de> | 2012-05-16 12:46:36 +0000 |
---|---|---|
committer | Georg-Johann Lay <gjl@gcc.gnu.org> | 2012-05-16 12:46:36 +0000 |
commit | 219d42f11a5f65265b8dda0ab4cb354746c3f456 (patch) | |
tree | 3b4b6b75b56a6d157491587f7bebf8acc6a97ef9 /gcc | |
parent | 0b2c4be5fdff70f1babd503c9f6dbabd664c44c7 (diff) | |
download | gcc-219d42f11a5f65265b8dda0ab4cb354746c3f456.zip gcc-219d42f11a5f65265b8dda0ab4cb354746c3f456.tar.gz gcc-219d42f11a5f65265b8dda0ab4cb354746c3f456.tar.bz2 |
re PR testsuite/52641 (Test cases fail for 16-bit int targets)
PR testsuite/52641
* gcc.dg/pr52549.c: Fix test for long != void*
* gcc.c-torture/execute/pr52979-1.x: New file.
* gcc.c-torture/execute/pr52979-2.x: New file.
From-SVN: r187588
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/testsuite/ChangeLog | 7 | ||||
-rw-r--r-- | gcc/testsuite/gcc.c-torture/execute/pr52979-1.x | 7 | ||||
-rw-r--r-- | gcc/testsuite/gcc.c-torture/execute/pr52979-2.x | 7 | ||||
-rw-r--r-- | gcc/testsuite/gcc.dg/pr52549.c | 7 |
4 files changed, 28 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index ac4f287..d1efffc 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,10 @@ +2012-05-16 Georg-Johann Lay <avr@gjlay.de> + + PR testsuite/52641 + * gcc.dg/pr52549.c: Fix test for long != void* + * gcc.c-torture/execute/pr52979-1.x: New file. + * gcc.c-torture/execute/pr52979-2.x: New file. + 2012-05-16 Dodji Seketeli <dodji@redhat.com> PR preprocessor/7263 diff --git a/gcc/testsuite/gcc.c-torture/execute/pr52979-1.x b/gcc/testsuite/gcc.c-torture/execute/pr52979-1.x new file mode 100644 index 0000000..4efed4c --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/execute/pr52979-1.x @@ -0,0 +1,7 @@ +load_lib target-supports.exp + +if { [check_effective_target_int32plus] } { + return 0 +} + +return 1; diff --git a/gcc/testsuite/gcc.c-torture/execute/pr52979-2.x b/gcc/testsuite/gcc.c-torture/execute/pr52979-2.x new file mode 100644 index 0000000..4efed4c --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/execute/pr52979-2.x @@ -0,0 +1,7 @@ +load_lib target-supports.exp + +if { [check_effective_target_int32plus] } { + return 0 +} + +return 1; diff --git a/gcc/testsuite/gcc.dg/pr52549.c b/gcc/testsuite/gcc.dg/pr52549.c index 89ec2aa..382f77d 100644 --- a/gcc/testsuite/gcc.dg/pr52549.c +++ b/gcc/testsuite/gcc.dg/pr52549.c @@ -1,6 +1,13 @@ /* { dg-do compile } */ +#if __SIZEOF_POINTER__ == __SIZEOF_LONG__ _mark (long obj, int i, char *a) { (char *)&(((long *)(obj)) [i]) - a; } +#elif __SIZEOF_POINTER__ == __SIZEOF_INT__ +_mark (int obj, int i, char *a) +{ + (char *)&(((int *)(obj)) [i]) - a; +} +#endif |