osprey/arith/mpp_sim.c File Reference

#include <stdio.h>
#include <stdlib.h>
#include <fcntl.h>
#include <errno.h>
#include <sys/types.h>
#include <unistd.h>
#include <ar.h>
#include "arith.internal.h"
#include "int64.h"

Include dependency graph for mpp_sim.c:

Go to the source code of this file.

Data Types

union  i64_union

Defines

#define AR_HDR_SIZE   sizeof(struct ar_hdr)
#define IEEE_FLOAT_32   (UNROUNDED_TYPE(AR_Float_IEEE_NR_32))
#define IEEE_FLOAT_64   (UNROUNDED_TYPE(AR_Float_IEEE_NR_64))
#define IEEE_FLOAT_128   (UNROUNDED_TYPE(AR_Float_IEEE_NR_128))
#define IEEE_COMPLEX_32   (UNROUNDED_TYPE(AR_Complex_IEEE_NR_32))
#define IEEE_COMPLEX_64   (UNROUNDED_TYPE(AR_Complex_IEEE_NR_64))
#define IEEE_COMPLEX_128   (UNROUNDED_TYPE(AR_Complex_IEEE_NR_128))
#define T3D   10
#define T3E   12
#define NOINTRIN   1
#define ARITHERR   2
#define EXTERROR   3
#define SETERRNO   4
#define IFACEERR   5
#define HOSTEXT   6
#define BADINSTR   7
#define MPP_STACK_SIZE   2048
#define MPP_DSIB_SIZE   6
#define MPP_MAX_ARGS   8
#define DISASM0(fmt)
#define DISASM1(fmt, x)
#define DISASM2(fmt, x, y)
#define DISASM3(fmt, x, y, z)
#define DISASM4(fmt, x, y, z, v)
#define DISASM5(fmt, x, y, z, v, w)
#define v0   0
#define t1   2
#define s0   9
#define fp   15
#define a0   16
#define a1   17
#define a2   18
#define a3   19
#define a4   20
#define a5   21
#define ci   25
#define ret   26
#define sp   30
#define zero   31
#define fv0   0
#define fv1   1
#define fa0   16
#define fzero   31
#define MAX_EXT_ADDRS   16
#define T3E_DSIB_LOC   (MPP_STACK_SIZE + (MPP_MAX_ARGS * 5))
#define T3D_AHDR_SIZE   174*8
#define CLD_T3E_AHDR_SIZE   512*8

Enumerations

enum  SegTypes {
  SEGT_DATA = 0, SEGT_TEXT = 1, SEGT_REGISTERS = 2, SEGT_STACK = 3,
  SEGT_EREGISTERS = 4, SEGT_BESUS = 5
}

Functions/Subroutines

static int call_host_external (char *func)
static void open_intrinsics_file (void)
static void load_mpp_word (AR_INT_64 *result, long segment, long offset)
static void store_mpp_word (long segment, long offset, AR_INT_64 *result)
int ar_clear_sim_state (AR_TYPE resulttype)
int ar_ext_address (AR_INT_64 *intaddr, const char *extaddr, int length)
int ar_pass_arg_address (const ar_data *arg, const AR_TYPE *argtype)
int ar_pass_ext_address (AR_INT_64 *extdesc, const char *addr, int nwords)
int ar_pass_fcd_address (const char *str, long lenstr)
int ar_pass_arg_value (const ar_data *arg, const AR_TYPE *argtype)
int ar_put_real_address (AR_INT_64 *extdesc)
int ar_get_function_value (ar_data *result, AR_TYPE *resulttype)
int ar_sim (char *intrinsic)

Variables

int ar_rounding_modes = 1<<AR_ROUND_NEAREST
int ar_underflow_modes = 1<<AR_UNDERFLOW_TO_PLUS_ZERO
char AR_libmv2 []
char AR_version []
static int ar_sim_version = 0
static int ar_mach_type = T3D
static AR_TYPE integer_64 = AR_Int_64_S
static AR_TYPE ieee_float_32 = (AR_TYPE) IEEE_FLOAT_32
static AR_TYPE ieee_float_64 = (AR_TYPE) IEEE_FLOAT_64
static unsigned char * mpp_intrin = NULL
static unsigned char * code = NULL
static unsigned char * data = NULL
static unsigned char * stack = NULL
static int D_roundmode = -1
static AR_TYPE D_float_32
static AR_TYPE D_float_64
static AR_TYPE D_float_128
static AR_TYPE D_complex_64
static AR_TYPE D_complex_128
static AR_INT_64 R [32]
static AR_INT_64 F [32]
static AR_HOST_SINT64 numargs = 0
static int n_external_addresses = 1
static unsigned code_segment_id
static unsigned data_segment_id
static unsigned stack_segment_id
static char * external_address [MAX_EXT_ADDRS]
static long external_length [MAX_EXT_ADDRS]
static int idf_fd
static long idf_size
static long text_size
static long data_offset
static char USMID [] = "\n%Z%%M% %I% %G% %U%\n"
static char rcsid [] = "$Id: mpp_sim.c,v 1.1.1.1 2005/10/21 19:00:00 marcel Exp $"


Define Documentation

#define a0   16

#define a1   17

#define a2   18

#define a3   19

Definition at line 216 of file mpp_sim.c.

Referenced by main(), and Process_Pair().

#define a4   20

Definition at line 217 of file mpp_sim.c.

Referenced by main().

#define a5   21

Definition at line 218 of file mpp_sim.c.

Referenced by main().

#define AR_HDR_SIZE   sizeof(struct ar_hdr)

Definition at line 48 of file mpp_sim.c.

Referenced by open_intrinsics_file(), and srch_ar_file_for_module_tbl().

#define ARITHERR   2

Definition at line 84 of file mpp_sim.c.

#define BADINSTR   7

Definition at line 89 of file mpp_sim.c.

Referenced by ar_sim().

#define ci   25

#define CLD_T3E_AHDR_SIZE   512*8

Definition at line 2673 of file mpp_sim.c.

Referenced by open_intrinsics_file().

#define DISASM0 ( fmt   ) 

Definition at line 198 of file mpp_sim.c.

#define DISASM1 ( fmt,
 ) 

Definition at line 199 of file mpp_sim.c.

#define DISASM2 ( fmt,
x,
 ) 

Definition at line 200 of file mpp_sim.c.

#define DISASM3 ( fmt,
x,
y,
 ) 

Definition at line 201 of file mpp_sim.c.

#define DISASM4 ( fmt,
x,
y,
z,
 ) 

Definition at line 202 of file mpp_sim.c.

#define DISASM5 ( fmt,
x,
y,
z,
v,
 ) 

Definition at line 203 of file mpp_sim.c.

#define EXTERROR   3

Definition at line 85 of file mpp_sim.c.

#define fa0   16

Definition at line 226 of file mpp_sim.c.

Referenced by ar_pass_arg_value().

#define fp   15

Definition at line 212 of file mpp_sim.c.

Referenced by Instr::__profile_finish(), __profile_finish(), ar_sim(), Cif_Getfiledir(), clean_graph_dump_file(), Compute_Actual_Miss_Bytes(), convtest128a(), convtest128b(), convtest128c(), convtest64(), craytest128_1(), craytest128_1t(), craytest128_2t(), craytest128_64(), craytest128_i(), craytest64_1(), craytest64_1t(), craytest64_2(), craytest64_2t(), craytest64_c(), craytest64_i(), craytest64_i2(), cwh_stab_emit_commons_and_equivalences(), cwh_stab_emit_list(), do_include(), dotest128_1(), dotest128_2(), dotest128_i(), dotest128_r(), dotest32_1s(), dotest32_2(), dotest32_2c(), dotest64_1(), dotest64_1s(), dotest64_2(), dotest64_2c(), dotest64_c(), dotest64_i(), dotest64_i2(), dump_backtrace(), expand_builtin_fprintf(), expand_builtin_longjmp(), expand_xref(), FB_EDGE_TYPE_fprintf(), fdopen_unlocked(), ffecom_file_(), ffecom_open_include_(), finclude(), find_toolroot(), finish_graph_dump_file(), fix_lexical_addr(), fold_builtin_fprintf(), fopen_unlocked(), freopen_unlocked(), frv_expand_epilogue(), frv_expand_prologue(), fstat(), gen_builtin_longjmp(), get_charset_aliases(), get_gcc_version(), getenv_(), ia64_dwarf2out_def_steady_cfa(), ia64_expand_epilogue(), ieeetest32_1t(), ieeetest32_2c(), ieeetest32_2cmp(), ieeetest32_2t(), ieeetest64_1t(), ieeetest64_2c(), ieeetest64_2cmp(), ieeetest64_2t(), java_get_line_col(), load_depfile(), load_file(), load_insn_classes(), lower_mp(), main(), mpw_fopen(), FIELD_MAP::Print(), IPA_EDGE::Print(), LCLSC_NODE::Print(), OPT_FB_EDGE::Print(), SCALAR_INFO::Print(), FIZ_FUSE_INFO::Print(), VN_INTR_OP_EXPR::print(), VN_BINARY_EXPR::print(), VN_TERNARY_EXPR::print(), VN_LDA_ADDR_EXPR::print(), BB_NODE_SET::Print(), VN_MEMLOC_EXPR::print(), VN_PHI_EXPR::print(), IDX_32_SET::Print(), OPT_FB_NODE::Print(), VN_ARRAY_ADDR_EXPR::print(), VN_UNARY_EXPR::print(), VN_LITERAL_EXPR::print(), Print_dom(), print_edges(), print_nodes(), Print_pdom(), Print_Prompl_Msgs(), print_rtl_graph_with_bb(), print_search_path(), Process_Feedback_File(), read_alias_file(), read_gcc_output(), s_lno_debug(), set_arg_arr(), stack_include_file(), time_summary(), trampoline_address(), unlock_1(), unwind_dump2ascii(), and unwind_process_prologue_desc().

#define fv0   0

Definition at line 224 of file mpp_sim.c.

Referenced by ar_get_function_value().

#define fv1   1

Definition at line 225 of file mpp_sim.c.

#define fzero   31

Definition at line 227 of file mpp_sim.c.

Referenced by ar_sim(), ia64_abi(), and main().

#define HOSTEXT   6

Definition at line 88 of file mpp_sim.c.

#define IEEE_COMPLEX_128   (UNROUNDED_TYPE(AR_Complex_IEEE_NR_128))

Definition at line 71 of file mpp_sim.c.

#define IEEE_COMPLEX_32   (UNROUNDED_TYPE(AR_Complex_IEEE_NR_32))

#define IEEE_COMPLEX_64   (UNROUNDED_TYPE(AR_Complex_IEEE_NR_64))

Definition at line 70 of file mpp_sim.c.

#define IEEE_FLOAT_128   (UNROUNDED_TYPE(AR_Float_IEEE_NR_128))

Definition at line 68 of file mpp_sim.c.

#define IEEE_FLOAT_32   (UNROUNDED_TYPE(AR_Float_IEEE_NR_32))

#define IEEE_FLOAT_64   (UNROUNDED_TYPE(AR_Float_IEEE_NR_64))

Definition at line 67 of file mpp_sim.c.

#define IFACEERR   5

Definition at line 87 of file mpp_sim.c.

#define MAX_EXT_ADDRS   16

Definition at line 229 of file mpp_sim.c.

#define MPP_DSIB_SIZE   6

Definition at line 92 of file mpp_sim.c.

Referenced by ar_sim().

#define MPP_MAX_ARGS   8

#define MPP_STACK_SIZE   2048

#define NOINTRIN   1

