Back to index

cell-binutils  2.17cvs20070401
Classes | Defines | Typedefs | Enumerations | Functions | Variables
tc-ia64.h File Reference
#include "opcode/ia64.h"
#include "elf/ia64.h"

Go to the source code of this file.

Classes

struct  ia64_segment_info_type
struct  ia64_fix
struct  unw_r_record
struct  unw_p_record
struct  unw_b_record
struct  unw_x_record
struct  unwind_record
struct  unw_r_record.mask
union  unw_p_record.off
union  unw_p_record.r
union  unw_x_record.where
union  unwind_record.record

Defines

#define TC_IA64
#define TARGET_BYTES_BIG_ENDIAN   0
#define MD_FLAGS_DEFAULT   EF_IA_64_ABI64
#define md_number_to_chars   (*ia64_number_to_chars)
#define md_elf_section_change_hook   ia64_elf_section_change_hook
#define TC_SEGMENT_INFO_TYPE   struct ia64_segment_info_type
#define tc_adjust_symtab()   ia64_adjust_symtab ()
#define tc_frob_file()   ia64_frob_file ()
#define HOST_SPECIAL_INIT   ia64_init
#define TARGET_FORMAT   ia64_target_format()
#define TARGET_ARCH   bfd_arch_ia64
#define DOUBLESLASH_LINE_COMMENTS   /* allow //-style comments */
#define NEED_LITERAL_POOL   /* need gp literal pool */
#define RELOC_REQUIRES_SYMBOL
#define DIFF_EXPR_OK   /* foo-. gets turned into PC relative relocs */
#define NEED_INDEX_OPERATOR   /* [ ] is index operator */
#define QUOTES_IN_INSN   /* allow `string "foo;bar"' */
#define LEX_AT   (LEX_NAME|LEX_BEGIN_NAME) /* allow `@' inside name */
#define LEX_QM   (LEX_NAME|LEX_BEGIN_NAME) /* allow `?' inside name */
#define LEX_HASH   LEX_END_NAME /* allow `#' ending a name */
#define tc_symbol_chars   ia64_symbol_chars
#define SUB_SEGMENT_ALIGN(SEG, FRCHAIN)   0
#define md_end()   ia64_end_of_source ()
#define md_start_line_hook()   ia64_start_line ()
#define tc_unrecognized_line(ch)   ia64_unrecognized_line (ch)
#define tc_frob_label(s)   ia64_frob_label (s)
#define md_flush_pending_output()   ia64_flush_pending_output ()
#define md_parse_name(s, e, m, c)   ia64_parse_name (s, e, c)
#define tc_canonicalize_symbol_name(s)   ia64_canonicalize_symbol_name (s)
#define tc_canonicalize_section_name(s)   ia64_canonicalize_symbol_name (s)
#define md_optimize_expr(l, o, r)   ia64_optimize_expr (l, o, r)
#define md_cons_align(n)   ia64_cons_align (n)
#define TC_FORCE_RELOCATION(f)   ia64_force_relocation (f)
#define tc_fix_adjustable(f)   ia64_fix_adjustable (f)
#define MD_APPLY_SYM_VALUE(FIX)   0
#define md_convert_frag(b, s, f)   ia64_convert_frag (f)
#define md_create_long_jump(p, f, t, fr, s)   as_fatal ("ia64_create_long_jump")
#define md_create_short_jump(p, f, t, fr, s)   as_fatal ("ia64_create_short_jump")
#define md_estimate_size_before_relax(f, s)   ia64_estimate_size_before_relax(f,s)
#define md_elf_section_letter   ia64_elf_section_letter
#define md_elf_section_flags   ia64_elf_section_flags
#define TC_FIX_TYPE   struct ia64_fix
#define TC_INIT_FIX_DATA(f)   { f->tc_fix_data.opnd = 0; }
#define TC_CONS_FIX_NEW(f, o, l, e)   ia64_cons_fix_new (f, o, l, e)
#define TC_VALIDATE_FIX(fix, seg, skip)   ia64_validate_fix (fix)
#define MD_PCREL_FROM_SECTION(fix, sec)   ia64_pcrel_from_section (fix, sec)
#define md_section_align(seg, size)   (size)
#define md_do_align(n, f, l, m, j)   ia64_md_do_align (n,f,l,m)
#define HANDLE_ALIGN(f)   ia64_handle_align (f)
#define md_elf_section_type(str, len)   ia64_elf_section_type (str, len)
#define md_after_parse_args()   ia64_after_parse_args ()
#define TC_DWARF2_EMIT_OFFSET   ia64_dwarf2_emit_offset
#define tc_check_label(l)   ia64_check_label (l)
#define TC_FRAG_TYPE   int
#define TC_FRAG_INIT(FRAGP)   do {(FRAGP)->tc_frag_data = 0;}while (0)
#define md_frag_check(FRAGP)
#define MAX_MEM_FOR_RS_ALIGN_CODE   (15 + 16)
#define WORKING_DOT_WORD   /* don't do broken word processing for now */
#define DWARF2_LINE_MIN_INSN_LENGTH   1 /* so slot-multipliers can be 1 */
#define UNW_R1   0x00
#define UNW_R2   0x40
#define UNW_R3   0x60
#define UNW_P1   0x80
#define UNW_P2   0xA0
#define UNW_P3   0xB0
#define UNW_P4   0xB8
#define UNW_P5   0xB9
#define UNW_P6   0xC0
#define UNW_P7   0xE0
#define UNW_P8   0xF0
#define UNW_P9   0xF1
#define UNW_P10   0xFF
#define UNW_X1   0xF9
#define UNW_X2   0xFA
#define UNW_X3   0xFB
#define UNW_X4   0xFC
#define UNW_B1   0x80
#define UNW_B2   0xC0
#define UNW_B3   0xE0
#define UNW_B4   0xF0
#define TC_FORCE_RELOCATION_LOCAL(FIX)

