This is the mail archive of the gcc@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]

question about register pairs


The docs say to use HARD_REGNO_MODE_OK to enforce register pairs.

But reload (find_valid_class_1) rejects classes that include such
registers:

      for (regno = 0; regno < FIRST_PSEUDO_REGISTER && !bad; regno++)
	{
	  if (in_hard_reg_set_p (reg_class_contents[rclass], mode, regno)
	      && !HARD_REGNO_MODE_OK (regno, mode))
	    {
	      bad = 1;

In the past, if I use a register class that excludes the second half
of register pairs, it can't do anything because it requires both parts
of the register pair to be in the class (example: in_hard_reg_set_p
checks this).

Which way is the "right" way?


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