Open64 (mfef90, whirl2f, and IR tools)
TAG: version-openad; SVN changeset: 916
|
Go to the source code of this file.
Classes | |
struct | pu_info |
Defines | |
#define | PU_HEADER_VERSION 1 |
#define | WT_SYMTAB 0x0 /* symbol table */ |
#define | WT_TREE 0x1 /* WHIRL tree nodes */ |
#define | WT_DEPGRAPH 0x2 /* dependence graph */ |
#define | WT_PREFETCH 0x3 /* prefetch pointers */ |
#define | WT_REGIONS 0x4 /* RID trees */ |
#define | WT_FEEDBACK 0x5 /* feedback data */ |
#define | WT_FREQ 0x6 /* obsolete */ |
#define | WT_AC_INTERNAL 0x7 /* alias classification temporary */ |
#define | WT_ALIAS_CLASS 0x8 /* alias classification */ |
#define | WT_SUBSECTIONS 0x9 /* number of subsection types */ |
#define | WT_PROC_SYM -1 /* special value for proc sym state */ |
#define | PU_HAS_GLOBALS |
#define | PU_HAS_NESTED_PU 0x2 /* has other PU nested under this one */ |
#define | PU_IS_COMPILER_GENERATED 0x4 /* compiler_generated PU */ |
#define | PU_IS_DRA_CLONE 0x8 /* clone generated for reshaped arrays */ |
#define | PU_PREGS_RENUMBERED |
#define | PU_INTERNAL_MASK 0xf0000000 |
#define | PU_DELETED 0x10000000 /* only used internally within IPA */ |
#define | PU_Info_proc_sym(pu) (pu)->proc_sym |
#define | PU_Info_proc_id(pu) (pu)->proc_sym |
#define | PU_Info_subsect_offset(pu, scn) (pu)->subsect[scn].offset |
#define | PU_Info_subsect_size(pu, scn) (pu)->subsect[scn].u.size |
#define | PU_Info_subsect_ptr(pu, scn) (pu)->subsect[scn].u.ptr |
#define | PU_Info_flags(pu) (pu)->flags |
#define | PU_Info_pu_dst(pu) (pu)->pu_dst |
#define | PU_Info_cu_dst(pu) (pu)->cu_dst |
#define | PU_Info_cu_dst(pu) (pu)->cu_dst |
#define | PU_Info_maptab(pu) (pu)->maptab |
#define | PU_Info_next(pu) (pu)->next |
#define | PU_Info_child(pu) (pu)->child |
#define | Set_PU_Info_flags(pu, flag_value) (pu)->flags |= (flag_value) |
#define | Clear_PU_Info_flags(pu, flag_value) (pu)->flags &= ~(flag_value) |
#define | Is_Set_PU_Info_flags(pu, flag_value) ((pu)->flags & (flag_value)) |
#define | PU_Info_state(pu, ndx) (Subsect_State)(((pu)->state >> (((ndx) + 1) << 1)) & 0x3) |
#define | Set_PU_Info_state(pu, ndx, st) |
#define | PU_Info_symtab_ptr(pu) (LOCAL_SYMTAB_HEADER_TABLE *) PU_Info_subsect_ptr((pu), WT_SYMTAB) |
#define | PU_Info_tree_ptr(pu) (WN *)PU_Info_subsect_ptr((pu), WT_TREE) |
#define | PU_Info_depgraph_ptr(pu) (void *)PU_Info_subsect_ptr((pu), WT_DEPGRAPH) |
#define | PU_Info_regions_ptr(pu) (struct region_id *)PU_Info_subsect_ptr((pu), WT_REGIONS) |
#define | PU_Info_feedback_ptr(pu) (void *)PU_Info_subsect_ptr((pu), WT_FEEDBACK) |
#define | PU_Info_frequencies_ptr(pu) (INT32 *) PU_Info_subsect_ptr((pu), WT_FREQ) |
#define | PU_Info_alias_class_ptr(pu) (INT32 *) PU_Info_subsect_ptr((pu), WT_ALIAS_CLASS) |
#define | PU_Info_ac_internal_ptr(pu) (void *) PU_Info_subsect_ptr((pu), WT_AC_INTERNAL) |
#define | Set_PU_Info_tree_ptr(pu, x) PU_Info_subsect_ptr((pu), WT_TREE) = (void *)(x) |
#define | Set_PU_Info_symtab_ptr(pu, x) PU_Info_subsect_ptr((pu), WT_SYMTAB) = (void *)(x) |
#define | Set_PU_Info_depgraph_ptr(pu, x) PU_Info_subsect_ptr((pu), WT_DEPGRAPH) = (void *)(x) |
#define | Set_PU_Info_regions_ptr(pu, x) PU_Info_subsect_ptr((pu), WT_REGIONS) = (void *)(x) |
#define | Set_PU_Info_feedback_ptr(pu, x) PU_Info_subsect_ptr((pu), WT_FEEDBACK) = (void *)(x) |
#define | Set_PU_Info_frequencies_ptr(pu, x) PU_Info_subsect_ptr((pu), WT_FREQ) = (void *) (x) |
#define | Set_PU_Info_alias_class_ptr(pu, x) PU_Info_subsect_ptr((pu), WT_ALIAS_CLASS) = (void *) (x) |
#define | Set_PU_Info_ac_internal_ptr(pu, x) PU_Info_subsect_ptr((pu), WT_AC_INTERNAL) = (void *) (x) |
#define | Set_PU_Info_pu_dst(pu, x) PU_Info_pu_dst(pu) = x; |
#define | Set_PU_Info_cu_dst(pu, x) PU_Info_cu_dst(pu) = x; |
Typedefs | |
typedef struct pu_info | PU_Info |
typedef enum subsect_state | Subsect_State |
Enumerations | |
enum | subsect_state { Subsect_Missing = 0, Subsect_Exists = 1, Subsect_InMem = 2, Subsect_Written = 3 } |
Functions | |
void | PU_Info_init (PU_Info *pu) |
INT | Sizeof_PU_Infos (PU_Info *pu_tree) |
INT | Write_PU_Infos (PU_Info *pu_tree, char *base) |
PU_Info * | Read_PU_Infos (char *base, INT32 size, INT32 *p_num_PUs) |
void | Save_Local_Symtab (SYMTAB_IDX level, PU_Info *pu) |
void | Restore_Local_Symtab (PU_Info *pu) |
Variables | |
PU_Info * | Current_PU_Info |
#define Clear_PU_Info_flags | ( | pu, | |
flag_value | |||
) | (pu)->flags &= ~(flag_value) |
#define Is_Set_PU_Info_flags | ( | pu, | |
flag_value | |||
) | ((pu)->flags & (flag_value)) |
Definition at line 167 of file pu_info.h.
Referenced by Post_LNO_Processing(), and Preprocess_PU().
#define PU_DELETED 0x10000000 /* only used internally within IPA */ |
#define PU_HAS_GLOBALS |
0x1 /* has globals symbols in local symtab, i.e., ST_EXPORT != EXPORT_LOCAL */
Definition at line 91 of file pu_info.h.
Referenced by PDGCS_do_proc().
#define PU_HAS_NESTED_PU 0x2 /* has other PU nested under this one */ |
Definition at line 92 of file pu_info.h.
Referenced by PDGCS_new_proc().
#define PU_HEADER_VERSION 1 |
Definition at line 61 of file pu_info.h.
Referenced by Read_PU_Infos(), and Write_PU_Infos().
#define PU_Info_ac_internal_ptr | ( | pu | ) | (void *) PU_Info_subsect_ptr((pu), WT_AC_INTERNAL) |
#define PU_Info_alias_class_ptr | ( | pu | ) | (INT32 *) PU_Info_subsect_ptr((pu), WT_ALIAS_CLASS) |
#define PU_Info_child | ( | pu | ) | (pu)->child |
Definition at line 163 of file pu_info.h.
Referenced by ir_b2a_process_PUs(), ir_sel(), main(), number_PU_Infos(), PDGCS_new_proc(), Preorder_Process_PUs(), process_pu(), PU_Info_init(), Pu_Next(), read_pu(), Read_PU_Infos(), size_of_each_pu(), write_PU_fields(), and write_PU_subsect_info().
#define PU_Info_cu_dst | ( | pu | ) | (pu)->cu_dst |
Definition at line 160 of file pu_info.h.
Referenced by PU_Info_init().
#define PU_Info_cu_dst | ( | pu | ) | (pu)->cu_dst |
#define PU_Info_depgraph_ptr | ( | pu | ) | (void *)PU_Info_subsect_ptr((pu), WT_DEPGRAPH) |
Definition at line 201 of file pu_info.h.
Referenced by LNO_Processing().
#define PU_Info_feedback_ptr | ( | pu | ) | (void *)PU_Info_subsect_ptr((pu), WT_FEEDBACK) |
Definition at line 205 of file pu_info.h.
Referenced by ir_b2a_process_PUs(), and Preprocess_PU().
#define PU_Info_flags | ( | pu | ) | (pu)->flags |
Definition at line 157 of file pu_info.h.
Referenced by PDGCS_do_proc(), PU_Info_init(), Read_PU_Infos(), and write_PU_fields().
#define PU_Info_frequencies_ptr | ( | pu | ) | (INT32 *) PU_Info_subsect_ptr((pu), WT_FREQ) |
#define PU_Info_maptab | ( | pu | ) | (pu)->maptab |
Definition at line 161 of file pu_info.h.
Referenced by DRA_Add_Clone(), Free_Local_Info(), number_PU_Infos(), PDGCS_new_proc(), Postprocess_PU(), Preprocess_PU(), PU_Info_init(), Read_Local_Info(), WN_get_prefetch(), WN_get_tree(), write_PU_fields(), and Write_PU_Info().
#define PU_Info_next | ( | pu | ) | (pu)->next |
Definition at line 162 of file pu_info.h.
Referenced by DRA_Add_Clone(), ir_b2a_process_PUs(), ir_sel(), main(), number_PU_Infos(), PDGCS_new_proc(), Preorder_Process_PUs(), process_pu(), PU_Info_init(), Pu_Next(), read_pu(), Read_PU_Infos(), size_of_each_pu(), write_pu(), write_PU_fields(), and write_PU_subsect_info().
#define PU_Info_proc_id | ( | pu | ) | (pu)->proc_sym |
Definition at line 143 of file pu_info.h.
Referenced by PU_Info_init(), and Read_PU_Infos().
#define PU_Info_proc_sym | ( | pu | ) | (pu)->proc_sym |
Definition at line 142 of file pu_info.h.
Referenced by cleanUpPUInfo(), Do_WOPT_and_CG_with_Regions(), DRA_Add_Clone(), fei_proc_body(), Free_Local_Info(), Get_Orig_PU_Name(), ir_b2a_process_PUs(), main(), PDGCS_do_proc(), PDGCS_new_proc(), Postprocess_PU(), Preorder_Process_PUs(), Preprocess_PU(), process_pu(), Prompf_Emit_Whirl_to_Source(), Read_Local_Info(), Restore_Local_Symtab(), Save_Local_Symtab(), WN_get_proc_sym(), WN_Rename_Duplicate_Labels(), WN_write_symtab(), and write_PU_fields().
#define PU_Info_pu_dst | ( | pu | ) | (pu)->pu_dst |
Definition at line 158 of file pu_info.h.
Referenced by DRA_Add_Clone(), DRA_Mangle_All(), Get_Orig_PU_Name(), Post_Process_Backend(), PU_Info_init(), Read_PU_Infos(), and write_PU_fields().
#define PU_Info_regions_ptr | ( | pu | ) | (struct region_id *)PU_Info_subsect_ptr((pu), WT_REGIONS) |
#define PU_Info_state | ( | pu, | |
ndx | |||
) | (Subsect_State)(((pu)->state >> (((ndx) + 1) << 1)) & 0x3) |
Definition at line 187 of file pu_info.h.
Referenced by fdump_PU_Info_state(), IPA_copy_PU(), Preprocess_PU(), Restore_Local_Symtab(), Save_Local_Symtab(), WN_get_feedback(), WN_get_prefetch(), WN_get_proc_sym(), WN_get_symtab(), WN_get_tree(), WN_read_generic_map(), WN_write_generic_map(), WN_write_prefetch(), WN_write_symtab(), WN_write_tree(), and write_PU_subsect_info().
#define PU_Info_subsect_offset | ( | pu, | |
scn | |||
) | (pu)->subsect[scn].offset |
Definition at line 154 of file pu_info.h.
Referenced by IPA_copy_PU(), Read_PU_Infos(), WN_get_feedback(), WN_get_prefetch(), WN_get_symtab(), WN_get_tree(), WN_read_generic_map(), WN_write_generic_map(), WN_write_prefetch(), WN_write_symtab(), WN_write_tree(), and write_PU_subsect_info().
#define PU_Info_subsect_ptr | ( | pu, | |
scn | |||
) | (pu)->subsect[scn].u.ptr |
Definition at line 156 of file pu_info.h.
Referenced by WN_get_prefetch(), WN_read_generic_map(), WN_write_generic_map(), WN_write_prefetch(), and WN_write_tree().
#define PU_Info_subsect_size | ( | pu, | |
scn | |||
) | (pu)->subsect[scn].u.size |
Definition at line 155 of file pu_info.h.
Referenced by IPA_copy_PU(), Read_PU_Infos(), size_of_each_pu(), WN_get_feedback(), WN_get_prefetch(), WN_get_symtab(), WN_get_tree(), WN_read_generic_map(), WN_write_generic_map(), WN_write_prefetch(), WN_write_symtab(), WN_write_tree(), and write_PU_subsect_info().
#define PU_Info_symtab_ptr | ( | pu | ) | (LOCAL_SYMTAB_HEADER_TABLE *) PU_Info_subsect_ptr((pu), WT_SYMTAB) |
Definition at line 197 of file pu_info.h.
Referenced by process_pu(), Restore_Local_Symtab(), and Save_Local_Symtab().
#define PU_Info_tree_ptr | ( | pu | ) | (WN *)PU_Info_subsect_ptr((pu), WT_TREE) |
Definition at line 199 of file pu_info.h.
Referenced by cleanUpPUInfo(), DRA_Add_Clone(), DRA_Clone_Instantiate(), Formal_Position(), ir_b2a_process_PUs(), ir_sel(), main(), Preprocess_PU(), process_pu(), WN_get_tree(), and WN_write_tree().
#define PU_INTERNAL_MASK 0xf0000000 |
#define PU_IS_COMPILER_GENERATED 0x4 /* compiler_generated PU */ |
Definition at line 93 of file pu_info.h.
Referenced by DRA_Add_Clone(), Post_LNO_Processing(), and Preprocess_PU().
#define PU_IS_DRA_CLONE 0x8 /* clone generated for reshaped arrays */ |
Definition at line 94 of file pu_info.h.
Referenced by DRA_Add_Clone(), and Preprocess_PU().
#define PU_PREGS_RENUMBERED |
#define Set_PU_Info_ac_internal_ptr | ( | pu, | |
x | |||
) | PU_Info_subsect_ptr((pu), WT_AC_INTERNAL) = (void *) (x) |
Definition at line 228 of file pu_info.h.
Referenced by WN_write_tree().
#define Set_PU_Info_alias_class_ptr | ( | pu, | |
x | |||
) | PU_Info_subsect_ptr((pu), WT_ALIAS_CLASS) = (void *) (x) |
Definition at line 226 of file pu_info.h.
Referenced by WN_write_tree().
#define Set_PU_Info_cu_dst | ( | pu, | |
x | |||
) | PU_Info_cu_dst(pu) = x; |
Definition at line 233 of file pu_info.h.
Referenced by PDGCS_do_proc().
#define Set_PU_Info_depgraph_ptr | ( | pu, | |
x | |||
) | PU_Info_subsect_ptr((pu), WT_DEPGRAPH) = (void *)(x) |
Definition at line 218 of file pu_info.h.
Referenced by Backend_Processing(), DRA_Add_Clone(), and LNO_Processing().
#define Set_PU_Info_feedback_ptr | ( | pu, | |
x | |||
) | PU_Info_subsect_ptr((pu), WT_FEEDBACK) = (void *)(x) |
Definition at line 222 of file pu_info.h.
Referenced by WN_get_feedback().
#define Set_PU_Info_flags | ( | pu, | |
flag_value | |||
) | (pu)->flags |= (flag_value) |
Definition at line 165 of file pu_info.h.
Referenced by DRA_Add_Clone(), PDGCS_do_proc(), and PDGCS_new_proc().
#define Set_PU_Info_frequencies_ptr | ( | pu, | |
x | |||
) | PU_Info_subsect_ptr((pu), WT_FREQ) = (void *) (x) |
#define Set_PU_Info_pu_dst | ( | pu, | |
x | |||
) | PU_Info_pu_dst(pu) = x; |
Definition at line 231 of file pu_info.h.
Referenced by DRA_Add_Clone(), and PDGCS_do_proc().
#define Set_PU_Info_regions_ptr | ( | pu, | |
x | |||
) | PU_Info_subsect_ptr((pu), WT_REGIONS) = (void *)(x) |
#define Set_PU_Info_state | ( | pu, | |
ndx, | |||
st | |||
) |
(pu)->state = (pu)->state & \ ~(0x3 << (((ndx) + 1) << 1)) | (st << (((ndx) + 1) << 1))
Definition at line 189 of file pu_info.h.
Referenced by Backend_Processing(), DRA_Add_Clone(), IPA_copy_PU(), LNO_Processing(), PDGCS_do_proc(), Read_PU_Infos(), WN_get_feedback(), WN_get_prefetch(), WN_get_proc_sym(), WN_get_symtab(), WN_get_tree(), WN_read_generic_map(), WN_write_generic_map(), WN_write_prefetch(), WN_write_symtab(), and WN_write_tree().
#define Set_PU_Info_symtab_ptr | ( | pu, | |
x | |||
) | PU_Info_subsect_ptr((pu), WT_SYMTAB) = (void *)(x) |
Definition at line 216 of file pu_info.h.
Referenced by DRA_Add_Clone(), and Save_Local_Symtab().
#define Set_PU_Info_tree_ptr | ( | pu, | |
x | |||
) | PU_Info_subsect_ptr((pu), WT_TREE) = (void *)(x) |
Definition at line 214 of file pu_info.h.
Referenced by Do_WOPT_and_CG_with_Regions(), DRA_Add_Clone(), Ipl_Processing(), PDGCS_do_proc(), Post_LNO_Processing(), and WN_get_tree().
#define WT_AC_INTERNAL 0x7 /* alias classification temporary */ |
Definition at line 82 of file pu_info.h.
Referenced by Read_Local_Info(), and WN_write_tree().
#define WT_ALIAS_CLASS 0x8 /* alias classification */ |
Definition at line 83 of file pu_info.h.
Referenced by Read_Local_Info(), WN_write_tree(), and Write_PU_Info().
#define WT_DEPGRAPH 0x2 /* dependence graph */ |
Definition at line 77 of file pu_info.h.
Referenced by Backend_Processing(), DRA_Add_Clone(), IPA_copy_PU(), LNO_Processing(), and size_of_each_pu().
#define WT_FEEDBACK 0x5 /* feedback data */ |
Definition at line 80 of file pu_info.h.
Referenced by Preprocess_PU(), size_of_each_pu(), and WN_get_feedback().
#define WT_FREQ 0x6 /* obsolete */ |
Definition at line 81 of file pu_info.h.
Referenced by DRA_Add_Clone().
#define WT_PREFETCH 0x3 /* prefetch pointers */ |
Definition at line 78 of file pu_info.h.
Referenced by IPA_copy_PU(), size_of_each_pu(), WN_get_prefetch(), WN_write_prefetch(), and WN_write_tree().
#define WT_PROC_SYM -1 /* special value for proc sym state */ |
Definition at line 86 of file pu_info.h.
Referenced by DRA_Add_Clone(), fdump_PU_Info_state(), PDGCS_do_proc(), Read_PU_Infos(), and WN_get_proc_sym().
#define WT_REGIONS 0x4 /* RID trees */ |
#define WT_SUBSECTIONS 0x9 /* number of subsection types */ |
Definition at line 85 of file pu_info.h.
Referenced by fdump_PU_Info_state(), Read_PU_Infos(), Sizeof_PU_Infos(), and Write_PU_Infos().
#define WT_SYMTAB 0x0 /* symbol table */ |
Definition at line 75 of file pu_info.h.
Referenced by DRA_Add_Clone(), IPA_copy_PU(), PDGCS_do_proc(), Restore_Local_Symtab(), Save_Local_Symtab(), size_of_each_pu(), WN_get_symtab(), and WN_write_symtab().
#define WT_TREE 0x1 /* WHIRL tree nodes */ |
Definition at line 76 of file pu_info.h.
Referenced by DRA_Add_Clone(), IPA_copy_PU(), PDGCS_do_proc(), Preprocess_PU(), size_of_each_pu(), WN_get_prefetch(), WN_get_tree(), WN_read_generic_map(), and WN_write_tree().
typedef enum subsect_state Subsect_State |
enum subsect_state |
void PU_Info_init | ( | PU_Info * | pu | ) |
Definition at line 73 of file pu_info.cxx.
References DST_INVALID_IDX, NULL, PU_Info_child, PU_Info_cu_dst, PU_Info_flags, PU_Info_maptab, PU_Info_next, PU_Info_proc_id, PU_Info_pu_dst, and pu_info::state.
Referenced by cwh_pdgcs_pu_mem(), DRA_Add_Clone(), and Read_PU_Infos().
PU_Info* Read_PU_Infos | ( | char * | base, |
INT32 | size, | ||
INT32 * | p_num_PUs | ||
) |
Definition at line 255 of file pu_info.cxx.
References kind, NULL, PU_HEADER_VERSION, PU_Info_child, PU_Info_flags, PU_Info_init(), PU_Info_next, PU_Info_proc_id, PU_Info_pu_dst, PU_Info_subsect_offset, PU_Info_subsect_size, Set_PU_Info_state, Subsect_Exists, WT_PROC_SYM, and WT_SUBSECTIONS.
Referenced by WN_get_PU_Infos().
void Restore_Local_Symtab | ( | PU_Info * | pu | ) |
Definition at line 412 of file pu_info.cxx.
References Current_scope, FmtAssert, SAVED_SCOPE::Get_Scope(), PU_Info_proc_sym, PU_Info_state, PU_Info_symtab_ptr, PU_lexical_level(), Scope_tab, St_Table, Subsect_InMem, and WT_SYMTAB.
Referenced by DRA_Add_Clone(), and Preprocess_PU().
void Save_Local_Symtab | ( | SYMTAB_IDX | level, |
PU_Info * | pu | ||
) |
Definition at line 382 of file pu_info.cxx.
References Current_scope, CURRENT_SYMTAB, CXX_NEW, FmtAssert, MEM_POOL_Alloc, NULL, pool, PU_Info_proc_sym, PU_Info_state, PU_Info_symtab_ptr, PU_lexical_level(), Scope_tab, Set_PU_Info_symtab_ptr, St_Table, Subsect_InMem, and WT_SYMTAB.
Referenced by DRA_Add_Clone().
INT Sizeof_PU_Infos | ( | PU_Info * | pu_tree | ) |
Definition at line 89 of file pu_info.cxx.
References number_PU_Infos(), and WT_SUBSECTIONS.
Referenced by ir_size(), and WN_write_PU_Infos().
INT Write_PU_Infos | ( | PU_Info * | pu_tree, |
char * | base | ||
) |
Definition at line 144 of file pu_info.cxx.
References PU_HEADER_VERSION, write_PU_fields(), write_PU_subsect_info(), and WT_SUBSECTIONS.
Referenced by WN_write_PU_Infos().
Definition at line 70 of file pu_info.cxx.
Referenced by Backend_Processing(), Change_ST_Of_Current_PU(), Formal_Position(), LNO_Processing(), main(), Preprocess_PU(), process_pu(), read_pu(), WN_Rename_Duplicate_Labels(), and write_pu().