Typedefs

typedef struct unw_r_record unw_r_record
typedef struct unw_p_record unw_p_record
typedef struct unw_b_record unw_b_record
typedef struct unw_x_record unw_x_record
typedef struct unwind_record unwind_record

Enumerations

enum  unw_record_type {
  prologue, prologue_gr, body, mem_stack_f,
  mem_stack_v, psp_gr, psp_sprel, rp_when,
  rp_gr, rp_br, rp_psprel, rp_sprel,
  pfs_when, pfs_gr, pfs_psprel, pfs_sprel,
  preds_when, preds_gr, preds_psprel, preds_sprel,
  fr_mem, frgr_mem, gr_gr, gr_mem,
  br_mem, br_gr, spill_base, spill_mask,
  unat_when, unat_gr, unat_psprel, unat_sprel,
  lc_when, lc_gr, lc_psprel, lc_sprel,
  fpsr_when, fpsr_gr, fpsr_psprel, fpsr_sprel,
  priunat_when_gr, priunat_when_mem, priunat_gr, priunat_psprel,
  priunat_sprel, bsp_when, bsp_gr, bsp_psprel,
  bsp_sprel, bspstore_when, bspstore_gr, bspstore_psprel,
  bspstore_sprel, rnat_when, rnat_gr, rnat_psprel,
  rnat_sprel, epilogue, label_state, copy_state,
  spill_psprel, spill_sprel, spill_reg, spill_psprel_p,
  spill_sprel_p, spill_reg_p, unwabi, endp
}

Functions