Definition at line 83 of file mpp_sim.c.

#define ret   26

Definition at line 220 of file mpp_sim.c.

Referenced by __popcounthi2(), __READ(), __READC(), __setpos64(), __WRITE(), __WRITEC(), _bfd_coff_debug_merge_hash_newfunc(), _bfd_coff_link_hash_newfunc(), _bfd_coff_link_hash_table_create(), _bfd_compute_and_write_armap(), _bfd_dlx_elf_hi16_reloc(), _bfd_ecoff_bfd_final_link(), _bfd_ecoff_bfd_link_hash_table_create(), _bfd_ecoff_sizeof_headers(), _bfd_elf_canonicalize_dynamic_reloc(), _bfd_elf_gc_mark(), _bfd_elf_get_dynamic_reloc_upper_bound(), _bfd_elf_link_hash_newfunc(), _bfd_elf_link_hash_table_create(), _bfd_elf_link_hash_table_init(), _bfd_elf_sizeof_headers(), _bfd_elf_stringtab_init(), _bfd_generic_link_hash_newfunc(), _bfd_generic_link_hash_table_create(), _bfd_generic_link_hash_table_free(), _bfd_mips_elf32_gprel16_reloc(), _bfd_mips_elf_additional_program_headers(), _bfd_mips_elf_discard_info(), _bfd_mips_elf_link_hash_table_create(), _bfd_mips_elf_lo16_reloc(), _bfd_vms_hash_newfunc(), _bfd_xcoff_bfd_link_hash_table_create(), _bfd_xcoff_bfd_link_hash_table_free(), _bfd_xcoff_read_ar_hdr(), _bfd_xcoff_stringtab_init(), _bfd_XXi_swap_scnhdr_out(), _BUFFERIN(), _BUFFEROUT(), _f_opn(), _fcleanup(), _flushall(), _frch(), _frvfdpic_get_got_entry(), _frvfdpic_get_tlsdesc_entry(), _frwd(), _fwch(), _FWU(), _fwwd(), _get_mismatch_error(), _GETENV(), _getfchar(), _GETPOS_(), _INQIL(), _LENGTH_(), _map_to_dv(), _nl_strd_derv(), _nl_stride_dv(), _objalloc_alloc(), _PXFFCNTL(), _rnl90to77(), _setpos(), _stride_dv(), _unit_bksp(), _unit_close(), _unit_scratch(), _Unwind_Find_FDE(), _Unwind_FindTableEntry(), _Unwind_GetGR(), _wnl_beautify(), _WUF(), _xfer_iolist(), absent(), add_to_sequence(), alpha_ecoff_object_p(), alpha_ecoff_read_ar_hdr(), alpha_initial_elimination_offset(), already_linked_newfunc(), CODEREP::Antloc(), ar_sim(), archive_hash_newfunc(), atomic_alloc(), avail_expr_eq(), bfd_alloc(), bfd_cache_close_all(), bfd_cache_delete(), bfd_close(), bfd_close_all_done(), bfd_elf_discard_info(), bfd_hash_allocate(), bfd_link_hash_lookup(), bfd_mach_o_core_file_failing_command(), bfd_mach_o_scan_read_symtab_symbols(), bfd_pef_canonicalize_symtab(), bfd_pef_parse_function_stubs(), bfd_pef_parse_traceback_tables(), bfd_pef_print_loader_section(), bfd_pef_print_symbol(), bfd_pef_scan_start_address(), bfd_realloc(), bfd_sym_fetch_long(), bfd_sym_print_file_reference(), bfd_sym_read_header_v32(), bfd_sym_read_name_table(), bfd_sym_read_version(), bitmap_equal_p(), bitmap_popcount(), bitmap_set_new(), bitmap_set_subtract_from_value_set(), browse_tree(), build_attrs_declarator(), build_c_parm(), build_function_declarator(), build_id_declarator(), build_java_jsr(), build_null_declspecs(), build_replicated_const(), build_stmt(), c4x_emit_libcall(), c4x_emit_libcall_mulhi(), c_begin_stmt_expr(), c_convert_parm_for_inlining(), c_parser_asm_statement(), c_parser_expr_list(), c_parser_omp_for(), c_parser_omp_sections(), c_parser_parms_declarator(), c_parser_parms_list_declarator(), c_parser_struct_declaration(), c_parser_type_name(), can_copy_bbs_p(), can_duplicate_loop_p(), can_merge_blocks_p(), categorize_decl_for_section(), cfg_layout_redirect_edge_and_branch(), CHECKTP(), Cif_Cifconv(), Cif_Lines(), Cif_Make_Cifconv(), CLOSEV(), coff_arm_link_hash_table_create(), combine_givs_p(), common_op_match_null_string_p(), comp_c_message(), comp_callsite(), comp_cdir(), comp_cdir_doshared(), comp_continuation(), comp_f90_callsite(), comp_f90_loop(), comp_id(), comp_loop(), comp_message(), comp_scope(), comp_src_pos(), comp_stmt_type(), comp_transform(), comp_usage(), comp_use(), compare_section(), compare_values(), compuse(), Compute_dependence(), compute_store_table(), construct_container(), count_rtxs(), cp_gimplify_expr(), cp_parser_omp_for(), cp_parser_omp_sections(), cplus_demangle(), cplus_demangle_opname(), cplus_demangle_type(), create_basic_block(), cref_hash_newfunc(), crx_expand_compare(), cval_to_f_int(), cxx_expand_expr(), cxx_omp_clause_apply_fn(), cxx_omp_clause_assign_op(), cxx_omp_clause_copy_ctor(), cxx_omp_clause_default_ctor(), cxx_omp_clause_dtor(), d30v_function_arg(), d30v_function_arg_partial_nregs(), d30v_function_arg_pass_by_reference(), d30v_legitimate_address_p(), d30v_legitimize_address(), d_demangle(), d_expr_primary(), d_function_type(), d_nested_name(), d_number(), d_prefix(), d_source_name(), d_template_arg(), d_unqualified_name(), darwin_gt_pch_use_address(), darwin_rs6000_gt_pch_use_address(), debug_find_var_in_block_tree(), decl_constant_value_for_broken_optimization(), decNumberSameQuantum(), default_spill_heuristic(), disable_extension_diagnostics(), do_compare(), do_pushlevel(), do_wait(), double_int_add(), double_int_divmod(), double_int_mul(), double_int_neg(), duplicate_eh_regions_1(), ecoff_add_string(), ecoff_final_link_debug_accumulate(), ecoff_link_hash_newfunc(), EH_Get_PU_Range_INITO(), elf32_hppa_link_hash_table_create(), elf32_hppa_link_hash_table_free(), elf32_mn10300_link_hash_newfunc(), elf32_mn10300_link_hash_table_create(), elf32_mn10300_link_hash_table_free(), elf32_sparc_link_hash_table_create(), elf64_alpha_bfd_link_hash_table_create(), elf64_alpha_do_reloc_gpdisp(), elf64_alpha_link_hash_newfunc(), elf64_alpha_reloc_gpdisp(), elf64_hppa_hash_table_create(), elf64_hppa_new_dyn_hash_entry(), elf64_x86_64_link_hash_table_create(), elf_bfd_discard_info(), elf_cris_link_hash_newfunc(), elf_cris_link_hash_table_create(), elf_gc_mark(), elf_i386_link_hash_table_create(), elf_link_add_object_symbols(), elf_link_sort_relocs(), elf_m68k_link_hash_newfunc(), elf_m68k_link_hash_table_create(), elf_s390_link_hash_table_create(), elf_strtab_hash_newfunc(), elf_vax_link_hash_newfunc(), elf_vax_link_hash_table_create(), elfNN_ia64_additional_program_headers(), elfNN_ia64_hash_table_create(), elfNN_ia64_new_elf_hash_entry(), emit_hpdiv_const(), emit_insxl(), emit_move_ccmode(), emit_move_change_mode(), emit_move_complex(), emit_move_insn_1(), emit_soft_tfmode_libcall(), ENDSP(), enter_str(), et_nca(), expand_builtin_expect_jump(), expand_builtin_memmove(), expand_builtin_stpcpy(), expand_decl_cleanup_eh(), expand_expr_real(), expand_expr_real_1(), expand_simple_operations(), expand_stack_save(), extract_cie_info(), extract_component(), extract_d16_15(), extract_d16_16(), extract_d22(), extract_d5_4(), extract_d8_6(), extract_d8_7(), extract_d9(), extract_i5div(), extract_i9(), extract_mbe(), extract_muldiv(), extract_nb(), extract_tbr(), extract_u9(), f8_record(), fibheap_delete_node(), fibheap_extr_min_node(), fibheap_extract_min(), fibnode_remove(), find_goto_replacement(), find_lattice_value(), LFTR::Find_lftr_var_id(), find_loads(), find_replaceable_exprs(), findmatch(), fold_builtin_memset(), fold_builtin_object_size(), fold_rtx_mem(), for_each_path(), force_gimple_operand(), free_temp_expr_table(), friend_accessible_p(), frv_arg_partial_bytes(), frv_function_arg(), frv_initial_elimination_offset(), frv_legitimate_address_p(), frv_local_funcdesc_p(), frv_print_operand_jump_hint(), frv_secondary_reload_class(), frv_split_abs(), frv_split_cond_move(), frv_split_minmax(), frv_split_scc(), frvfdpic_elf_link_hash_table_create(), function_arg(), function_arg_partial_nregs(), function_epilogue(), funcvec_hash_newfunc(), gcc_loopnest_to_lambda_loopnest(), generate_element_init(), generic_link_add_symbols(), get_arg_pointer_save_area(), get_component_ssa_name(), get_component_var(), get_ivts_expr(), get_local_sym_hash(), get_use_iv_cost(), GETTP(), gimplify_addr_expr(), gimplify_asm_expr(), gimplify_build1(), gimplify_build2(), gimplify_build3(), gimplify_call_expr(), gimplify_compound_lval(), gimplify_cond_expr(), gimplify_expr(), gimplify_function_tree(), gimplify_init_constructor(), gimplify_modify_expr(), gimplify_modify_expr_rhs(), gimplify_omp_for(), gimplify_save_expr(), gimplify_self_mod_expr(), gimplify_switch_expr(), gimplify_target_expr(), grok_op_properties(), h8300_coff_link_hash_table_create(), h8300_return_addr_rtx(), hppa_tls_call(), i370_elf_relocate_section(), i860_saveregs(), i860_va_arg(), i960_function_arg(), ia64_expand_fetch_and_op(), ia64_expand_lock_test_and_set(), ia64_expand_op_and_fetch(), ia64_single_set(), init_test_hash_newfunc(), inline_forbidden_p(), insn_extract(), BB_LOOP::Invariant_cr(), iq2000_elf_howto_hi16_reloc(), iq2000_move_1word(), is_ctor_dtor(), is_ctor_or_dtor(), is_elf_file(), is_mem_ref(), is_regular_file(), ix86_expand_compare(), ix86_expand_setcc(), ix86_function_value(), ix86_pad_returns(), l_write(), lambda_body_vector_new(), lambda_lattice_compute_base(), lambda_lattice_new(), lambda_linear_expression_new(), lambda_loopnest_new(), lambda_trans_matrix_new(), lang_add_vers_depend(), lang_definedness_newfunc(), lang_new_vers_node(), lang_new_vers_pattern(), legitimize_tls_address(), linux_link_hash_newfunc(), linux_link_hash_table_create(), lookup_tmp_var(), loop_find_equiv_value(), lowpart_subreg_maybe_copy(), lrealpath(), lvalue_or_else(), lw_A(), m32r_elf_generic_reloc(), m32r_elf_hi16_reloc(), m32r_elf_link_hash_newfunc(), m32r_elf_link_hash_table_create(), m32r_elf_relocate_section(), m68hc11_elf_bfd_link_hash_table_create(), m68hc11_elf_bfd_link_hash_table_free(), m68hc11_elf_hash_table_create(), m68hc11_emit_libcall(), m68hc11_expand_compare(), m68hc12_elf_bfd_link_hash_table_create(), make_fdspec(), make_pointer_declarator(), make_relative_prefix(), mark_used_regs(), marked_ssa_names(), maybe_fold_tmr(), mcore_elf_relocate_section(), mips16_gprel_reloc(), mips_elf64_canonicalize_dynamic_reloc(), mips_elf64_gprel16_reloc(), mips_elf64_gprel32_reloc(), mips_elf64_literal_reloc(), mips_elf_gprel16_reloc(), mips_elf_gprel32_reloc(), mips_elf_link_hash_newfunc(), mips_elf_literal_reloc(), mips_move_1word(), mips_move_2words(), mips_refhi_reloc(), mips_tls_got_relocs(), move_block_after(), n_getv(), NAMEfindit(), new_constraint(), new_constraint_edge(), new_var_info(), non_cast_lvalue_or_else(), objalloc_create(), omp_notice_variable(), OP_is_copy(), OPCODE_make_op(), VECTOR_SPACE< T >::operator-=(), or32_elf_consth_reloc(), or32_extract(), output_153(), output_155(), output_fp_compare(), parse_hi16(), parse_lo16(), pex_get_status_and_time(), pex_init(), pointer_int_sum(), pop_best_coalesce(), ppc64_elf_link_hash_table_free(), ppc64_elf_next_input_section(), ppc64_elf_relocate_section(), ppc_coff_link_hash_newfunc(), ppc_coff_link_hash_table_create(), ppc_elf_additional_program_headers(), ppc_elf_link_hash_table_create(), ppc_elf_relocate_section(), pragma_lex(), print_header_records(), print_include_records(), print_operand(), print_records(), UPDATE< TRANSFORM, CACHE, VERSION >::Process_CR_no_repeat(), pstrcmp(), re_compile_pattern(), re_set_syntax(), reachable_at_most_once(), reachable_next_level(), read_complex_part(), Record_And_Del_Loop_Region(), redirect_edge_and_branch(), redirect_edge_and_branch_force(), regex_compile(), REGION_add_preg_in(), REGION_add_preg_out(), OPT_STAB::REGION_add_to_bound(), PRUNE_BOUND::REGION_remove_from_bound(), register_Btype(), resolve_mixers(), RID_Fprint(), RNL(), rs6000_arg_partial_bytes(), rs6000_expand_builtin(), rs6000_trampoline_size(), rtl_redirect_edge_and_branch(), rtx_to_undefined(), s390_emit_compare(), s390_emit_compare_and_swap(), s390_expand_addcc(), s390_split_branches(), s_cmp(), score_function_arg(), sec_merge_hash_newfunc(), set_new(), SETSP(), sh64_elf64_link_hash_newfunc(), sh64_elf64_link_hash_table_create(), sh_elf_link_hash_newfunc(), sh_elf_link_hash_table_create(), simplify_by_exploding(), simplify_cond(), simplify_replace_tree(), simplify_using_assignment(), SKIPF(), sparc64_elf_bfd_link_hash_table_create(), sparc64_elf_canonicalize_dynamic_reloc(), sparc_nonflat_function_epilogue(), split_edge(), ssa_names_to_replace(), stab_link_includes_newfunc(), stack_protect_classify_type(), stack_protect_decl_phase(), STARTSP(), string_hash_newfunc(), strtab_hash_newfunc(), subreg_regno(), sunos_link_hash_newfunc(), sunos_link_hash_table_create(), toc_adjusting_stub_needed(), tree_redirect_edge_and_branch(), try_move_mult_to_index(), TSYNC(), TY_POINT_TO_NON_UNIONSTRUCT(), unwind_dump2ascii(), unwind_dump_body_desc(), unwind_dump_header_desc(), unwind_dump_prologue_desc(), unwind_get_unwind_table_data(), unwind_info_add_body_copy_state_info(), unwind_info_add_body_epilogue_info(), unwind_info_add_body_header(), unwind_info_add_body_label_state_info(), unwind_info_add_prologue_br_gr_info(), unwind_info_add_prologue_br_mem_info(), unwind_info_add_prologue_bsp_gr_info(), unwind_info_add_prologue_bsp_psprel_info(), unwind_info_add_prologue_bsp_sprel_info(), unwind_info_add_prologue_bsp_when_info(), unwind_info_add_prologue_bspstore_gr_info(), unwind_info_add_prologue_bspstore_psprel_info(), unwind_info_add_prologue_bspstore_sprel_info(), unwind_info_add_prologue_bspstore_when_info(), unwind_info_add_prologue_fpsr_gr_info(), unwind_info_add_prologue_fpsr_psprel_info(), unwind_info_add_prologue_fpsr_sprel_info(), unwind_info_add_prologue_fpsr_when_info(), unwind_info_add_prologue_fr_mem_info(), unwind_info_add_prologue_frgr_mem_info(), unwind_info_add_prologue_gr_gr_info(), unwind_info_add_prologue_gr_header(), unwind_info_add_prologue_gr_mem_info(), unwind_info_add_prologue_header(), unwind_info_add_prologue_lc_gr_info(), unwind_info_add_prologue_lc_psprel_info(), unwind_info_add_prologue_lc_sprel_info(), unwind_info_add_prologue_lc_when_info(), unwind_info_add_prologue_mem_stack_f_info(), unwind_info_add_prologue_mem_stack_v_info(), unwind_info_add_prologue_pfs_gr_info(), unwind_info_add_prologue_pfs_psprel_info(), unwind_info_add_prologue_pfs_sprel_info(), unwind_info_add_prologue_pfs_when_info(), unwind_info_add_prologue_preds_gr_info(), unwind_info_add_prologue_preds_psprel_info(), unwind_info_add_prologue_preds_sprel_info(), unwind_info_add_prologue_preds_when_info(), unwind_info_add_prologue_priunat_gr_info(), unwind_info_add_prologue_priunat_psprel_info(), unwind_info_add_prologue_priunat_sprel_info(), unwind_info_add_prologue_priunat_when_info(), unwind_info_add_prologue_psp_gr_info(), unwind_info_add_prologue_psp_sprel_info(), unwind_info_add_prologue_rnat_gr_info(), unwind_info_add_prologue_rnat_psprel_info(), unwind_info_add_prologue_rnat_sprel_info(), unwind_info_add_prologue_rnat_when_info(), unwind_info_add_prologue_rp_br_info(), unwind_info_add_prologue_rp_gr_info(), unwind_info_add_prologue_rp_psprel_info(), unwind_info_add_prologue_rp_sprel_info(), unwind_info_add_prologue_rp_when_info(), unwind_info_add_prologue_spill_base_info(), unwind_info_add_prologue_spill_mask_info(), unwind_info_add_prologue_unat_gr_info(), unwind_info_add_prologue_unat_psprel_info(), unwind_info_add_prologue_unat_sprel_info(), unwind_info_add_prologue_unat_when_info(), unwind_info_add_restore_reg_info(), unwind_info_add_restore_reg_p_info(), unwind_info_add_spill_psprel_info(), unwind_info_add_spill_psprel_p_info(), unwind_info_add_spill_reg_to_br_info(), unwind_info_add_spill_reg_to_br_p_info(), unwind_info_add_spill_reg_to_fr_info(), unwind_info_add_spill_reg_to_fr_p_info(), unwind_info_add_spill_reg_to_gr_info(), unwind_info_add_spill_reg_to_gr_p_info(), unwind_info_add_spill_sprel_info(), unwind_info_add_spill_sprel_p_info(), unwind_info_finalize(), unwind_process_body_desc(), unwind_process_header_desc(), unwind_process_prologue_desc(), unwind_restore_gp(), v850_elf_check_relocs(), v850_interrupt_function_p(), va_list_counter_bump(), Verify_alias(), verify_jvm_instructions(), vrp_evaluate_conditional(), WNL(), write_switch(), x86_machine_dependent_reorg(), xcoff_link_hash_newfunc(), xstrdup(), and xvasprintf().

