osfrose.h
来自「gcc3.2.1源代码」· C头文件 代码 · 共 721 行 · 第 1/2 页
H
721 行
/* A C statement to output to the stdio stream STREAM an assembler command to advance the location counter to a multiple of 2 to the POWER bytes. POWER will be a C expression of type `int'. */#undef ASM_OUTPUT_ALIGN#define ASM_OUTPUT_ALIGN(STREAM, POWER) \ fprintf (STREAM, "\t.align\t%d\n", \ (!TARGET_LARGE_ALIGN && (POWER) > 2) ? 2 : (POWER))/* A C expression that is 1 if the RTX X is a constant which is a valid address. On most machines, this can be defined as `CONSTANT_P (X)', but a few machines are more restrictive in which constant addresses are supported. `CONSTANT_P' accepts integer-values expressions whose values are not explicitly known, such as `symbol_ref', `label_ref', and `high' expressions and `const' arithmetic expressions, in addition to `const_int' and `const_double' expressions. */#define CONSTANT_ADDRESS_P_ORIG(X) \ (GET_CODE (X) == LABEL_REF || GET_CODE (X) == SYMBOL_REF \ || GET_CODE (X) == CONST_INT || GET_CODE (X) == CONST \ || GET_CODE (X) == HIGH)#undef CONSTANT_ADDRESS_P#define CONSTANT_ADDRESS_P(X) \ ((CONSTANT_ADDRESS_P_ORIG (X)) && (!HALF_PIC_P () || !HALF_PIC_ADDRESS_P (X)))/* Nonzero if the constant value X is a legitimate general operand. It is given that X satisfies CONSTANT_P or is a CONST_DOUBLE. */#undef LEGITIMATE_CONSTANT_P#define LEGITIMATE_CONSTANT_P(X) \ (!HALF_PIC_P () \ || GET_CODE (X) == CONST_DOUBLE \ || GET_CODE (X) == CONST_INT \ || !HALF_PIC_ADDRESS_P (X))/* Sometimes certain combinations of command options do not make sense on a particular target machine. You can define a macro `OVERRIDE_OPTIONS' to take account of this. This macro, if defined, is executed once just after all the command options have been parsed. */#undef SUBTARGET_OVERRIDE_OPTIONS#define SUBTARGET_OVERRIDE_OPTIONS \{ \ /* \ if (TARGET_ELF && TARGET_HALF_PIC) \ { \ target_flags &= ~MASK_HALF_PIC; \ flag_pic = 1; \ } \ */ \ \ if (TARGET_ROSE && flag_pic) \ { \ target_flags |= MASK_HALF_PIC; \ flag_pic = 0; \ } \ \ if (TARGET_HALF_PIC) \ half_pic_init (); \}/* Define this macro if references to a symbol must be treated differently depending on something about the variable or function named by the symbol (such as what section it is in). The macro definition, if any, is executed immediately after the rtl for DECL has been created and stored in `DECL_RTL (DECL)'. The value of the rtl will be a `mem' whose address is a `symbol_ref'. The usual thing for this macro to do is to a flag in the `symbol_ref' (such as `SYMBOL_REF_FLAG') or to store a modified name string in the `symbol_ref' (if one bit is not enough information). The best way to modify the name string is by adding text to the beginning, with suitable punctuation to prevent any ambiguity. Allocate the new name in `saveable_obstack'. You will have to modify `ASM_OUTPUT_LABELREF' to remove and decode the added text and output the name accordingly. You can also check the information stored in the `symbol_ref' in the definition of `GO_IF_LEGITIMATE_ADDRESS' or `PRINT_OPERAND_ADDRESS'. */#undef ENCODE_SECTION_INFO#define ENCODE_SECTION_INFO(DECL) \do \ { \ if (HALF_PIC_P ()) \ HALF_PIC_ENCODE (DECL); \ \ else if (flag_pic) \ { \ rtx rtl = (TREE_CODE_CLASS (TREE_CODE (DECL)) != 'd' \ ? TREE_CST_RTL (DECL) : DECL_RTL (DECL)); \ SYMBOL_REF_FLAG (XEXP (rtl, 0)) \ = (TREE_CODE_CLASS (TREE_CODE (DECL)) != 'd' \ || ! TREE_PUBLIC (DECL)); \ } \ } \while (0)/* On most machines, read-only variables, constants, and jump tables are placed in the text section. If this is not the case on your machine, this macro should be defined to be the name of a function (either `data_section' or a function defined in `EXTRA_SECTIONS') that switches to the section to be used for read-only items. If these items should be placed in the text section, this macro should not be defined. */#if 0#undef READONLY_DATA_SECTION#define READONLY_DATA_SECTION() \do \ { \ if (TARGET_ELF) \ { \ if (in_section != in_rodata) \ { \ fprintf (asm_out_file, "\t.section \"rodata\"\n"); \ in_section = in_rodata; \ } \ } \ else \ text_section (); \ } \while (0)#endif/* A list of names for sections other than the standard two, which are `in_text' and `in_data'. You need not define this macro on a system with no other sections (that GCC needs to use). */#undef EXTRA_SECTIONS#define EXTRA_SECTIONS in_rodata, in_data1/* Given a decl node or constant node, choose the section to output it in and select that section. */#undef SELECT_RTX_SECTION#define SELECT_RTX_SECTION(MODE, RTX, ALIGN) \do \ { \ if (MODE == Pmode && HALF_PIC_P () && HALF_PIC_ADDRESS_P (RTX)) \ data_section (); \ else \ readonly_data_section (); \ } \while (0)#undef SELECT_SECTION#define SELECT_SECTION(DECL, RELOC, ALIGN) \{ \ if (RELOC && HALF_PIC_P ()) \ data_section (); \ \ else if (TREE_CODE (DECL) == STRING_CST) \ { \ if (flag_writable_strings) \ data_section (); \ else \ readonly_data_section (); \ } \ \ else if (TREE_CODE (DECL) != VAR_DECL) \ readonly_data_section (); \ \ else if (!TREE_READONLY (DECL) || TREE_SIDE_EFFECTS (DECL) \ || !DECL_INITIAL (DECL) \ || (DECL_INITIAL (DECL) != error_mark_node \ && !TREE_CONSTANT (DECL_INITIAL (DECL)))) \ data_section (); \ \ else \ readonly_data_section (); \}/* Define the strings used for the special svr4 .type and .size directives. These strings generally do not vary from one system running svr4 to another, but if a given system (e.g. m88k running svr) needs to use different pseudo-op names for these, they may be overridden in the file which includes this one. */#define TYPE_ASM_OP "\t.type\t"#define SIZE_ASM_OP "\t.size\t"#define SET_ASM_OP "\t.set\t"/* This is how we tell the assembler that a symbol is weak. */#define ASM_WEAKEN_LABEL(FILE,NAME) \ do { fputs ("\t.weak\t", FILE); assemble_name (FILE, NAME); \ fputc ('\n', FILE); } while (0)/* The following macro defines the format used to output the second operand of the .type assembler directive. Different svr4 assemblers expect various different forms for this operand. The one given here is just a default. You may need to override it in your machine- specific tm.h file (depending upon the particulars of your assembler). */#define TYPE_OPERAND_FMT "@%s"/* A C statement (sans semicolon) to output to the stdio stream STREAM any text necessary for declaring the name NAME of an initialized variable which is being defined. This macro must output the label definition (perhaps using `ASM_OUTPUT_LABEL'). The argument DECL is the `VAR_DECL' tree node representing the variable. If this macro is not defined, then the variable name is defined in the usual manner as a label (by means of `ASM_OUTPUT_LABEL'). */#undef ASM_DECLARE_OBJECT_NAME#define ASM_DECLARE_OBJECT_NAME(STREAM, NAME, DECL) \do \ { \ ASM_OUTPUT_LABEL(STREAM,NAME); \ HALF_PIC_DECLARE (NAME); \ if (TARGET_ELF) \ { \ fprintf (STREAM, "%s", TYPE_ASM_OP); \ assemble_name (STREAM, NAME); \ putc (',', STREAM); \ fprintf (STREAM, TYPE_OPERAND_FMT, "object"); \ putc ('\n', STREAM); \ size_directive_output = 0; \ if (!flag_inhibit_size_directive && DECL_SIZE (DECL)) \ { \ size_directive_output = 1; \ fprintf (STREAM, "%s", SIZE_ASM_OP); \ assemble_name (STREAM, NAME); \ fprintf (STREAM, ",%d\n", int_size_in_bytes (TREE_TYPE (DECL))); \ } \ } \ } \while (0)/* Output the size directive for a decl in rest_of_decl_compilation in the case where we did not do so before the initializer. Once we find the error_mark_node, we know that the value of size_directive_output was set by ASM_DECLARE_OBJECT_NAME when it was run for the same decl. */#define ASM_FINISH_DECLARE_OBJECT(FILE, DECL, TOP_LEVEL, AT_END) \do { \ const char *name = XSTR (XEXP (DECL_RTL (DECL), 0), 0); \ if (TARGET_ELF \ && !flag_inhibit_size_directive && DECL_SIZE (DECL) \ && ! AT_END && TOP_LEVEL \ && DECL_INITIAL (DECL) == error_mark_node \ && !size_directive_output) \ { \ fprintf (FILE, "%s", SIZE_ASM_OP); \ assemble_name (FILE, name); \ fprintf (FILE, ",%d\n", int_size_in_bytes (TREE_TYPE (DECL))); \ } \ } while (0)/* This is how to declare a function name. */#undef ASM_DECLARE_FUNCTION_NAME#define ASM_DECLARE_FUNCTION_NAME(STREAM,NAME,DECL) \do \ { \ ASM_OUTPUT_LABEL(STREAM,NAME); \ HALF_PIC_DECLARE (NAME); \ if (TARGET_ELF) \ { \ fprintf (STREAM, "%s", TYPE_ASM_OP); \ assemble_name (STREAM, NAME); \ putc (',', STREAM); \ fprintf (STREAM, TYPE_OPERAND_FMT, "function"); \ putc ('\n', STREAM); \ ASM_DECLARE_RESULT (STREAM, DECL_RESULT (DECL)); \ } \ } \while (0)/* Write the extra assembler code needed to declare a function's result. Most svr4 assemblers don't require any special declaration of the result value, but there are exceptions. */#ifndef ASM_DECLARE_RESULT#define ASM_DECLARE_RESULT(FILE, RESULT)#endif/* This is how to declare the size of a function. */#define ASM_DECLARE_FUNCTION_SIZE(FILE, FNAME, DECL) \do \ { \ if (TARGET_ELF && !flag_inhibit_size_directive) \ { \ char label[256]; \ static int labelno; \ labelno++; \ ASM_GENERATE_INTERNAL_LABEL (label, "Lfe", labelno); \ ASM_OUTPUT_INTERNAL_LABEL (FILE, "Lfe", labelno); \ fprintf (FILE, "%s", SIZE_ASM_OP); \ assemble_name (FILE, (FNAME)); \ fprintf (FILE, ","); \ assemble_name (FILE, label); \ fprintf (FILE, "-"); \ assemble_name (FILE, (FNAME)); \ putc ('\n', FILE); \ } \ } \while (0)#define IDENT_ASM_OP "\t.ident\t"/* Allow #sccs in preprocessor. */#define SCCS_DIRECTIVE/* This says what to print at the end of the assembly file */#undef ASM_FILE_END#define ASM_FILE_END(STREAM) \do \ { \ if (HALF_PIC_P ()) \ HALF_PIC_FINISH (STREAM); \ ix86_asm_file_end (STREAM); \ } \while (0)/* Tell collect that the object format is OSF/rose. */#define OBJECT_FORMAT_ROSE/* Tell collect where the appropriate binaries are. */#define REAL_NM_FILE_NAME "/usr/ccs/gcc/bfd-nm"#define REAL_STRIP_FILE_NAME "/usr/ccs/bin/strip"/* Define this macro meaning that gcc should find the library 'libgcc.a' by hand, rather than passing the argument '-lgcc' to tell the linker to do the search */#define LINK_LIBGCC_SPECIAL/* Generate calls to memcpy, etc., not bcopy, etc. */#define TARGET_MEM_FUNCTIONS/* Don't default to pcc-struct-return, because gcc is the only compiler, and we want to retain compatibility with older gcc versions. */#define DEFAULT_PCC_STRUCT_RETURN 0/* Map i386 registers to the numbers dwarf expects. Of course this is different from what stabs expects. */#undef DBX_REGISTER_NUMBER#define DBX_REGISTER_NUMBER(n) ((write_symbols == DWARF_DEBUG) \ ? svr4_dbx_register_map[n] \ : dbx_register_map[n])
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?