void ia64_number_to_chars PARAMS ((char *, valueT, int))
void ia64_elf_section_change_hook PARAMS ((void))
void ia64_init PARAMS ((int, char **))
int ia64_unrecognized_line PARAMS ((int ch))
void ia64_frob_label PARAMS ((struct symbol *sym))
int ia64_parse_name PARAMS ((char *name, expressionS *e, char *nextP))
int ia64_optimize_expr PARAMS ((expressionS *l, operatorT op, expressionS *r))
void ia64_cons_align PARAMS ((int))
int ia64_fix_adjustable PARAMS ((struct fix *fix))
int ia64_force_relocation PARAMS ((struct fix *))
void ia64_cons_fix_new PARAMS ((fragS *f, int where, int nbytes, expressionS *exp))
char *ia64_canonicalize_symbol_name PARAMS ((char *))
flagword ia64_elf_section_flags PARAMS ((flagword, int, int))
int ia64_elf_section_type PARAMS ((const char *, size_t len))
long ia64_pcrel_from_section PARAMS ((struct fix *fix, segT sec))
void ia64_md_do_align PARAMS ((int, const char *, int, int))
void ia64_handle_align PARAMS ((fragS *f))
void ia64_dwarf2_emit_offset PARAMS ((symbolS *, unsigned int))
void ia64_check_label PARAMS ((symbolS *))
int ia64_estimate_size_before_relax (fragS *, asection *)
void ia64_convert_frag (fragS *)

Variables

const char ia64_symbol_chars []

Class Documentation

struct ia64_segment_info_type

Definition at line 45 of file tc-ia64.h.

Class Members
unsigned int endian: 2
struct ia64_fix

Definition at line 87 of file tc-ia64.h.

Class Members
int bigendian
struct unw_r_record

Definition at line 233 of file tc-ia64.h.

Class Members
unsigned short grmask
unsigned short grsave
unsigned long imask_size
struct unw_r_record mask
unsigned long rlen
struct unw_p_record

Definition at line 250 of file tc-ia64.h.

Collaboration diagram for unw_p_record:
Class Members
unsigned char abi
unsigned char brmask
unsigned char context
unsigned int frmask
unsigned char grmask
struct unw_rec_list * next
union unw_p_record off
union unw_p_record r
unsigned long size
unsigned long t
struct unw_b_record

Definition at line 272 of file tc-ia64.h.

Class Members
unsigned short ecount
unsigned long label
unsigned long t
struct unw_x_record

Definition at line 279 of file tc-ia64.h.

Class Members
unsigned short ab
unsigned short qp
unsigned short reg
unsigned long t
union unw_x_record where
unsigned short xy
struct unwind_record

Definition at line 296 of file tc-ia64.h.

Class Members
union unwind_record record
unw_record_type type
struct unw_r_record.mask

Definition at line 241 of file tc-ia64.h.

Class Members
unsigned char br_mem
unsigned int fr_mem
unsigned char gr_mem
unsigned char * i
union unw_p_record.off

Definition at line 255 of file tc-ia64.h.

Class Members
unsigned long psp
unsigned long sp
union unw_p_record.r

Definition at line 260 of file tc-ia64.h.

Class Members
unsigned short br
unsigned short gr
union unw_x_record.where

Definition at line 282 of file tc-ia64.h.

Class Members
unsigned long pspoff
unsigned int reg
unsigned long spoff
union unwind_record.record

Definition at line 299 of file tc-ia64.h.

Class Members
unw_b_record b
unw_p_record p
unw_r_record r
unw_x_record x

Define Documentation

#define DIFF_EXPR_OK   /* foo-. gets turned into PC relative relocs */

Definition at line 74 of file tc-ia64.h.

#define DOUBLESLASH_LINE_COMMENTS   /* allow //-style comments */

Definition at line 70 of file tc-ia64.h.

#define DWARF2_LINE_MIN_INSN_LENGTH   1 /* so slot-multipliers can be 1 */

Definition at line 177 of file tc-ia64.h.

#define HANDLE_ALIGN (   f)    ia64_handle_align (f)

Definition at line 155 of file tc-ia64.h.

Definition at line 63 of file tc-ia64.h.

#define LEX_AT   (LEX_NAME|LEX_BEGIN_NAME) /* allow `@' inside name */

Definition at line 78 of file tc-ia64.h.

#define LEX_HASH   LEX_END_NAME /* allow `#' ending a name */

Definition at line 80 of file tc-ia64.h.

#define LEX_QM   (LEX_NAME|LEX_BEGIN_NAME) /* allow `?' inside name */

Definition at line 79 of file tc-ia64.h.

#define MAX_MEM_FOR_RS_ALIGN_CODE   (15 + 16)