#define s0   9

#define SETERRNO   4

Definition at line 86 of file mpp_sim.c.

#define sp   30

Definition at line 221 of file mpp_sim.c.

Referenced by _dwarf_p_get_alloc(), _ft_stclose(), _ft_stopen(), _gather_data(), _scatter_data(), _Unwind_VRS_Pop(), add_local_decl(), ar_sim(), c_parser_binary_expression(), calc_dfs_tree_nonrec(), check_for_plus_in_loops_1(), compute_avail(), convert_from_eh_region_ranges_1(), cp_parser_binary_expression(), d30v_expand_epilogue(), d30v_expand_prologue(), dfs_enumerate_from(), elf_link_sort_relocs(), ffestc_promote_sfdummy_(), ffesymbol_declare_sfdummy(), flow_depth_first_order_compute(), flow_loop_nodes_find(), flow_preorder_transversal_compute(), flow_reverse_top_sort_order_compute(), Formal_Machine_Type(), frv_expand_epilogue(), frv_expand_prologue(), gen_eh_epilogue(), get_srcfid(), get_symref(), h8300_push_pop(), IPA_LNO_Annotate_Array_Call(), IPA_LNO_Annotate_Execution_Cost(), IPA_LNO_Annotate_Scalar_Call(), IPA_LNO_Map_Node(), m32c_function_needs_enter(), mark_dfs_back_edges(), Mismatched_Types(), mt_expand_eh_return(), pa32_fallback_frame_state(), parse_expression(), DaVinci::Parse_Node_Ids(), post_order_compute(), pre_and_rev_post_order_compute(), process_template(), Profile_Switch_Init(), Instr::Profile_Switch_Init(), rd_F(), reachable_at_most_once(), remap_symbols(), remove_reachable_equiv_notes(), retrieve_specialization(), Save_And_Restore_Stack(), save_idents(), set_arg_arr(), splay_tree_new_with_allocator(), WB_BROWSER::Summary_Phi(), CG_BROWSER::Summary_Procedure(), WB_BROWSER::Summary_Procedure(), sweep_pages(), translate_options(), Try_Reshape_Callee_Formal(), unwind_frame(), Update_Execution_Cost(), vt_stack_adjustments(), walk_dominator_tree(), write_header(), and write_unit().

