Open64 (mfef90, whirl2f, and IR tools)  TAG: version-openad; SVN changeset: 916
stab_attr.cxx File Reference
#include "whirl2c_common.h"
#include "const.h"
#include "PUinfo.h"
#include "cxx_memory.h"
#include "unparse_target.h"
Include dependency graph for stab_attr.cxx:

Go to the source code of this file.

Classes

class  W2FC_FLAG_ARRAY
struct  TmpVarInfo

Defines

#define MIN_NAME_SLOTS   8
#define MIN_NAME_BUF_SIZE   1024
#define MAX_NUMSTRING_SIZE   128
#define TMPVAR_ALLOC_INCREMENTS   32

Typedefs

typedef struct TmpVarInfo TMPVARINFO

Enumerations

enum  W2FC_FLAGS { W2FC_TY_TRANS = 0x02 }

Functions

BOOL Stab_Reserved_Ty (TY_IDX ty)
BOOL Stab_Reserved_St (const ST *st)
void Stab_Reset_Referenced_Flag (SYMTAB_IDX symtab)
void Set_TY_is_translated_to_c (const TY_IDX ty)
void Reset_TY_is_translated_to_c (const TY_IDX ty)
BOOL TY_is_translated_to_c (const TY_IDX ty)
void Clear_w2fc_flags (void)
static BOOL Stab_Compare_Types (TY_IDX t1, TY_IDX t2, BOOL check_quals, BOOL check_pointed_quals, BOOL check_scalars, BOOL ptrs_as_scalars, BOOL assign_t2_to_t1)
BOOL Stab_Identical_Types (TY_IDX t1, TY_IDX t2, BOOL check_quals, BOOL check_scalars, BOOL ptrs_as_scalars)
BOOL Stab_Assignment_Compatible_Types (TY_IDX t1, TY_IDX t2, BOOL check_quals, BOOL check_scalars, BOOL ptrs_as_scalars)
BOOL Stab_Array_Has_Dynamic_Bounds (TY_IDX ty)
BOOL Stab_Is_Assumed_Sized_Array (TY_IDX ty)
BOOL Stab_Is_Element_Type_Of_Array (TY_IDX atype, TY_IDX etype)
BOOL Stab_Is_Equivalenced_Struct (TY_IDX ty)
TY_IDX Stab_Get_Mload_Ty (TY_IDX base, STAB_OFFSET offset, STAB_OFFSET size)
TY_IDX Stab_Array_Of (TY_IDX etype, mINT64 num_elts)
void Stab_initialize_flags (void)
void Stab_finalize_flags (void)
void Stab_initialize (void)
void Stab_finalize (void)
void Stab_Free_Namebufs (void)
char * Get_Name_Buf_Slot (UINT size)
const char * Number_as_String (INT64 number, const char *fmt)
const char * Ptr_as_String (const void *ptr)
const char * Concat2_Strings (const char *name1, const char *name2)
UINT64 Get_Hash_Value_For_Name (const char *name)
STAB_OFFSET Stab_Full_Split_Offset (const ST *split_out_st)
void Stab_Free_Tmpvars (void)
UINT Stab_Lock_Tmpvar (TY_IDX ty, void(*declare_tmpvar)(TY_IDX, UINT))
void Stab_Unlock_Tmpvar (UINT idx)

Variables

static W2FC_FLAG_ARRAYW2fc_ty_tab
static char * Name_Buf
static UINT Name_Buf_Idx = 0
static UINT Name_Buf_Size = 0
static char * buffer_to_be_freed [MIN_NAME_SLOTS]
static UINT next_delay_slot = 0
static UINT delay_count [MIN_NAME_SLOTS] = {0, 0, 0, 0, 0, 0, 0, 0}
static INT next_to_be_freed = -1
static TMPVARINFOTmpVar = NULL
static INT Next_Tmpvar_Idx = 0
static INT Max_Tmpvar_Idx = -1

Define Documentation

#define MAX_NUMSTRING_SIZE   128

