+2004-03-06 Ulrich Weigand <uweigand@de.ibm.com>
+
+ * config/s390/s390.md ("load_multiple", "*load_multiple_di",
+ "*load_multiple_si"): Allow only if reload_completed.
+ ("store_multiple", "*store_multiple_di", "*store_multiple_si"):
+ Likewise.
+
2004-03-06 Kazu Hirata <kazu@cs.umass.edu>
* config/vax/vax-protos.h: Add a prototype for
;
; load_multiple pattern(s).
;
+; ??? Due to reload problems with replacing registers inside match_parallel
+; we currently support load_multiple/store_multiple only after reload.
+;
(define_expand "load_multiple"
[(match_par_dup 3 [(set (match_operand 0 "" "")
(match_operand 1 "" ""))
(use (match_operand 2 "" ""))])]
- ""
+ "reload_completed"
{
enum machine_mode mode;
int regno;
[(match_parallel 0 "load_multiple_operation"
[(set (match_operand:DI 1 "register_operand" "=r")
(match_operand:DI 2 "s_operand" "QS"))])]
- "word_mode == DImode"
+ "reload_completed && word_mode == DImode"
{
int words = XVECLEN (operands[0], 0);
operands[0] = gen_rtx_REG (DImode, REGNO (operands[1]) + words - 1);
[(match_parallel 0 "load_multiple_operation"
[(set (match_operand:SI 1 "register_operand" "=r,r")
(match_operand:SI 2 "s_operand" "Q,S"))])]
- ""
+ "reload_completed"
{
int words = XVECLEN (operands[0], 0);
operands[0] = gen_rtx_REG (SImode, REGNO (operands[1]) + words - 1);
[(match_par_dup 3 [(set (match_operand 0 "" "")
(match_operand 1 "" ""))
(use (match_operand 2 "" ""))])]
- ""
+ "reload_completed"
{
enum machine_mode mode;
int regno;
[(match_parallel 0 "store_multiple_operation"
[(set (match_operand:DI 1 "s_operand" "=QS")
(match_operand:DI 2 "register_operand" "r"))])]
- "word_mode == DImode"
+ "reload_completed && word_mode == DImode"
{
int words = XVECLEN (operands[0], 0);
operands[0] = gen_rtx_REG (DImode, REGNO (operands[2]) + words - 1);
[(match_parallel 0 "store_multiple_operation"
[(set (match_operand:SI 1 "s_operand" "=Q,S")
(match_operand:SI 2 "register_operand" "r,r"))])]
- ""
+ "reload_completed"
{
int words = XVECLEN (operands[0], 0);
operands[0] = gen_rtx_REG (SImode, REGNO (operands[2]) + words - 1);
+2004-03-06 Ulrich Weigand <uweigand@de.ibm.com>
+
+ * gcc.dg/20040306-1.c: New test.
+
2004-03-06 Kazu Hirata <kazu@cs.umass.edu>
* gcc.dg/sibcall-3.c (recurser_void1, recurser_void2): Make
--- /dev/null
+/* This used to ICE due to a reload bug on s390*. */
+
+/* { dg-do compile } */
+/* { dg-options "-O2" } */
+
+
+typedef struct test
+{
+ unsigned short pad;
+ unsigned char type[6];
+} t;
+
+extern void set (t *a, t *b, t *c, t *d, t *e, t *f, t *g, t *h,
+ t *i, t *j, t *k, t *l, t *m, t *n, t *o, t *p);
+extern void use (t a, t b, t c, t d, t e, t f, t g, t h,
+ t i, t j, t k, t l, t m, t n, t o, t p);
+void test (void)
+{
+ t a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p;
+ set (&a, &b, &c, &d, &e, &f, &g, &h, &i, &j, &k, &l, &m, &n, &o, &p);
+ use (a, b, c, d, e, f, g, h, i, j, k, l, m, n, o, p);
+}