From 821581e4157fb400dfeb1a8927df0ef988800b8d Mon Sep 17 00:00:00 2001 From: Doug Evans Date: Fri, 12 Jul 1996 21:15:05 +0000 Subject: (ASM_OUTPUT_MI_THUNK): Handle fns returning structures. From-SVN: r12438 --- gcc/config/arm/arm.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'gcc') diff --git a/gcc/config/arm/arm.h b/gcc/config/arm/arm.h index d7a22a1..ab9fbc1 100644 --- a/gcc/config/arm/arm.h +++ b/gcc/config/arm/arm.h @@ -1697,6 +1697,8 @@ do { \ int mi_delta = (DELTA); \ char *mi_op = mi_delta < 0 ? "sub" : "add"; \ int shift = 0; \ + int this_regno = (aggregate_value_p (TREE_TYPE (TREE_TYPE (FUNCTION))) \ + ? 1 : 0); \ if (mi_delta < 0) mi_delta = -mi_delta; \ while (mi_delta != 0) \ { \ @@ -1705,8 +1707,8 @@ do { \ else \ { \ fprintf (FILE, "\t%s\t%s%s, %s%s, #%d\n", \ - mi_op, REGISTER_PREFIX, reg_names[0], \ - REGISTER_PREFIX, reg_names[0], \ + mi_op, REGISTER_PREFIX, reg_names[this_regno], \ + REGISTER_PREFIX, reg_names[this_regno], \ mi_delta & (0xff << shift)); \ arm_increase_location (4); \ mi_delta &= ~(0xff << shift); \ -- cgit v1.1