comparison gcc/defaults.h @ 111:04ced10e8804

gcc 7
author kono
date Fri, 27 Oct 2017 22:46:09 +0900
parents f6334be47118
children 84e7813d76e9
comparison
equal deleted inserted replaced
68:561a7518be6b 111:04ced10e8804
1 /* Definitions of various defaults for tm.h macros. 1 /* Definitions of various defaults for tm.h macros.
2 Copyright (C) 1992, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2 Copyright (C) 1992-2017 Free Software Foundation, Inc.
3 2005, 2007, 2008, 2009, 2010
4 Free Software Foundation, Inc.
5 Contributed by Ron Guilmette (rfg@monkeys.com) 3 Contributed by Ron Guilmette (rfg@monkeys.com)
6 4
7 This file is part of GCC. 5 This file is part of GCC.
8 6
9 GCC is free software; you can redistribute it and/or modify it under 7 GCC is free software; you can redistribute it and/or modify it under
25 see the files COPYING3 and COPYING.RUNTIME respectively. If not, see 23 see the files COPYING3 and COPYING.RUNTIME respectively. If not, see
26 <http://www.gnu.org/licenses/>. */ 24 <http://www.gnu.org/licenses/>. */
27 25
28 #ifndef GCC_DEFAULTS_H 26 #ifndef GCC_DEFAULTS_H
29 #define GCC_DEFAULTS_H 27 #define GCC_DEFAULTS_H
28
29 /* How to start an assembler comment. */
30 #ifndef ASM_COMMENT_START
31 #define ASM_COMMENT_START ";#"
32 #endif
30 33
31 /* Store in OUTPUT a string (made with alloca) containing an 34 /* Store in OUTPUT a string (made with alloca) containing an
32 assembler-name for a local static variable or function named NAME. 35 assembler-name for a local static variable or function named NAME.
33 LABELNO is an integer which is different for each call. */ 36 LABELNO is an integer which is different for each call. */
34 37
71 for (i = 0; i < thissize; i++) \ 74 for (i = 0; i < thissize; i++) \
72 { \ 75 { \
73 int c = p[i]; \ 76 int c = p[i]; \
74 if (c == '\"' || c == '\\') \ 77 if (c == '\"' || c == '\\') \
75 putc ('\\', asm_out_file); \ 78 putc ('\\', asm_out_file); \
76 if (ISPRINT(c)) \ 79 if (ISPRINT (c)) \
77 putc (c, asm_out_file); \ 80 putc (c, asm_out_file); \
78 else \ 81 else \
79 { \ 82 { \
80 fprintf (asm_out_file, "\\%o", c); \ 83 fprintf (asm_out_file, "\\%o", c); \
81 /* After an octal-escape, if a digit follows, \ 84 /* After an octal-escape, if a digit follows, \
82 terminate one string constant and start another. \ 85 terminate one string constant and start another. \
83 The VAX assembler fails to stop reading the escape \ 86 The VAX assembler fails to stop reading the escape \
84 after three digits, so this is the only way we \ 87 after three digits, so this is the only way we \
85 can get it to parse the data properly. */ \ 88 can get it to parse the data properly. */ \
86 if (i < thissize - 1 && ISDIGIT(p[i + 1])) \ 89 if (i < thissize - 1 && ISDIGIT (p[i + 1])) \
87 fprintf (asm_out_file, "\"\n\t.ascii \""); \ 90 fprintf (asm_out_file, "\"\n\t.ascii \""); \
88 } \ 91 } \
89 } \ 92 } \
90 fprintf (asm_out_file, "\"\n"); \ 93 fprintf (asm_out_file, "\"\n"); \
91 } \ 94 } \
118 #define ASM_OUTPUT_TLS_COMMON(FILE, DECL, NAME, SIZE) \ 121 #define ASM_OUTPUT_TLS_COMMON(FILE, DECL, NAME, SIZE) \
119 do \ 122 do \
120 { \ 123 { \
121 fprintf ((FILE), "\t%s\t", TLS_COMMON_ASM_OP); \ 124 fprintf ((FILE), "\t%s\t", TLS_COMMON_ASM_OP); \
122 assemble_name ((FILE), (NAME)); \ 125 assemble_name ((FILE), (NAME)); \
123 fprintf ((FILE), ","HOST_WIDE_INT_PRINT_UNSIGNED",%u\n", \ 126 fprintf ((FILE), "," HOST_WIDE_INT_PRINT_UNSIGNED",%u\n", \
124 (SIZE), DECL_ALIGN (DECL) / BITS_PER_UNIT); \ 127 (SIZE), DECL_ALIGN (DECL) / BITS_PER_UNIT); \
125 } \ 128 } \
126 while (0) 129 while (0)
127 #endif 130 #endif
128 131
135 /* This is how to output the definition of a user-level label named 138 /* This is how to output the definition of a user-level label named
136 NAME, such as the label on variable NAME. */ 139 NAME, such as the label on variable NAME. */
137 140
138 #ifndef ASM_OUTPUT_LABEL 141 #ifndef ASM_OUTPUT_LABEL
139 #define ASM_OUTPUT_LABEL(FILE,NAME) \ 142 #define ASM_OUTPUT_LABEL(FILE,NAME) \
140 do { assemble_name ((FILE), (NAME)); fputs (":\n", (FILE)); } while (0) 143 do { \
144 assemble_name ((FILE), (NAME)); \
145 fputs (":\n", (FILE)); \
146 } while (0)
141 #endif 147 #endif
142 148
143 /* This is how to output the definition of a user-level label named 149 /* This is how to output the definition of a user-level label named
144 NAME, such as the label on a function. */ 150 NAME, such as the label on a function. */
145 151
158 #endif 164 #endif
159 165
160 /* This is how to output a reference to a user-level label named NAME. */ 166 /* This is how to output a reference to a user-level label named NAME. */
161 167
162 #ifndef ASM_OUTPUT_LABELREF 168 #ifndef ASM_OUTPUT_LABELREF
163 #define ASM_OUTPUT_LABELREF(FILE,NAME) asm_fprintf ((FILE), "%U%s", (NAME)) 169 #define ASM_OUTPUT_LABELREF(FILE,NAME) \
170 do { \
171 fputs (user_label_prefix, (FILE)); \
172 fputs ((NAME), (FILE)); \
173 } while (0);
164 #endif 174 #endif
165 175
166 /* Allow target to print debug info labels specially. This is useful for 176 /* Allow target to print debug info labels specially. This is useful for
167 VLIW targets, since debug info labels should go into the middle of 177 VLIW targets, since debug info labels should go into the middle of
168 instruction bundles instead of breaking them. */ 178 instruction bundles instead of breaking them. */
318 # else 328 # else
319 # define TARGET_ATTRIBUTE_WEAK 329 # define TARGET_ATTRIBUTE_WEAK
320 # endif 330 # endif
321 #endif 331 #endif
322 332
323 /* Determines whether we may use common symbols to represent one-only
324 semantics (a.k.a. "vague linkage"). */
325 #ifndef USE_COMMON_FOR_ONE_ONLY
326 # define USE_COMMON_FOR_ONE_ONLY 1
327 #endif
328
329 /* By default we can assume that all global symbols are in one namespace, 333 /* By default we can assume that all global symbols are in one namespace,
330 across all shared libraries. */ 334 across all shared libraries. */
331 #ifndef MULTIPLE_SYMBOL_SPACES 335 #ifndef MULTIPLE_SYMBOL_SPACES
332 # define MULTIPLE_SYMBOL_SPACES 0 336 # define MULTIPLE_SYMBOL_SPACES 0
333 #endif 337 #endif
336 SUPPORTS_INIT_PRIORITY a nonzero value. */ 340 SUPPORTS_INIT_PRIORITY a nonzero value. */
337 #ifndef SUPPORTS_INIT_PRIORITY 341 #ifndef SUPPORTS_INIT_PRIORITY
338 #define SUPPORTS_INIT_PRIORITY 1 342 #define SUPPORTS_INIT_PRIORITY 1
339 #endif /* SUPPORTS_INIT_PRIORITY */ 343 #endif /* SUPPORTS_INIT_PRIORITY */
340 344
341 /* If duplicate library search directories can be removed from a
342 linker command without changing the linker's semantics, give this
343 symbol a nonzero. */
344 #ifndef LINK_ELIMINATE_DUPLICATE_LDIRECTORIES
345 #define LINK_ELIMINATE_DUPLICATE_LDIRECTORIES 0
346 #endif /* LINK_ELIMINATE_DUPLICATE_LDIRECTORIES */
347
348 /* If we have a definition of INCOMING_RETURN_ADDR_RTX, assume that 345 /* If we have a definition of INCOMING_RETURN_ADDR_RTX, assume that
349 the rest of the DWARF 2 frame unwind support is also provided. */ 346 the rest of the DWARF 2 frame unwind support is also provided. */
350 #if !defined (DWARF2_UNWIND_INFO) && defined (INCOMING_RETURN_ADDR_RTX) 347 #if !defined (DWARF2_UNWIND_INFO) && defined (INCOMING_RETURN_ADDR_RTX)
351 #define DWARF2_UNWIND_INFO 1 348 #define DWARF2_UNWIND_INFO 1
352 #endif 349 #endif
353 350
354 /* If we have named sections, and we're using crtstuff to run ctors, 351 /* If we have named sections, and we're using crtstuff to run ctors,
355 use them for registering eh frame information. */ 352 use them for registering eh frame information. */
356 #if defined (TARGET_ASM_NAMED_SECTION) && DWARF2_UNWIND_INFO \ 353 #if defined (TARGET_ASM_NAMED_SECTION) && DWARF2_UNWIND_INFO \
357 && !defined(EH_FRAME_IN_DATA_SECTION) 354 && !defined (EH_FRAME_THROUGH_COLLECT2)
358 #ifndef EH_FRAME_SECTION_NAME 355 #ifndef EH_FRAME_SECTION_NAME
359 #define EH_FRAME_SECTION_NAME ".eh_frame" 356 #define EH_FRAME_SECTION_NAME ".eh_frame"
360 #endif 357 #endif
361 #endif 358 #endif
362 359
378 #else 375 #else
379 #define EH_TABLES_CAN_BE_READ_ONLY 0 376 #define EH_TABLES_CAN_BE_READ_ONLY 0
380 #endif 377 #endif
381 #endif 378 #endif
382 379
383 /* If we have named section and we support weak symbols, then use the 380 /* Provide defaults for stuff that may not be defined when using
384 .jcr section for recording java classes which need to be registered 381 sjlj exceptions. */
385 at program start-up time. */ 382 #ifndef EH_RETURN_DATA_REGNO
386 #if defined (TARGET_ASM_NAMED_SECTION) && SUPPORTS_WEAK 383 #define EH_RETURN_DATA_REGNO(N) INVALID_REGNUM
387 #ifndef JCR_SECTION_NAME 384 #endif
388 #define JCR_SECTION_NAME ".jcr" 385
389 #endif 386 /* Offset between the eh handler address and entry in eh tables. */
390 #endif 387 #ifndef RETURN_ADDR_OFFSET
391 388 #define RETURN_ADDR_OFFSET 0
392 /* This decision to use a .jcr section can be overridden by defining 389 #endif
393 USE_JCR_SECTION to 0 in target file. This is necessary if target 390
394 can define JCR_SECTION_NAME but does not have crtstuff or 391 #ifndef MASK_RETURN_ADDR
395 linker support for .jcr section. */ 392 #define MASK_RETURN_ADDR NULL_RTX
396 #ifndef TARGET_USE_JCR_SECTION
397 #ifdef JCR_SECTION_NAME
398 #define TARGET_USE_JCR_SECTION 1
399 #else
400 #define TARGET_USE_JCR_SECTION 0
401 #endif
402 #endif 393 #endif
403 394
404 /* Number of hardware registers that go into the DWARF-2 unwind info. 395 /* Number of hardware registers that go into the DWARF-2 unwind info.
405 If not defined, equals FIRST_PSEUDO_REGISTER */ 396 If not defined, equals FIRST_PSEUDO_REGISTER */
406 397
407 #ifndef DWARF_FRAME_REGISTERS 398 #ifndef DWARF_FRAME_REGISTERS
408 #define DWARF_FRAME_REGISTERS FIRST_PSEUDO_REGISTER 399 #define DWARF_FRAME_REGISTERS FIRST_PSEUDO_REGISTER
409 #endif 400 #endif
410 401
402 /* Offsets recorded in opcodes are a multiple of this alignment factor. */
403 #ifndef DWARF_CIE_DATA_ALIGNMENT
404 #ifdef STACK_GROWS_DOWNWARD
405 #define DWARF_CIE_DATA_ALIGNMENT (-((int) UNITS_PER_WORD))
406 #else
407 #define DWARF_CIE_DATA_ALIGNMENT ((int) UNITS_PER_WORD)
408 #endif
409 #endif
410
411 /* The DWARF 2 CFA column which tracks the return address. Normally this
412 is the column for PC, or the first column after all of the hard
413 registers. */
414 #ifndef DWARF_FRAME_RETURN_COLUMN
415 #ifdef PC_REGNUM
416 #define DWARF_FRAME_RETURN_COLUMN DWARF_FRAME_REGNUM (PC_REGNUM)
417 #else
418 #define DWARF_FRAME_RETURN_COLUMN DWARF_FRAME_REGISTERS
419 #endif
420 #endif
421
411 /* How to renumber registers for dbx and gdb. If not defined, assume 422 /* How to renumber registers for dbx and gdb. If not defined, assume
412 no renumbering is necessary. */ 423 no renumbering is necessary. */
413 424
414 #ifndef DBX_REGISTER_NUMBER 425 #ifndef DBX_REGISTER_NUMBER
415 #define DBX_REGISTER_NUMBER(REGNO) (REGNO) 426 #define DBX_REGISTER_NUMBER(REGNO) (REGNO)
427 #endif
428
429 /* The mapping from gcc register number to DWARF 2 CFA column number.
430 By default, we just provide columns for all registers. */
431 #ifndef DWARF_FRAME_REGNUM
432 #define DWARF_FRAME_REGNUM(REG) DBX_REGISTER_NUMBER (REG)
433 #endif
434
435 /* The mapping from dwarf CFA reg number to internal dwarf reg numbers. */
436 #ifndef DWARF_REG_TO_UNWIND_COLUMN
437 #define DWARF_REG_TO_UNWIND_COLUMN(REGNO) (REGNO)
438 #endif
439
440 /* Map register numbers held in the call frame info that gcc has
441 collected using DWARF_FRAME_REGNUM to those that should be output in
442 .debug_frame and .eh_frame. */
443 #ifndef DWARF2_FRAME_REG_OUT
444 #define DWARF2_FRAME_REG_OUT(REGNO, FOR_EH) (REGNO)
445 #endif
446
447 /* The size of addresses as they appear in the Dwarf 2 data.
448 Some architectures use word addresses to refer to code locations,
449 but Dwarf 2 info always uses byte addresses. On such machines,
450 Dwarf 2 addresses need to be larger than the architecture's
451 pointers. */
452 #ifndef DWARF2_ADDR_SIZE
453 #define DWARF2_ADDR_SIZE ((POINTER_SIZE + BITS_PER_UNIT - 1) / BITS_PER_UNIT)
454 #endif
455
456 /* The size in bytes of a DWARF field indicating an offset or length
457 relative to a debug info section, specified to be 4 bytes in the
458 DWARF-2 specification. The SGI/MIPS ABI defines it to be the same
459 as PTR_SIZE. */
460 #ifndef DWARF_OFFSET_SIZE
461 #define DWARF_OFFSET_SIZE 4
462 #endif
463
464 /* The size in bytes of a DWARF 4 type signature. */
465 #ifndef DWARF_TYPE_SIGNATURE_SIZE
466 #define DWARF_TYPE_SIGNATURE_SIZE 8
416 #endif 467 #endif
417 468
418 /* Default sizes for base C types. If the sizes are different for 469 /* Default sizes for base C types. If the sizes are different for
419 your target, you should override these values by defining the 470 your target, you should override these values by defining the
420 appropriate symbols in your tm.h file. */ 471 appropriate symbols in your tm.h file. */
421
422 #ifndef BITS_PER_UNIT
423 #define BITS_PER_UNIT 8
424 #endif
425 472
426 #ifndef BITS_PER_WORD 473 #ifndef BITS_PER_WORD
427 #define BITS_PER_WORD (BITS_PER_UNIT * UNITS_PER_WORD) 474 #define BITS_PER_WORD (BITS_PER_UNIT * UNITS_PER_WORD)
428 #endif 475 #endif
429 476
518 it would be best to do something here to figure out automatically 565 it would be best to do something here to figure out automatically
519 from other information what type to use. */ 566 from other information what type to use. */
520 567
521 #ifndef SIZE_TYPE 568 #ifndef SIZE_TYPE
522 #define SIZE_TYPE "long unsigned int" 569 #define SIZE_TYPE "long unsigned int"
570 #endif
571
572 #ifndef SIZETYPE
573 #define SIZETYPE SIZE_TYPE
523 #endif 574 #endif
524 575
525 #ifndef PID_TYPE 576 #ifndef PID_TYPE
526 #define PID_TYPE "int" 577 #define PID_TYPE "int"
527 #endif 578 #endif
689 740
690 /* Width in bits of a pointer. Mind the value of the macro `Pmode'. */ 741 /* Width in bits of a pointer. Mind the value of the macro `Pmode'. */
691 #ifndef POINTER_SIZE 742 #ifndef POINTER_SIZE
692 #define POINTER_SIZE BITS_PER_WORD 743 #define POINTER_SIZE BITS_PER_WORD
693 #endif 744 #endif
745 #ifndef POINTER_SIZE_UNITS
746 #define POINTER_SIZE_UNITS ((POINTER_SIZE + BITS_PER_UNIT - 1) / BITS_PER_UNIT)
747 #endif
748
694 749
695 #ifndef PIC_OFFSET_TABLE_REGNUM 750 #ifndef PIC_OFFSET_TABLE_REGNUM
696 #define PIC_OFFSET_TABLE_REGNUM INVALID_REGNUM 751 #define PIC_OFFSET_TABLE_REGNUM INVALID_REGNUM
697 #endif 752 #endif
698 753
722 #endif 777 #endif
723 #endif 778 #endif
724 779
725 #ifndef ACCUMULATE_OUTGOING_ARGS 780 #ifndef ACCUMULATE_OUTGOING_ARGS
726 #define ACCUMULATE_OUTGOING_ARGS 0 781 #define ACCUMULATE_OUTGOING_ARGS 0
782 #endif
783
784 /* By default, use the GNU runtime for Objective C. */
785 #ifndef NEXT_OBJC_RUNTIME
786 #define NEXT_OBJC_RUNTIME 0
727 #endif 787 #endif
728 788
729 /* Supply a default definition for PUSH_ARGS. */ 789 /* Supply a default definition for PUSH_ARGS. */
730 #ifndef PUSH_ARGS 790 #ifndef PUSH_ARGS
731 #ifdef PUSH_ROUNDING 791 #ifdef PUSH_ROUNDING
798 #ifndef TARGET_USE_LOCAL_THUNK_ALIAS_P 858 #ifndef TARGET_USE_LOCAL_THUNK_ALIAS_P
799 #ifdef ASM_OUTPUT_DEF 859 #ifdef ASM_OUTPUT_DEF
800 #define TARGET_USE_LOCAL_THUNK_ALIAS_P(DECL) 1 860 #define TARGET_USE_LOCAL_THUNK_ALIAS_P(DECL) 1
801 #else 861 #else
802 #define TARGET_USE_LOCAL_THUNK_ALIAS_P(DECL) 0 862 #define TARGET_USE_LOCAL_THUNK_ALIAS_P(DECL) 0
863 #endif
864 #endif
865
866 /* Decide whether target supports aliases. */
867 #ifndef TARGET_SUPPORTS_ALIASES
868 #ifdef ASM_OUTPUT_DEF
869 #define TARGET_SUPPORTS_ALIASES 1
870 #else
871 #define TARGET_SUPPORTS_ALIASES 0
803 #endif 872 #endif
804 #endif 873 #endif
805 874
806 /* Select a format to encode pointers in exception handling data. We 875 /* Select a format to encode pointers in exception handling data. We
807 prefer those that result in fewer dynamic relocations. Assume no 876 prefer those that result in fewer dynamic relocations. Assume no
823 892
824 #ifndef DEFAULT_GDB_EXTENSIONS 893 #ifndef DEFAULT_GDB_EXTENSIONS
825 #define DEFAULT_GDB_EXTENSIONS 1 894 #define DEFAULT_GDB_EXTENSIONS 1
826 #endif 895 #endif
827 896
897 #ifndef SDB_DEBUGGING_INFO
898 #define SDB_DEBUGGING_INFO 0
899 #endif
900
828 /* If more than one debugging type is supported, you must define 901 /* If more than one debugging type is supported, you must define
829 PREFERRED_DEBUGGING_TYPE to choose the default. */ 902 PREFERRED_DEBUGGING_TYPE to choose the default. */
830 903
831 #if 1 < (defined (DBX_DEBUGGING_INFO) + defined (SDB_DEBUGGING_INFO) \ 904 #if 1 < (defined (DBX_DEBUGGING_INFO) + (SDB_DEBUGGING_INFO) \
832 + defined (DWARF2_DEBUGGING_INFO) + defined (XCOFF_DEBUGGING_INFO) \ 905 + defined (DWARF2_DEBUGGING_INFO) + defined (XCOFF_DEBUGGING_INFO) \
833 + defined (VMS_DEBUGGING_INFO)) 906 + defined (VMS_DEBUGGING_INFO))
834 #ifndef PREFERRED_DEBUGGING_TYPE 907 #ifndef PREFERRED_DEBUGGING_TYPE
835 #error You must define PREFERRED_DEBUGGING_TYPE 908 #error You must define PREFERRED_DEBUGGING_TYPE
836 #endif /* no PREFERRED_DEBUGGING_TYPE */ 909 #endif /* no PREFERRED_DEBUGGING_TYPE */
838 /* If only one debugging format is supported, define PREFERRED_DEBUGGING_TYPE 911 /* If only one debugging format is supported, define PREFERRED_DEBUGGING_TYPE
839 here so other code needn't care. */ 912 here so other code needn't care. */
840 #elif defined DBX_DEBUGGING_INFO 913 #elif defined DBX_DEBUGGING_INFO
841 #define PREFERRED_DEBUGGING_TYPE DBX_DEBUG 914 #define PREFERRED_DEBUGGING_TYPE DBX_DEBUG
842 915
843 #elif defined SDB_DEBUGGING_INFO 916 #elif SDB_DEBUGGING_INFO
844 #define PREFERRED_DEBUGGING_TYPE SDB_DEBUG 917 #define PREFERRED_DEBUGGING_TYPE SDB_DEBUG
845 918
846 #elif defined DWARF2_DEBUGGING_INFO 919 #elif defined DWARF2_DEBUGGING_INFO || defined DWARF2_LINENO_DEBUGGING_INFO
847 #define PREFERRED_DEBUGGING_TYPE DWARF2_DEBUG 920 #define PREFERRED_DEBUGGING_TYPE DWARF2_DEBUG
848 921
849 #elif defined VMS_DEBUGGING_INFO 922 #elif defined VMS_DEBUGGING_INFO
850 #define PREFERRED_DEBUGGING_TYPE VMS_AND_DWARF2_DEBUG 923 #define PREFERRED_DEBUGGING_TYPE VMS_AND_DWARF2_DEBUG
851 924
853 #define PREFERRED_DEBUGGING_TYPE XCOFF_DEBUG 926 #define PREFERRED_DEBUGGING_TYPE XCOFF_DEBUG
854 927
855 #else 928 #else
856 /* No debugging format is supported by this target. */ 929 /* No debugging format is supported by this target. */
857 #define PREFERRED_DEBUGGING_TYPE NO_DEBUG 930 #define PREFERRED_DEBUGGING_TYPE NO_DEBUG
858 #endif
859
860 #ifndef LARGEST_EXPONENT_IS_NORMAL
861 #define LARGEST_EXPONENT_IS_NORMAL(SIZE) 0
862 #endif
863
864 #ifndef ROUND_TOWARDS_ZERO
865 #define ROUND_TOWARDS_ZERO 0
866 #endif 931 #endif
867 932
868 #ifndef FLOAT_LIB_COMPARE_RETURNS_BOOL 933 #ifndef FLOAT_LIB_COMPARE_RETURNS_BOOL
869 #define FLOAT_LIB_COMPARE_RETURNS_BOOL(MODE, COMPARISON) false 934 #define FLOAT_LIB_COMPARE_RETURNS_BOOL(MODE, COMPARISON) false
870 #endif 935 #endif
880 then the word-endianness is the same as for integers. */ 945 then the word-endianness is the same as for integers. */
881 #ifndef FLOAT_WORDS_BIG_ENDIAN 946 #ifndef FLOAT_WORDS_BIG_ENDIAN
882 #define FLOAT_WORDS_BIG_ENDIAN WORDS_BIG_ENDIAN 947 #define FLOAT_WORDS_BIG_ENDIAN WORDS_BIG_ENDIAN
883 #endif 948 #endif
884 949
885 #ifdef TARGET_FLT_EVAL_METHOD 950 #ifndef REG_WORDS_BIG_ENDIAN
886 #define TARGET_FLT_EVAL_METHOD_NON_DEFAULT 1 951 #define REG_WORDS_BIG_ENDIAN WORDS_BIG_ENDIAN
887 #else 952 #endif
888 #define TARGET_FLT_EVAL_METHOD 0 953
889 #define TARGET_FLT_EVAL_METHOD_NON_DEFAULT 0
890 #endif
891 954
892 #ifndef TARGET_DEC_EVAL_METHOD 955 #ifndef TARGET_DEC_EVAL_METHOD
893 #define TARGET_DEC_EVAL_METHOD 2 956 #define TARGET_DEC_EVAL_METHOD 2
894 #endif 957 #endif
895 958
905 register C++ destructors for local statics and global objects. */ 968 register C++ destructors for local statics and global objects. */
906 #ifndef DEFAULT_USE_CXA_ATEXIT 969 #ifndef DEFAULT_USE_CXA_ATEXIT
907 #define DEFAULT_USE_CXA_ATEXIT 0 970 #define DEFAULT_USE_CXA_ATEXIT 0
908 #endif 971 #endif
909 972
910 /* If none of these macros are defined, the port must use the new
911 technique of defining constraints in the machine description.
912 tm_p.h will define those macros that machine-independent code
913 still uses. */
914 #if !defined CONSTRAINT_LEN \
915 && !defined REG_CLASS_FROM_LETTER \
916 && !defined REG_CLASS_FROM_CONSTRAINT \
917 && !defined CONST_OK_FOR_LETTER_P \
918 && !defined CONST_OK_FOR_CONSTRAINT_P \
919 && !defined CONST_DOUBLE_OK_FOR_LETTER_P \
920 && !defined CONST_DOUBLE_OK_FOR_CONSTRAINT_P \
921 && !defined EXTRA_CONSTRAINT \
922 && !defined EXTRA_CONSTRAINT_STR \
923 && !defined EXTRA_MEMORY_CONSTRAINT \
924 && !defined EXTRA_ADDRESS_CONSTRAINT
925
926 #define USE_MD_CONSTRAINTS
927
928 #if GCC_VERSION >= 3000 && defined IN_GCC 973 #if GCC_VERSION >= 3000 && defined IN_GCC
929 /* These old constraint macros shouldn't appear anywhere in a 974 /* These old constraint macros shouldn't appear anywhere in a
930 configuration using MD constraint definitions. */ 975 configuration using MD constraint definitions. */
931 #pragma GCC poison REG_CLASS_FROM_LETTER CONST_OK_FOR_LETTER_P \ 976 #endif
932 CONST_DOUBLE_OK_FOR_LETTER_P EXTRA_CONSTRAINT 977
933 #endif 978 /* Determin whether the target runtime library is Bionic */
934 979 #ifndef TARGET_HAS_BIONIC
935 #else /* old constraint mechanism in use */ 980 #define TARGET_HAS_BIONIC 0
936
937 /* Determine whether extra constraint letter should be handled
938 via address reload (like 'o'). */
939 #ifndef EXTRA_MEMORY_CONSTRAINT
940 #define EXTRA_MEMORY_CONSTRAINT(C,STR) 0
941 #endif
942
943 /* Determine whether extra constraint letter should be handled
944 as an address (like 'p'). */
945 #ifndef EXTRA_ADDRESS_CONSTRAINT
946 #define EXTRA_ADDRESS_CONSTRAINT(C,STR) 0
947 #endif
948
949 /* When a port defines CONSTRAINT_LEN, it should use DEFAULT_CONSTRAINT_LEN
950 for all the characters that it does not want to change, so things like the
951 'length' of a digit in a matching constraint is an implementation detail,
952 and not part of the interface. */
953 #define DEFAULT_CONSTRAINT_LEN(C,STR) 1
954
955 #ifndef CONSTRAINT_LEN
956 #define CONSTRAINT_LEN(C,STR) DEFAULT_CONSTRAINT_LEN (C, STR)
957 #endif
958
959 #if defined (CONST_OK_FOR_LETTER_P) && ! defined (CONST_OK_FOR_CONSTRAINT_P)
960 #define CONST_OK_FOR_CONSTRAINT_P(VAL,C,STR) CONST_OK_FOR_LETTER_P (VAL, C)
961 #endif
962
963 #if defined (CONST_DOUBLE_OK_FOR_LETTER_P) && ! defined (CONST_DOUBLE_OK_FOR_CONSTRAINT_P)
964 #define CONST_DOUBLE_OK_FOR_CONSTRAINT_P(OP,C,STR) \
965 CONST_DOUBLE_OK_FOR_LETTER_P (OP, C)
966 #endif
967
968 #ifndef REG_CLASS_FROM_CONSTRAINT
969 #define REG_CLASS_FROM_CONSTRAINT(C,STR) REG_CLASS_FROM_LETTER (C)
970 #endif
971
972 #if defined (EXTRA_CONSTRAINT) && ! defined (EXTRA_CONSTRAINT_STR)
973 #define EXTRA_CONSTRAINT_STR(OP, C,STR) EXTRA_CONSTRAINT (OP, C)
974 #endif
975
976 #endif /* old constraint mechanism in use */
977
978 /* Determine whether the entire c99 runtime
979 is present in the runtime library. */
980 #ifndef TARGET_C99_FUNCTIONS
981 #define TARGET_C99_FUNCTIONS 0
982 #endif
983
984 /* Determine whether the target runtime library has
985 a sincos implementation following the GNU extension. */
986 #ifndef TARGET_HAS_SINCOS
987 #define TARGET_HAS_SINCOS 0
988 #endif 981 #endif
989 982
990 /* Indicate that CLZ and CTZ are undefined at zero. */ 983 /* Indicate that CLZ and CTZ are undefined at zero. */
991 #ifndef CLZ_DEFINED_VALUE_AT_ZERO 984 #ifndef CLZ_DEFINED_VALUE_AT_ZERO
992 #define CLZ_DEFINED_VALUE_AT_ZERO(MODE, VALUE) 0 985 #define CLZ_DEFINED_VALUE_AT_ZERO(MODE, VALUE) 0
1009 1002
1010 #ifndef MOVE_MAX_PIECES 1003 #ifndef MOVE_MAX_PIECES
1011 #define MOVE_MAX_PIECES MOVE_MAX 1004 #define MOVE_MAX_PIECES MOVE_MAX
1012 #endif 1005 #endif
1013 1006
1007 /* STORE_MAX_PIECES is the number of bytes at a time that we can
1008 store efficiently. Due to internal GCC limitations, this is
1009 MOVE_MAX_PIECES limited by the number of bytes GCC can represent
1010 for an immediate constant. */
1011
1012 #ifndef STORE_MAX_PIECES
1013 #define STORE_MAX_PIECES MIN (MOVE_MAX_PIECES, 2 * sizeof (HOST_WIDE_INT))
1014 #endif
1015
1016 /* Likewise for block comparisons. */
1017 #ifndef COMPARE_MAX_PIECES
1018 #define COMPARE_MAX_PIECES MOVE_MAX_PIECES
1019 #endif
1020
1014 #ifndef MAX_MOVE_MAX 1021 #ifndef MAX_MOVE_MAX
1015 #define MAX_MOVE_MAX MOVE_MAX 1022 #define MAX_MOVE_MAX MOVE_MAX
1016 #endif 1023 #endif
1017 1024
1018 #ifndef MIN_UNITS_PER_WORD 1025 #ifndef MIN_UNITS_PER_WORD
1027 #define STACK_POINTER_OFFSET 0 1034 #define STACK_POINTER_OFFSET 0
1028 #endif 1035 #endif
1029 1036
1030 #ifndef LOCAL_REGNO 1037 #ifndef LOCAL_REGNO
1031 #define LOCAL_REGNO(REGNO) 0 1038 #define LOCAL_REGNO(REGNO) 0
1039 #endif
1040
1041 #ifndef HONOR_REG_ALLOC_ORDER
1042 #define HONOR_REG_ALLOC_ORDER 0
1032 #endif 1043 #endif
1033 1044
1034 /* EXIT_IGNORE_STACK should be nonzero if, when returning from a function, 1045 /* EXIT_IGNORE_STACK should be nonzero if, when returning from a function,
1035 the stack pointer does not matter. The value is tested only in 1046 the stack pointer does not matter. The value is tested only in
1036 functions that have frame pointers. */ 1047 functions that have frame pointers. */
1041 /* Assume that case vectors are not pc-relative. */ 1052 /* Assume that case vectors are not pc-relative. */
1042 #ifndef CASE_VECTOR_PC_RELATIVE 1053 #ifndef CASE_VECTOR_PC_RELATIVE
1043 #define CASE_VECTOR_PC_RELATIVE 0 1054 #define CASE_VECTOR_PC_RELATIVE 0
1044 #endif 1055 #endif
1045 1056
1057 /* Force minimum alignment to be able to use the least significant bits
1058 for distinguishing descriptor addresses from code addresses. */
1059 #define FUNCTION_ALIGNMENT(ALIGN) \
1060 (lang_hooks.custom_function_descriptors \
1061 && targetm.calls.custom_function_descriptors > 0 \
1062 ? MAX ((ALIGN), \
1063 2 * targetm.calls.custom_function_descriptors * BITS_PER_UNIT)\
1064 : (ALIGN))
1065
1046 /* Assume that trampolines need function alignment. */ 1066 /* Assume that trampolines need function alignment. */
1047 #ifndef TRAMPOLINE_ALIGNMENT 1067 #ifndef TRAMPOLINE_ALIGNMENT
1048 #define TRAMPOLINE_ALIGNMENT FUNCTION_BOUNDARY 1068 #define TRAMPOLINE_ALIGNMENT FUNCTION_ALIGNMENT (FUNCTION_BOUNDARY)
1049 #endif 1069 #endif
1050 1070
1051 /* Register mappings for target machines without register windows. */ 1071 /* Register mappings for target machines without register windows. */
1052 #ifndef INCOMING_REGNO 1072 #ifndef INCOMING_REGNO
1053 #define INCOMING_REGNO(N) (N) 1073 #define INCOMING_REGNO(N) (N)
1078 #define MAX_OFILE_ALIGNMENT BIGGEST_ALIGNMENT 1098 #define MAX_OFILE_ALIGNMENT BIGGEST_ALIGNMENT
1079 #endif 1099 #endif
1080 1100
1081 #ifndef FRAME_GROWS_DOWNWARD 1101 #ifndef FRAME_GROWS_DOWNWARD
1082 #define FRAME_GROWS_DOWNWARD 0 1102 #define FRAME_GROWS_DOWNWARD 0
1103 #endif
1104
1105 #ifndef RETURN_ADDR_IN_PREVIOUS_FRAME
1106 #define RETURN_ADDR_IN_PREVIOUS_FRAME 0
1083 #endif 1107 #endif
1084 1108
1085 /* On most machines, the CFA coincides with the first incoming parm. */ 1109 /* On most machines, the CFA coincides with the first incoming parm. */
1086 #ifndef ARG_POINTER_CFA_OFFSET 1110 #ifndef ARG_POINTER_CFA_OFFSET
1087 #define ARG_POINTER_CFA_OFFSET(FNDECL) \ 1111 #define ARG_POINTER_CFA_OFFSET(FNDECL) \
1144 /* Alignment value for attribute ((aligned)). */ 1168 /* Alignment value for attribute ((aligned)). */
1145 #ifndef ATTRIBUTE_ALIGNED_VALUE 1169 #ifndef ATTRIBUTE_ALIGNED_VALUE
1146 #define ATTRIBUTE_ALIGNED_VALUE BIGGEST_ALIGNMENT 1170 #define ATTRIBUTE_ALIGNED_VALUE BIGGEST_ALIGNMENT
1147 #endif 1171 #endif
1148 1172
1149 /* Many ports have no mode-dependent addresses (except possibly autoincrement
1150 and autodecrement addresses, which are handled by target-independent code
1151 in recog.c). */
1152 #ifndef GO_IF_MODE_DEPENDENT_ADDRESS
1153 #define GO_IF_MODE_DEPENDENT_ADDRESS(X, WIN)
1154 #endif
1155
1156 /* For most ports anything that evaluates to a constant symbolic 1173 /* For most ports anything that evaluates to a constant symbolic
1157 or integer value is acceptable as a constant address. */ 1174 or integer value is acceptable as a constant address. */
1158 #ifndef CONSTANT_ADDRESS_P 1175 #ifndef CONSTANT_ADDRESS_P
1159 #define CONSTANT_ADDRESS_P(X) (CONSTANT_P (X) && GET_CODE (X) != CONST_DOUBLE) 1176 #define CONSTANT_ADDRESS_P(X) (CONSTANT_P (X) && GET_CODE (X) != CONST_DOUBLE)
1160 #endif 1177 #endif
1168 This should only be defined if compatibility with another compiler or 1185 This should only be defined if compatibility with another compiler or
1169 with an ABI is needed, because it results in slower code. */ 1186 with an ABI is needed, because it results in slower code. */
1170 1187
1171 #ifndef DEFAULT_PCC_STRUCT_RETURN 1188 #ifndef DEFAULT_PCC_STRUCT_RETURN
1172 #define DEFAULT_PCC_STRUCT_RETURN 1 1189 #define DEFAULT_PCC_STRUCT_RETURN 1
1190 #endif
1191
1192 #ifndef PCC_BITFIELD_TYPE_MATTERS
1193 #define PCC_BITFIELD_TYPE_MATTERS false
1194 #endif
1195
1196 #ifndef INSN_SETS_ARE_DELAYED
1197 #define INSN_SETS_ARE_DELAYED(INSN) false
1198 #endif
1199
1200 #ifndef INSN_REFERENCES_ARE_DELAYED
1201 #define INSN_REFERENCES_ARE_DELAYED(INSN) false
1202 #endif
1203
1204 #ifndef NO_FUNCTION_CSE
1205 #define NO_FUNCTION_CSE false
1206 #endif
1207
1208 #ifndef HARD_REGNO_RENAME_OK
1209 #define HARD_REGNO_RENAME_OK(FROM, TO) true
1210 #endif
1211
1212 #ifndef EPILOGUE_USES
1213 #define EPILOGUE_USES(REG) false
1214 #endif
1215
1216 #ifndef ARGS_GROW_DOWNWARD
1217 #define ARGS_GROW_DOWNWARD 0
1218 #endif
1219
1220 #ifndef STACK_GROWS_DOWNWARD
1221 #define STACK_GROWS_DOWNWARD 0
1222 #endif
1223
1224 #ifndef STACK_PUSH_CODE
1225 #if STACK_GROWS_DOWNWARD
1226 #define STACK_PUSH_CODE PRE_DEC
1227 #else
1228 #define STACK_PUSH_CODE PRE_INC
1229 #endif
1230 #endif
1231
1232 /* Default value for flag_pie when flag_pie is initialized to -1:
1233 --enable-default-pie: Default flag_pie to -fPIE.
1234 --disable-default-pie: Default flag_pie to 0.
1235 */
1236 #ifdef ENABLE_DEFAULT_PIE
1237 # ifndef DEFAULT_FLAG_PIE
1238 # define DEFAULT_FLAG_PIE 2
1239 # endif
1240 #else
1241 # define DEFAULT_FLAG_PIE 0
1242 #endif
1243
1244 #ifndef SWITCHABLE_TARGET
1245 #define SWITCHABLE_TARGET 0
1246 #endif
1247
1248 /* If the target supports integers that are wider than two
1249 HOST_WIDE_INTs on the host compiler, then the target should define
1250 TARGET_SUPPORTS_WIDE_INT and make the appropriate fixups.
1251 Otherwise the compiler really is not robust. */
1252 #ifndef TARGET_SUPPORTS_WIDE_INT
1253 #define TARGET_SUPPORTS_WIDE_INT 0
1254 #endif
1255
1256 #ifndef SHORT_IMMEDIATES_SIGN_EXTEND
1257 #define SHORT_IMMEDIATES_SIGN_EXTEND 0
1258 #endif
1259
1260 #ifndef WORD_REGISTER_OPERATIONS
1261 #define WORD_REGISTER_OPERATIONS 0
1262 #endif
1263
1264 #ifndef LOAD_EXTEND_OP
1265 #define LOAD_EXTEND_OP(M) UNKNOWN
1266 #endif
1267
1268 #ifndef INITIAL_FRAME_ADDRESS_RTX
1269 #define INITIAL_FRAME_ADDRESS_RTX NULL
1270 #endif
1271
1272 #ifndef SETUP_FRAME_ADDRESSES
1273 #define SETUP_FRAME_ADDRESSES() do { } while (0)
1274 #endif
1275
1276 #ifndef DYNAMIC_CHAIN_ADDRESS
1277 #define DYNAMIC_CHAIN_ADDRESS(x) (x)
1278 #endif
1279
1280 #ifndef FRAME_ADDR_RTX
1281 #define FRAME_ADDR_RTX(x) (x)
1282 #endif
1283
1284 #ifndef REVERSE_CONDITION
1285 #define REVERSE_CONDITION(code, mode) reverse_condition (code)
1286 #endif
1287
1288 #ifndef TARGET_PECOFF
1289 #define TARGET_PECOFF 0
1290 #endif
1291
1292 #ifndef EH_RETURN_HANDLER_RTX
1293 #define EH_RETURN_HANDLER_RTX NULL
1173 #endif 1294 #endif
1174 1295
1175 #ifdef GCC_INSN_FLAGS_H 1296 #ifdef GCC_INSN_FLAGS_H
1176 /* Dependent default target macro definitions 1297 /* Dependent default target macro definitions
1177 1298
1221 1342
1222 /* If a memory set (to value other than zero) operation would take 1343 /* If a memory set (to value other than zero) operation would take
1223 SET_RATIO or more simple move-instruction sequences, we will do a movmem 1344 SET_RATIO or more simple move-instruction sequences, we will do a movmem
1224 or libcall instead. */ 1345 or libcall instead. */
1225 #ifndef SET_RATIO 1346 #ifndef SET_RATIO
1226 #define SET_RATIO(speed) MOVE_RATIO(speed) 1347 #define SET_RATIO(speed) MOVE_RATIO (speed)
1227 #endif
1228
1229 /* Supply a default definition for FUNCTION_ARG_PADDING:
1230 usually pad upward, but pad short args downward on
1231 big-endian machines. */
1232
1233 #define DEFAULT_FUNCTION_ARG_PADDING(MODE, TYPE) \
1234 (! BYTES_BIG_ENDIAN \
1235 ? upward \
1236 : (((MODE) == BLKmode \
1237 ? ((TYPE) && TREE_CODE (TYPE_SIZE (TYPE)) == INTEGER_CST \
1238 && int_size_in_bytes (TYPE) < (PARM_BOUNDARY / BITS_PER_UNIT)) \
1239 : GET_MODE_BITSIZE (MODE) < PARM_BOUNDARY) \
1240 ? downward : upward))
1241
1242 #ifndef FUNCTION_ARG_PADDING
1243 #define FUNCTION_ARG_PADDING(MODE, TYPE) \
1244 DEFAULT_FUNCTION_ARG_PADDING ((MODE), (TYPE))
1245 #endif 1348 #endif
1246 1349
1247 /* Supply a default definition of STACK_SAVEAREA_MODE for emit_stack_save. 1350 /* Supply a default definition of STACK_SAVEAREA_MODE for emit_stack_save.
1248 Normally move_insn, so Pmode stack pointer. */ 1351 Normally move_insn, so Pmode stack pointer. */
1249 1352
1254 /* Supply a default definition of STACK_SIZE_MODE for 1357 /* Supply a default definition of STACK_SIZE_MODE for
1255 allocate_dynamic_stack_space. Normally PLUS/MINUS, so word_mode. */ 1358 allocate_dynamic_stack_space. Normally PLUS/MINUS, so word_mode. */
1256 1359
1257 #ifndef STACK_SIZE_MODE 1360 #ifndef STACK_SIZE_MODE
1258 #define STACK_SIZE_MODE word_mode 1361 #define STACK_SIZE_MODE word_mode
1362 #endif
1363
1364 /* Default value for flag_stack_protect when flag_stack_protect is initialized to -1:
1365 --enable-default-ssp: Default flag_stack_protect to -fstack-protector-strong.
1366 --disable-default-ssp: Default flag_stack_protect to 0.
1367 */
1368 #ifdef ENABLE_DEFAULT_SSP
1369 # ifndef DEFAULT_FLAG_SSP
1370 # define DEFAULT_FLAG_SSP 3
1371 # endif
1372 #else
1373 # define DEFAULT_FLAG_SSP 0
1259 #endif 1374 #endif
1260 1375
1261 /* Provide default values for the macros controlling stack checking. */ 1376 /* Provide default values for the macros controlling stack checking. */
1262 1377
1263 /* The default is neither full builtin stack checking... */ 1378 /* The default is neither full builtin stack checking... */
1286 for the latter because part of the protection area is effectively 1401 for the latter because part of the protection area is effectively
1287 included in STACK_CHECK_MAX_FRAME_SIZE for the former. */ 1402 included in STACK_CHECK_MAX_FRAME_SIZE for the former. */
1288 #ifdef STACK_CHECK_PROTECT 1403 #ifdef STACK_CHECK_PROTECT
1289 #define STACK_OLD_CHECK_PROTECT STACK_CHECK_PROTECT 1404 #define STACK_OLD_CHECK_PROTECT STACK_CHECK_PROTECT
1290 #else 1405 #else
1291 #define STACK_OLD_CHECK_PROTECT \ 1406 #define STACK_OLD_CHECK_PROTECT \
1292 (targetm.except_unwind_info (&global_options) == UI_SJLJ \ 1407 (!global_options.x_flag_exceptions \
1293 ? 75 * UNITS_PER_WORD \ 1408 ? 75 * UNITS_PER_WORD \
1294 : 8 * 1024) 1409 : targetm_common.except_unwind_info (&global_options) == UI_SJLJ \
1410 ? 4 * 1024 \
1411 : 8 * 1024)
1295 #endif 1412 #endif
1296 1413
1297 /* Minimum amount of stack required to recover from an anticipated stack 1414 /* Minimum amount of stack required to recover from an anticipated stack
1298 overflow detection. The default value conveys an estimate of the amount 1415 overflow detection. The default value conveys an estimate of the amount
1299 of stack required to propagate an exception. */ 1416 of stack required to propagate an exception. */
1300 #ifndef STACK_CHECK_PROTECT 1417 #ifndef STACK_CHECK_PROTECT
1301 #define STACK_CHECK_PROTECT \ 1418 #define STACK_CHECK_PROTECT \
1302 (targetm.except_unwind_info (&global_options) == UI_SJLJ \ 1419 (!global_options.x_flag_exceptions \
1303 ? 75 * UNITS_PER_WORD \ 1420 ? 4 * 1024 \
1304 : 12 * 1024) 1421 : targetm_common.except_unwind_info (&global_options) == UI_SJLJ \
1422 ? 8 * 1024 \
1423 : 12 * 1024)
1305 #endif 1424 #endif
1306 1425
1307 /* Make the maximum frame size be the largest we can and still only need 1426 /* Make the maximum frame size be the largest we can and still only need
1308 one probe per function. */ 1427 one probe per function. */
1309 #ifndef STACK_CHECK_MAX_FRAME_SIZE 1428 #ifndef STACK_CHECK_MAX_FRAME_SIZE
1331 pointer to a function. */ 1450 pointer to a function. */
1332 #ifndef TARGET_VTABLE_USES_DESCRIPTORS 1451 #ifndef TARGET_VTABLE_USES_DESCRIPTORS
1333 #define TARGET_VTABLE_USES_DESCRIPTORS 0 1452 #define TARGET_VTABLE_USES_DESCRIPTORS 0
1334 #endif 1453 #endif
1335 1454
1336 #ifndef SWITCHABLE_TARGET
1337 #define SWITCHABLE_TARGET 0
1338 #endif
1339
1340 #endif /* GCC_INSN_FLAGS_H */ 1455 #endif /* GCC_INSN_FLAGS_H */
1341 1456
1457 #ifndef DWARF_GNAT_ENCODINGS_DEFAULT
1458 #define DWARF_GNAT_ENCODINGS_DEFAULT DWARF_GNAT_ENCODINGS_GDB
1459 #endif
1460
1342 #endif /* ! GCC_DEFAULTS_H */ 1461 #endif /* ! GCC_DEFAULTS_H */