osprey/be/cg/orc_ict/edge_profile.h File Reference

#include "cxx_memory.h"
#include "profile_com.h"
#include "tn.h"
#include "instr_reader.h"
#include "glob.h"
#include "fb_freq.h"
#include "fb_info.h"
#include "const.h"
#include "op.h"
#include "mempool.h"
#include "profile_util.h"
#include "wn.h"

Include dependency graph for edge_profile.h:

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Types

module  PROFILE_MEM
module  PROFILE
module  EDGE_PROFILE

Defines

#define INSTR_INIT_NAME   "__profile_init"
#define PU_INIT_NAME   "__profile_pu_init"
#define EDGE_INST_NAME   "__profile_edge"
#define FIRST_INPUT_REG   (32+REGISTER_MIN)
#define FIRST_LOCAL_REG   (32+REGISTER_MIN)
#define FIRST_OUTPUT_REG   (127+REGISTER_MIN)
#define LAST_STACKED_REG   (127+REGISTER_MIN)
#define FIRST_ROTATING_INTEGER_REG   (32+REGISTER_MIN)
#define FIRST_ROTATING_FLOAT_REG   (32+REGISTER_MIN)
#define FIRST_ROTATING_PREDICATE_REG   (16+REGISTER_MIN)
#define LAST_ROTATING_INTEGER_REG   (127+REGISTER_MIN)
#define LAST_ROTATING_FLOAT_REG   (127+REGISTER_MIN)
#define LAST_ROTATING_PREDICATE_REG   (63+REGISTER_MIN)
#define RETURN_REG   (8+REGISTER_MIN)
#define RETURN_REG1   (8+REGISTER_MIN)
#define RETURN_REG2   (9+REGISTER_MIN)
#define RETURN_REG3   (10+REGISTER_MIN)
#define RETURN_REG4   (11+REGISTER_MIN)
#define FLOAT_RETURN_REG   (8+REGISTER_MIN)
#define FLOAT_RETURN_REG1   (8+REGISTER_MIN)
#define FLOAT_RETURN_REG2   (9+REGISTER_MIN)
#define FLOAT_RETURN_REG3   (10+REGISTER_MIN)
#define FLOAT_RETURN_REG4   (11+REGISTER_MIN)
#define FLOAT_RETURN_REG5   (12+REGISTER_MIN)
#define FLOAT_RETURN_REG6   (13+REGISTER_MIN)
#define FLOAT_RETURN_REG7   (14+REGISTER_MIN)
#define FLOAT_RETURN_REG8   (15+REGISTER_MIN)
#define BBlist_Alloc(void)   TYPE_PU_ALLOC(BBLIST)
#define ERROR_FREQ(freq)   freq < 0.0
#define ERROR_PROB(prob)   prob < 0.0
#define UNINIT_FREQ(freq)   freq < 0.0
#define UNINIT_PROB(prob)   prob < 0.0
#define ZERO_FREQ(freq)   freq == 0.0
#define ZERO_PROB(prob)   prob == 0.0
#define FB_FREQ_UNINIT   -1.0
#define FB_FREQ_UNKNOWN   -2.0
#define FB_FREQ_ERROR   -3.0
#define LABEL_IDX_NONE   0

Functions/Subroutines

void Compute_Edge_Freq_Base_Prob (void)
void Compute_Edge_Prob_Base_Freq (void)
void CG_Edge_Profile_Annotation (CGRIN *cgrin, PROFILE_PHASE phase)
void CG_Edge_Profile_Instrument (CGRIN *cgrin, PROFILE_PHASE phase)
WNGen_Call (char *name, WN *arg1, WN *arg2, TYPE_ID rtype=MTYPE_V)
WNGen_Call_Shell (char *name, TYPE_ID rtype, INT32 argc)
INT32 Curr_PU_BB_Count (void)
void Init_CFG (void)
void Change_BB_Label (BB *bb, LABEL_IDX i)
BBFirst_Branch_BB (void)
BOOL Result_Tn_In_BB (BB *bb, TN *tn)
BOOL Opnd_Tn_In_BB (BB *bb, TN *tn)
LABEL_IDX Get_Br_Op_Tgt_Label (OP *branch_op)
INT32 Get_Return_Reg_Sum (BB *bb)
INT32 Get_Float_Return_Reg_Sum (BB *bb)
WNGen_Param (WN *arg, UINT32 flag)

Variables

INT32 current_PU_handle
BOOL CG_PU_Has_Feedback
BOOL FREQ_freqs_computed


Define Documentation

#define BBlist_Alloc ( void   )     TYPE_PU_ALLOC(BBLIST)

Definition at line 104 of file edge_profile.h.

#define EDGE_INST_NAME   "__profile_edge"

#define ERROR_FREQ ( freq   )     freq < 0.0

Definition at line 105 of file edge_profile.h.

Referenced by Compute_Edge_Freq_Base_Prob(), and Compute_Edge_Prob_Base_Freq().

#define ERROR_PROB ( prob   )     prob < 0.0

Definition at line 106 of file edge_profile.h.

Referenced by Compute_Edge_Freq_Base_Prob().

#define FB_FREQ_ERROR   -3.0

Definition at line 114 of file edge_profile.h.

#define FB_FREQ_UNINIT   -1.0

#define FB_FREQ_UNKNOWN   -2.0

#define FIRST_INPUT_REG   (32+REGISTER_MIN)

Definition at line 77 of file edge_profile.h.

#define FIRST_LOCAL_REG   (32+REGISTER_MIN)

Definition at line 78 of file edge_profile.h.

#define FIRST_OUTPUT_REG   (127+REGISTER_MIN)

Definition at line 79 of file edge_profile.h.

#define FIRST_ROTATING_FLOAT_REG   (32+REGISTER_MIN)

Definition at line 82 of file edge_profile.h.

#define FIRST_ROTATING_INTEGER_REG   (32+REGISTER_MIN)

Definition at line 81 of file edge_profile.h.

#define FIRST_ROTATING_PREDICATE_REG   (16+REGISTER_MIN)

Definition at line 83 of file edge_profile.h.

#define FLOAT_RETURN_REG   (8+REGISTER_MIN)

Definition at line 94 of file edge_profile.h.

Referenced by EDGE_PROFILE::Gen_Call_BB(), and Get_Float_Return_Reg_Sum().

#define FLOAT_RETURN_REG1   (8+REGISTER_MIN)

Definition at line 95 of file edge_profile.h.

#define FLOAT_RETURN_REG2   (9+REGISTER_MIN)

Definition at line 96 of file edge_profile.h.

#define FLOAT_RETURN_REG3   (10+REGISTER_MIN)

Definition at line 97 of file edge_profile.h.

#define FLOAT_RETURN_REG4   (11+REGISTER_MIN)

Definition at line 98 of file edge_profile.h.

#define FLOAT_RETURN_REG5   (12+REGISTER_MIN)

Definition at line 99 of file edge_profile.h.

#define FLOAT_RETURN_REG6   (13+REGISTER_MIN)

Definition at line 100 of file edge_profile.h.

#define FLOAT_RETURN_REG7   (14+REGISTER_MIN)

Definition at line 101 of file edge_profile.h.

#define FLOAT_RETURN_REG8   (15+REGISTER_MIN)

Definition at line 102 of file edge_profile.h.

#define INSTR_INIT_NAME   "__profile_init"

Definition at line 65 of file edge_profile.h.

Referenced by EDGE_PROFILE::Instrument_Entry().

#define LABEL_IDX_NONE   0

#define LAST_ROTATING_FLOAT_REG   (127+REGISTER_MIN)

Definition at line 85 of file edge_profile.h.

