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]

Re: CLASS_CANNOT_CHANGE_MODE* redesign


Hi,

On Thu, 24 Oct 2002, Aldy Hernandez wrote:

> How does this look?

Strange.  The patch is doubled.  Hmm, no the first half seems to be the
old patch, Ok, ignoring ...  but:

+ #ifdef HARD_CONST
+ extern void cannot_change_mode_set_regs PARAMS ((HARD_REG_SET *,
+                                                enum machine_mode,
+                                                unsigned int));
+ #endif
+ extern bool invalid_mode_change_p     PARAMS ((unsigned int,
+                                                enum reg_class,
+                                                enum machine_mode));

in rtl.h looks wrong.  Also

! #define CLASS_CANNOT_CHANGE_MODE_P(CLASS, FROM, TO) \
!   (reg_classes_intersect_p (CLASS, FLOAT_REGS)      \
!    && (GET_MODE_SIZE (FROM) != GET_MODE_SIZE (TO)))

It would be better to swap the operands of the && so that the function
only is called when necessary (above in alpha.h, but generally
applicable).


Ciao,
Michael.


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