This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[gcc-in-cxx] Enum fix for df.h


I committed this patch to gcc-in-cxx branch to fix some more enum
cases.  When you store a set of bitflags, you don't have an enum type,
you have an int type.  This was only caught in stage 2, presumably
because my stage 1 g++ doesn't recognize ENUM_BITFIELD.

Ian


2009-02-10  Ian Lance Taylor  <iant@google.com>

	* df.h (struct df_mw_hardreg): Change flags field to int.
	(struct df_base_ref): Likewise.


Index: df.h
===================================================================
--- df.h	(revision 143890)
+++ df.h	(working copy)
@@ -344,8 +344,7 @@ struct df_mw_hardreg
      accesses to 16-bit fields will usually be quicker.  */
   ENUM_BITFIELD(df_ref_type) type : 16;
 				/* Used to see if the ref is read or write.  */
-  ENUM_BITFIELD(df_ref_flags) flags : 16;
-				/* Various flags.  */
+  int flags : 16;		/* Various flags.  */
   unsigned int start_regno;     /* First word of the multi word subreg.  */
   unsigned int end_regno;       /* Last word of the multi word subreg.  */
   unsigned int mw_order;        /* Same as df_ref.ref_order.  */
@@ -363,8 +362,7 @@ struct df_base_ref
 
   ENUM_BITFIELD(df_ref_type) type : 8;
 				/* Type of ref.  */
-  ENUM_BITFIELD(df_ref_flags) flags : 16;
-				/* Various flags.  */
+  int flags : 16;		/* Various flags.  */
   rtx reg;			/* The register referenced.  */
   struct df_link *chain;	/* Head of def-use, use-def.  */
   /* Pointer to the insn info of the containing instruction.  FIXME! 

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]