#include <stdint.h>#include "elf_stuff.h"#include "defs.h"#include "config_targ_opt.h"#include "targ_const.h"#include "targ_const_private.h"#include "vstring.h"#include "config_asm.h"#include "em_elf.h"#include "symtab.h"#include "tn.h"#include "cgemit.h"#include "cgemit_targ.h"#include "cgtarget.h"#include "data_layout.h"#include "bb.h"#include "op.h"#include "iface_scn.h"#include "cg_flags.h"#include "glob.h"#include "sections.h"#include "targ_isa_print.h"#include "config_debug.h"

Go to the source code of this file.
| #define EH_DESC_LINKONCE_PREFIX ".gnu.linkonce.h." |
| #define EH_REGION_LINKONCE_PREFIX ".gnu.linkonce.e." |
| #define NAME_LEN 8192 |
| #define USE_STANDARD_TYPES 1 |
Definition at line 71 of file cgemit_targ.cxx.
| enum OPND_REG |
Definition at line 1504 of file cgemit_targ.cxx.
Definition at line 1578 of file cgemit_targ.cxx.
References function, Gen_PIC_Shared, Get_OP_stack_reg(), Get_Opnd_Reg(), int_reg_names, Is_Target_32bit, n, nl, NULL, OP_code, OP_find_opnd_use, OP_opnd, rc, REGISTER_CLASS_last_register, REGISTER_MIN, REGISTER_name, sprintf(), ST_is_export_local(), Str_Prepend(), strcat(), strcmp(), strcpy, strstr(), TN_is_label, TN_relocs, TN_var, and TOP.
Referenced by CGEMIT_Print_Inst().
Definition at line 469 of file cgemit_targ.cxx.
References ANNOT_CALLINFO, ANNOT_callinfo, ANNOT_Get(), BB_annotations, CALLINFO_call_st, CALLINFO_call_wn, Em_Add_New_Event(), Em_Add_New_Rela(), EMIT_interface_section, EMT_Put_Elf_Symbol(), Interface_Scn_Add_Call(), NULL, R_IA_64_PCREL21B, and ST_is_export_local().
Referenced by r_assemble_op().
Definition at line 599 of file cgemit_targ.cxx.
References Asm_File, CLASS_VAR, Emit_Global_Data, fprintf(), Get_Current_PU_ST, GLOBAL_SYMTAB, Label_Name_Separator, SCLASS_PSTATIC, ST_class, ST_index, ST_is_export_local(), ST_level, ST_name, ST_pu(), and ST_sclass.
Referenced by CGEMIT_Weak_Alias(), and EMT_End_File().
| BOOL CGEMIT_Align_Section_Once | ( | const char * | scn_name | ) |
Definition at line 321 of file cgemit_targ.cxx.
References AS_ALIGN, AS_ORIGIN, Asm_File, CG_emit_non_gas_syntax, EH_DESC_LINKONCE_PREFIX, EH_REGION_LINKONCE_PREFIX, fprintf(), ST_name, strcmp(), strlen(), and strncmp().
Definition at line 502 of file cgemit_targ.cxx.
References AS_FRAME, Asm_File, Current_PU_Stack_Model, FP_TN, fprintf(), rc, REGISTER_machine_id, SMODEL_SMALL, SP_TN, TN_register, and TN_register_class.
Referenced by EMT_Emit_PU().
Definition at line 1687 of file cgemit_targ.cxx.
References Adjust_Opnd_Name(), comp, FmtAssert, fprintf(), i, Init_OP_Name(), INT, Is_True, NAME_LEN, NULL, OP_code, op_name, OP_Name, p, Segment_Prefix(), sprintf(), strcpy, strlen(), TOP, and TRUE.
Referenced by r_assemble_list().
Definition at line 140 of file cgemit_targ.cxx.
References AS_FILE, Asm_File, CG_emit_non_gas_syntax, fprintf(), and USRCPOS_filenum.
Referenced by Cg_Dwarf_Add_Line_Entry().
Definition at line 157 of file cgemit_targ.cxx.
References Asm_File, CG_emit_asm_dwarf, CG_emit_non_gas_syntax, fprintf(), USRCPOS_column, USRCPOS_filenum, and USRCPOS_linenum.
Referenced by Cg_Dwarf_Add_Line_Entry().
| void CGEMIT_Prn_Scn_In_Asm | ( | FILE * | asm_file, | |
| const char * | scn_name, | |||
| Elf64_Word | scn_type, | |||
| Elf64_Word | scn_flags, | |||
| Elf64_Xword | scn_entsize, | |||
| Elf64_Word | scn_align, | |||
| const char * | cur_scn_name | |||
| ) |
Definition at line 205 of file cgemit_targ.cxx.
References AS_ALIGN, AS_SECTION, BOOL, BSS_RAW_NAME, CG_emit_non_gas_syntax, CGEMIT_Align_Section_Once(), CGEMIT_Prn_Scn_In_Asm(), DEBUG_FRAME_SECTNAME, EH_FRAME_SECTNAME, FALSE, fprintf(), Non_Default_Text_Section(), NULL, p, printed, SHF_ALLOC, SHF_EXECINSTR, SHF_TLS, SHF_WRITE, SHT_NOBITS, SHT_PROGBITS, ST_base, ST_name, strcmp(), strncmp(), tmp1, tmp2, and TRUE.
Definition at line 182 of file cgemit_targ.cxx.
References Asm_File, CGEMIT_Prn_Scn_In_Asm(), Get_Section_Elf_Entsize(), Get_Section_Elf_Flags(), Get_Section_Elf_Type(), NULL, ST_name, STB_align, STB_section_idx, strstr(), tmp, and UINT32.
Definition at line 376 of file cgemit_targ.cxx.
References asprintf(), CLASS_BLOCK, FALSE, FmtAssert, free(), GP_DISP, INT, Is_Target_32bit, Is_Target_Core, Is_Target_EM64T, Is_Target_Wolfdale, NULL, ST_class, ST_name, STB_section, str, Symbol_Name_Suffix, TN_RELOC_GOT_DISP, TN_RELOC_GOT_OFST, TN_RELOC_GOT_PAGE, TN_RELOC_GPREL16, TN_RELOC_HI_GPSUB, TN_RELOC_HIGH16, TN_RELOC_LO_GPSUB, TN_RELOC_LOW16, TN_relocs, and vstr_concat().
Referenced by r_apply_l_const().
Definition at line 462 of file cgemit_targ.cxx.
References FALSE, and FmtAssert.
Referenced by r_assemble_binary().
Definition at line 1785 of file cgemit_targ.cxx.
References BOOL, Cur_PU_Name, DEBUG_Trap_Uv, FALSE, FmtAssert, fprintf(), IEEE_ACCURATE, IEEE_Arithmetic, Is_Target_64bit, strcmp(), and Target_x87_precision.
Referenced by EMT_Assemble_BB(), EMT_Emit_PU(), and r_assemble_op().
Definition at line 1889 of file cgemit_targ.cxx.
References Asm_File, fprintf(), and ip_calc_funcname.
Referenced by EETARG_Emit_IP_Calc_Func().
Definition at line 111 of file cgemit_targ.cxx.
Definition at line 126 of file cgemit_targ.cxx.
References Asm_File, fprintf(), and Non_Default_Text_Section().
Definition at line 118 of file cgemit_targ.cxx.
References Asm_File, fprintf(), Non_Default_Text_Section(), ST_base, and ST_name.
Definition at line 357 of file cgemit_targ.cxx.
References FALSE, SCLASS_TEXT, ST_is_export_local(), ST_sclass, and TN_RELOC_IA_LTOFF_FPTR.
Referenced by r_apply_l_const(), and r_assemble_binary().
Definition at line 531 of file cgemit_targ.cxx.
References AS_WEAK, Asm_File, CGEMIT_Alias(), fprintf(), and ST_name.
Referenced by EMT_End_File().
Definition at line 555 of file cgemit_targ.cxx.
References Asm_File, EMT_Write_Qualified_Name(), fprintf(), LABEL_name, bfd_link_order::p, p, bfd_link_order::u, and UINT64.
| void CGEMIT_Write_Literal_Symbol | ( | ST * | lit_st, | |
| ST * | sym, | |||
| Elf64_Sxword | sym_ofst | |||
| ) |
Definition at line 568 of file cgemit_targ.cxx.
References Asm_File, Base_Symbol_And_Offset(), CLASS_CONST, CLASS_FUNC, EMT_Write_Qualified_Name(), fprintf(), Has_Base_Block, INT64, ST_class, and ST_is_export_local().
| static enum OPND_REG Get_Opnd_Reg | ( | TOP | topcode, | |
| int | opnd | |||
| ) | [static] |
Definition at line 1506 of file cgemit_targ.cxx.
References BYTE_REG, DWORD_REG, FmtAssert, Is_Target_32bit, Pointer_Size, QWORD_REG, SSE2_REG, and WORD_REG.
Referenced by Adjust_Opnd_Name().
| static void Init_OP_Name | ( | ) | [static] |
Definition at line 627 of file cgemit_targ.cxx.
References BOOL, bzero(), FALSE, Is_Target_Barcelona, Is_Target_Core, Is_Target_EM64T, Is_Target_Pentium4, Is_Target_SSE3, Is_Target_Wolfdale, OP_Name, and TRUE.
Referenced by CGEMIT_Print_Inst().
Definition at line 100 of file cgemit_targ.cxx.
References FALSE, SCLASS_TEXT, ST_base, ST_name, ST_sclass, and strcmp().
| static const char* Segment_Prefix | ( | OP * | op | ) | [static] |
Definition at line 1679 of file cgemit_targ.cxx.
References CGTARG_Is_Thread_Local_Memory_OP(), and Is_Target_32bit.
Referenced by CGEMIT_Print_Inst().
| void STACK_FP_Fixup_PU | ( | ) |
| static void Str_Prepend | ( | char * | str, | |
| char | c | |||
| ) | [static] |
ST* current_pu = NULL [static] |
Definition at line 97 of file cgemit_targ.cxx.
const char* int_reg_names[4][16] [static] |
Initial value:
{
{ "%al", "%bl", "%bpl", "%spl", "%dil", "%sil", "%dl", "%cl",
"%r8b", "%r9b", "%r10b", "%r11b", "%r12b", "%r13b", "%r14b", "%r15b" },
{ "%ax", "%bx", "%bp", "%sp", "%di", "%si", "%dx", "%cx",
"%r8w", "%r9w", "%r10w", "%r11w", "%r12w", "%r13w", "%r14w", "%r15w" },
{ "%eax", "%ebx", "%ebp", "%esp", "%edi", "%esi", "%edx", "%ecx",
"%r8d", "%r9d", "%r10d", "%r11d", "%r12d", "%r13d", "%r14d", "%r15d" },
{ "%rax", "%rbx", "%rbp", "%rsp", "%rdi", "%rsi", "%rdx", "%rcx",
"%r8", "%r9", "%r10", "%r11", "%r12", "%r13", "%r14", "%r15" },
}
Definition at line 1563 of file cgemit_targ.cxx.
| const char* ip_calc_funcname |
Definition at line 79 of file entry_exit_targ.cxx.
Referenced by CGEMIT_Setup_IP_Calc(), and EETARG_Generate_PIC_Entry_Code().
const char* OP_Name[TOP_count] [static] |
Definition at line 625 of file cgemit_targ.cxx.
Referenced by CGEMIT_Print_Inst(), and Init_OP_Name().
1.5.6