diff options
author | James E. Wilson <wilson@codesourcery.com> | 2009-05-07 00:24:53 +0000 |
---|---|---|
committer | Jim Wilson <wilson@gcc.gnu.org> | 2009-05-06 17:24:53 -0700 |
commit | e289f7a42d07c0a1e633782a1983b9bc03e33efb (patch) | |
tree | 5bfe4a6c216e9c2b78f69ca3d1870ae7b652e7a1 | |
parent | 8aa7ac967f7665bd6ccc3f16c9475f07c27254bc (diff) | |
download | gcc-e289f7a42d07c0a1e633782a1983b9bc03e33efb.zip gcc-e289f7a42d07c0a1e633782a1983b9bc03e33efb.tar.gz gcc-e289f7a42d07c0a1e633782a1983b9bc03e33efb.tar.bz2 |
* gcc.target/mips/const-high-part.c: New test.
From-SVN: r147213
-rw-r--r-- | gcc/testsuite/ChangeLog | 4 | ||||
-rw-r--r-- | gcc/testsuite/gcc.c-torture/compile/const-high-part.c | 19 |
2 files changed, 23 insertions, 0 deletions
diff --git a/gcc/testsuite/ChangeLog b/gcc/testsuite/ChangeLog index 08c7a9a..cd764f8 100644 --- a/gcc/testsuite/ChangeLog +++ b/gcc/testsuite/ChangeLog @@ -1,3 +1,7 @@ +2009-05-06 James E. Wilson <wilson@codesourcery.com> + + * gcc.target/mips/const-high-part.c: New test. + 2009-05-06 H.J. Lu <hongjiu.lu@intel.com> PR testsuite/40050 diff --git a/gcc/testsuite/gcc.c-torture/compile/const-high-part.c b/gcc/testsuite/gcc.c-torture/compile/const-high-part.c new file mode 100644 index 0000000..95e2059 --- /dev/null +++ b/gcc/testsuite/gcc.c-torture/compile/const-high-part.c @@ -0,0 +1,19 @@ +/* { dg-require-effective-target int32plus } */ +/* { dg-require-effective-target size32plus } */ + +char *buf; +int buflen; + +inline int +sub (int length) +{ + if (length <= buflen) + buf[length] = '\0'; + return 0; +} + +int +sub2 (void) +{ + return sub (0x7fffffff); +} |