From dc65c307c80fc0817b0452685f3e4b804f1d521e Mon Sep 17 00:00:00 2001 From: Ulrich Weigand Date: Fri, 27 Jun 2003 21:10:17 +0000 Subject: s390.h (SECONDARY_OUTPUT_RELOAD_CLASS): Define. gcc/ChangeLog: * config/s390/s390.h (SECONDARY_OUTPUT_RELOAD_CLASS): Define. * config/s390/s390.c (s390_secondary_output_reload_class): New function. * config/s390/s390-protos.h (s390_secondary_output_reload_class): Declare it. * config/s390/s390.md ("reload_outti", "reload_outdi", "reload_outdf"): New expanders. * config/s390/s390.md ("movti" + splitters): Handle non-offsettable memory operands as source. ("movdi" + splitters): Likewise. ("movdf" + splitters): Likewise. * config/s390/s390.c (s390_split_ok_p): New function. * config/s390/s390-protos.h (s390_split_ok_p): Declare it. gcc/testsuite/ChangeLog: * gcc.dg/20030627-1.c: New test. From-SVN: r68607 --- gcc/testsuite/gcc.dg/20030627-1.c | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100644 gcc/testsuite/gcc.dg/20030627-1.c (limited to 'gcc/testsuite/gcc.dg/20030627-1.c') diff --git a/gcc/testsuite/gcc.dg/20030627-1.c b/gcc/testsuite/gcc.dg/20030627-1.c new file mode 100644 index 0000000..4135f71 --- /dev/null +++ b/gcc/testsuite/gcc.dg/20030627-1.c @@ -0,0 +1,20 @@ +/* This tests whether non-offsettable memory operands are reloaded + correctly in certain corner cases on s390 targets. */ +/* { dg-do compile } */ +/* { dg-options "-std=gnu89" } */ + +void test_inout (char *bd, int xd, char *bs, int xs) +{ + *(long long *)(bd + xd + 4093) = *(long long *)(bs + xs + 4093); +} + +void test_in (char *bd, int xd, char *bs, int xs) +{ + *(long long *)(bd + xd) = *(long long *)(bs + xs + 4093); +} + +void test_out (char *bd, int xd, char *bs, int xs) +{ + *(long long *)(bd + xd + 4093) = *(long long *)(bs + xs); +} + -- cgit v1.1