Definition at line 663 of file stab_attr.cxx.

Referenced by Number_as_String(), and Ptr_as_String().

#define MIN_NAME_BUF_SIZE   1024

Definition at line 662 of file stab_attr.cxx.

Referenced by Get_Name_Buf_Slot().

#define MIN_NAME_SLOTS   8

Definition at line 661 of file stab_attr.cxx.

Referenced by Get_Name_Buf_Slot(), and Stab_Free_Namebufs().

#define TMPVAR_ALLOC_INCREMENTS   32

Definition at line 882 of file stab_attr.cxx.

Referenced by Stab_Lock_Tmpvar().


Typedef Documentation

typedef struct TmpVarInfo TMPVARINFO

Enumeration Type Documentation

enum W2FC_FLAGS
Enumerator:
W2FC_TY_TRANS 

Definition at line 126 of file stab_attr.cxx.


Function Documentation

void Clear_w2fc_flags ( void  )

Definition at line 210 of file stab_attr.cxx.

References W2FC_FLAG_ARRAY::Clear_w2fc_flags().

Referenced by Stab_Reset_Referenced_Flag(), W2F_Outfile_Fini(), and W2F_Push_PU().

Here is the call graph for this function:

const char* Ptr_as_String ( const void *  ptr)

Definition at line 772 of file stab_attr.cxx.

References FALSE, Get_Name_Buf_Slot(), Is_True, and MAX_NUMSTRING_SIZE.

Referenced by WN2C_prefetch(), WN2C_Prefetch_Map(), WN2F_Append_Prefetch_Map(), and WN2F_prefetch().

Here is the call graph for this function:

Definition at line 389 of file stab_attr.cxx.

References TRUE, TY_AR_const_lbnd(), TY_AR_const_stride(), TY_AR_const_ubnd(), and TY_AR_ndims().

Referenced by TY2C_array(), and WN2C_array().

Here is the call graph for this function:

BOOL Stab_Assignment_Compatible_Types ( TY_IDX  t1,
TY_IDX  t2,
BOOL  check_quals,
BOOL  check_scalars,
BOOL  ptrs_as_scalars 
)

Definition at line 373 of file stab_attr.cxx.

References FALSE, Stab_Compare_Types(), and TRUE.

Referenced by Stab_Is_Element_Type_Of_Array().

Here is the call graph for this function:

void Stab_finalize_flags ( void  )

Definition at line 592 of file stab_attr.cxx.

References CXX_DELETE, and Malloc_Mem_Pool.

Referenced by W2C_Fini(), and W2F_Fini().

Definition at line 850 of file stab_attr.cxx.

References name, and ST_name().

Referenced by WN2C_lvalue_st(), and WN2F_Offset_Symref().

Here is the call graph for this function:

TY_IDX Stab_Get_Mload_Ty ( TY_IDX  base,
STAB_OFFSET  offset,
STAB_OFFSET  size 
)

Definition at line 466 of file stab_attr.cxx.

References FLD_next(), FLD_ofst(), FLD_type(), FLD_HANDLE::Is_Null(), Is_True, size, Stab_Get_Mload_Ty(), TY_flist(), TY_Is_Structured(), TY_Is_Union(), TY_size(), and Ty_Table.

Referenced by Stab_Get_Mload_Ty(), and WN_Tree_Type().

Here is the call graph for this function:

BOOL Stab_Identical_Types ( TY_IDX  t1,
TY_IDX  t2,
BOOL  check_quals,
BOOL  check_scalars,
BOOL  ptrs_as_scalars 
)

Definition at line 358 of file stab_attr.cxx.

References FALSE, and Stab_Compare_Types().

Referenced by Construct_Fld_Path(), INITV2C_symoff(), Select_Best_Fld_Path(), Stab_Lock_Tmpvar(), and TY2C_get_field_info().

Here is the call graph for this function:

void Stab_initialize ( void  )

Definition at line 598 of file stab_attr.cxx.