#define t1   2

Definition at line 210 of file mpp_sim.c.

Referenced by MEM_ACCESS_ANALYZER::Analyze_ofst_helper(), ar_c1frecip(), ar_cfdiv128(), ar_sim(), attribute_list_contained(), BB_Sink_Op_Before(), break_out_calls(), build_new_function_call(), build_static_cast(), build_static_cast_1(), c_common_get_alias_set(), c_parser_postfix_expression(), c_qtenscale(), chainon(), check_ivars(), chrec_fold_multiply_poly_poly(), Cmp_FLD_COUNT1(), comp_target_parms(), comp_template_parms(), compare_ics(), compare_names(), complex_divide(), compparms(), comptypes(), comptypes_internal(), compute_overlap_steps_for_affine_1_2(), conditional_conversion(), const_binop(), cris_pic_symbol_type_of(), cwh_get_highest_type(), cwh_stmt_insert_conformance_check(), OPT_FEEDBACK::Delete_node(), duplicate_decls(), elfNN_ia64_install_value(), elfNN_ia64_relax_brl(), execute_stack_op(), Exp_Intrinsic_Op(), expand_complex_div_straight(), expand_complex_div_wide(), expand_complex_multiplication(), Expand_Divide(), expand_divmod(), Expand_DivRem(), expand_expr(), expand_expr_real_1(), Expand_F10_Div_By_Const(), Expand_F4_Div_By_Const(), Expand_F8_Div_By_Const(), Expand_Fast_Power_Of_2_Rem(), Expand_Float_Div_By_Pow2(), Expand_Intel_F10_Sqrt(), Expand_Intel_Max_Thr_F10_Divide(), Expand_Intel_Max_Thr_F4_Divide(), Expand_Intel_Max_Thr_F4_Sqrt(), Expand_Intel_Max_Thr_F8_Divide(), Expand_Intel_Max_Thr_F8_Sqrt(), Expand_Intel_Min_Lat_F10_Divide(), Expand_Intel_Min_Lat_F4_Divide(), Expand_Intel_Min_Lat_F4_Sqrt(), Expand_Intel_Min_Lat_F8_Divide(), Expand_Intel_Min_Lat_F8_Sqrt(), Expand_Multiply(), Expand_Power_Of_2_Divide(), Expand_Power_Of_2_Rem(), expand_sync_fetch_operation(), expand_sync_operation(), expand_twoval_binop(), expand_twoval_unop(), extract_muldiv_1(), fei_mask(), fei_mvbits(), fei_new_binop_cshift(), interference_cache::find_interference_from_edge(), finish_struct(), fold(), fold_binary(), fold_unary(), gen_tablejump_mips161(), gen_tablejump_mips162(), get_base_and_offset(), gimple_tree_eq(), gimplify_self_mod_expr(), GTY(), FB_CFG::Guess_unknowns(), htab_mod_1(), i960_va_arg(), ia64_expand_vecint_compare(), ia64_sched_init(), Identical_Array_Refbase(), identical_stmt_lists_p(), initialize_trampoline(), interface_strcmp(), iv_number_of_iterations(), ix86_expand_int_vcond(), joust(), legitimize_tls_address(), lower_bit_field_id(), maybe_both_true_1(), multiple_of_p(), nodes_identical(), omp_get_wtick(), ppc_elf_relocate_section(), print_insn_ia64(), print_pattern(), RSolve(), Select_Best_Fld_Path(), Similar_BE_Types(), store_bindings(), Targ_WhirlOp(), test_significance(), type_hash_canon(), type_list_equal(), typename_compare(), unify(), MA_OFFSET::Union(), unwind_table_entry_compare(), verify_class_type(), vho_lower_if(), WFE_Add_Aggregate_Init_Complex(), WFE_Add_Aggregate_Init_Real(), WFE_Expand_Stmt(), AGGINIT::WGEN_Add_Aggregate_Init_Complex(), and WGEN_Expand_Stmt().

