osprey/kgccfe/wfe_expr.cxx File Reference

#include <values.h>
#include "defs.h"
#include "glob.h"
#include "config.h"
#include "wn.h"
#include "wn_util.h"
#include "targ_sim.h"
#include "const.h"
#include "c_int_model.h"
#include "gnu_config.h"
#include "gnu/flags.h"
#include "gnu/system.h"
#include "gnu/machmode.h"
#include "gnu/tree.h"
#include "gnu/function.h"
#include "ir_reader.h"
#include "tree_symtab.h"
#include "wfe_misc.h"
#include "wfe_decl.h"
#include "wfe_expr.h"
#include "wfe_stmt.h"
#include <cmplrs/rcodes.h>
#include "config_asm.h"
#include "tree_cmp.h"

Include dependency graph for wfe_expr.cxx:

Go to the source code of this file.

Data Types

type  operator_from_tree_t
type  wfe_bind_expr_t
type  wfe_save_expr_t

Typedefs

typedef struct wfe_bind_expr_t WFE_BIND_EXPR
typedef struct wfe_save_expr_t WFE_SAVE_EXPR

Functions/Subroutines

void warning (char *,...)
tree c_strlen_exported (tree)
void dump_ty_idx (TY_IDX)
int get_expr_stmts_for_value (void)
bool Has_Subsumed_Cvtl (OPERATOR opr)
UINT64 Parameter_Size (UINT64 sz)
TYPE_ID Widen_Mtype (TYPE_ID t)
void WFE_Set_ST_Addr_Saved (WN *wn)
void WFE_Expand_Start_Stmt_Expr (tree t)
void WFE_Expand_End_Stmt_Expr (tree t)
static WNWFE_Save_Expr (tree save_exp)
static void WFE_Unsave_Expr (tree save_exp)
static WNWFE_Array_Expr (tree exp, TY_IDX *ty_idx, TY_IDX component_ty_idx, INT64 component_offset, UINT32 field_id)
WNWFE_Lhs_Of_Modify_Expr (tree_code assign_code, tree lhs, bool need_result, TY_IDX component_ty_idx, INT64 component_offset, UINT32 field_id, bool is_bit_field, WN *rhs_wn, PREG_NUM rhs_preg_num, bool is_realpart, bool is_imagpart)
WNWFE_Expand_Expr_With_Sequence_Point (tree exp, TYPE_ID mtype)
static void emit_barrier (bool type, tree list, INT32 k)
static WNemit_builtin_lock_test_and_set (tree exp, INT32 k)
static void emit_builtin_lock_release (tree exp, INT32 k)
static WNemit_builtin_compare_and_swap (tree exp, INT32 k)
static void emit_builtin_synchronize (tree exp, INT32 k)
static char * get_string_pointer (WN *wn)
WNWFE_Expand_Expr (tree exp, bool need_result, TY_IDX nop_ty_idx, TY_IDX component_ty_idx, INT64 component_offset, UINT16 field_id, bool is_bit_field, bool expect_boolean)
void WFE_One_Stmt (tree exp)
void WFE_Null_Return (void)
UINT64 Get_Integer_Value (tree exp)
void WFE_Expr_Init (void)
char * WFE_Tree_Node_Name (tree op)

Variables

PREG_NUM asm_neg_preg
struct operator_from_tree_t Operator_From_Tree []
WFE_BIND_EXPRwfe_bind_expr_stack = NULL
INT32 wfe_bind_expr_stack_last = -1
INT32 wfe_bind_expr_stack_max = 0
WFE_SAVE_EXPRwfe_save_expr_stack = NULL
INT32 wfe_save_expr_stack_last = -1
INT32 wfe_save_expr_stack_max = 0


Typedef Documentation


Function Documentation

tree c_strlen_exported ( tree   ) 

Referenced by WFE_Expand_Expr().

void dump_ty_idx ( TY_IDX   ) 

Definition at line 2283 of file symtab.cxx.

