This is the mail archive of the
gcc-patches@gcc.gnu.org
mailing list for the GCC project.
Re: Patch for HP-UX IA64 bootstrap failure
- From: Steve Ellcey <sje at cup dot hp dot com>
- To: rth at redhat dot com, hjl at lucon dot org, zack at codesourcery dot com,gcc-patches at gcc dot gnu dot org
- Date: Mon, 13 Sep 2004 08:56:10 -0700 (PDT)
- Subject: Re: Patch for HP-UX IA64 bootstrap failure
Here is a new version of the ia64_scalar_mode_supported_p routine.
I left Linux TFmode as unsupported which is exactly the same as the
current behaviour. I just want to get IA64 HPUX bootstrap working
again.
Tested on IA64 HPUX and Linux, ok for checkin?
2004-09-13 Steve Ellcey <sje@cup.hp.com>
* config/ia64/ia64.c (ia64_scalar_mode_supported_p): New.
(TARGET_SCALAR_MODE_SUPPORTED_P): New.
*** gcc.orig/gcc/gcc/config/ia64/ia64.c Mon Sep 13 08:50:11 2004
--- gcc/gcc/gcc/config/ia64/ia64.c Mon Sep 13 08:50:00 2004
*************** static tree ia64_handle_model_attribute
*** 276,281 ****
--- 276,282 ----
static void ia64_encode_section_info (tree, rtx, int);
static rtx ia64_struct_value_rtx (tree, int);
static tree ia64_gimplify_va_arg (tree, tree, tree *, tree *);
+ static bool ia64_scalar_mode_supported_p (enum machine_mode mode);
/* Table of valid machine attributes. */
*************** static const struct attribute_spec ia64_
*** 416,421 ****
--- 417,425 ----
#undef TARGET_UNWIND_EMIT
#define TARGET_UNWIND_EMIT process_for_unwind_directive
+ #undef TARGET_SCALAR_MODE_SUPPORTED_P
+ #define TARGET_SCALAR_MODE_SUPPORTED_P ia64_scalar_mode_supported_p
+
struct gcc_target targetm = TARGET_INITIALIZER;
typedef enum
*************** ia64_struct_value_rtx (tree fntype,
*** 8476,8481 ****
--- 8480,8510 ----
if (fntype && ia64_struct_retval_addr_is_first_parm_p (fntype))
return NULL_RTX;
return gen_rtx_REG (Pmode, GR_REG (8));
+ }
+
+ static bool
+ ia64_scalar_mode_supported_p (enum machine_mode mode)
+ {
+ switch (mode)
+ {
+ case QImode:
+ case HImode:
+ case SImode:
+ case DImode:
+ case TImode:
+ return true;
+
+ case SFmode:
+ case DFmode:
+ case XFmode:
+ return true;
+
+ case TFmode:
+ return TARGET_HPUX;
+
+ default:
+ return false;
+ }
}
#include "gt-ia64.h"