#define LAST_ROTATING_INTEGER_REG   (127+REGISTER_MIN)

Definition at line 84 of file edge_profile.h.

#define LAST_ROTATING_PREDICATE_REG   (63+REGISTER_MIN)

Definition at line 86 of file edge_profile.h.

#define LAST_STACKED_REG   (127+REGISTER_MIN)

Definition at line 80 of file edge_profile.h.

#define PU_INIT_NAME   "__profile_pu_init"

#define RETURN_REG   (8+REGISTER_MIN)

#define RETURN_REG1   (8+REGISTER_MIN)

Definition at line 89 of file edge_profile.h.

#define RETURN_REG2   (9+REGISTER_MIN)

Definition at line 90 of file edge_profile.h.

#define RETURN_REG3   (10+REGISTER_MIN)

Definition at line 91 of file edge_profile.h.

#define RETURN_REG4   (11+REGISTER_MIN)

Definition at line 92 of file edge_profile.h.

#define UNINIT_FREQ ( freq   )     freq < 0.0

#define UNINIT_PROB ( prob   )     prob < 0.0

Definition at line 108 of file edge_profile.h.

#define ZERO_FREQ ( freq   )     freq == 0.0

Definition at line 109 of file edge_profile.h.

Referenced by Compute_Edge_Prob_Base_Freq().

#define ZERO_PROB ( prob   )     prob == 0.0

Definition at line 110 of file edge_profile.h.

Referenced by Set_Prob().


Function Documentation

void CG_Edge_Profile_Annotation ( CGRIN cgrin,
PROFILE_PHASE  phase 
)

void CG_Edge_Profile_Instrument ( CGRIN cgrin,
PROFILE_PHASE  phase 
)

void Change_BB_Label ( BB bb,
LABEL_IDX  i 
)

void Compute_Edge_Freq_Base_Prob ( void   ) 

void Compute_Edge_Prob_Base_Freq ( void   ) 

INT32 Curr_PU_BB_Count ( void   ) 

Definition at line 1822 of file edge_profile.cxx.

References BB_next, count, INT32, NULL, and REGION_First_BB.

Referenced by EDGE_PROFILE::CG_Instrument().

BB* First_Branch_BB ( void   ) 

WN* Gen_Call ( char *  name,
WN arg1,
WN arg2,
TYPE_ID  rtype = MTYPE_V 
)

WN* Gen_Call_Shell ( char *  name,
TYPE_ID  rtype,
INT32  argc 
)

WN* Gen_Param ( WN arg,
UINT32  flag 
) [inline]

Definition at line 349 of file edge_profile.h.

References MTYPE_To_TY, WN_CreateParm, and WN_rtype().

Referenced by Gen_Call(), Gen_Call_ref3(), and Gen_Call_ref35().

LABEL_IDX Get_Br_Op_Tgt_Label ( OP branch_op  ) 

INT32 Get_Float_Return_Reg_Sum ( BB bb  ) 

INT32 Get_Return_Reg_Sum ( BB bb  ) 

void Init_CFG ( void   ) 

Definition at line 1830 of file edge_profile.cxx.

References BB_next, BB_succs, BBLIST_next, FB_FREQ_UNINIT, NULL, and REGION_First_BB.

Referenced by CG_Edge_Profile_Annotation().

BOOL Opnd_Tn_In_BB ( BB bb,
TN tn 
)

Definition at line 2064 of file edge_profile.cxx.

References FALSE, ops::first, i, NULL, OP_next, OP_opnd, OP_opnds, opcode, bb::ops, and TRUE.

BOOL Result_Tn_In_BB ( BB bb,
TN tn 
)

Definition at line 2049 of file edge_profile.cxx.

References FALSE, ops::first, i, NULL, OP_next, OP_result, OP_results, opcode, bb::ops, and TRUE.


Variable Documentation


Generated on Wed Apr 8 14:28:27 2009 for Open64 by  doxygen 1.5.6