aboutsummaryrefslogtreecommitdiff
path: root/gcc/testsuite/gcc.dg
diff options
context:
space:
mode:
authorUlrich Weigand <uweigand@de.ibm.com>2005-11-02 23:16:31 +0000
committerUlrich Weigand <uweigand@gcc.gnu.org>2005-11-02 23:16:31 +0000
commitd98ad4101fa724d2d7f7364405f31fd3e8090371 (patch)
tree292c78d7d1f4715de0268e2e75d7ed0d2e075510 /gcc/testsuite/gcc.dg
parentf55b94653531277c15fbda2a69b5fa61dccbd589 (diff)
downloadgcc-d98ad4101fa724d2d7f7364405f31fd3e8090371.zip
gcc-d98ad4101fa724d2d7f7364405f31fd3e8090371.tar.gz
gcc-d98ad4101fa724d2d7f7364405f31fd3e8090371.tar.bz2
re PR target/24615 (internal compiler error: in print_shift_count_operand, at config/s390/s390.c:4025)
ChangeLog: PR target/24615 * config/s390/s390-protos.h (s390_decompose_shift_count): Declare. * config/s390/s390.c (s390_decompose_shift_count): New function. (s390_extra_constraint_str) ['Y']: Use s390_decompose_shift_count. (print_shift_count_operand): Use s390_decompose_shift_count. * config/s390/predicates.md ("setmem_operand", "shift_count_operand"): Use s390_decompose_shift_count. Do not accept any non-base hard regs. testsuite/ChangeLog: PR target/24615 * gcc.dg/pr24615.c: New test. From-SVN: r106405
Diffstat (limited to 'gcc/testsuite/gcc.dg')
-rw-r--r--gcc/testsuite/gcc.dg/pr24615.c27
1 files changed, 27 insertions, 0 deletions
diff --git a/gcc/testsuite/gcc.dg/pr24615.c b/gcc/testsuite/gcc.dg/pr24615.c
new file mode 100644
index 0000000..9699d8e
--- /dev/null
+++ b/gcc/testsuite/gcc.dg/pr24615.c
@@ -0,0 +1,27 @@
+
+/* { dg-do compile } */
+/* { dg-options "-Os -fPIC" } */
+
+void *memset (void *, int, __SIZE_TYPE__);
+void *memcpy (void *, const void *, __SIZE_TYPE__);
+
+char *alloc (int);
+
+char *
+test (int type, int size, char *data, int len)
+{
+ char *block = alloc (size);
+ char *bp = block;
+
+ *bp++ = type;
+ switch (type)
+ {
+ case 0:
+ case 1:
+ memset (bp, type == 0 ? 0x00 : 0xff, size);
+ memcpy (bp, data, len);
+ }
+
+ return block;
+}
+