+Tue Mar 22 20:12:53 1994 Jeffrey A. Law (law@snake.cs.utah.edu)
+
+ * stabsread.c (REG_STRUCT_HAS_ADDR): Accept additional argument
+ for the structure's type. All callers changed.
+
+ * valops.c (call_function_by_hand): Check REG_STRUCT_HAS_ADDR
+ for each structure argument rather than assuming it's either
+ true or false for all structure arguments.
+
+ * config/pa/tm-hppa.h (REG_STRUCT_HAS_ADDR): Depend only
+ on the length structure passed, not the compiler used.
+
+ * config/sparc/tm-sparc.h (REG_STRUCT_HAS_ADDR): Accept additional
+ argument for the structure's type.
+
Tue Mar 22 15:28:33 1994 Jim Kingdon (kingdon@lioth.cygnus.com)
* values.c (set_internalvar): Don't set var->value until we are
1.92) behaves like sun cc. REG_STRUCT_HAS_ADDR is smart enough to
distinguish between Sun cc, gcc version 1 and gcc version 2. */
-#define REG_STRUCT_HAS_ADDR(gcc_p) (gcc_p != 1)
+#define REG_STRUCT_HAS_ADDR(gcc_p,type) (gcc_p != 1)
/* Sun /bin/cc gets this right as of SunOS 4.1.x. We need to define
BELIEVE_PCC_PROMOTION to get this right now that the code which
static char *type_synonym_name;
#if !defined (REG_STRUCT_HAS_ADDR)
-#define REG_STRUCT_HAS_ADDR(gcc_p) 0
+#define REG_STRUCT_HAS_ADDR(gcc_p,type) 0
#endif
/* ARGSUSED */
if (local_symbols
&& local_symbols->nsyms > 0
- && REG_STRUCT_HAS_ADDR (processing_gcc_compilation)
+ && REG_STRUCT_HAS_ADDR (processing_gcc_compilation,
+ SYMBOL_TYPE (sym))
&& (TYPE_CODE (SYMBOL_TYPE (sym)) == TYPE_CODE_STRUCT
|| TYPE_CODE (SYMBOL_TYPE (sym)) == TYPE_CODE_UNION))
{
to LOC_REGPARM_ADDR for structures and unions. */
if (SYMBOL_CLASS (sym) == LOC_REGPARM
- && REG_STRUCT_HAS_ADDR (processing_gcc_compilation)
+ && REG_STRUCT_HAS_ADDR (processing_gcc_compilation,
+ SYMBOL_TYPE (sym))
&& ((TYPE_CODE (SYMBOL_TYPE (sym)) == TYPE_CODE_STRUCT)
|| (TYPE_CODE (SYMBOL_TYPE (sym)) == TYPE_CODE_UNION)))
SYMBOL_CLASS (sym) = LOC_REGPARM_ADDR;
/* Likewise for converting LOC_ARG to LOC_REF_ARG (for the 7th and
subsequent arguments on the sparc, for example). */
if (SYMBOL_CLASS (sym) == LOC_ARG
- && REG_STRUCT_HAS_ADDR (processing_gcc_compilation)
+ && REG_STRUCT_HAS_ADDR (processing_gcc_compilation,
+ SYMBOL_TYPE (sym))
&& ((TYPE_CODE (SYMBOL_TYPE (sym)) == TYPE_CODE_STRUCT)
|| (TYPE_CODE (SYMBOL_TYPE (sym)) == TYPE_CODE_UNION)))
SYMBOL_CLASS (sym) = LOC_REF_ARG;