2004-10-07 J"orn Rennecke <joern.rennecke@st.com>
[official-gcc.git] / gcc / hard-reg-set.h
blob397660c0d074ea1be18516914a205ce3ce3894aa
1 /* Sets (bit vectors) of hard registers, and operations on them.
2 Copyright (C) 1987, 1992, 1994, 2000, 2003 Free Software Foundation, Inc.
4 This file is part of GCC
6 GCC is free software; you can redistribute it and/or modify it under
7 the terms of the GNU General Public License as published by the Free
8 Software Foundation; either version 2, or (at your option) any later
9 version.
11 GCC is distributed in the hope that it will be useful, but WITHOUT ANY
12 WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
14 for more details.
16 You should have received a copy of the GNU General Public License
17 along with GCC; see the file COPYING. If not, write to the Free
18 Software Foundation, 59 Temple Place - Suite 330, Boston, MA
19 02111-1307, USA. */
21 #ifndef GCC_HARD_REG_SET_H
22 #define GCC_HARD_REG_SET_H
24 /* Define the type of a set of hard registers. */
26 /* HARD_REG_ELT_TYPE is a typedef of the unsigned integral type which
27 will be used for hard reg sets, either alone or in an array.
29 If HARD_REG_SET is a macro, its definition is HARD_REG_ELT_TYPE,
30 and it has enough bits to represent all the target machine's hard
31 registers. Otherwise, it is a typedef for a suitably sized array
32 of HARD_REG_ELT_TYPEs. HARD_REG_SET_LONGS is defined as how many.
34 Note that lots of code assumes that the first part of a regset is
35 the same format as a HARD_REG_SET. To help make sure this is true,
36 we only try the widest fast integer mode (HOST_WIDEST_FAST_INT)
37 instead of all the smaller types. This approach loses only if
38 there are very few registers and then only in the few cases where
39 we have an array of HARD_REG_SETs, so it needn't be as complex as
40 it used to be. */
42 typedef unsigned HOST_WIDEST_FAST_INT HARD_REG_ELT_TYPE;
44 #if FIRST_PSEUDO_REGISTER <= HOST_BITS_PER_WIDEST_FAST_INT
46 #define HARD_REG_SET HARD_REG_ELT_TYPE
48 #else
50 #define HARD_REG_SET_LONGS \
51 ((FIRST_PSEUDO_REGISTER + HOST_BITS_PER_WIDEST_FAST_INT - 1) \
52 / HOST_BITS_PER_WIDEST_FAST_INT)
53 typedef HARD_REG_ELT_TYPE HARD_REG_SET[HARD_REG_SET_LONGS];
55 #endif
57 /* HARD_CONST is used to cast a constant to the appropriate type
58 for use with a HARD_REG_SET. */
60 #define HARD_CONST(X) ((HARD_REG_ELT_TYPE) (X))
62 /* Define macros SET_HARD_REG_BIT, CLEAR_HARD_REG_BIT and TEST_HARD_REG_BIT
63 to set, clear or test one bit in a hard reg set of type HARD_REG_SET.
64 All three take two arguments: the set and the register number.
66 In the case where sets are arrays of longs, the first argument
67 is actually a pointer to a long.
69 Define two macros for initializing a set:
70 CLEAR_HARD_REG_SET and SET_HARD_REG_SET.
71 These take just one argument.
73 Also define macros for copying hard reg sets:
74 COPY_HARD_REG_SET and COMPL_HARD_REG_SET.
75 These take two arguments TO and FROM; they read from FROM
76 and store into TO. COMPL_HARD_REG_SET complements each bit.
78 Also define macros for combining hard reg sets:
79 IOR_HARD_REG_SET and AND_HARD_REG_SET.
80 These take two arguments TO and FROM; they read from FROM
81 and combine bitwise into TO. Define also two variants
82 IOR_COMPL_HARD_REG_SET and AND_COMPL_HARD_REG_SET
83 which use the complement of the set FROM.
85 Also define GO_IF_HARD_REG_SUBSET (X, Y, TO):
86 if X is a subset of Y, go to TO.
89 #ifdef HARD_REG_SET
91 #define SET_HARD_REG_BIT(SET, BIT) \
92 ((SET) |= HARD_CONST (1) << (BIT))
93 #define CLEAR_HARD_REG_BIT(SET, BIT) \
94 ((SET) &= ~(HARD_CONST (1) << (BIT)))
95 #define TEST_HARD_REG_BIT(SET, BIT) \
96 (!!((SET) & (HARD_CONST (1) << (BIT))))
98 #define CLEAR_HARD_REG_SET(TO) ((TO) = HARD_CONST (0))
99 #define SET_HARD_REG_SET(TO) ((TO) = ~ HARD_CONST (0))
101 #define COPY_HARD_REG_SET(TO, FROM) ((TO) = (FROM))
102 #define COMPL_HARD_REG_SET(TO, FROM) ((TO) = ~(FROM))
104 #define IOR_HARD_REG_SET(TO, FROM) ((TO) |= (FROM))
105 #define IOR_COMPL_HARD_REG_SET(TO, FROM) ((TO) |= ~ (FROM))
106 #define AND_HARD_REG_SET(TO, FROM) ((TO) &= (FROM))
107 #define AND_COMPL_HARD_REG_SET(TO, FROM) ((TO) &= ~ (FROM))
109 #define GO_IF_HARD_REG_SUBSET(X,Y,TO) if (HARD_CONST (0) == ((X) & ~(Y))) goto TO
111 #define GO_IF_HARD_REG_EQUAL(X,Y,TO) if ((X) == (Y)) goto TO
113 #else
115 #define UHOST_BITS_PER_WIDE_INT ((unsigned) HOST_BITS_PER_WIDEST_FAST_INT)
117 #define SET_HARD_REG_BIT(SET, BIT) \
118 ((SET)[(BIT) / UHOST_BITS_PER_WIDE_INT] \
119 |= HARD_CONST (1) << ((BIT) % UHOST_BITS_PER_WIDE_INT))
121 #define CLEAR_HARD_REG_BIT(SET, BIT) \
122 ((SET)[(BIT) / UHOST_BITS_PER_WIDE_INT] \
123 &= ~(HARD_CONST (1) << ((BIT) % UHOST_BITS_PER_WIDE_INT)))
125 #define TEST_HARD_REG_BIT(SET, BIT) \
126 (!!((SET)[(BIT) / UHOST_BITS_PER_WIDE_INT] \
127 & (HARD_CONST (1) << ((BIT) % UHOST_BITS_PER_WIDE_INT))))
129 #if FIRST_PSEUDO_REGISTER <= 2*HOST_BITS_PER_WIDEST_FAST_INT
130 #define CLEAR_HARD_REG_SET(TO) \
131 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO); \
132 scan_tp_[0] = 0; \
133 scan_tp_[1] = 0; } while (0)
135 #define SET_HARD_REG_SET(TO) \
136 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO); \
137 scan_tp_[0] = -1; \
138 scan_tp_[1] = -1; } while (0)
140 #define COPY_HARD_REG_SET(TO, FROM) \
141 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
142 scan_tp_[0] = scan_fp_[0]; \
143 scan_tp_[1] = scan_fp_[1]; } while (0)
145 #define COMPL_HARD_REG_SET(TO, FROM) \
146 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
147 scan_tp_[0] = ~ scan_fp_[0]; \
148 scan_tp_[1] = ~ scan_fp_[1]; } while (0)
150 #define AND_HARD_REG_SET(TO, FROM) \
151 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
152 scan_tp_[0] &= scan_fp_[0]; \
153 scan_tp_[1] &= scan_fp_[1]; } while (0)
155 #define AND_COMPL_HARD_REG_SET(TO, FROM) \
156 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
157 scan_tp_[0] &= ~ scan_fp_[0]; \
158 scan_tp_[1] &= ~ scan_fp_[1]; } while (0)
160 #define IOR_HARD_REG_SET(TO, FROM) \
161 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
162 scan_tp_[0] |= scan_fp_[0]; \
163 scan_tp_[1] |= scan_fp_[1]; } while (0)
165 #define IOR_COMPL_HARD_REG_SET(TO, FROM) \
166 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
167 scan_tp_[0] |= ~ scan_fp_[0]; \
168 scan_tp_[1] |= ~ scan_fp_[1]; } while (0)
170 #define GO_IF_HARD_REG_SUBSET(X,Y,TO) \
171 do { HARD_REG_ELT_TYPE *scan_xp_ = (X), *scan_yp_ = (Y); \
172 if ((0 == (scan_xp_[0] & ~ scan_yp_[0])) \
173 && (0 == (scan_xp_[1] & ~ scan_yp_[1]))) \
174 goto TO; } while (0)
176 #define GO_IF_HARD_REG_EQUAL(X,Y,TO) \
177 do { HARD_REG_ELT_TYPE *scan_xp_ = (X), *scan_yp_ = (Y); \
178 if ((scan_xp_[0] == scan_yp_[0]) \
179 && (scan_xp_[1] == scan_yp_[1])) \
180 goto TO; } while (0)
182 #else
183 #if FIRST_PSEUDO_REGISTER <= 3*HOST_BITS_PER_WIDEST_FAST_INT
184 #define CLEAR_HARD_REG_SET(TO) \
185 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO); \
186 scan_tp_[0] = 0; \
187 scan_tp_[1] = 0; \
188 scan_tp_[2] = 0; } while (0)
190 #define SET_HARD_REG_SET(TO) \
191 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO); \
192 scan_tp_[0] = -1; \
193 scan_tp_[1] = -1; \
194 scan_tp_[2] = -1; } while (0)
196 #define COPY_HARD_REG_SET(TO, FROM) \
197 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
198 scan_tp_[0] = scan_fp_[0]; \
199 scan_tp_[1] = scan_fp_[1]; \
200 scan_tp_[2] = scan_fp_[2]; } while (0)
202 #define COMPL_HARD_REG_SET(TO, FROM) \
203 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
204 scan_tp_[0] = ~ scan_fp_[0]; \
205 scan_tp_[1] = ~ scan_fp_[1]; \
206 scan_tp_[2] = ~ scan_fp_[2]; } while (0)
208 #define AND_HARD_REG_SET(TO, FROM) \
209 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
210 scan_tp_[0] &= scan_fp_[0]; \
211 scan_tp_[1] &= scan_fp_[1]; \
212 scan_tp_[2] &= scan_fp_[2]; } while (0)
214 #define AND_COMPL_HARD_REG_SET(TO, FROM) \
215 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
216 scan_tp_[0] &= ~ scan_fp_[0]; \
217 scan_tp_[1] &= ~ scan_fp_[1]; \
218 scan_tp_[2] &= ~ scan_fp_[2]; } while (0)
220 #define IOR_HARD_REG_SET(TO, FROM) \
221 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
222 scan_tp_[0] |= scan_fp_[0]; \
223 scan_tp_[1] |= scan_fp_[1]; \
224 scan_tp_[2] |= scan_fp_[2]; } while (0)
226 #define IOR_COMPL_HARD_REG_SET(TO, FROM) \
227 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
228 scan_tp_[0] |= ~ scan_fp_[0]; \
229 scan_tp_[1] |= ~ scan_fp_[1]; \
230 scan_tp_[2] |= ~ scan_fp_[2]; } while (0)
232 #define GO_IF_HARD_REG_SUBSET(X,Y,TO) \
233 do { HARD_REG_ELT_TYPE *scan_xp_ = (X), *scan_yp_ = (Y); \
234 if ((0 == (scan_xp_[0] & ~ scan_yp_[0])) \
235 && (0 == (scan_xp_[1] & ~ scan_yp_[1])) \
236 && (0 == (scan_xp_[2] & ~ scan_yp_[2]))) \
237 goto TO; } while (0)
239 #define GO_IF_HARD_REG_EQUAL(X,Y,TO) \
240 do { HARD_REG_ELT_TYPE *scan_xp_ = (X), *scan_yp_ = (Y); \
241 if ((scan_xp_[0] == scan_yp_[0]) \
242 && (scan_xp_[1] == scan_yp_[1]) \
243 && (scan_xp_[2] == scan_yp_[2])) \
244 goto TO; } while (0)
246 #else
247 #if FIRST_PSEUDO_REGISTER <= 4*HOST_BITS_PER_WIDEST_FAST_INT
248 #define CLEAR_HARD_REG_SET(TO) \
249 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO); \
250 scan_tp_[0] = 0; \
251 scan_tp_[1] = 0; \
252 scan_tp_[2] = 0; \
253 scan_tp_[3] = 0; } while (0)
255 #define SET_HARD_REG_SET(TO) \
256 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO); \
257 scan_tp_[0] = -1; \
258 scan_tp_[1] = -1; \
259 scan_tp_[2] = -1; \
260 scan_tp_[3] = -1; } while (0)
262 #define COPY_HARD_REG_SET(TO, FROM) \
263 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
264 scan_tp_[0] = scan_fp_[0]; \
265 scan_tp_[1] = scan_fp_[1]; \
266 scan_tp_[2] = scan_fp_[2]; \
267 scan_tp_[3] = scan_fp_[3]; } while (0)
269 #define COMPL_HARD_REG_SET(TO, FROM) \
270 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
271 scan_tp_[0] = ~ scan_fp_[0]; \
272 scan_tp_[1] = ~ scan_fp_[1]; \
273 scan_tp_[2] = ~ scan_fp_[2]; \
274 scan_tp_[3] = ~ scan_fp_[3]; } while (0)
276 #define AND_HARD_REG_SET(TO, FROM) \
277 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
278 scan_tp_[0] &= scan_fp_[0]; \
279 scan_tp_[1] &= scan_fp_[1]; \
280 scan_tp_[2] &= scan_fp_[2]; \
281 scan_tp_[3] &= scan_fp_[3]; } while (0)
283 #define AND_COMPL_HARD_REG_SET(TO, FROM) \
284 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
285 scan_tp_[0] &= ~ scan_fp_[0]; \
286 scan_tp_[1] &= ~ scan_fp_[1]; \
287 scan_tp_[2] &= ~ scan_fp_[2]; \
288 scan_tp_[3] &= ~ scan_fp_[3]; } while (0)
290 #define IOR_HARD_REG_SET(TO, FROM) \
291 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
292 scan_tp_[0] |= scan_fp_[0]; \
293 scan_tp_[1] |= scan_fp_[1]; \
294 scan_tp_[2] |= scan_fp_[2]; \
295 scan_tp_[3] |= scan_fp_[3]; } while (0)
297 #define IOR_COMPL_HARD_REG_SET(TO, FROM) \
298 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
299 scan_tp_[0] |= ~ scan_fp_[0]; \
300 scan_tp_[1] |= ~ scan_fp_[1]; \
301 scan_tp_[2] |= ~ scan_fp_[2]; \
302 scan_tp_[3] |= ~ scan_fp_[3]; } while (0)
304 #define GO_IF_HARD_REG_SUBSET(X,Y,TO) \
305 do { HARD_REG_ELT_TYPE *scan_xp_ = (X), *scan_yp_ = (Y); \
306 if ((0 == (scan_xp_[0] & ~ scan_yp_[0])) \
307 && (0 == (scan_xp_[1] & ~ scan_yp_[1])) \
308 && (0 == (scan_xp_[2] & ~ scan_yp_[2])) \
309 && (0 == (scan_xp_[3] & ~ scan_yp_[3]))) \
310 goto TO; } while (0)
312 #define GO_IF_HARD_REG_EQUAL(X,Y,TO) \
313 do { HARD_REG_ELT_TYPE *scan_xp_ = (X), *scan_yp_ = (Y); \
314 if ((scan_xp_[0] == scan_yp_[0]) \
315 && (scan_xp_[1] == scan_yp_[1]) \
316 && (scan_xp_[2] == scan_yp_[2]) \
317 && (scan_xp_[3] == scan_yp_[3])) \
318 goto TO; } while (0)
320 #else /* FIRST_PSEUDO_REGISTER > 3*HOST_BITS_PER_WIDEST_FAST_INT */
322 #define CLEAR_HARD_REG_SET(TO) \
323 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO); \
324 int i; \
325 for (i = 0; i < HARD_REG_SET_LONGS; i++) \
326 *scan_tp_++ = 0; } while (0)
328 #define SET_HARD_REG_SET(TO) \
329 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO); \
330 int i; \
331 for (i = 0; i < HARD_REG_SET_LONGS; i++) \
332 *scan_tp_++ = -1; } while (0)
334 #define COPY_HARD_REG_SET(TO, FROM) \
335 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
336 int i; \
337 for (i = 0; i < HARD_REG_SET_LONGS; i++) \
338 *scan_tp_++ = *scan_fp_++; } while (0)
340 #define COMPL_HARD_REG_SET(TO, FROM) \
341 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
342 int i; \
343 for (i = 0; i < HARD_REG_SET_LONGS; i++) \
344 *scan_tp_++ = ~ *scan_fp_++; } while (0)
346 #define AND_HARD_REG_SET(TO, FROM) \
347 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
348 int i; \
349 for (i = 0; i < HARD_REG_SET_LONGS; i++) \
350 *scan_tp_++ &= *scan_fp_++; } while (0)
352 #define AND_COMPL_HARD_REG_SET(TO, FROM) \
353 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
354 int i; \
355 for (i = 0; i < HARD_REG_SET_LONGS; i++) \
356 *scan_tp_++ &= ~ *scan_fp_++; } while (0)
358 #define IOR_HARD_REG_SET(TO, FROM) \
359 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
360 int i; \
361 for (i = 0; i < HARD_REG_SET_LONGS; i++) \
362 *scan_tp_++ |= *scan_fp_++; } while (0)
364 #define IOR_COMPL_HARD_REG_SET(TO, FROM) \
365 do { HARD_REG_ELT_TYPE *scan_tp_ = (TO), *scan_fp_ = (FROM); \
366 int i; \
367 for (i = 0; i < HARD_REG_SET_LONGS; i++) \
368 *scan_tp_++ |= ~ *scan_fp_++; } while (0)
370 #define GO_IF_HARD_REG_SUBSET(X,Y,TO) \
371 do { HARD_REG_ELT_TYPE *scan_xp_ = (X), *scan_yp_ = (Y); \
372 int i; \
373 for (i = 0; i < HARD_REG_SET_LONGS; i++) \
374 if (0 != (*scan_xp_++ & ~ *scan_yp_++)) break; \
375 if (i == HARD_REG_SET_LONGS) goto TO; } while (0)
377 #define GO_IF_HARD_REG_EQUAL(X,Y,TO) \
378 do { HARD_REG_ELT_TYPE *scan_xp_ = (X), *scan_yp_ = (Y); \
379 int i; \
380 for (i = 0; i < HARD_REG_SET_LONGS; i++) \
381 if (*scan_xp_++ != *scan_yp_++) break; \
382 if (i == HARD_REG_SET_LONGS) goto TO; } while (0)
384 #endif
385 #endif
386 #endif
387 #endif
389 /* Define some standard sets of registers. */
391 /* Indexed by hard register number, contains 1 for registers
392 that are fixed use (stack pointer, pc, frame pointer, etc.).
393 These are the registers that cannot be used to allocate
394 a pseudo reg whose life does not cross calls. */
396 extern char fixed_regs[FIRST_PSEUDO_REGISTER];
398 /* The same info as a HARD_REG_SET. */
400 extern HARD_REG_SET fixed_reg_set;
402 /* Indexed by hard register number, contains 1 for registers
403 that are fixed use or are clobbered by function calls.
404 These are the registers that cannot be used to allocate
405 a pseudo reg whose life crosses calls. */
407 extern char call_used_regs[FIRST_PSEUDO_REGISTER];
409 #ifdef CALL_REALLY_USED_REGISTERS
410 extern char call_really_used_regs[];
411 #endif
413 /* The same info as a HARD_REG_SET. */
415 extern HARD_REG_SET call_used_reg_set;
417 /* Registers that we don't want to caller save. */
418 extern HARD_REG_SET losing_caller_save_reg_set;
420 /* Indexed by hard register number, contains 1 for registers that are
421 fixed use -- i.e. in fixed_regs -- or a function value return register
422 or TARGET_STRUCT_VALUE_RTX or STATIC_CHAIN_REGNUM. These are the
423 registers that cannot hold quantities across calls even if we are
424 willing to save and restore them. */
426 extern char call_fixed_regs[FIRST_PSEUDO_REGISTER];
428 /* The same info as a HARD_REG_SET. */
430 extern HARD_REG_SET call_fixed_reg_set;
432 /* Indexed by hard register number, contains 1 for registers
433 that are being used for global register decls.
434 These must be exempt from ordinary flow analysis
435 and are also considered fixed. */
437 extern char global_regs[FIRST_PSEUDO_REGISTER];
439 /* Contains 1 for registers that are set or clobbered by calls. */
440 /* ??? Ideally, this would be just call_used_regs plus global_regs, but
441 for someone's bright idea to have call_used_regs strictly include
442 fixed_regs. Which leaves us guessing as to the set of fixed_regs
443 that are actually preserved. We know for sure that those associated
444 with the local stack frame are safe, but scant others. */
446 extern HARD_REG_SET regs_invalidated_by_call;
448 #ifdef REG_ALLOC_ORDER
449 /* Table of register numbers in the order in which to try to use them. */
451 extern int reg_alloc_order[FIRST_PSEUDO_REGISTER];
453 /* The inverse of reg_alloc_order. */
455 extern int inv_reg_alloc_order[FIRST_PSEUDO_REGISTER];
456 #endif
458 /* For each reg class, a HARD_REG_SET saying which registers are in it. */
460 extern HARD_REG_SET reg_class_contents[N_REG_CLASSES];
462 /* For each reg class, number of regs it contains. */
464 extern unsigned int reg_class_size[N_REG_CLASSES];
466 /* For each reg class, table listing all the containing classes. */
468 extern enum reg_class reg_class_superclasses[N_REG_CLASSES][N_REG_CLASSES];
470 /* For each reg class, table listing all the classes contained in it. */
472 extern enum reg_class reg_class_subclasses[N_REG_CLASSES][N_REG_CLASSES];
474 /* For each pair of reg classes,
475 a largest reg class contained in their union. */
477 extern enum reg_class reg_class_subunion[N_REG_CLASSES][N_REG_CLASSES];
479 /* For each pair of reg classes,
480 the smallest reg class that contains their union. */
482 extern enum reg_class reg_class_superunion[N_REG_CLASSES][N_REG_CLASSES];
484 /* Number of non-fixed registers. */
486 extern int n_non_fixed_regs;
488 /* Vector indexed by hardware reg giving its name. */
490 extern const char * reg_names[FIRST_PSEUDO_REGISTER];
492 /* Given a hard REGN a FROM mode and a TO mode, return nonzero if
493 REGN cannot change modes between the specified modes. */
494 #define REG_CANNOT_CHANGE_MODE_P(REGN, FROM, TO) \
495 CANNOT_CHANGE_MODE_CLASS (FROM, TO, REGNO_REG_CLASS (REGN))
497 #endif /* ! GCC_HARD_REG_SET_H */