#define T3D   10

Definition at line 73 of file mpp_sim.c.

#define T3D_AHDR_SIZE   174*8

Definition at line 2672 of file mpp_sim.c.

Referenced by open_intrinsics_file().

#define T3E   12

Definition at line 74 of file mpp_sim.c.

#define T3E_DSIB_LOC   (MPP_STACK_SIZE + (MPP_MAX_ARGS * 5))

Referenced by ar_sim().

#define v0   0

#define zero   31


Enumeration Type Documentation

enum SegTypes

Enumerator:
SEGT_DATA 
SEGT_TEXT 
SEGT_REGISTERS 
SEGT_STACK 
SEGT_EREGISTERS 
SEGT_BESUS 

Definition at line 245 of file mpp_sim.c.


Function Documentation

int ar_clear_sim_state ( AR_TYPE  resulttype  ) 

int ar_ext_address ( AR_INT_64 intaddr,
const char *  extaddr,
int  length 
)

int ar_get_function_value ( ar_data result,
AR_TYPE resulttype 
)

int ar_pass_arg_address ( const ar_data arg,
const AR_TYPE argtype 
)

int ar_pass_arg_value ( const ar_data arg,
const AR_TYPE argtype 
)

int ar_pass_ext_address ( AR_INT_64 extdesc,
const char *  addr,
int  nwords 
)

