⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 xcoff.h

📁 gcc3.2.1源代码
💻 H
📖 第 1 页 / 共 2 页
字号:
       RS6000_OUTPUT_BASENAME (FILE, NAME); putc ('\n', FILE);} while (0)/* Remove any trailing [DS] or the like from the symbol name.  */#define STRIP_NAME_ENCODING(VAR,NAME)			\  do							\    {							\      const char *_name = (NAME);			\      size_t _len;					\      if (*_name == '*')				\        _name++;					\      _len = strlen (_name);				\      if (_name[_len - 1] != ']')			\	(VAR) = _name;					\      else						\	{						\	  char *_new_name = (char *) alloca (_len + 1);	\	  strcpy (_new_name, _name);			\	  _new_name[_len - 4] = '\0';			\	  (VAR) = _new_name;				\	}						\    }							\  while (0)/* Output at beginning of assembler file.   Initialize the section names for the RS/6000 at this point.   Specify filename, including full path, to assembler.   We want to go into the TOC section so at least one .toc will be emitted.   Also, in order to output proper .bs/.es pairs, we need at least one static   [RW] section emitted.   Finally, declare mcount when profiling to make the assembler happy.  */#define ASM_FILE_START(FILE)					\{								\  rs6000_gen_section_name (&xcoff_bss_section_name,		\			   main_input_filename, ".bss_");	\  rs6000_gen_section_name (&xcoff_private_data_section_name,	\			   main_input_filename, ".rw_");	\  rs6000_gen_section_name (&xcoff_read_only_section_name,	\			   main_input_filename, ".ro_");	\								\  fprintf (FILE, "\t.file\t\"%s\"\n", main_input_filename);	\  if (TARGET_64BIT)						\    fputs ("\t.machine\t\"ppc64\"\n", FILE);			\  toc_section ();						\  if (write_symbols != NO_DEBUG)				\    private_data_section ();					\  text_section ();						\  if (profile_flag)						\    fprintf (FILE, "\t.extern %s\n", RS6000_MCOUNT);		\  rs6000_file_start (FILE, TARGET_CPU_DEFAULT);			\}/* Output at end of assembler file.   On the RS/6000, referencing data should automatically pull in text.  */#define ASM_FILE_END(FILE)					\{								\  text_section ();						\  fputs ("_section_.text:\n", FILE);				\  data_section ();						\  fputs (TARGET_32BIT						\	 ? "\t.long _section_.text\n" : "\t.llong _section_.text\n", FILE); \}/* This macro produces the initial definition of a function name.   On the RS/6000, we need to place an extra '.' in the function name and   output the function descriptor.   The csect for the function will have already been created by the   `text_section' call previously done.  We do have to go back to that   csect, however.   We also record that the function exists in the current compilation   unit, reachable by short branch, by setting SYMBOL_REF_FLAG.   The third and fourth parameters to the .function pseudo-op (16 and 044)   are placeholders which no longer have any use.  */#define ASM_DECLARE_FUNCTION_NAME(FILE,NAME,DECL)		\{ rtx sym_ref = XEXP (DECL_RTL (DECL), 0);			\  if (!DECL_WEAK (DECL))					\    SYMBOL_REF_FLAG (sym_ref) = 1;				\  if (TREE_PUBLIC (DECL))					\    {								\      if (!RS6000_WEAK || !DECL_WEAK (decl))			\	{							\	  fputs ("\t.globl .", FILE);				\	  RS6000_OUTPUT_BASENAME (FILE, NAME);			\	  putc ('\n', FILE);					\	}							\    }								\  else								\    {								\      fputs ("\t.lglobl .", FILE);				\      RS6000_OUTPUT_BASENAME (FILE, NAME);			\      putc ('\n', FILE);					\    }								\  fputs ("\t.csect ", FILE);					\  RS6000_OUTPUT_BASENAME (FILE, NAME);				\  fputs (TARGET_32BIT ? "[DS]\n" : "[DS],3\n", FILE);		\  RS6000_OUTPUT_BASENAME (FILE, NAME);				\  fputs (":\n", FILE);						\  fputs (TARGET_32BIT ? "\t.long ." : "\t.llong .", FILE);	\  RS6000_OUTPUT_BASENAME (FILE, NAME);				\  fputs (", TOC[tc0], 0\n", FILE);				\  in_section = no_section;					\  function_section(DECL);					\  putc ('.', FILE);						\  RS6000_OUTPUT_BASENAME (FILE, NAME);				\  fputs (":\n", FILE);						\  if (write_symbols == XCOFF_DEBUG)				\    xcoffout_declare_function (FILE, DECL, NAME);		\}/* Output a reference to SYM on FILE.  */#define ASM_OUTPUT_SYMBOL_REF(FILE, SYM) \  rs6000_output_symbol_ref (FILE, SYM)/* This says how to output an external.  */#undef ASM_OUTPUT_EXTERNAL#define ASM_OUTPUT_EXTERNAL(FILE, DECL, NAME)	\{ rtx _symref = XEXP (DECL_RTL (DECL), 0);	\  if ((TREE_CODE (DECL) == VAR_DECL		\       || TREE_CODE (DECL) == FUNCTION_DECL)	\      && (NAME)[strlen (NAME) - 1] != ']')	\    {						\      char *_name = (char *) permalloc (strlen (XSTR (_symref, 0)) + 5); \      strcpy (_name, XSTR (_symref, 0));	\      strcat (_name, TREE_CODE (DECL) == FUNCTION_DECL ? "[DS]" : "[RW]"); \      XSTR (_symref, 0) = _name;		\    }						\}/* This is how to output an internal numbered label where   PREFIX is the class of label and NUM is the number within the class.  */#define ASM_OUTPUT_INTERNAL_LABEL(FILE,PREFIX,NUM)	\  fprintf (FILE, "%s..%u:\n", (PREFIX), (unsigned) (NUM))/* This is how to output an internal label prefix.  rs6000.c uses this   when generating traceback tables.  */#define ASM_OUTPUT_INTERNAL_LABEL_PREFIX(FILE,PREFIX)   \  fprintf (FILE, "%s..", PREFIX)/* This is how to output a label for a jump table.  Arguments are the same as   for ASM_OUTPUT_INTERNAL_LABEL, except the insn for the jump table is   passed.  */#define ASM_OUTPUT_CASE_LABEL(FILE,PREFIX,NUM,TABLEINSN)	\{ ASM_OUTPUT_ALIGN (FILE, 2); ASM_OUTPUT_INTERNAL_LABEL (FILE, PREFIX, NUM); }/* This is how to store into the string LABEL   the symbol_ref name of an internal numbered label where   PREFIX is the class of label and NUM is the number within the class.   This is suitable for output with `assemble_name'.  */#define ASM_GENERATE_INTERNAL_LABEL(LABEL,PREFIX,NUM)	\  sprintf (LABEL, "*%s..%u", (PREFIX), (unsigned) (NUM))/* This is how to output an assembler line to define N characters starting   at P to FILE.  */#define ASM_OUTPUT_ASCII(FILE, P, N)  output_ascii ((FILE), (P), (N))/* This is how to advance the location counter by SIZE bytes.  */#define ASM_OUTPUT_SKIP(FILE,SIZE)  \  fprintf (FILE, "\t.space %d\n", (SIZE))/* This says how to output an assembler line   to define a global common symbol.  */#define ASM_OUTPUT_ALIGNED_COMMON(FILE, NAME, SIZE, ALIGNMENT)	\  do { fputs ("\t.comm ", (FILE));			\       RS6000_OUTPUT_BASENAME ((FILE), (NAME));		\       if ( (SIZE) > 4)					\         fprintf ((FILE), ",%d,3\n", (SIZE));		\       else						\	 fprintf ((FILE), ",%d\n", (SIZE));		\  } while (0)/* This says how to output an assembler line   to define a local common symbol.   Alignment cannot be specified, but we can try to maintain   alignment after preceding TOC section if it was aligned   for 64-bit mode.  */#define ASM_OUTPUT_LOCAL(FILE, NAME, SIZE, ROUNDED)	\  do { fputs ("\t.lcomm ", (FILE));			\       RS6000_OUTPUT_BASENAME ((FILE), (NAME));		\       fprintf ((FILE), ",%d,%s\n", (TARGET_32BIT ? (SIZE) : (ROUNDED)), \		xcoff_bss_section_name);		\     } while (0)/* This is how we tell the assembler that two symbols have the same value.  */#define SET_ASM_OP "\t.set "/* This is how we tell the assembler to equate two values.  */#define ASM_OUTPUT_DEF(FILE,LABEL1,LABEL2)				\ do {	fprintf ((FILE), "%s", SET_ASM_OP);				\	RS6000_OUTPUT_BASENAME (FILE, LABEL1);				\	fprintf (FILE, ",");						\	RS6000_OUTPUT_BASENAME (FILE, LABEL2);				\	fprintf (FILE, "\n");						\  } while (0)/* Used by rs6000_assemble_integer, among others.  */#define DOUBLE_INT_ASM_OP "\t.llong\t"/* Output before instructions.  */#define TEXT_SECTION_ASM_OP "\t.csect .text[PR]"/* Output before writable data.   Align entire section to BIGGEST_ALIGNMENT.  */#define DATA_SECTION_ASM_OP "\t.csect .data[RW],3"/* Define unique section name -- functions only.  */#define UNIQUE_SECTION(DECL,RELOC)			\  do {							\    int len;						\    const char *name;					\    char *string;					\							\    if (TREE_CODE (DECL) == FUNCTION_DECL) {		\      name = IDENTIFIER_POINTER (DECL_ASSEMBLER_NAME (DECL)); \      len = strlen (name) + 5;				\      string = alloca (len + 1);			\      sprintf (string, ".%s[PR]", name);		\      DECL_SECTION_NAME (DECL) = build_string (len, string); \    }							\  } while (0)/* Switch into a generic section.  */#define TARGET_ASM_NAMED_SECTION  xcoff_asm_named_section/* Define the name of the section to use for the EH language specific   data areas (.gcc_except_table on most other systems).  */#define TARGET_ASM_EXCEPTION_SECTION data_section/* Define to prevent DWARF2 unwind info in the data section rather   than in the .eh_frame section.  We do this because the AIX linker   would otherwise garbage collect these sections.  */#define EH_FRAME_IN_DATA_SECTION 1

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -