summaryrefslogtreecommitdiffstats
path: root/gcc
diff options
context:
space:
mode:
authorbwilson <bwilson@138bc75d-0d04-0410-961f-82ee72b054a4>2002-06-05 18:55:19 +0000
committerbwilson <bwilson@138bc75d-0d04-0410-961f-82ee72b054a4>2002-06-05 18:55:19 +0000
commit049d6666fe52e46b2c698e10714173b186df2d45 (patch)
tree27a5eb835513422788b52b90130eff4f2270185b /gcc
parent77ac272e279863cea818ff5bb1db863660710a15 (diff)
downloadppe42-gcc-049d6666fe52e46b2c698e10714173b186df2d45.tar.gz
ppe42-gcc-049d6666fe52e46b2c698e10714173b186df2d45.zip
* config/xtensa/xtensa.c (xtensa_build_va_list): Use
lang_hooks.types.make_type instead of make_node; set up __va_list_tag type decl. (xtensa_builtin_saveregs): Remove broken use of RTX_UNCHANGING_P and unnecessary use of MEM_IN_STRUCT_P for saved registers; add varargs alias set. git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@54288 138bc75d-0d04-0410-961f-82ee72b054a4
Diffstat (limited to 'gcc')
-rw-r--r--gcc/ChangeLog9
-rw-r--r--gcc/config/xtensa/xtensa.c12
2 files changed, 16 insertions, 5 deletions
diff --git a/gcc/ChangeLog b/gcc/ChangeLog
index d6c942ab23d..d7aa706f311 100644
--- a/gcc/ChangeLog
+++ b/gcc/ChangeLog
@@ -1,3 +1,12 @@
+2002-06-05 Bob Wilson <bob.wilson@acm.org>
+
+ * config/xtensa/xtensa.c (xtensa_build_va_list): Use
+ lang_hooks.types.make_type instead of make_node; set up
+ __va_list_tag type decl.
+ (xtensa_builtin_saveregs): Remove broken use of
+ RTX_UNCHANGING_P and unnecessary use of MEM_IN_STRUCT_P
+ for saved registers; add varargs alias set.
+
2002-06-05 Neil Booth <neil@daikokuya.demon.co.uk>
config:
diff --git a/gcc/config/xtensa/xtensa.c b/gcc/config/xtensa/xtensa.c
index 911b349bc9f..f2cb700e1ba 100644
--- a/gcc/config/xtensa/xtensa.c
+++ b/gcc/config/xtensa/xtensa.c
@@ -47,6 +47,7 @@ Software Foundation, 59 Temple Place - Suite 330, Boston, MA
#include "ggc.h"
#include "target.h"
#include "target-def.h"
+#include "langhooks.h"
/* Enumeration for all of the relational tests, so that we can build
arrays indexed by the test type, and not worry about the order
@@ -2303,9 +2304,10 @@ xtensa_function_epilogue (file, size)
tree
xtensa_build_va_list (void)
{
- tree f_stk, f_reg, f_ndx, record;
+ tree f_stk, f_reg, f_ndx, record, type_decl;
- record = make_node (RECORD_TYPE);
+ record = (*lang_hooks.types.make_type) (RECORD_TYPE);
+ type_decl = build_decl (TYPE_DECL, get_identifier ("__va_list_tag"), record);
f_stk = build_decl (FIELD_DECL, get_identifier ("__va_stk"),
ptr_type_node);
@@ -2318,6 +2320,8 @@ xtensa_build_va_list (void)
DECL_FIELD_CONTEXT (f_reg) = record;
DECL_FIELD_CONTEXT (f_ndx) = record;
+ TREE_CHAIN (record) = type_decl;
+ TYPE_NAME (record) = type_decl;
TYPE_FIELDS (record) = f_stk;
TREE_CHAIN (f_stk) = f_reg;
TREE_CHAIN (f_reg) = f_ndx;
@@ -2344,9 +2348,7 @@ xtensa_builtin_saveregs ()
/* allocate the general-purpose register space */
gp_regs = assign_stack_local
(BLKmode, MAX_ARGS_IN_REGISTERS * UNITS_PER_WORD, -1);
- MEM_IN_STRUCT_P (gp_regs) = 1;
- RTX_UNCHANGING_P (gp_regs) = 1;
- RTX_UNCHANGING_P (XEXP (gp_regs, 0)) = 1;
+ set_mem_alias_set (gp_regs, get_varargs_alias_set ());
/* Now store the incoming registers. */
dest = change_address (gp_regs, SImode,
OpenPOWER on IntegriCloud