References ARB_Table_Size(), FLD_Table_Size(), TY_Table_Size(), and TYLIST_Table_Size().

Referenced by W2C_Push_PU(), and W2F_Push_PU().

Here is the call graph for this function:

void Stab_initialize_flags ( void  )

Definition at line 586 of file stab_attr.cxx.

References CXX_NEW, Malloc_Mem_Pool, and TY_Table_Size().

Referenced by W2C_Init(), and W2F_Init().

Here is the call graph for this function:

Definition at line 406 of file stab_attr.cxx.

References ARB_const_lbnd(), ARB_const_ubnd(), ARB_lbnd_val(), ARB_lbnd_var(), ARB_ubnd_val(), ARB_ubnd_var(), FALSE, TRUE, TY_arb(), and TY_Is_Array().

Referenced by TY2F_Translate_Purple_Array().

Here is the call graph for this function:

Definition at line 436 of file stab_attr.cxx.

References FALSE, Stab_Assignment_Compatible_Types(), Stab_Is_Element_Type_Of_Array(), TRUE, TY_AR_etype(), and TY_Is_Array().

Referenced by Stab_Is_Element_Type_Of_Array().

Here is the call graph for this function:

Definition at line 451 of file stab_attr.cxx.

References FALSE, FLD_equivalence(), FLD_last_field(), Make_fld_iter(), TY_flist(), and Ty_Table.

Referenced by TY2C_complete_struct(), TY2C_get_field_info(), and TY2C_struct().

Here is the call graph for this function:

Definition at line 72 of file stab_attr.cxx.

References Unparse_Target::Reserved_St_Name(), ST_name(), and W2X_Unparse_Target.

Referenced by WN2C_Append_Symtab_Vars().

Here is the call graph for this function:

Definition at line 64 of file stab_attr.cxx.

References Unparse_Target::Builtin_Type(), Unparse_Target::Reserved_Ty_Name(), TY_name(), and W2X_Unparse_Target.

Referenced by WN2C_Append_Symtab_Types().

Here is the call graph for this function:


Variable Documentation

Definition at line 669 of file stab_attr.cxx.

Referenced by Get_Name_Buf_Slot(), and Stab_Free_Namebufs().

UINT delay_count[MIN_NAME_SLOTS] = {0, 0, 0, 0, 0, 0, 0, 0} [static]

Definition at line 671 of file stab_attr.cxx.

Referenced by Get_Name_Buf_Slot(), and Stab_Free_Namebufs().

INT Max_Tmpvar_Idx = -1 [static]

Definition at line 885 of file stab_attr.cxx.

Referenced by Stab_Free_Tmpvars(), and Stab_Lock_Tmpvar().

char* Name_Buf [static]

Definition at line 665 of file stab_attr.cxx.

Referenced by Get_Name_Buf_Slot(), and Stab_Free_Namebufs().

UINT Name_Buf_Idx = 0 [static]

Definition at line 666 of file stab_attr.cxx.

Referenced by Get_Name_Buf_Slot(), and Stab_Free_Namebufs().

UINT Name_Buf_Size = 0 [static]

Definition at line 667 of file stab_attr.cxx.

Referenced by Get_Name_Buf_Slot(), and Stab_Free_Namebufs().

UINT next_delay_slot = 0 [static]

Definition at line 670 of file stab_attr.cxx.

Referenced by Get_Name_Buf_Slot(), and Stab_Free_Namebufs().

INT Next_Tmpvar_Idx = 0 [static]

Definition at line 884 of file stab_attr.cxx.

Referenced by Stab_Free_Tmpvars(), Stab_Lock_Tmpvar(), and Stab_Unlock_Tmpvar().

INT next_to_be_freed = -1 [static]

Definition at line 672 of file stab_attr.cxx.

Referenced by Get_Name_Buf_Slot(), and Stab_Free_Namebufs().

TMPVARINFO* TmpVar = NULL [static]

Definition at line 883 of file stab_attr.cxx.

Definition at line 185 of file stab_attr.cxx.

 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines