OSDN Git Service

* c-typeck.c, combine.c, cse.c, dominance.c, et-forest.h,
[pf3gnuchains/gcc-fork.git] / gcc / config / pdp11 / pdp11.h
1 /* Definitions of target machine for GNU compiler, for the pdp-11
2    Copyright (C) 1994, 1995, 1996, 1998, 1999, 2000, 2001, 2002, 2004
3    Free Software Foundation, Inc.
4    Contributed by Michael K. Gschwind (mike@vlsivie.tuwien.ac.at).
5
6 This file is part of GCC.
7
8 GCC is free software; you can redistribute it and/or modify
9 it under the terms of the GNU General Public License as published by
10 the Free Software Foundation; either version 2, or (at your option)
11 any later version.
12
13 GCC is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 GNU General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with GCC; see the file COPYING.  If not, write to
20 the Free Software Foundation, 59 Temple Place - Suite 330,
21 Boston, MA 02111-1307, USA.  */
22
23 #define CONSTANT_POOL_BEFORE_FUNCTION   0
24
25 /* check whether load_fpu_reg or not */
26 #define LOAD_FPU_REG_P(x) ((x)>=8 && (x)<=11)
27 #define NO_LOAD_FPU_REG_P(x) ((x)==12 || (x)==13)
28 #define FPU_REG_P(x)    (LOAD_FPU_REG_P(x) || NO_LOAD_FPU_REG_P(x))
29 #define CPU_REG_P(x)    ((x)<8)
30
31 /* Names to predefine in the preprocessor for this target machine.  */
32
33 #define TARGET_CPU_CPP_BUILTINS()               \
34   do                                            \
35     {                                           \
36       builtin_define_std ("pdp11");             \
37     }                                           \
38   while (0)
39
40 /* Print subsidiary information on the compiler version in use.  */
41 #define TARGET_VERSION fprintf (stderr, " (pdp11)");
42
43
44 /* Generate DBX debugging information.  */
45
46 /* #define DBX_DEBUGGING_INFO */
47
48 /* Run-time compilation parameters selecting different hardware subsets.
49 */
50
51 extern int target_flags;
52
53 /* Macro to define tables used to set the flags.
54    This is a list in braces of triplets in braces,
55    each triplet being { "NAME", VALUE, DOC }
56    where VALUE is the bits to set or minus the bits to clear and DOC
57    is the documentation for --help (NULL if intentionally undocumented).
58    An empty string NAME is used to identify the default VALUE.  */
59
60 #define TARGET_SWITCHES  \
61 {   { "fpu", 1, N_("Use hardware floating point") },                    \
62     { "soft-float", -1, N_("Do not use hardware floating point") },     \
63 /* return float result in ac0 */                                        \
64     { "ac0", 2, N_("Return floating point results in ac0") },           \
65     { "no-ac0", -2, N_("Return floating point results in memory") },    \
66 /* is 11/40 */                                                          \
67     { "40", 4, N_("Generate code for an 11/40") },                      \
68     { "no-40", -4, "" },                                                \
69 /* is 11/45 */                                                          \
70     { "45", 8, N_("Generate code for an 11/45") },                      \
71     { "no-45", -8, "" },                                                \
72 /* is 11/10 */                                                          \
73     { "10", -12, N_("Generate code for an 11/10") },                    \
74 /* use movstrhi for bcopy */                                            \
75     { "bcopy", 16, NULL },                                              \
76     { "bcopy-builtin", -16, NULL },                                     \
77 /* use 32 bit for int */                                                \
78     { "int32", 32, N_("Use 32 bit int") },                              \
79     { "no-int16", 32, N_("Use 32 bit int") },                           \
80     { "int16", -32, N_("Use 16 bit int") },                             \
81     { "no-int32", -32, N_("Use 16 bit int") },                          \
82 /* use 32 bit for float */                                              \
83     { "float32", 64, N_("Use 32 bit float") },                          \
84     { "no-float64", 64, N_("Use 32 bit float") },                       \
85     { "float64", -64, N_("Use 64 bit float") },                         \
86     { "no-float32", -64, N_("Use 64 bit float") },                      \
87 /* allow abshi pattern? - can trigger "optimizations" which make code SLOW! */\
88     { "abshi", 128, NULL },                                             \
89     { "no-abshi", -128, NULL },                                         \
90 /* is branching expensive - on a PDP, it's actually really cheap */ \
91 /* this is just to play around and check what code gcc generates */ \
92     { "branch-expensive", 256, NULL },                                  \
93     { "branch-cheap", -256, NULL },                                     \
94 /* split instruction and data memory? */                                \
95     { "split", 1024, N_("Target has split I&D") },                      \
96     { "no-split", -1024, N_("Target does not have split I&D") },        \
97 /* UNIX assembler syntax?  */                                           \
98     { "unix-asm", 2048, N_("Use UNIX assembler syntax") },              \
99     { "dec-asm", -2048, N_("Use DEC assembler syntax") },               \
100 /* default */                   \
101     { "", TARGET_DEFAULT, NULL} \
102 }
103
104 #define TARGET_DEFAULT (1 | 8 | 128 | TARGET_UNIX_ASM_DEFAULT)
105
106 #define TARGET_FPU              (target_flags & 1)
107 #define TARGET_SOFT_FLOAT       (!TARGET_FPU)
108
109 #define TARGET_AC0              ((target_flags & 2) && TARGET_FPU)
110 #define TARGET_NO_AC0           (! TARGET_AC0)
111
112 #define TARGET_45               (target_flags & 8)
113 #define TARGET_40_PLUS          ((target_flags & 4) || (target_flags & 8))
114 #define TARGET_10               (! TARGET_40_PLUS)
115
116 #define TARGET_BCOPY_BUILTIN    (! (target_flags & 16))
117
118 #define TARGET_INT16            (! TARGET_INT32)
119 #define TARGET_INT32            (target_flags & 32)
120
121 #define TARGET_FLOAT32          (target_flags & 64)
122 #define TARGET_FLOAT64          (! TARGET_FLOAT32)
123
124 #define TARGET_ABSHI_BUILTIN    (target_flags & 128)
125
126 #define TARGET_BRANCH_EXPENSIVE (target_flags & 256)
127 #define TARGET_BRANCH_CHEAP     (!TARGET_BRANCH_EXPENSIVE)
128
129 #define TARGET_SPLIT            (target_flags & 1024)
130 #define TARGET_NOSPLIT          (! TARGET_SPLIT)
131
132 #define TARGET_UNIX_ASM         (target_flags & 2048)
133 #define TARGET_UNIX_ASM_DEFAULT 0
134
135 #define ASSEMBLER_DIALECT       (TARGET_UNIX_ASM ? 1 : 0)
136
137 \f
138
139 /* TYPE SIZES */
140 #define SHORT_TYPE_SIZE         16
141 #define INT_TYPE_SIZE           (TARGET_INT16 ? 16 : 32)
142 #define LONG_TYPE_SIZE          32
143 #define LONG_LONG_TYPE_SIZE     64     
144
145 /* if we set FLOAT_TYPE_SIZE to 32, we could have the benefit 
146    of saving core for huge arrays - the definitions are 
147    already in md - but floats can never reside in 
148    an FPU register - we keep the FPU in double float mode 
149    all the time !! */
150 #define FLOAT_TYPE_SIZE         (TARGET_FLOAT32 ? 32 : 64)
151 #define DOUBLE_TYPE_SIZE        64
152 #define LONG_DOUBLE_TYPE_SIZE   64
153
154 /* machine types from ansi */
155 #define SIZE_TYPE "unsigned int"        /* definition of size_t */
156 #define WCHAR_TYPE "int"                /* or long int???? */
157 #define WCHAR_TYPE_SIZE 16
158
159 #define PTRDIFF_TYPE "int"
160
161 /* target machine storage layout */
162
163 /* Define this if most significant bit is lowest numbered
164    in instructions that operate on numbered bit-fields.  */
165 #define BITS_BIG_ENDIAN 0
166
167 /* Define this if most significant byte of a word is the lowest numbered.  */
168 #define BYTES_BIG_ENDIAN 0
169
170 /* Define this if most significant word of a multiword number is first.  */
171 #define WORDS_BIG_ENDIAN 1
172
173 /* Define that floats are in VAX order, not high word first as for ints.  */
174 #define FLOAT_WORDS_BIG_ENDIAN 0
175
176 /* Width of a word, in units (bytes). 
177
178    UNITS OR BYTES - seems like units */
179 #define UNITS_PER_WORD 2
180
181 /* This machine doesn't use IEEE floats.  */
182 /* Because the pdp11 (at least Unix) convention for 32 bit ints is
183    big endian, opposite for what you need for float, the vax float
184    conversion routines aren't actually used directly.  But the underlying
185    format is indeed the vax/pdp11 float format.  */
186 #define TARGET_FLOAT_FORMAT VAX_FLOAT_FORMAT
187
188 extern const struct real_format pdp11_f_format;
189 extern const struct real_format pdp11_d_format;
190
191 /* Maximum sized of reasonable data type 
192    DImode or Dfmode ...*/
193 #define MAX_FIXED_MODE_SIZE 64  
194
195 /* Allocation boundary (in *bits*) for storing pointers in memory.  */
196 #define POINTER_BOUNDARY 16
197
198 /* Allocation boundary (in *bits*) for storing arguments in argument list.  */
199 #define PARM_BOUNDARY 16
200
201 /* Boundary (in *bits*) on which stack pointer should be aligned.  */
202 #define STACK_BOUNDARY 16
203
204 /* Allocation boundary (in *bits*) for the code of a function.  */
205 #define FUNCTION_BOUNDARY 16
206
207 /* Alignment of field after `int : 0' in a structure.  */
208 #define EMPTY_FIELD_BOUNDARY 16
209
210 /* No data type wants to be aligned rounder than this.  */
211 #define BIGGEST_ALIGNMENT 16
212
213 /* Define this if move instructions will actually fail to work
214    when given unaligned data.  */
215 #define STRICT_ALIGNMENT 1
216 \f
217 /* Standard register usage.  */
218
219 /* Number of actual hardware registers.
220    The hardware registers are assigned numbers for the compiler
221    from 0 to just below FIRST_PSEUDO_REGISTER.
222    All registers that the compiler knows about must be given numbers,
223    even those that are not normally considered general registers.
224
225    we have 8 integer registers, plus 6 float 
226    (don't use scratch float !) */
227
228 #define FIRST_PSEUDO_REGISTER 14
229
230 /* 1 for registers that have pervasive standard uses
231    and are not available for the register allocator.
232
233    On the pdp, these are:
234    Reg 7        = pc;
235    reg 6        = sp;
236    reg 5        = fp;  not necessarily! 
237 */
238
239 /* don't let them touch fp regs for the time being !*/
240
241 #define FIXED_REGISTERS  \
242 {0, 0, 0, 0, 0, 0, 1, 1, \
243  0, 0, 0, 0, 0, 0     }
244
245
246
247 /* 1 for registers not available across function calls.
248    These must include the FIXED_REGISTERS and also any
249    registers that can be used without being saved.
250    The latter must include the registers where values are returned
251    and the register where structure-value addresses are passed.
252    Aside from that, you can include as many other registers as you like.  */
253
254 /* don't know about fp */
255 #define CALL_USED_REGISTERS  \
256 {1, 1, 0, 0, 0, 0, 1, 1, \
257  0, 0, 0, 0, 0, 0 }
258
259
260 /* Make sure everything's fine if we *don't* have an FPU.
261    This assumes that putting a register in fixed_regs will keep the
262    compiler's mitts completely off it.  We don't bother to zero it out
263    of register classes.  Also fix incompatible register naming with
264    the UNIX assembler.
265 */
266 #define CONDITIONAL_REGISTER_USAGE \
267 {                                               \
268   int i;                                        \
269   HARD_REG_SET x;                               \
270   if (!TARGET_FPU)                              \
271     {                                           \
272       COPY_HARD_REG_SET (x, reg_class_contents[(int)FPU_REGS]); \
273       for (i = 0; i < FIRST_PSEUDO_REGISTER; i++ ) \
274        if (TEST_HARD_REG_BIT (x, i))            \
275         fixed_regs[i] = call_used_regs[i] = 1;  \
276     }                                           \
277                                                 \
278   if (TARGET_AC0)                               \
279       call_used_regs[8] = 1;                    \
280   if (TARGET_UNIX_ASM)                          \
281     {                                           \
282       /* Change names of FPU registers for the UNIX assembler.  */ \
283       reg_names[8] = "fr0";                     \
284       reg_names[9] = "fr1";                     \
285       reg_names[10] = "fr2";                    \
286       reg_names[11] = "fr3";                    \
287       reg_names[12] = "fr4";                    \
288       reg_names[13] = "fr5";                    \
289     }                                           \
290 }
291
292 /* Return number of consecutive hard regs needed starting at reg REGNO
293    to hold something of mode MODE.
294    This is ordinarily the length in words of a value of mode MODE
295    but can be less for certain modes in special long registers.
296 */
297
298 #define HARD_REGNO_NREGS(REGNO, MODE)   \
299 ((REGNO < 8)?                                                           \
300     ((GET_MODE_SIZE (MODE) + UNITS_PER_WORD - 1) / UNITS_PER_WORD)      \
301     :1)
302     
303
304 /* Value is 1 if hard register REGNO can hold a value of machine-mode MODE.
305    On the pdp, the cpu registers can hold any mode - check alignment
306
307    FPU can only hold DF - simplifies life!
308 */
309 #define HARD_REGNO_MODE_OK(REGNO, MODE) \
310 (((REGNO) < 8)?                                         \
311   ((GET_MODE_BITSIZE(MODE) <= 16)                       \
312    || (GET_MODE_BITSIZE(MODE) == 32 && !((REGNO) & 1))) \
313   :(MODE) == DFmode)
314     
315
316 /* Value is 1 if it is a good idea to tie two pseudo registers
317    when one has mode MODE1 and one has mode MODE2.
318    If HARD_REGNO_MODE_OK could produce different values for MODE1 and MODE2,
319    for any hard reg, then this must be 0 for correct output.  */
320 #define MODES_TIEABLE_P(MODE1, MODE2) 0
321
322 /* Specify the registers used for certain standard purposes.
323    The values of these macros are register numbers.  */
324
325 /* the pdp11 pc overloaded on a register that the compiler knows about.  */
326 #define PC_REGNUM  7
327
328 /* Register to use for pushing function arguments.  */
329 #define STACK_POINTER_REGNUM 6
330
331 /* Base register for access to local variables of the function.  */
332 #define FRAME_POINTER_REGNUM 5
333
334 /* Value should be nonzero if functions must have frame pointers.
335    Zero means the frame pointer need not be set up (and parms
336    may be accessed via the stack pointer) in functions that seem suitable.
337    This is computed in `reload', in reload1.c.
338   */
339
340 #define FRAME_POINTER_REQUIRED 0
341
342 /* Base register for access to arguments of the function.  */
343 #define ARG_POINTER_REGNUM 5
344
345 /* Register in which static-chain is passed to a function.  */
346 /* ??? - i don't want to give up a reg for this! */
347 #define STATIC_CHAIN_REGNUM 4
348 \f
349 /* Define the classes of registers for register constraints in the
350    machine description.  Also define ranges of constants.
351
352    One of the classes must always be named ALL_REGS and include all hard regs.
353    If there is more than one class, another class must be named NO_REGS
354    and contain no registers.
355
356    The name GENERAL_REGS must be the name of a class (or an alias for
357    another name such as ALL_REGS).  This is the class of registers
358    that is allowed by "g" or "r" in a register constraint.
359    Also, registers outside this class are allocated only when
360    instructions express preferences for them.
361
362    The classes must be numbered in nondecreasing order; that is,
363    a larger-numbered class must never be contained completely
364    in a smaller-numbered class.
365
366    For any two classes, it is very desirable that there be another
367    class that represents their union.  */
368    
369 /* The pdp has a couple of classes:
370
371 MUL_REGS are used for odd numbered regs, to use in 16 bit multiplication
372          (even numbered do 32 bit multiply)
373 LMUL_REGS long multiply registers (even numbered regs )
374           (don't need them, all 32 bit regs are even numbered!)
375 GENERAL_REGS is all cpu
376 LOAD_FPU_REGS is the first four cpu regs, they are easier to load
377 NO_LOAD_FPU_REGS is ac4 and ac5, currently - difficult to load them
378 FPU_REGS is all fpu regs 
379 */
380
381 enum reg_class { NO_REGS, MUL_REGS, GENERAL_REGS, LOAD_FPU_REGS, NO_LOAD_FPU_REGS, FPU_REGS, ALL_REGS, LIM_REG_CLASSES };
382
383 #define N_REG_CLASSES (int) LIM_REG_CLASSES
384
385 /* have to allow this till cmpsi/tstsi are fixed in a better way !! */
386 #define SMALL_REGISTER_CLASSES 1
387
388 /* Since GENERAL_REGS is the same class as ALL_REGS,
389    don't give it a different class number; just make it an alias.  */
390
391 /* #define GENERAL_REGS ALL_REGS */
392
393 /* Give names of register classes as strings for dump file.  */
394
395 #define REG_CLASS_NAMES {"NO_REGS", "MUL_REGS", "GENERAL_REGS", "LOAD_FPU_REGS", "NO_LOAD_FPU_REGS", "FPU_REGS", "ALL_REGS" }
396
397 /* Define which registers fit in which classes.
398    This is an initializer for a vector of HARD_REG_SET
399    of length N_REG_CLASSES.  */
400
401 #define REG_CLASS_CONTENTS {{0}, {0x00aa}, {0x00ff}, {0x0f00}, {0x3000}, {0x3f00}, {0x3fff}}
402
403 /* The same information, inverted:
404    Return the class number of the smallest class containing
405    reg number REGNO.  This could be a conditional expression
406    or could index an array.  */
407
408 #define REGNO_REG_CLASS(REGNO)          \
409 ((REGNO)>=8?((REGNO)<=11?LOAD_FPU_REGS:NO_LOAD_FPU_REGS):(((REGNO)&1)?MUL_REGS:GENERAL_REGS))
410
411
412 /* The class value for index registers, and the one for base regs.  */
413 #define INDEX_REG_CLASS GENERAL_REGS
414 #define BASE_REG_CLASS GENERAL_REGS
415
416 /* Get reg_class from a letter such as appears in the machine description.  */
417
418 #define REG_CLASS_FROM_LETTER(C)        \
419 ((C) == 'f' ? FPU_REGS :                        \
420   ((C) == 'd' ? MUL_REGS :                      \
421    ((C) == 'a' ? LOAD_FPU_REGS : NO_REGS)))
422     
423
424 /* The letters I, J, K, L and M in a register constraint string
425    can be used to stand for particular ranges of immediate operands.
426    This macro defines what the ranges are.
427    C is the letter, and VALUE is a constant value.
428    Return 1 if VALUE is in the range specified by C.
429
430    I            bits 31-16 0000
431    J            bits 15-00 0000
432    K            completely random 32 bit
433    L,M,N        -1,1,0 respectively
434    O            where doing shifts in sequence is faster than 
435                 one big shift 
436 */
437
438 #define CONST_OK_FOR_LETTER_P(VALUE, C)  \
439   ((C) == 'I' ? ((VALUE) & 0xffff0000) == 0             \
440    : (C) == 'J' ? ((VALUE) & 0x0000ffff) == 0           \
441    : (C) == 'K' ? (((VALUE) & 0xffff0000) != 0          \
442                    && ((VALUE) & 0x0000ffff) != 0)      \
443    : (C) == 'L' ? ((VALUE) == 1)                        \
444    : (C) == 'M' ? ((VALUE) == -1)                       \
445    : (C) == 'N' ? ((VALUE) == 0)                        \
446    : (C) == 'O' ? (abs(VALUE) >1 && abs(VALUE) <= 4)            \
447    : 0)
448
449 /* Similar, but for floating constants, and defining letters G and H.
450    Here VALUE is the CONST_DOUBLE rtx itself.  */
451
452 #define CONST_DOUBLE_OK_FOR_LETTER_P(VALUE, C)  \
453   ((C) == 'G' && XINT (VALUE, 0) == 0 && XINT (VALUE, 1) == 0)
454
455
456 /* Letters in the range `Q' through `U' may be defined in a
457    machine-dependent fashion to stand for arbitrary operand types. 
458    The machine description macro `EXTRA_CONSTRAINT' is passed the
459    operand as its first argument and the constraint letter as its
460    second operand.
461
462    `Q'  is for memory references that require an extra word after the opcode.
463    `R'  is for memory references which are encoded within the opcode.  */
464
465 #define EXTRA_CONSTRAINT(OP,CODE)                                       \
466   ((GET_CODE (OP) != MEM) ? 0                                           \
467    : !legitimate_address_p (GET_MODE (OP), XEXP (OP, 0)) ? 0            \
468    : ((CODE) == 'Q')      ? !simple_memory_operand (OP, GET_MODE (OP))  \
469    : ((CODE) == 'R')      ? simple_memory_operand (OP, GET_MODE (OP))   \
470    : 0)
471
472 /* Given an rtx X being reloaded into a reg required to be
473    in class CLASS, return the class of reg to actually use.
474    In general this is just CLASS; but on some machines
475    in some cases it is preferable to use a more restrictive class.  
476
477 loading is easier into LOAD_FPU_REGS than FPU_REGS! */
478
479 #define PREFERRED_RELOAD_CLASS(X,CLASS)         \
480 (((CLASS) != FPU_REGS)?(CLASS):LOAD_FPU_REGS)
481
482 #define SECONDARY_RELOAD_CLASS(CLASS,MODE,x)    \
483 (((CLASS) == NO_LOAD_FPU_REGS && !(REG_P(x) && LOAD_FPU_REG_P(REGNO(x))))?LOAD_FPU_REGS:NO_REGS)
484
485 /* Return the maximum number of consecutive registers
486    needed to represent mode MODE in a register of class CLASS.  */
487 #define CLASS_MAX_NREGS(CLASS, MODE)    \
488 ((CLASS == GENERAL_REGS || CLASS == MUL_REGS)?                          \
489   ((GET_MODE_SIZE (MODE) + UNITS_PER_WORD - 1) / UNITS_PER_WORD):       \
490   1                                                                     \
491 )
492
493 \f
494 /* Stack layout; function entry, exit and calling.  */
495
496 /* Define this if pushing a word on the stack
497    makes the stack pointer a smaller address.  */
498 #define STACK_GROWS_DOWNWARD
499
500 /* Define this if the nominal address of the stack frame
501    is at the high-address end of the local variables;
502    that is, each additional local variable allocated
503    goes at a more negative offset in the frame.
504 */
505 #define FRAME_GROWS_DOWNWARD
506
507 /* Offset within stack frame to start allocating local variables at.
508    If FRAME_GROWS_DOWNWARD, this is the offset to the END of the
509    first local allocated.  Otherwise, it is the offset to the BEGINNING
510    of the first local allocated.  */
511 #define STARTING_FRAME_OFFSET 0
512
513 /* If we generate an insn to push BYTES bytes,
514    this says how many the stack pointer really advances by.
515    On the pdp11, the stack is on an even boundary */
516 #define PUSH_ROUNDING(BYTES) ((BYTES + 1) & ~1)
517
518 /* current_first_parm_offset stores the # of registers pushed on the 
519    stack */
520 extern int current_first_parm_offset;
521
522 /* Offset of first parameter from the argument pointer register value.  
523    For the pdp11, this is nonzero to account for the return address.
524         1 - return address
525         2 - frame pointer (always saved, even when not used!!!!)
526                 -- chnage some day !!!:q!
527
528 */
529 #define FIRST_PARM_OFFSET(FNDECL) 4
530
531 /* Value is 1 if returning from a function call automatically
532    pops the arguments described by the number-of-args field in the call.
533    FUNDECL is the declaration node of the function (as a tree),
534    FUNTYPE is the data type of the function (as a tree),
535    or for a library call it is an identifier node for the subroutine name.  */
536
537 #define RETURN_POPS_ARGS(FUNDECL,FUNTYPE,SIZE) 0
538
539 /* Define how to find the value returned by a function.
540    VALTYPE is the data type of the value (as a tree).
541    If the precise function being called is known, FUNC is its FUNCTION_DECL;
542    otherwise, FUNC is 0.  */
543 #define BASE_RETURN_VALUE_REG(MODE) \
544  ((MODE) == DFmode ? 8 : 0) 
545
546 /* On the pdp11 the value is found in R0 (or ac0??? 
547 not without FPU!!!! ) */
548
549 #define FUNCTION_VALUE(VALTYPE, FUNC)  \
550   gen_rtx_REG (TYPE_MODE (VALTYPE), BASE_RETURN_VALUE_REG(TYPE_MODE(VALTYPE)))
551
552 /* and the called function leaves it in the first register.
553    Difference only on machines with register windows.  */
554
555 #define FUNCTION_OUTGOING_VALUE(VALTYPE, FUNC)  \
556   gen_rtx_REG (TYPE_MODE (VALTYPE), BASE_RETURN_VALUE_REG(TYPE_MODE(VALTYPE)))
557
558 /* Define how to find the value returned by a library function
559    assuming the value has mode MODE.  */
560
561 #define LIBCALL_VALUE(MODE)  gen_rtx_REG (MODE, BASE_RETURN_VALUE_REG(MODE))
562
563 /* 1 if N is a possible register number for a function value
564    as seen by the caller.
565    On the pdp, the first "output" reg is the only register thus used. 
566
567 maybe ac0 ? - as option someday! */
568
569 #define FUNCTION_VALUE_REGNO_P(N) (((N) == 0) || (TARGET_AC0 && (N) == 8))
570
571 /* 1 if N is a possible register number for function argument passing.
572    - not used on pdp */
573
574 #define FUNCTION_ARG_REGNO_P(N) 0
575 \f
576 /* Define a data type for recording info about an argument list
577    during the scan of that argument list.  This data type should
578    hold all necessary information about the function itself
579    and about the args processed so far, enough to enable macros
580    such as FUNCTION_ARG to determine where the next arg should go.
581
582 */
583
584 #define CUMULATIVE_ARGS int
585
586 /* Initialize a variable CUM of type CUMULATIVE_ARGS
587    for a call to a function whose data type is FNTYPE.
588    For a library call, FNTYPE is 0.
589
590    ...., the offset normally starts at 0, but starts at 1 word
591    when the function gets a structure-value-address as an
592    invisible first argument.  */
593
594 #define INIT_CUMULATIVE_ARGS(CUM, FNTYPE, LIBNAME, INDIRECT, N_NAMED_ARGS) \
595  ((CUM) = 0)
596
597 /* Update the data in CUM to advance over an argument
598    of mode MODE and data type TYPE.
599    (TYPE is null for libcalls where that information may not be available.)  
600
601 */
602
603
604 #define FUNCTION_ARG_ADVANCE(CUM, MODE, TYPE, NAMED)    \
605  ((CUM) += ((MODE) != BLKmode                   \
606             ? (GET_MODE_SIZE (MODE))            \
607             : (int_size_in_bytes (TYPE))))      
608
609 /* Determine where to put an argument to a function.
610    Value is zero to push the argument on the stack,
611    or a hard register in which to store the argument.
612
613    MODE is the argument's machine mode.
614    TYPE is the data type of the argument (as a tree).
615     This is null for libcalls where that information may
616     not be available.
617    CUM is a variable of type CUMULATIVE_ARGS which gives info about
618     the preceding args and about the function being called.
619    NAMED is nonzero if this argument is a named parameter
620     (otherwise it is an extra parameter matching an ellipsis).  */
621
622 #define FUNCTION_ARG(CUM, MODE, TYPE, NAMED)  0
623
624 /* Define where a function finds its arguments.
625    This would be different from FUNCTION_ARG if we had register windows.  */
626 /*
627 #define FUNCTION_INCOMING_ARG(CUM, MODE, TYPE, NAMED)   \
628   FUNCTION_ARG (CUM, MODE, TYPE, NAMED)
629 */
630
631 /* For an arg passed partly in registers and partly in memory,
632    this is the number of registers used.
633    For args passed entirely in registers or entirely in memory, zero.  */
634
635 #define FUNCTION_ARG_PARTIAL_NREGS(CUM, MODE, TYPE, NAMED) 0
636
637 /* Output assembler code to FILE to increment profiler label # LABELNO
638    for profiling a function entry.  */
639
640 #define FUNCTION_PROFILER(FILE, LABELNO)  \
641    abort ();
642
643 /* EXIT_IGNORE_STACK should be nonzero if, when returning from a function,
644    the stack pointer does not matter.  The value is tested only in
645    functions that have frame pointers.
646    No definition is equivalent to always zero.  */
647
648 extern int may_call_alloca;
649
650 #define EXIT_IGNORE_STACK       1
651
652 #define INITIAL_FRAME_POINTER_OFFSET(DEPTH_VAR) \
653 {                                                               \
654   int offset, regno;                                            \
655   offset = get_frame_size();                                    \
656   for (regno = 0; regno < 8; regno++)                           \
657     if (regs_ever_live[regno] && ! call_used_regs[regno])       \
658       offset += 2;                                              \
659   for (regno = 8; regno < 14; regno++)                          \
660     if (regs_ever_live[regno] && ! call_used_regs[regno])       \
661       offset += 8;                                              \
662   /* offset -= 2;   no fp on stack frame */                     \
663   (DEPTH_VAR) = offset;                                         \
664 }   
665     
666 \f
667 /* Addressing modes, and classification of registers for them.  */
668
669 #define HAVE_POST_INCREMENT 1
670
671 #define HAVE_PRE_DECREMENT 1
672
673 /* Macros to check register numbers against specific register classes.  */
674
675 /* These assume that REGNO is a hard or pseudo reg number.
676    They give nonzero only if REGNO is a hard reg of the suitable class
677    or a pseudo reg currently allocated to a suitable hard reg.
678    Since they use reg_renumber, they are safe only once reg_renumber
679    has been allocated, which happens in local-alloc.c.  */
680
681 #define REGNO_OK_FOR_INDEX_P(REGNO) \
682   ((REGNO) < 8 || (unsigned) reg_renumber[REGNO] < 8)
683 #define REGNO_OK_FOR_BASE_P(REGNO)  \
684   ((REGNO) < 8 || (unsigned) reg_renumber[REGNO] < 8)
685
686 /* Now macros that check whether X is a register and also,
687    strictly, whether it is in a specified class.
688 */
689
690
691 \f
692 /* Maximum number of registers that can appear in a valid memory address.  */
693
694 #define MAX_REGS_PER_ADDRESS 1
695
696 /* Recognize any constant value that is a valid address.  */
697
698 #define CONSTANT_ADDRESS_P(X)  CONSTANT_P (X)
699
700 /* Nonzero if the constant value X is a legitimate general operand.
701    It is given that X satisfies CONSTANT_P or is a CONST_DOUBLE.  */
702
703 #define LEGITIMATE_CONSTANT_P(X)                                        \
704   (GET_CODE (X) != CONST_DOUBLE || legitimate_const_double_p (X))
705
706 /* The macros REG_OK_FOR..._P assume that the arg is a REG rtx
707    and check its validity for a certain class.
708    We have two alternate definitions for each of them.
709    The usual definition accepts all pseudo regs; the other rejects
710    them unless they have been allocated suitable hard regs.
711    The symbol REG_OK_STRICT causes the latter definition to be used.
712
713    Most source files want to accept pseudo regs in the hope that
714    they will get allocated to the class that the insn wants them to be in.
715    Source files for reload pass need to be strict.
716    After reload, it makes no difference, since pseudo regs have
717    been eliminated by then.  */
718
719 #ifndef REG_OK_STRICT
720
721 /* Nonzero if X is a hard reg that can be used as an index
722    or if it is a pseudo reg.  */
723 #define REG_OK_FOR_INDEX_P(X) (1)
724 /* Nonzero if X is a hard reg that can be used as a base reg
725    or if it is a pseudo reg.  */
726 #define REG_OK_FOR_BASE_P(X) (1)
727
728 #else
729
730 /* Nonzero if X is a hard reg that can be used as an index.  */
731 #define REG_OK_FOR_INDEX_P(X) REGNO_OK_FOR_INDEX_P (REGNO (X))
732 /* Nonzero if X is a hard reg that can be used as a base reg.  */
733 #define REG_OK_FOR_BASE_P(X) REGNO_OK_FOR_BASE_P (REGNO (X))
734
735 #endif
736 \f
737 /* GO_IF_LEGITIMATE_ADDRESS recognizes an RTL expression
738    that is a valid memory address for an instruction.
739    The MODE argument is the machine mode for the MEM expression
740    that wants to use this address.
741
742 */
743
744 #define GO_IF_LEGITIMATE_ADDRESS(mode, operand, ADDR) \
745 {                                                     \
746     rtx xfoob;                                                          \
747                                                                         \
748     /* accept (R0) */                                                   \
749     if (GET_CODE (operand) == REG                                       \
750         && REG_OK_FOR_BASE_P(operand))                                  \
751       goto ADDR;                                                        \
752                                                                         \
753     /* accept @#address */                                              \
754     if (CONSTANT_ADDRESS_P (operand))                                   \
755       goto ADDR;                                                        \
756                                                                         \
757     /* accept X(R0) */                                                  \
758     if (GET_CODE (operand) == PLUS                                      \
759         && GET_CODE (XEXP (operand, 0)) == REG                          \
760         && REG_OK_FOR_BASE_P (XEXP (operand, 0))                        \
761         && CONSTANT_ADDRESS_P (XEXP (operand, 1)))                      \
762       goto ADDR;                                                        \
763                                                                         \
764     /* accept -(R0) */                                                  \
765     if (GET_CODE (operand) == PRE_DEC                                   \
766         && GET_CODE (XEXP (operand, 0)) == REG                          \
767         && REG_OK_FOR_BASE_P (XEXP (operand, 0)))                       \
768       goto ADDR;                                                        \
769                                                                         \
770     /* accept (R0)+ */                                                  \
771     if (GET_CODE (operand) == POST_INC                                  \
772         && GET_CODE (XEXP (operand, 0)) == REG                          \
773         && REG_OK_FOR_BASE_P (XEXP (operand, 0)))                       \
774       goto ADDR;                                                        \
775                                                                         \
776     /* accept -(SP) -- which uses PRE_MODIFY for byte mode */           \
777     if (GET_CODE (operand) == PRE_MODIFY                                \
778         && GET_CODE (XEXP (operand, 0)) == REG                          \
779         && REGNO (XEXP (operand, 0)) == 6                               \
780         && GET_CODE ((xfoob = XEXP (operand, 1))) == PLUS               \
781         && GET_CODE (XEXP (xfoob, 0)) == REG                            \
782         && REGNO (XEXP (xfoob, 0)) == 6                                 \
783         && CONSTANT_P (XEXP (xfoob, 1))                                 \
784         && INTVAL (XEXP (xfoob,1)) == -2)                               \
785       goto ADDR;                                                        \
786                                                                         \
787     /* accept (SP)+ -- which uses POST_MODIFY for byte mode */          \
788     if (GET_CODE (operand) == POST_MODIFY                               \
789         && GET_CODE (XEXP (operand, 0)) == REG                          \
790         && REGNO (XEXP (operand, 0)) == 6                               \
791         && GET_CODE ((xfoob = XEXP (operand, 1))) == PLUS               \
792         && GET_CODE (XEXP (xfoob, 0)) == REG                            \
793         && REGNO (XEXP (xfoob, 0)) == 6                                 \
794         && CONSTANT_P (XEXP (xfoob, 1))                                 \
795         && INTVAL (XEXP (xfoob,1)) == 2)                                \
796       goto ADDR;                                                        \
797                                                                         \
798                                                                         \
799     /* handle another level of indirection ! */                         \
800     if (GET_CODE(operand) != MEM)                                       \
801       goto fail;                                                        \
802                                                                         \
803     xfoob = XEXP (operand, 0);                                          \
804                                                                         \
805     /* (MEM:xx (MEM:xx ())) is not valid for SI, DI and currently */    \
806     /* also forbidden for float, because we have to handle this */      \
807     /* in output_move_double and/or output_move_quad() - we could */    \
808     /* do it, but currently it's not worth it!!! */                     \
809     /* now that DFmode cannot go into CPU register file, */             \
810     /* maybe I should allow float ... */                                \
811     /*  but then I have to handle memory-to-memory moves in movdf ?? */ \
812                                                                         \
813     if (GET_MODE_BITSIZE(mode) > 16)                                    \
814       goto fail;                                                        \
815                                                                         \
816     /* accept @(R0) - which is @0(R0) */                                \
817     if (GET_CODE (xfoob) == REG                                         \
818         && REG_OK_FOR_BASE_P(xfoob))                                    \
819       goto ADDR;                                                        \
820                                                                         \
821     /* accept @address */                                               \
822     if (CONSTANT_ADDRESS_P (xfoob))                                     \
823       goto ADDR;                                                        \
824                                                                         \
825     /* accept @X(R0) */                                                 \
826     if (GET_CODE (xfoob) == PLUS                                        \
827         && GET_CODE (XEXP (xfoob, 0)) == REG                            \
828         && REG_OK_FOR_BASE_P (XEXP (xfoob, 0))                          \
829         && CONSTANT_ADDRESS_P (XEXP (xfoob, 1)))                        \
830       goto ADDR;                                                        \
831                                                                         \
832     /* accept @-(R0) */                                                 \
833     if (GET_CODE (xfoob) == PRE_DEC                                     \
834         && GET_CODE (XEXP (xfoob, 0)) == REG                            \
835         && REG_OK_FOR_BASE_P (XEXP (xfoob, 0)))                         \
836       goto ADDR;                                                        \
837                                                                         \
838     /* accept @(R0)+ */                                                 \
839     if (GET_CODE (xfoob) == POST_INC                                    \
840         && GET_CODE (XEXP (xfoob, 0)) == REG                            \
841         && REG_OK_FOR_BASE_P (XEXP (xfoob, 0)))                         \
842       goto ADDR;                                                        \
843                                                                         \
844   /* anything else is invalid */                                        \
845   fail: ;                                                               \
846 }
847
848 \f
849 /* Go to LABEL if ADDR (a legitimate address expression)
850    has an effect that depends on the machine mode it is used for.
851    On the pdp this is for predec/postinc */
852
853 #define GO_IF_MODE_DEPENDENT_ADDRESS(ADDR,LABEL)        \
854  { if (GET_CODE (ADDR) == POST_INC || GET_CODE (ADDR) == PRE_DEC)       \
855      goto LABEL;                                                        \
856  }
857
858 \f
859 /* Specify the machine mode that this machine uses
860    for the index in the tablejump instruction.  */
861 #define CASE_VECTOR_MODE HImode
862
863 /* Define this if a raw index is all that is needed for a
864    `tablejump' insn.  */
865 #define CASE_TAKES_INDEX_RAW
866
867 /* Define this as 1 if `char' should by default be signed; else as 0.  */
868 #define DEFAULT_SIGNED_CHAR 1
869
870 /* Max number of bytes we can move from memory to memory
871    in one reasonably fast instruction.  
872 */
873
874 #define MOVE_MAX 2
875
876 /* Nonzero if access to memory by byte is slow and undesirable. -
877 */
878 #define SLOW_BYTE_ACCESS 0
879
880 /* Do not break .stabs pseudos into continuations.  */
881 #define DBX_CONTIN_LENGTH 0
882
883 /* Value is 1 if truncating an integer of INPREC bits to OUTPREC bits
884    is done just by pretending it is already truncated.  */
885 #define TRULY_NOOP_TRUNCATION(OUTPREC, INPREC) 1
886
887 /* Give a comparison code (EQ, NE etc) and the first operand of a COMPARE,
888    return the mode to be used for the comparison.  For floating-point, CCFPmode
889    should be used.  */
890
891 #define SELECT_CC_MODE(OP,X,Y)  \
892 (GET_MODE_CLASS(GET_MODE(X)) == MODE_FLOAT? CCFPmode : CCmode)
893
894 /* Specify the machine mode that pointers have.
895    After generation of rtl, the compiler makes no further distinction
896    between pointers and any other objects of this machine mode.  */
897 #define Pmode HImode
898
899 /* A function address in a call instruction
900    is a word address (for indexing purposes)
901    so give the MEM rtx a word's mode.  */
902 #define FUNCTION_MODE HImode
903
904 /* Define this if addresses of constant functions
905    shouldn't be put through pseudo regs where they can be cse'd.
906    Desirable on machines where ordinary constants are expensive
907    but a CALL with constant address is cheap.  */
908 /* #define NO_FUNCTION_CSE */
909
910 \f
911 /* cost of moving one register class to another */
912 #define REGISTER_MOVE_COST(MODE, CLASS1, CLASS2) \
913   register_move_cost (CLASS1, CLASS2)
914
915 /* Tell emit-rtl.c how to initialize special values on a per-function base.  */
916 extern int optimize;
917 extern struct rtx_def *cc0_reg_rtx;
918
919 #define CC_STATUS_MDEP rtx
920
921 #define CC_STATUS_MDEP_INIT (cc_status.mdep = 0)
922 \f
923 /* Tell final.c how to eliminate redundant test instructions.  */
924
925 /* Here we define machine-dependent flags and fields in cc_status
926    (see `conditions.h').  */
927
928 #define CC_IN_FPU 04000 
929
930 /* Do UPDATE_CC if EXP is a set, used in
931    NOTICE_UPDATE_CC 
932
933    floats only do compare correctly, else nullify ...
934
935    get cc0 out soon ...
936 */
937
938 /* Store in cc_status the expressions
939    that the condition codes will describe
940    after execution of an instruction whose pattern is EXP.
941    Do not alter them if the instruction would not alter the cc's.  */
942
943 #define NOTICE_UPDATE_CC(EXP, INSN) \
944 { if (GET_CODE (EXP) == SET)                                    \
945     {                                                           \
946       notice_update_cc_on_set(EXP, INSN);                       \
947     }                                                           \
948   else if (GET_CODE (EXP) == PARALLEL                           \
949            && GET_CODE (XVECEXP (EXP, 0, 0)) == SET)            \
950     {                                                           \
951       notice_update_cc_on_set(XVECEXP (EXP, 0, 0), INSN);       \
952     }                                                           \
953   else if (GET_CODE (EXP) == CALL)                              \
954     { /* all bets are off */ CC_STATUS_INIT; }                  \
955   if (cc_status.value1 && GET_CODE (cc_status.value1) == REG    \
956       && cc_status.value2                                       \
957       && reg_overlap_mentioned_p (cc_status.value1, cc_status.value2)) \
958     {                                                           \
959       printf ("here!\n");                                       \
960       cc_status.value2 = 0;                                     \
961     }                                                           \
962 }
963 \f
964 /* Control the assembler format that we output.  */
965
966 /* Output to assembler file text saying following lines
967    may contain character constants, extra white space, comments, etc.  */
968
969 #define ASM_APP_ON ""
970
971 /* Output to assembler file text saying following lines
972    no longer contain unusual constructs.  */
973
974 #define ASM_APP_OFF ""
975
976 /* Output before read-only data.  */
977
978 #define TEXT_SECTION_ASM_OP "\t.text\n"
979
980 /* Output before writable data.  */
981
982 #define DATA_SECTION_ASM_OP "\t.data\n"
983
984 /* How to refer to registers in assembler output.
985    This sequence is indexed by compiler's hard-register-number (see above).  */
986
987 #define REGISTER_NAMES \
988 {"r0", "r1", "r2", "r3", "r4", "r5", "sp", "pc",     \
989  "ac0", "ac1", "ac2", "ac3", "ac4", "ac5" }
990
991 /* Globalizing directive for a label.  */
992 #define GLOBAL_ASM_OP "\t.globl "
993
994 /* The prefix to add to user-visible assembler symbols.  */
995
996 #define USER_LABEL_PREFIX "_"
997
998 /* This is how to store into the string LABEL
999    the symbol_ref name of an internal numbered label where
1000    PREFIX is the class of label and NUM is the number within the class.
1001    This is suitable for output with `assemble_name'.  */
1002
1003 #define ASM_GENERATE_INTERNAL_LABEL(LABEL,PREFIX,NUM)   \
1004   sprintf (LABEL, "*%s_%lu", PREFIX, (unsigned long)(NUM))
1005
1006 #define ASM_OUTPUT_ASCII(FILE, P, SIZE)  \
1007   output_ascii (FILE, P, SIZE)
1008
1009 /* This is how to output an element of a case-vector that is absolute.  */
1010
1011 #define ASM_OUTPUT_ADDR_VEC_ELT(FILE, VALUE)  \
1012   fprintf (FILE, "\t%sL_%d\n", TARGET_UNIX_ASM ? "" : ".word ", VALUE)
1013
1014 /* This is how to output an element of a case-vector that is relative.
1015    Don't define this if it is not supported.  */
1016
1017 /* #define ASM_OUTPUT_ADDR_DIFF_ELT(FILE, VALUE, REL) */
1018
1019 /* This is how to output an assembler line
1020    that says to advance the location counter
1021    to a multiple of 2**LOG bytes. 
1022
1023    who needs this????
1024 */
1025
1026 #define ASM_OUTPUT_ALIGN(FILE,LOG)      \
1027   switch (LOG)                          \
1028     {                                   \
1029       case 0:                           \
1030         break;                          \
1031       case 1:                           \
1032         fprintf (FILE, "\t.even\n");    \
1033         break;                          \
1034       default:                          \
1035         abort ();                       \
1036     }
1037
1038 #define ASM_OUTPUT_SKIP(FILE,SIZE)  \
1039   fprintf (FILE, "\t.=.+ %#ho\n", (unsigned short)(SIZE))
1040
1041 /* This says how to output an assembler line
1042    to define a global common symbol.  */
1043
1044 #define ASM_OUTPUT_COMMON(FILE, NAME, SIZE, ROUNDED)  \
1045 ( fprintf ((FILE), ".globl "),                  \
1046   assemble_name ((FILE), (NAME)),               \
1047   fprintf ((FILE), "\n"),                       \
1048   assemble_name ((FILE), (NAME)),               \
1049   fprintf ((FILE), ": .=.+ %#ho\n", (unsigned short)(ROUNDED))          \
1050 )
1051
1052 /* This says how to output an assembler line
1053    to define a local common symbol.  */
1054
1055 #define ASM_OUTPUT_LOCAL(FILE, NAME, SIZE, ROUNDED)  \
1056 ( assemble_name ((FILE), (NAME)),                               \
1057   fprintf ((FILE), ":\t.=.+ %#ho\n", (unsigned short)(ROUNDED)))
1058
1059 /* Print operand X (an rtx) in assembler syntax to file FILE.
1060    CODE is a letter or dot (`z' in `%z0') or 0 if no letter was specified.
1061    For `%' followed by punctuation, CODE is the punctuation and X is null.
1062
1063 */
1064
1065
1066 #define PRINT_OPERAND(FILE, X, CODE)  \
1067 { if (CODE == '#') fprintf (FILE, "#");                                 \
1068   else if (GET_CODE (X) == REG)                                         \
1069     fprintf (FILE, "%s", reg_names[REGNO (X)]);                         \
1070   else if (GET_CODE (X) == MEM)                                         \
1071     output_address (XEXP (X, 0));                                       \
1072   else if (GET_CODE (X) == CONST_DOUBLE && GET_MODE (X) != SImode)      \
1073     { REAL_VALUE_TYPE r;                                                \
1074       long sval[2];                                                     \
1075       REAL_VALUE_FROM_CONST_DOUBLE (r, X);                              \
1076       REAL_VALUE_TO_TARGET_DOUBLE (r, sval);                            \
1077       fprintf (FILE, "$%#o", sval[0] >> 16); }                          \
1078   else { putc ('$', FILE); output_addr_const_pdp11 (FILE, X); }}
1079 \f
1080 /* Print a memory address as an operand to reference that memory location.  */
1081
1082 #define PRINT_OPERAND_ADDRESS(FILE, ADDR)  \
1083  print_operand_address (FILE, ADDR)
1084
1085 #define ASM_OUTPUT_REG_PUSH(FILE,REGNO)                 \
1086 (                                                       \
1087   fprintf (FILE, "\tmov %s, -(sp)\n", reg_names[REGNO]) \
1088 )
1089
1090 #define ASM_OUTPUT_REG_POP(FILE,REGNO)                          \
1091 (                                                               \
1092   fprintf (FILE, "\tmov (sp)+, %s\n", reg_names[REGNO])         \
1093 )
1094
1095 /* trampoline - how should i do it in separate i+d ? 
1096    have some allocate_trampoline magic??? 
1097
1098    the following should work for shared I/D: */
1099
1100 /* lets see whether this works as trampoline:
1101 MV      #STATIC, $4     0x940Y  0x0000 <- STATIC; Y = STATIC_CHAIN_REGNUM
1102 JMP     FUNCTION        0x0058  0x0000 <- FUNCTION
1103 */
1104
1105 #define TRAMPOLINE_TEMPLATE(FILE)       \
1106 {                                       \
1107   if (TARGET_SPLIT)                     \
1108     abort();                            \
1109                                         \
1110   assemble_aligned_integer (2, GEN_INT (0x9400+STATIC_CHAIN_REGNUM));   \
1111   assemble_aligned_integer (2, const0_rtx);                             \
1112   assemble_aligned_integer (2, GEN_INT(0x0058));                        \
1113   assemble_aligned_integer (2, const0_rtx);                             \
1114 }
1115
1116 #define TRAMPOLINE_SIZE 8
1117 #define TRAMPOLINE_ALIGNMENT 16
1118
1119 /* Emit RTL insns to initialize the variable parts of a trampoline.
1120    FNADDR is an RTX for the address of the function's pure code.
1121    CXT is an RTX for the static chain value for the function.  */
1122
1123 #define INITIALIZE_TRAMPOLINE(TRAMP,FNADDR,CXT) \
1124 {                                       \
1125   if (TARGET_SPLIT)                     \
1126     abort();                            \
1127                                         \
1128   emit_move_insn (gen_rtx_MEM (HImode, plus_constant (TRAMP, 2)), CXT); \
1129   emit_move_insn (gen_rtx_MEM (HImode, plus_constant (TRAMP, 6)), FNADDR); \
1130 }
1131
1132
1133 /* Some machines may desire to change what optimizations are
1134    performed for various optimization levels.   This macro, if
1135    defined, is executed once just after the optimization level is
1136    determined and before the remainder of the command options have
1137    been parsed.  Values set in this macro are used as the default
1138    values for the other command line options.
1139
1140    LEVEL is the optimization level specified; 2 if -O2 is
1141    specified, 1 if -O is specified, and 0 if neither is specified.  */
1142
1143 #define OPTIMIZATION_OPTIONS(LEVEL,SIZE)                                \
1144 {                                                                       \
1145   if (LEVEL >= 3)                                                       \
1146     {                                                                   \
1147       if (! SIZE)                                                       \
1148         flag_inline_functions           = 1;                            \
1149       flag_omit_frame_pointer           = 1;                            \
1150       /* flag_unroll_loops                      = 1; */                 \
1151     }                                                                   \
1152 }
1153
1154 /* there is no point in avoiding branches on a pdp, 
1155    since branches are really cheap - I just want to find out
1156    how much difference the BRANCH_COST macro makes in code */
1157 #define BRANCH_COST (TARGET_BRANCH_CHEAP ? 0 : 1)
1158
1159
1160 #define COMPARE_FLAG_MODE HImode