int ar_pass_fcd_address ( const char *  str,
long  lenstr 
)

int ar_put_real_address ( AR_INT_64 extdesc  ) 

int ar_sim ( char *  intrinsic  ) 

Definition at line 887 of file mpp_sim.c.

References __LINE__, A, ADD64, AMASK, ar_c1frecip(), ar_cfadd64(), ar_cfmul64(), ar_cfsub64(), ar_check_status(), AR_compare(), AR_Compare_EQ, AR_Compare_GT, AR_Compare_LT, AR_Compare_Unord, ar_convert_to_float(), AR_CRAY_FLOATING_POINT, AR_ERROR_STATUS, ar_ext_address(), ar_state_info::ar_float_format, AR_Float_IEEE_NR_32, AR_Float_IEEE_ZE_32, AR_IEEE_FLOATING_POINT, ar_ifadd64(), ar_ifcmp64(), ar_ifdiv64(), ar_ifix64(), ar_iflt64(), ar_ifmul64(), ar_ifsub64(), ar_imul64u(), ar_internal_error(), ar_isqrt64(), ar_mach_type, AR_RECIPROCAL_ITERATION, AR_ROUND_NEAREST, AR_ROUND_ZERO, AR_ROUNDED, ar_state_info::ar_rounding_mode, ar_sim_version, ar_sqrt(), AR_STAT_NEGATIVE, AR_STAT_OK, AR_STAT_OVERFLOW, AR_STAT_UNDEFINED, AR_STAT_ZERO, ar_state_register, ar_state_info::ar_truncate_bits, AR_UNROUNDED, i64_union::ari64, ARITHERR, ASB, B, BADINSTR, call_host_external(), ci, COPY64, D_float_32, D_roundmode, DISASM0, DISASM1, DISASM2, DISASM3, DISASM4, DISASM5, DISASMB, DISASMT, DISASMV, errno, EXTERROR, fp, func, fzero, getp1, HOSTEXT, I, i, ieee_float_32, ieee_float_64, IFACEERR, int64, Internal, INTERRUPT_DIV, INTERRUPT_INP, INTERRUPT_INV, INTERRUPT_INX, INTERRUPT_OVF, INTERRUPT_UNF, IS_ERROR_STATUS, isalnum(), J, JSZP, i64_union::l64, load_mpp_word(), load_pvp_word(), memset, MPP_DSIB_SIZE, MPP_STACK_SIZE, n, NEG64, NOINTRIN, NOT64, numargs, numargwds, offset, ok(), one, p1, p2, AR_INT_64::part1, AR_INT_64::part2, AR_INT_64::part3, AR_INT_64::part4, pc, prefix, prefix_check, PRINTMSG(), rc, ret, RMMASK, RN, rr, S, s0, SETERRNO, SHLEFT64, SHLEFT64N, SHRIGHT64, SHRIGHT64N, sp, SR0, stack_segment_id, STACK_SIZE, store_mpp_word(), store_pvp_word(), str, T, t1, T3D, T3E_DSIB_LOC, T90, toupper(), UNIMPL_INST, UNIMPL_PRFX, V, v0, VL, VM, VM1, VSZ, zero, and ZERO64.