References dump_ty().

static void emit_barrier ( bool  type,
tree  list,
INT32  k 
) [static]

static WN* emit_builtin_compare_and_swap ( tree  exp,
INT32  k 
) [static]

static void emit_builtin_lock_release ( tree  exp,
INT32  k 
) [static]

static WN* emit_builtin_lock_test_and_set ( tree  exp,
INT32  k 
) [static]

static void emit_builtin_synchronize ( tree  exp,
INT32  k 
) [static]

int get_expr_stmts_for_value ( void   ) 

Referenced by WFE_One_Stmt().

UINT64 Get_Integer_Value ( tree  exp  ) 

Definition at line 8600 of file wfe_expr.cxx.

References FmtAssert, h, TREE_CODE, TREE_INT_CST_HIGH, TREE_INT_CST_LOW, and UINT64.

static char* get_string_pointer ( WN wn  )  [static]

bool Has_Subsumed_Cvtl ( OPERATOR  opr  ) 

UINT64 Parameter_Size ( UINT64  sz  )  [inline]

Definition at line 697 of file wfe_expr.cxx.

References UNITS_PER_WORD.

void warning ( char *  ,
  ... 
)

Definition at line 122 of file errors.c.

References args, fprintf(), print_warnings, program_name, va_end, va_start, and vfprintf().

static WN* WFE_Array_Expr ( tree  exp,
TY_IDX ty_idx,
TY_IDX  component_ty_idx,
INT64  component_offset,
UINT32  field_id 
) [static]

void WFE_Expand_End_Stmt_Expr ( tree  t  ) 

WN* WFE_Expand_Expr ( tree  exp,
bool  need_result,
TY_IDX  nop_ty_idx,
TY_IDX  component_ty_idx,
INT64  component_offset,
UINT16  field_id,
bool  is_bit_field,
bool  expect_boolean 
)

Definition at line 3751 of file wfe_expr.cxx.