Definition at line 173 of file tc-ia64.h.

Definition at line 157 of file tc-ia64.h.

#define MD_APPLY_SYM_VALUE (   FIX)    0

Definition at line 139 of file tc-ia64.h.

#define md_cons_align (   n)    ia64_cons_align (n)

Definition at line 136 of file tc-ia64.h.

#define md_convert_frag (   b,
  s,
  f 
)    ia64_convert_frag (f)

Definition at line 140 of file tc-ia64.h.

#define md_create_long_jump (   p,
  f,
  t,
  fr,
  s 
)    as_fatal ("ia64_create_long_jump")

Definition at line 141 of file tc-ia64.h.

#define md_create_short_jump (   p,
  f,
  t,
  fr,
  s 
)    as_fatal ("ia64_create_short_jump")

Definition at line 142 of file tc-ia64.h.

#define md_do_align (   n,
  f,
  l,
  m,
  j 
)    ia64_md_do_align (n,f,l,m)

Definition at line 154 of file tc-ia64.h.

Definition at line 41 of file tc-ia64.h.

Definition at line 147 of file tc-ia64.h.

Definition at line 146 of file tc-ia64.h.

#define md_elf_section_type (   str,
  len 
)    ia64_elf_section_type (str, len)

Definition at line 156 of file tc-ia64.h.

#define md_end ( )    ia64_end_of_source ()

Definition at line 124 of file tc-ia64.h.

Definition at line 144 of file tc-ia64.h.

Definition at line 34 of file tc-ia64.h.

Definition at line 131 of file tc-ia64.h.

#define md_frag_check (   FRAGP)
Value:
if ((FRAGP)->has_code                                                 \
      && (((FRAGP)->fr_address + (FRAGP)->insn_addr) & 15) != 0)      \
     as_bad_where ((FRAGP)->fr_file, (FRAGP)->fr_line,                \
                 _("instruction address is not a multiple of 16"));

Definition at line 167 of file tc-ia64.h.

#define md_number_to_chars   (*ia64_number_to_chars)

Definition at line 38 of file tc-ia64.h.

#define md_optimize_expr (   l,
  o,
  r 
)    ia64_optimize_expr (l, o, r)

Definition at line 135 of file tc-ia64.h.

#define md_parse_name (   s,
  e,
  m,
  c 
)    ia64_parse_name (s, e, c)

Definition at line 132 of file tc-ia64.h.

#define MD_PCREL_FROM_SECTION (   fix,
  sec 
)    ia64_pcrel_from_section (fix, sec)

Definition at line 152 of file tc-ia64.h.

#define md_section_align (   seg,
  size 
)    (size)

Definition at line 153 of file tc-ia64.h.

#define md_start_line_hook ( )    ia64_start_line ()

Definition at line 125 of file tc-ia64.h.

#define NEED_INDEX_OPERATOR   /* [ ] is index operator */

Definition at line 75 of file tc-ia64.h.

#define NEED_LITERAL_POOL   /* need gp literal pool */

Definition at line 72 of file tc-ia64.h.

#define QUOTES_IN_INSN   /* allow `string "foo;bar"' */

Definition at line 77 of file tc-ia64.h.

Definition at line 73 of file tc-ia64.h.

#define SUB_SEGMENT_ALIGN (   SEG,
  FRCHAIN 
)    0

Definition at line 85 of file tc-ia64.h.

#define TARGET_ARCH   bfd_arch_ia64

Definition at line 69 of file tc-ia64.h.

#define TARGET_BYTES_BIG_ENDIAN   0

Definition at line 33 of file tc-ia64.h.

Definition at line 66 of file tc-ia64.h.

#define tc_adjust_symtab ( )    ia64_adjust_symtab ()

Definition at line 53 of file tc-ia64.h.

Definition at line 134 of file tc-ia64.h.

Definition at line 133 of file tc-ia64.h.

#define tc_check_label (   l)    ia64_check_label (l)

Definition at line 159 of file tc-ia64.h.