static int call_host_external ( char *  func  )  [static]

Definition at line 870 of file mpp_sim.c.

References a0, ar_ext_address(), AR_STAT_UNDEFINED, length, malloc, AR_INT_64::part3, strncmp(), and v0.

static void load_mpp_word ( AR_INT_64 result,
long  segment,
long  offset 
) [static]

static void open_intrinsics_file ( void   )  [static]

static void store_mpp_word ( long  segment,
long  offset,
AR_INT_64 result 
) [static]


Variable Documentation

char AR_libmv2[]

Definition at line 39 of file edition.c.

int ar_mach_type = T3D [static]

Definition at line 77 of file mpp_sim.c.

int ar_rounding_modes = 1<<AR_ROUND_NEAREST

Definition at line 60 of file mpp_sim.c.

int ar_sim_version = 0 [static]

Definition at line 76 of file mpp_sim.c.

int ar_underflow_modes = 1<<AR_UNDERFLOW_TO_PLUS_ZERO

Definition at line 61 of file mpp_sim.c.

char AR_version[]

Definition at line 38 of file edition.c.

unsigned char* code = NULL [static]

Definition at line 96 of file mpp_sim.c.

unsigned code_segment_id [static]

Definition at line 238 of file mpp_sim.c.

Referenced by ar_ext_address(), and open_intrinsics_file().

AR_TYPE D_float_128 [static]

AR_TYPE D_float_32 [static]

Definition at line 102 of file mpp_sim.c.

Referenced by ar_clear_sim_state(), ar_pass_arg_address(), ar_pass_arg_value(), and ar_sim().

AR_TYPE D_float_64 [static]

int D_roundmode = -1 [static]

Definition at line 100 of file mpp_sim.c.

Referenced by ar_clear_sim_state(), ar_pass_arg_address(), ar_pass_arg_value(), and ar_sim().

unsigned char* data = NULL [static]

Definition at line 97 of file mpp_sim.c.

long data_offset [static]

Definition at line 2684 of file mpp_sim.c.

unsigned data_segment_id [static]

Definition at line 239 of file mpp_sim.c.

Referenced by ar_ext_address(), load_mpp_word(), open_intrinsics_file(), and store_mpp_word().

char* external_address[MAX_EXT_ADDRS] [static]

Definition at line 254 of file mpp_sim.c.

long external_length[MAX_EXT_ADDRS] [static]

Definition at line 255 of file mpp_sim.c.

AR_INT_64 F[32] [static]

Definition at line 111 of file mpp_sim.c.

int idf_fd [static]

Definition at line 2681 of file mpp_sim.c.

long idf_size [static]

Definition at line 2682 of file mpp_sim.c.

AR_TYPE ieee_float_32 = (AR_TYPE) IEEE_FLOAT_32 [static]

Definition at line 80 of file mpp_sim.c.

Referenced by ar_pass_arg_value(), and ar_sim().

AR_TYPE ieee_float_64 = (AR_TYPE) IEEE_FLOAT_64 [static]

Definition at line 81 of file mpp_sim.c.

AR_TYPE integer_64 = AR_Int_64_S [static]

Definition at line 79 of file mpp_sim.c.

Referenced by ar_get_function_value(), and ar_pass_arg_value().

unsigned char* mpp_intrin = NULL [static]

Definition at line 95 of file mpp_sim.c.

Referenced by ar_clear_sim_state(), and open_intrinsics_file().

int n_external_addresses = 1 [static]

Definition at line 233 of file mpp_sim.c.

AR_HOST_SINT64 numargs = 0 [static]

Definition at line 231 of file mpp_sim.c.

AR_INT_64 R[32] [static]

Definition at line 110 of file mpp_sim.c.

char rcsid[] = "$Id: mpp_sim.c,v 1.1.1.1 2005/10/21 19:00:00 marcel Exp $" [static]

Definition at line 3077 of file mpp_sim.c.

unsigned char* stack = NULL [static]

Definition at line 98 of file mpp_sim.c.

unsigned stack_segment_id [static]

long text_size [static]

Definition at line 2683 of file mpp_sim.c.

char USMID[] = "\n%Z%%M% %I% %G% %U%\n" [static]

Definition at line 3076 of file mpp_sim.c.


Generated on Wed Apr 8 14:24:29 2009 for Open64 by  doxygen 1.5.6