References access, addr(), Aggregate_Alignment, align, asm_neg_preg, Be_Type_Tbl, BITS_PER_UNIT, wfe_bind_expr_t::block, BOOL, Boolean_type, build_new_1(), BUILT_IN_MD, c_strlen_exported(), CASE_LABEL, CLASS_CONST, CLASS_VAR, Classify_Aggregate(), comma, cond, Create_Preg(), current_function_calls_longjmp, current_function_calls_setjmp, current_function_decl, CURRENT_SYMTAB, DECL_ARGUMENTS, DECL_BIT_FIELD, DECL_BUILT_IN, DECL_BUILT_IN_CLASS, DECL_FIELD_BIT_OFFSET, DECL_FIELD_ID(), DECL_FIELD_OFFSET, DECL_FUNCTION_CODE, DECL_INITIAL, DECL_INLINE, DECL_NAME, DECL_SIZE, DECL_ST2(), DevWarn, dst, ECF_MALLOC, ECF_NORETURN, ECF_PURE, emit_builtin_compare_and_swap(), emit_builtin_lock_release(), emit_builtin_lock_test_and_set(), emit_builtin_synchronize(), END_BUILTINS, Enter_tcon(), error_mark_node, exit(), EXPORT_LOCAL, Fail_FmtAssertion(), FALSE, Fatal_Error(), fdump_tree(), FE_Pointer_Type_To_Mtype(), Fix_TY_mtype(), flag_errno_math, flags, flags_from_decl_or_type(), FLD_type, FmtAssert, Force_IEEE_Comparisons, fprintf(), free(), Gen_Temp_Symbol(), Get_Current_PU, Get_Current_PU_ST, get_field_type(), Get_Integer_Value(), Get_ST, get_string_pointer(), Get_TY(), Has_Subsumed_Cvtl(), high, Host_Byte_Sex, Host_To_Targ_Complex(), Host_To_Targ_Complex_10(), Host_To_Targ_Complex_4(), Host_To_Targ_Complex_Quad(), Host_To_Targ_Float(), Host_To_Targ_Float_10(), Host_To_Targ_Float_4(), Host_To_Targ_Quad(), Host_To_Targ_String(), IDENTIFIER_POINTER, Index_To_Str(), init_expr(), INT, INT32, INT64, int_size_in_bytes(), INTRINSIC_NONE, INTRN_BZERO, INTRN_F4COS, INTRN_F4EXP, INTRN_F4SIN, INTRN_F8COS, INTRN_F8EXP, INTRN_F8EXPEXPR, INTRN_F8SIN, INTRN_FMERGE_NS, INTRN_FMERGE_S, INTRN_FMERGE_SE, INTRN_GETF_EXP, INTRN_GETF_SIG, INTRN_I4FFS, INTRN_MEMCMP, INTRN_MEMCPY, INTRN_MEMSET, INTRN_SETF_EXP, INTRN_SETF_SIG, INTRN_STRCMP, INTRN_STRCPY, INTRN_STRLEN, INTRN_STRNCPY, Is_Target_32bit, Is_True, KIND_POINTER, KIND_STRUCT, Label_Name_Separator, LANG_Ansi_Setjmp_On, last, len, lineno, load(), loop_nest, low, Make_Pointer_Type(), malloc, MAX_CLASSES, MAX_FIELD_ID, MTYPE_align_best, Mtype_AlignmentClass(), MTYPE_B, MTYPE_bit_size, MTYPE_BS, MTYPE_byte_size, MTYPE_C10, MTYPE_C4, MTYPE_C8, MTYPE_CLASS_INTEGER, MTYPE_CLASS_UNSIGNED_INTEGER, Mtype_comparison(), MTYPE_complement, Mtype_complex_to_real(), MTYPE_CQ, MTYPE_F10, MTYPE_F4, MTYPE_F8, MTYPE_float, MTYPE_FQ, MTYPE_I1, MTYPE_I4, MTYPE_I8, MTYPE_is_complex, MTYPE_is_integral, MTYPE_is_signed, MTYPE_is_size_double, MTYPE_is_vector, MTYPE_is_void, MTYPE_M, MTYPE_signed, MTYPE_size_min, MTYPE_STRING, MTYPE_To_PREG, MTYPE_To_TY, Mtype_TransferSign(), MTYPE_type_class, MTYPE_U1, MTYPE_U4, MTYPE_U8, MTYPE_UNKNOWN, MTYPE_V, mUINT16, mUINT32, mUINT64, n, New_Const_Sym(), New_LABEL(), New_ST(), New_TY(), NULL, OPC_I4INTCONST, OPC_I4U4CVT, OPC_I8U8CVT, OPC_U4I4CVT, OPC_U8I8CVT, OPCODE_is_leaf(), OPCODE_is_load(), Operator_From_Tree, OPR_ADD, OPR_ASHR, OPR_BAND, OPR_CALL, OPR_CEIL, OPR_COMMA, OPR_COMPLEX, OPR_CONST, OPR_CSELECT, OPR_CVT, OPR_CVTL, OPR_EVAL, OPR_FLOOR, OPR_HIGHMPY, OPR_ICALL, OPR_ILDBITS, OPR_ILOAD, OPR_IMAGPART, OPR_INTCONST, OPR_INTRINSIC_CALL, OPR_INTRINSIC_OP, OPR_ISTORE, OPR_LDA, OPR_LDBITS, OPR_LDID, OPR_LSHR, OPR_MAX, OPR_MIN, OPR_MPY, OPR_NEG, OPR_REALPART, OPR_RND, OPR_RSQRT, OPR_SHL, OPR_SQRT, OPR_SUB, OPR_TRUNC, Opt_Level, Parameter_Size(), PARM_BOUNDARY, PF_SET_MANUAL, PF_SET_READ, PF_SET_WRITE, Pointer_Mtype, printf(), PU_is_nested_func(), Pu_Table, RC_USER_ERROR, REAL_VALUE_TO_TARGET_DOUBLE, REAL_VALUE_TO_TARGET_LONG_DOUBLE, REAL_VALUE_TO_TARGET_SINGLE, REAL_VALUE_TYPE, really_constant_p(), Return_Val_Preg, wfe_bind_expr_t::rtl_expr, Save_Str(), Save_Str2(), SCLASS_AUTO, Set_LABEL_addr_saved(), Set_PU_calls_longjmp(), Set_PU_calls_setjmp(), Set_PU_has_alloca(), Set_PU_has_user_alloca(), Set_PU_has_very_high_whirl(), Set_PU_is_pure(), Set_PU_no_inline(), Set_ST_addr_passed(), Set_ST_addr_saved(), Set_ST_is_temp_var, Set_ST_name_idx(), Set_TY_align, Set_TY_is_volatile, size, Spill_Int_Mtype, Spill_Int_Type, ST_assigned_to_dedicated_preg(), ST_base, ST_class, ST_export, ST_Init(), ST_name, ST_ofst, ST_pu(), ST_size, ST_st_idx, ST_tcon, ST_type, store(), strcmp(), STRIP_NOPS, Targ_String_Address(), Targ_String_Length(), TARGET_64BIT, Target_Byte_Sex, Tcon_Table, TCON_ty, TREE_CHAIN, TREE_CODE, TREE_IMAGPART, TREE_INT_CST_LOW, tree_last(), TREE_OPERAND, TREE_PURPOSE, TREE_READONLY, TREE_REAL_CST, TREE_REALPART, TREE_SIDE_EFFECTS, TREE_STRING_LENGTH, TREE_STRING_POINTER, TREE_STRING_ST(), TREE_THIS_VOLATILE, TREE_TYPE, TREE_VALUE, TRUE, TY_align, TY_fld, TY_Init(), TY_kind, TY_mtype, TY_name_idx(), TY_pointed, TY_size, Ty_Table, TYPE_ALIGN, TYPE_ID, TYPE_SIZE, UINT, UINT32, UINT64, warning, WFE_Add_Case_Node(), WFE_add_pragma_to_enclosing_regions(), WFE_Array_Expr(), WFE_Convert_Internal_Real_to_IEEE_Double(), WFE_Convert_Internal_Real_to_IEEE_Double_Extended(), WFE_Convert_Internal_Real_to_IEEE_Single(), WFE_Decl(), Wfe_Expand_Asm_Operands(), WFE_Expand_Computed_Goto(), WFE_Expand_Continue_Loop(), WFE_Expand_End_Case(), WFE_Expand_End_Cond(), WFE_Expand_End_Loop(), WFE_Expand_Exit_Loop_If_False(), WFE_Expand_Exit_Something(), WFE_Expand_Expr(), WFE_Expand_Expr_With_Sequence_Point(), WFE_Expand_Goto(), WFE_Expand_Label(), WFE_Expand_Loop_Continue_Here(), WFE_Expand_Return(), WFE_Expand_Start_Case(), WFE_Expand_Start_Cond(), WFE_Expand_Start_Else(), WFE_Expand_Start_Loop(), WFE_Expand_Start_Loop_Continue_Elsewhere(), WFE_Generate_Temp_For_Initialized_Aggregate(), WFE_Get_LABEL(), WFE_Get_Return_Address_ST(), wfe_invoke_inliner, WFE_Keep_Zero_Length_Structs, WFE_Lhs_Of_Modify_Expr(), WFE_Null_Return(), WFE_One_Stmt(), WFE_Record_Switch_Default_Label(), WFE_Save_Expr(), WFE_Set_ST_Addr_Saved(), WFE_Stmt_Append(), WFE_Stmt_Pop(), WFE_Stmt_Push(), WFE_Unsave_Expr(), WFE_Vararg_Start_ST, Widen_Mtype(), WN_Add, WN_Binary(), WN_COPY_Tree(), WN_CopyNode(), WN_Create(), WN_Create_Intrinsic, WN_CreateAlloca(), WN_CreateBlock, WN_CreateComma, WN_CreateConst, WN_CreateCvtl, WN_CreateDealloca(), WN_CreateEval, WN_CreateExp1, WN_CreateExp2, WN_CreateExp3, WN_CreateIf, WN_CreateIload, WN_CreateIntconst, WN_CreateIstore, WN_CreateLabel, WN_CreateLdid, WN_CreateMload, WN_CreateMstore, WN_CreateParm, WN_CreatePrefetch, WN_Cvt(), WN_Delete, WN_DELETE_FromBlock(), WN_desc(), WN_Div, WN_field_id(), WN_has_side_effects(), WN_has_sym, WN_Iload(), WN_INSERT_BlockLast, WN_Intconst(), WN_intrinsic(), WN_Istore(), WN_kid(), WN_kid0(), WN_kid1(), WN_kid2(), WN_last(), WN_Lda(), WN_LdaLabel(), WN_Ldid(), WN_LdidPreg(), WN_load_addr_ty(), WN_load_offset(), WN_Mpy, WN_offset(), WN_opcode(), WN_operator(), WN_PARM_BY_VALUE, WN_PRAGMA_LOCAL, WN_Rrotate(), WN_rtype(), WN_set_bit_offset_size(), WN_Set_Call_Default_Flags, WN_set_desc(), WN_set_field_id(), WN_Set_Linenum(), WN_set_load_addr_ty(), WN_set_operator(), WN_set_rtype(), WN_set_ty(), WN_st(), WN_st_idx(), WN_Stid(), WN_Tas(), WN_Trunc(), WN_ty(), WN_Unary(), X86_64_INTEGER_CLASS, and X86_64_SSE_CLASS.

WN* WFE_Expand_Expr_With_Sequence_Point ( tree  exp,
TYPE_ID  mtype 
)

void WFE_Expand_Start_Stmt_Expr ( tree  t  ) 

Definition at line 862 of file wfe_expr.cxx.

References WFE_Stmt_Push(), and WN_CreateBlock.

void WFE_Expr_Init ( void   ) 

Definition at line 8622 of file wfe_expr.cxx.

References FmtAssert, INT, and Operator_From_Tree.

WN* WFE_Lhs_Of_Modify_Expr ( tree_code  assign_code,
tree  lhs,
bool  need_result,
TY_IDX  component_ty_idx,
INT64  component_offset,
UINT32  field_id,
bool  is_bit_field,
WN rhs_wn,
PREG_NUM  rhs_preg_num,
bool  is_realpart,
bool  is_imagpart 
)

void WFE_Null_Return ( void   ) 

Definition at line 8593 of file wfe_expr.cxx.

References WFE_Stmt_Append(), and WN_CreateReturn.

void WFE_One_Stmt ( tree  exp  ) 

static WN* WFE_Save_Expr ( tree  save_exp  )  [static]

void WFE_Set_ST_Addr_Saved ( WN wn  ) 

char* WFE_Tree_Node_Name ( tree  op  ) 

Definition at line 8631 of file wfe_expr.cxx.

References operator_from_tree_t::name, Operator_From_Tree, and TREE_CODE.

static void WFE_Unsave_Expr ( tree  save_exp  )  [static]

TYPE_ID Widen_Mtype ( TYPE_ID  t  ) 


Variable Documentation

Definition at line 857 of file wfe_expr.cxx.

Definition at line 858 of file wfe_expr.cxx.

Definition at line 859 of file wfe_expr.cxx.

Definition at line 898 of file wfe_expr.cxx.

Definition at line 899 of file wfe_expr.cxx.

Definition at line 900 of file wfe_expr.cxx.


Generated on Wed Apr 8 15:48:46 2009 for Open64 by  doxygen 1.5.6