#define TC_CONS_FIX_NEW (   f,
  o,
  l,
  e 
)    ia64_cons_fix_new (f, o, l, e)

Definition at line 150 of file tc-ia64.h.

Definition at line 158 of file tc-ia64.h.

#define tc_fix_adjustable (   f)    ia64_fix_adjustable (f)

Definition at line 138 of file tc-ia64.h.

#define TC_FIX_TYPE   struct ia64_fix

Definition at line 148 of file tc-ia64.h.

Definition at line 137 of file tc-ia64.h.

Value:
((FIX)->fx_r_type != BFD_RELOC_UNUSED                   \
   && (!(FIX)->fx_pcrel                                 \
       || (FIX)->fx_r_type == BFD_RELOC_IA64_PLTOFF22   \
       || TC_FORCE_RELOCATION (FIX)))

Definition at line 315 of file tc-ia64.h.

#define TC_FRAG_INIT (   FRAGP)    do {(FRAGP)->tc_frag_data = 0;}while (0)

Definition at line 163 of file tc-ia64.h.

#define TC_FRAG_TYPE   int

Definition at line 162 of file tc-ia64.h.

#define tc_frob_file ( )    ia64_frob_file ()

Definition at line 56 of file tc-ia64.h.

#define tc_frob_label (   s)    ia64_frob_label (s)

Definition at line 127 of file tc-ia64.h.

#define TC_IA64

Definition at line 26 of file tc-ia64.h.

#define TC_INIT_FIX_DATA (   f)    { f->tc_fix_data.opnd = 0; }

Definition at line 149 of file tc-ia64.h.

Definition at line 50 of file tc-ia64.h.

Definition at line 83 of file tc-ia64.h.

Definition at line 126 of file tc-ia64.h.

#define TC_VALIDATE_FIX (   fix,
  seg,
  skip 
)    ia64_validate_fix (fix)

Definition at line 151 of file tc-ia64.h.

#define UNW_B1   0x80

Definition at line 207 of file tc-ia64.h.

#define UNW_B2   0xC0

Definition at line 208 of file tc-ia64.h.

#define UNW_B3   0xE0

Definition at line 209 of file tc-ia64.h.

#define UNW_B4   0xF0

Definition at line 210 of file tc-ia64.h.

#define UNW_P1   0x80

Definition at line 193 of file tc-ia64.h.

#define UNW_P10   0xFF

Definition at line 202 of file tc-ia64.h.

#define UNW_P2   0xA0

Definition at line 194 of file tc-ia64.h.

#define UNW_P3   0xB0

Definition at line 195 of file tc-ia64.h.

#define UNW_P4   0xB8

Definition at line 196 of file tc-ia64.h.

#define UNW_P5   0xB9

Definition at line 197 of file tc-ia64.h.

#define UNW_P6   0xC0

Definition at line 198 of file tc-ia64.h.

#define UNW_P7   0xE0

Definition at line 199 of file tc-ia64.h.

#define UNW_P8   0xF0

Definition at line 200 of file tc-ia64.h.

#define UNW_P9   0xF1

Definition at line 201 of file tc-ia64.h.

#define UNW_R1   0x00

Definition at line 190 of file tc-ia64.h.

#define UNW_R2   0x40

Definition at line 191 of file tc-ia64.h.

#define UNW_R3   0x60

Definition at line 192 of file tc-ia64.h.

#define UNW_X1   0xF9

Definition at line 203 of file tc-ia64.h.

#define UNW_X2   0xFA

Definition at line 204 of file tc-ia64.h.

#define UNW_X3   0xFB

Definition at line 205 of file tc-ia64.h.

#define UNW_X4   0xFC

Definition at line 206 of file tc-ia64.h.

#define WORKING_DOT_WORD   /* don't do broken word processing for now */

Definition at line 175 of file tc-ia64.h.


Typedef Documentation


Enumeration Type Documentation

Enumerator:
prologue 
prologue_gr 
body 
mem_stack_f 
mem_stack_v 
psp_gr 
psp_sprel 
rp_when 
rp_gr 
rp_br 
rp_psprel 
rp_sprel 
pfs_when 
pfs_gr 
pfs_psprel 
pfs_sprel 
preds_when 
preds_gr 
preds_psprel 
preds_sprel 
fr_mem 
frgr_mem 
gr_gr 
gr_mem 
br_mem 
br_gr 
spill_base 
spill_mask 
unat_when 
unat_gr 
unat_psprel 
unat_sprel 
lc_when 
lc_gr 
lc_psprel 
lc_sprel 
fpsr_when 
fpsr_gr 
fpsr_psprel 
fpsr_sprel 
priunat_when_gr 
priunat_when_mem 
priunat_gr 
priunat_psprel 
priunat_sprel 
bsp_when 
bsp_gr 
bsp_psprel 
bsp_sprel 
bspstore_when 
bspstore_gr 
bspstore_psprel 
bspstore_sprel 
rnat_when 
rnat_gr 
rnat_psprel 
rnat_sprel 
epilogue 
label_state 
copy_state 
spill_psprel 
spill_sprel 
spill_reg 
spill_psprel_p 
spill_sprel_p 
spill_reg_p 
unwabi 
endp 

Definition at line 214 of file tc-ia64.h.


Function Documentation

void ia64_convert_frag ( fragS *  )

Definition at line 3115 of file tc-ia64.c.

{
  unw_rec_list *list;
  int len, size, pad;
  valueT flag_value;

  /* ??? This code is identical to ia64_estimate_size_before_relax.  */
  list = (unw_rec_list *) frag->fr_opcode;
  fixup_unw_records (list, 0);

  len = calc_record_size (list);
  /* pad to pointer-size boundary.  */
  pad = len % md.pointer_size;
  if (pad != 0)
    len += md.pointer_size - pad;
  /* Add 8 for the header.  */
  size = len + 8;
  /* Add a pointer for the personality offset.  */
  if (frag->fr_offset)
    size += md.pointer_size;

  /* fr_var carries the max_chars that we created the fragment with.
     We must, of course, have allocated enough memory earlier.  */
  assert (frag->fr_var >= size);

  /* Initialize the header area. fr_offset is initialized with
     unwind.personality_routine.  */
  if (frag->fr_offset)
    {
      if (md.flags & EF_IA_64_ABI64)
       flag_value = (bfd_vma) 3 << 32;
      else
       /* 32-bit unwind info block.  */
       flag_value = (bfd_vma) 0x1003 << 32;
    }
  else
    flag_value = 0;

 md_number_to_chars (frag->fr_literal,
                   (((bfd_vma) 1 << 48) /* Version.  */
                    | flag_value        /* U & E handler flags.  */
                    | (len / md.pointer_size)), /* Length.  */
                   8);

  /* Skip the header.  */
  vbyte_mem_ptr = frag->fr_literal + 8;
  process_unw_records (list, output_vbyte_mem);

  /* Fill the padding bytes with zeros.  */
  if (pad != 0)
    md_number_to_chars (frag->fr_literal + len + 8 - md.pointer_size + pad, 0,
                     md.pointer_size - pad);

  frag->fr_fix += size;
  frag->fr_type = rs_fill;
  frag->fr_var = 0;
  frag->fr_offset = 0;
}

Here is the call graph for this function:

void ia64_number_to_chars PARAMS ( (char *, valueT, int )
void ia64_init PARAMS ( (int, char **)  )
int ia64_parse_name PARAMS ( (char *name, expressionS *e, char *nextP)  )
void ia64_cons_align PARAMS ( (int )
void ia64_cons_fix_new PARAMS ( (fragS *f, int where, int nbytes, expressionS *exp )
char* ia64_canonicalize_symbol_name PARAMS ( (char *)  )
void ia64_md_do_align PARAMS ( (int, const char *, int, int )
void ia64_handle_align PARAMS ( (fragS *f )
void ia64_dwarf2_emit_offset PARAMS ( (symbolS *, unsigned int )
void ia64_check_label PARAMS ( (symbolS *)  )

Variable Documentation

Definition at line 186 of file tc-ia64.c.