osprey/be/lno/lnoutils.cxx File Reference

#include <alloca.h>
#include <sys/types.h>
#include <ctype.h>
#include <limits.h>
#include "pu_info.h"
#include "lnoutils.h"
#include "config.h"
#include "config_cache.h"
#include "config_lno.h"
#include "lnopt_main.h"
#include "stab.h"
#include "targ_const.h"
#include "wn_simp.h"
#include "stdlib.h"
#include "lwn_util.h"
#include "strtab.h"
#include "targ_sim.h"
#include "optimizer.h"
#include "opt_du.h"
#include "name.h"
#include "wintrinsic.h"
#include "lno_bv.h"
#include "region_util.h"
#include "fb_whirl.h"
#include "lego_gen.h"
#include "snl_utils.h"
#include "dep_graph.h"
#include "wn_pragmas.h"
#include "ff_utils.h"
#include "move.h"
#include "w2op.h"
#include "prompf.h"
#include "anl_driver.h"
#include "ipa_lno_util.h"
#include "debug.h"
#include "wutil.h"
#include "intrn_info.h"

Include dependency graph for lnoutils.cxx:

Go to the source code of this file.

Defines

#define lnoutils_CXX   "lnoutils.cxx"

Typedefs

typedef HASH_TABLE< WN *, WN * > LOOP_MAPPING
typedef HASH_TABLE< WN *, BOOLLOOPS_ONLY

Functions/Subroutines

void LWN_Parentize_One_Level (const WN *wn)
WNLWN_Make_Icon (TYPE_ID wtype, INT64 i)
TYPE_ID Do_Wtype (WN *wn)
INT64 Step_Size (WN *loop, INT64 newstep)
INT64 Step_Size (WN *loop)
static void Add_Barrier_Vertex (WN *wn_barrier)
void Create_Single_Region (WN *wn_single, WN *wn_end)
INT32 Dot_Product (const mINT32 *v1, const mINT32 *v2, INT cnt)
INT64 Dot_Product (const mINT64 *v1, const mINT64 *v2, INT cnt)
INT64 Dot_Product (const mINT32 *v1, const mINT64 *v2, INT cnt)
INT64 Dot_Product (const mINT64 *v1, const mINT32 *v2, INT cnt)
static void printws (FILE *f, INT ws)
void wn_dumpexpr (WN *wn, INT fancy, FILE *f, ARRAY_DIRECTED_GRAPH16 *dg, WN **list, WN *parent, BOOL recursive)
void Dump_WN (WN *wn, FILE *f, INT fancy, INT ws, INT ws_inc, ARRAY_DIRECTED_GRAPH16 *dg, WN **list, WN *parent, BOOL recursive)
TYPE_ID Max_Wtype (TYPE_ID a, TYPE_ID b)
INT Do_Depth (WN *wn, WN **loops, INT mx)
INT Good_Do_Depth (WN *wn, WN **loops, INT mx)
static void Build_Doloop_Stack_Rec (WN *wn, WN *parent, DOLOOP_STACK *stack)
void Build_Doloop_Stack (WN *wn, DOLOOP_STACK *stack)
void Replace_Symbol (WN *wn, SYMBOL symold, SYMBOL symnew, WN *alias_wn, WN *ancestor)
void Replace_Symbols (WN *wn, SYMBOL *sold, SYMBOL *snew, INT count, WN **alias_wn, WN **ancestors)
BOOL Add_To_Symbol (WN *wn, INT64 i, SYMBOL sym, BOOL stok)
BOOL Add_To_Symbol (WN *wn, INT64 i, ST *st, WN_OFFSET offset, TYPE_ID wtype, BOOL stok)
WNReplace_Wnexp_With_Exp_Copy (WN *wn, WN *expr, DU_MANAGER *du, BOOL *added_cvt, ARRAY_DIRECTED_GRAPH16 *dep_graph)
WNReplace_Scalar_Store_With_Array_Store (WN *scalar_store, WN *array_store, DU_MANAGER *du)
void Replace_Ldid_With_Exp_Copy (SYMBOL symbol, WN *wn, WN *expr, DU_MANAGER *du, ARRAY_DIRECTED_GRAPH16 *dep_graph)
INT sz (TYPE_ID wtype)
static INT bitcount (TYPE_ID wtype)
static WNLWN_Short_Integer_Cast (WN *tree, TYPE_ID *to, TYPE_ID from)
WNLWN_Integer_Cast (WN *tree, TYPE_ID to, TYPE_ID from)
WNLWN_Integer_Casts (WN *tree, TYPE_ID to, TYPE_ID from)
SYMBOL Create_Preg_Symbol (const char *name, TYPE_ID type)
SYMBOL Create_Stack_Symbol (const char *name, TYPE_ID type)
STLookup_Function_Name (const char *name)
static void reset_do (WN *body, INT depth)
void Reset_Do_Loop_Depths (WN *loop, INT depth)
ACCESS_VECTORDifference_Inequality (ACCESS_VECTOR *lb, ACCESS_VECTOR *ub, INT var, DIFFERENCE_KIND code, MEM_POOL *pool)
BOOL Statically_Safe_Node (WN *wn)
BOOL Statically_Safe_Exp (WN *wn)
void Print_Def_Use (WN *wn, FILE *fp)
static void Unrolled_DU_Update_V (WN **bodies, UINT u, HASH_TABLE< WN *, WN ** > *hash_table, STACK< WN * > *load_stack, STACK< WN * > *store_stack)
static void Unrolled_DU_Update_E (UINT u, INT loopno, HASH_TABLE< WN *, WN ** > *hash_table, STACK< WN * > *load_stack, STACK< WN * > *store_stack, BOOL update_pointers, SYMBOL *index_loopno)
void Unrolled_DU_Update (WN **bodies, UINT u, INT loopno, BOOL update_pointers, BOOL cross_index)
static STGet_ST_Base (ST *st)
STGet_ST_Base (WN *load)
static BOOL All_Uses_Within (WN *def, WN *region)
BOOL Index_Variable_Live_At_Exit (WN *loop)
static BOOL Is_Used (WN *wn, const SYMBOL &sym)
BOOL Index_Variable_Live_At_Entry (WN *loop)
INT Symbol_Count (WN *wn, const SYMBOL &sym)
static void Flip_Le_And_Ge (WN *wn)
BOOL Solve_For (WN *wn_top, const SYMBOL &sym)
BOOL Do_Loop_Is_Unsigned (WN *wn_loop)
BOOL Upper_Bound_Standardize (WN *ub, BOOL ok_to_fail)
WNOutermost_Enclosing_Loop (WN *loop)
WNOutermost_Enclosing_Good_Loop (WN *loop)
static void Patch_Uses_In_Loop (WN *wn_asg, WN *wn_loop)
static void Update_Nest_Depth_Traverse (WN *wn_tree)
static void Update_Nest_Depth (WN *wn_tree)
void Finalize_Index_Variable (WN *loop, BOOL insert_after_loop, BOOL try_sink)
void Finalize_Index_Variable_For_Remove_Unity_Trip_Loop (WN *loop, BOOL insert_after_loop, BOOL try_sink)
WNWN_prev_executable (WN *wn)
WNWN_next_executable (WN *wn)
static void LNO_Erase_Vertices_In_Loop_Rec (WN *wn, ARRAY_DIRECTED_GRAPH16 *dg)
void LNO_Erase_Vertices_In_Loop (WN *wn, ARRAY_DIRECTED_GRAPH16 *dg)
void Du_Sanity_Check_Matching_Du (STACK< WN * > *read_stack, STACK< WN * > *write_stack, FILE *fp, UINT fancy)
static void Du_Sanity_Check_r (WN *wn, HASH_TABLE< WN *, INT > *h_table, UINT pass, FILE *fp, UINT fancy, STACK< WN * > *reads, STACK< WN * > *writes)
static void IV_Loop_Stmt_Check_X (STACK< SYMBOL > &symbols, STACK< WN * > &loops, WN *wn)
static void Initialize_Symbols (STACK< SYMBOL > &symbols, STACK< WN * > &loops, WN *wn)
void IV_Loop_Stmt_Check (WN *wn, MEM_POOL *pool)
void Du_Sanity_Check (WN *wn, FILE *fp, UINT fancy)
void FB_Sanity_Check (WN *wn)
BOOL Wn_Is_Inside (WN *inner, const WN *outer)
INT64 LWN_Get_Linenum (const WN *wn)
BOOL Is_Permutation_Vector (const INT order[], INT nloops)
BOOL Are_Permutations (const INT *order1, const INT *order2, INT count)
BOOL Is_Loop_Invariant_Use (WN *wn, WN *outerloop)
BOOL Is_Loop_Invariant_Exp (WN *wn, WN *outerloop)
static void SNL_Make_Loop_Mapping_Inside (WN *orig, WN *copy, LOOP_MAPPING *ht)
LOOP_MAPPINGMake_Loop_Mapping (WN *orig, WN *copy, MEM_POOL *pool)
static void Find_Loops_Within_Walk (WN *wn, HASH_TABLE< WN *, BOOL > *ht)
HASH_TABLE< WN *, BOOL > * Find_Loops_Within (WN *orig, MEM_POOL *pool)
INT Num_Common_Loops (WN *wn1, WN *wn2)
WNLNO_Common_Loop (WN *wn1, WN *wn2)
BOOL Equivalent_Access_Arrays (ACCESS_ARRAY *array1, ACCESS_ARRAY *array2, WN *wn1, WN *wn2)
WNEnclosing_Do_Loop (WN *wn)
WNEnclosing_Loop (WN *wn)
WNEnclosing_Loop_Body (WN *wn)
WNEnclosing_Proper_Do_Loop (WN *wn_ref)
static BOOL Exp_Depends_On_Outer_Loop (WN *wn_exp, SYMBOL index_var, ARRAY_DIRECTED_GRAPH16 *dg, DU_MANAGER *du)
BOOL Loop_Is_Trapezoidal (WN *wn_loop, ARRAY_DIRECTED_GRAPH16 *dg, DU_MANAGER *du)
void Remove_Redundant_Stids (WN *wn_start, DU_MANAGER *du)
OPCODE Matching_Load_Opcode (OPCODE store_op)
WNCreate_ILoad_From_IStore (WN *wn_store, DU_MANAGER *du, ARRAY_DIRECTED_GRAPH16 *dg)
BOOL Is_Local_Array_Reference (WN *array)
BOOL Is_Mp_Region (WN *wn)
BOOL Do_Loop_Is_Mp (WN *wn)
RIDGet_Enclosing_Region_ID (WN *wn)
BOOL Is_Nested_Doacross (WN *wn_loop)
void Remark_Depth (WN *wn, mUINT8 depth)
WNUBexp (WN *end, BOOL *ne)
WNUBvar (WN *end)
INT Loop_Depth (WN *stat)
INT Block_Loop_Depth (WN *stat)
void Add_Pragma_To_MP_Region (const WN *cwn, ST *st, WN_OFFSET offset, WN_PRAGMA_ID pragma_id, BOOL make_compiler_generated)
void Update_MP_Local_Var (ST *st, WN_OFFSET offset, WN *wn)
static WNUnique_Stid_Definition (WN *wn_ldid, DU_MANAGER *du)
static BOOL Symbol_In_Expression (WN *wn_exp, SYMBOL sym, DU_MANAGER *du)
static WNUnique_Ldid_Symbol (WN *wn_exp, DU_MANAGER *du)
static WNWind_Down_Parent (WN *wn_loop, DU_MANAGER *du)
static WNNormal_Outer_Tile (WN *wn_loop, DU_MANAGER *du)
WNOuter_Tile (WN *wn_loop, DU_MANAGER *du)
WNReturn_Node (WN *wn_func_nd)
WNLoop_Step (WN *wn_loop)
WNCommon_Loop_Ancestor (WN *wn1, WN *wn2)
void Build_Parent_Stack (WN *wn, STACK< WN * > *stack)
WNCommon_Ancestor (WN *wn1, WN *wn2)
BOOL Is_Lex_Before (WN *wn1, WN *wn2)
WNFind_Node (SYMBOL sym, WN *wn_tree)
BOOL Identity_Permutation (INT permutation[], INT nloops)
WNTrip_Count (WN *wn_loop)
INT Reduce_Permutation (INT permutation[], INT nloops, INT spermutation[], INT max_reduction)
BOOL Index_Variable (WN *wn_index)
BOOL Contains_Dedicated_Preg (WN *wn_tree)
INT Factorial (INT n)
void Permutation (INT order, INT nloops, INT permutation[])
INT WN_Whirl_Linenum (WN *wn_ref)
void Constant_Propogate (WN *stid, INT64 const_val)
WNMessy_Subscript (WN *wn_array)
void Replace_Index_Variable (WN *loop, WN *cp_loop, const char prefix[])

Variables

WNglobal_fd


Define Documentation

#define lnoutils_CXX   "lnoutils.cxx"

Definition at line 45 of file lnoutils.cxx.


Typedef Documentation

Definition at line 3446 of file lnoutils.cxx.

Definition at line 3503 of file lnoutils.cxx.


Function Documentation

static void Add_Barrier_Vertex ( WN wn_barrier  )  [static]

void Add_Pragma_To_MP_Region ( const WN cwn,
ST st,
WN_OFFSET  offset,
WN_PRAGMA_ID  pragma_id,
BOOL  make_compiler_generated 
)

BOOL Add_To_Symbol ( WN wn,
INT64  i,
ST st,
WN_OFFSET  offset,
TYPE_ID  wtype,
BOOL  stok 
)

Definition at line 1016 of file lnoutils.cxx.

References Add_To_Symbol(), FALSE, INT, printf(), sym, and TRUE.

BOOL Add_To_Symbol ( WN wn,
INT64  i,
SYMBOL  sym,
BOOL  stok 
)

static BOOL All_Uses_Within ( WN def,
WN region 
) [static]

BOOL Are_Permutations ( const INT order1,
const INT order2,
INT  count 
)

Definition at line 3328 of file lnoutils.cxx.

References FALSE, i, INT, and TRUE.

static INT bitcount ( TYPE_ID  wtype  )  [static]

Definition at line 1176 of file lnoutils.cxx.

References FmtAssert, MTYPE_I1, MTYPE_I2, MTYPE_I4, MTYPE_I8, MTYPE_U1, MTYPE_U2, MTYPE_U4, and MTYPE_U8.

Referenced by LWN_Integer_Casts().

INT Block_Loop_Depth ( WN stat  ) 

void Build_Doloop_Stack ( WN wn,
DOLOOP_STACK stack 
)

Definition at line 776 of file lnoutils.cxx.

References Build_Doloop_Stack_Rec(), LWN_Get_Parent, OPC_DO_LOOP, STACK< T >::Push(), and WN_opcode().

Referenced by Add_Condition(), Analyse_Dependencies(), ARA_LOOP_INFO::ARA_LOOP_INFO(), BS_Replace_Load(), BS_Replace_Store(), BS_Substitute(), Build_Statement_Dependence_Graph(), Check_Doacross_Sync_Coverage(), Common_Loop_Ancestor(), Constant_Propogate(), Convert_Do_Loops_Conditionals(), Convex_Peeling_Depth(), Create_Initialize_Loop(), Create_Shackle_If_Per_Stmt(), PAR_STAT::Distribute(), PAR_STAT::Distribute_By_Splitting(), PAR_STAT::Distribute_For_Permutation(), Do_Automatic_Transformation(), Doacross_Cost(), Extended_Lower_Bound(), Extended_Upper_Bound(), Fiss_Gather_Inner_Loop(), Fission_DU_Update(), Fission_Inner_Loop(), Fix_Access_Arrays_In_Copy_Block(), Fix_Blockable_Dependences(), Fix_Deps_For_Load(), Fix_Deps_For_Load_Or_Store(), Forward_Substitute_Ldids(), Freeze_Numthreads_Ldid(), Fully_Permutable_Permutation(), Fuse(), Fuse_Outer_Loops(), Fusion_Du_Update(), Fusion_Loop_Stmt_Update(), Gather_Scatter_Scalar_Expand(), Gen_CheckNo_DART(), ARA_LOOP_INFO::Generate_Copyout_Loop(), Generate_If_Accesses(), ARA_LOOP_INFO::Generate_Parallel_Pragma(), Guard_A_Do(), HAB_Copy_Array_Deps(), Handle_Sink_Promotion_Case(), HMB_Compound_Guard_Test(), HMB_Copy_Array_Deps(), HMB_Hoist_Expressions(), HMB_Hoist_Messy_Bounds(), HMB_Hoist_Messy_Subscripts(), HMB_Maximum_Point(), HMB_Replace_Messy_Bounds_Loop(), HMB_Simple_Guard_Test(), Hoist_Bounds_One_Level(), Hoist_Iload_Ldid_Upper_Bound_One_Level(), Hoist_Outer_Invar(), Hoist_Varying_Lower_Bounds_Traverse(), Initialize_Pdo_Last_Local_Index(), PAR_STAT::Innermost_Sandwiched_Code(), Inv_Dep_Info(), Invariant_Loop_Count(), Invariant_Loops(), Invariant_Permutation(), IPA_LNO_Evaluate_Array_Formals(), IPA_LNO_Read_Projected_Region(), Is_Rectangular_Nested_Doacross(), Lego_Skew_Loop(), LNO_FB_Inv_Interchange(), Loop_Invariant_Access(), Loop_Stmt_Update(), ARRAY_LOWER_REF::Lower_Array_Expr(), SX_INFO::Make_Sx_Info(), Mark_Code(), Max_Dep_Distance(), Maybe_Handle_Sink_Promotion_Case(), MIR_Replace(), MIR_Update_Dependences(), Mp_Collapse_Cleanup(), Mp_Collapse_Loop_Heads(), Mp_Collapse_Loop_Statements(), Mp_Coordinate_Copy_Out_Coordinates(), Mp_Fix_Deps(), Mp_Layout_Copy_Out_Layout(), Mp_Layout_Lego_Layout(), Mp_Version_Loop(), Mp_Version_Parallel_Region(), Parallel_Directive_Class(), PAR_STAT::Parallel_Interchange(), Parallelizable_At_Depth(), Parallelize_Doacross_Loop(), Perform_Gather_Scatter(), PAR_STAT::Permute_Loops(), Post_loop_peeling(), Pre_loop_peeling(), Processor_2D_Tile_Loop(), Processor_3D_Tile_Loop(), Processor_Update_Outer_Tile(), Prompf_Interchange(), Prompf_Interchanges(), Prompf_Nested_Tile(), Read_Pragma_Thread_Affinity(), Rebuild_Access_Arrays(), Recompute_Deps(), Red_Dep_Info(), Redundant_Condition(), Remove_Unity_Trip_Loop(), Repair_Bad_Dependences(), Rewrite_Bounds(), RV_Reverse_Loop(), Scalar_Dependence_Prevent_Fusion(), Scalar_Expand(), Scalar_Variable_Renaming(), Scan_Parameters(), SE_CT_New_Tile_Infos(), SE_Fix_Dependence(), SE_Guard_Tests(), Shackle_Postprocess_Do_Loop_Bounds(), Simd_Analysis(), Simd_Finalize_Loops(), Sink_Out_Sandwiched_Statement(), SNL_Auto_Parallelization(), SNL_Bad_Scalars_Are_Distributable(), SNL_Dir_Cannot_Interchange(), SNL_Distribute(), SNL_Distribute_By_Splitting(), SNL_Distribute_For_Permutation(), SNL_Finalize_Index_Variables(), SNL_GEN_2D_Regtile(), SNL_GEN_Distribute(), SNL_GEN_Permute_Loops(), SNL_GEN_Protect_Nest_With_Conditionals(), SNL_GEN_Scalar_Expand(), SNL_GEN_U_Ctiling(), SNL_Inner_Cache_Cost(), SNL_Inner_Machine_Cost(), SNL_INV_Distribute(), SNL_INV_Distribution(), SNL_INV_Limited_SE_And_Dist(), SNL_INV_Permute_Loops(), SNL_INV_Scalar_Expand(), SNL_INV_Scalar_Expand_Tile(), SNL_INV_SE_Distribute(), SNL_INV_Transforms(), SNL_Is_Distributable(), SNL_Is_Scalar_Expandable(), SNL_Legal_Permutation(), SNL_Lift_Lego_Tile_Loops_Once(), SNL_Lift_Lego_Tile_Loops_Shifts(), SNL_Min_Parallel_Overhead_Cost(), SNL_NEST_INFO::SNL_NEST_INFO(), SNL_Parallelization_Costs(), SNL_Peel_Iteration(), SNL_Permutation_Is_Distributable(), SNL_Permutation_Needs_Distribution(), SNL_Permute_Loops(), SNL_Rebuild_Access_Arrays(), SNL_Scalar_Expand(), SNL_Scalar_Expand_For_Splitting(), SNL_Transform(), SNL_Upper_Bound_Standardize(), Split_Depth(), PF_LOOPNODE::Split_Loops(), Splittable(), Statement_Sinkable_Out_Of_Loop(), Tile_Loop(), Transform_Code(), LOOP_MODEL::Try_Inner(), Unify_Loop(), SX_INFO::Update_Reduction_Loop_Stmts(), UT_Generate_Imperfect_If_Code(), Version_Loop(), Version_Region(), Vintrinsic_Fission(), Walk_Projected_Region(), and Wind_Down().

static void Build_Doloop_Stack_Rec ( WN wn,
WN parent,
DOLOOP_STACK stack 
) [static]

Definition at line 765 of file lnoutils.cxx.

References LWN_Get_Parent, OPC_DO_LOOP, STACK< T >::Push(), WN_do_body, and WN_opcode().

Referenced by Build_Doloop_Stack().

void Build_Parent_Stack ( WN wn,
STACK< WN * > *  stack 
)

Definition at line 4507 of file lnoutils.cxx.

References Build_Parent_Stack(), LWN_Get_Parent, and STACK< T >::Push().

Referenced by Build_Parent_Stack(), and Common_Ancestor().

WN* Common_Ancestor ( WN wn1,
WN wn2 
)

WN* Common_Loop_Ancestor ( WN wn1,
WN wn2 
)

void Constant_Propogate ( WN stid,
INT64  const_val 
)

BOOL Contains_Dedicated_Preg ( WN wn_tree  ) 

WN* Create_ILoad_From_IStore ( WN wn_store,
DU_MANAGER du,
ARRAY_DIRECTED_GRAPH16 dg 
)

SYMBOL Create_Preg_Symbol ( const char *  name,
TYPE_ID  type 
)

void Create_Single_Region ( WN wn_single,
WN wn_end 
)

SYMBOL Create_Stack_Symbol ( const char *  name,
TYPE_ID  type 
)

ACCESS_VECTOR* Difference_Inequality ( ACCESS_VECTOR lb,
ACCESS_VECTOR ub,
INT  var,
DIFFERENCE_KIND  code,
MEM_POOL pool 
)

INT Do_Depth ( WN wn,
WN **  loops,
INT  mx 
)

BOOL Do_Loop_Is_Mp ( WN wn  ) 

BOOL Do_Loop_Is_Unsigned ( WN wn_loop  ) 

TYPE_ID Do_Wtype ( WN wn  ) 

INT64 Dot_Product ( const mINT64 v1,
const mINT32 v2,
INT  cnt 
)

Definition at line 338 of file lnoutils.cxx.

References i, INT, INT64, and s.

INT64 Dot_Product ( const mINT32 v1,
const mINT64 v2,
INT  cnt 
)

Definition at line 330 of file lnoutils.cxx.

References i, INT, INT64, and s.

INT64 Dot_Product ( const mINT64 v1,
const mINT64 v2,
INT  cnt 
)

Definition at line 322 of file lnoutils.cxx.

References i, INT, INT64, and s.

INT32 Dot_Product ( const mINT32 v1,
const mINT32 v2,
INT  cnt 
)

Definition at line 314 of file lnoutils.cxx.

References i, INT, INT32, and s.

Referenced by SNL_GEN_U_Ctiling().

void Du_Sanity_Check ( WN wn,
FILE fp,
UINT  fancy 
)

void Du_Sanity_Check_Matching_Du ( STACK< WN * > *  read_stack,
STACK< WN * > *  write_stack,
FILE fp,
UINT  fancy 
)

static void Du_Sanity_Check_r ( WN wn,
HASH_TABLE< WN *, INT > *  h_table,
UINT  pass,
FILE fp,
UINT  fancy,
STACK< WN * > *  reads,
STACK< WN * > *  writes 
) [static]

void Dump_WN ( WN wn,
FILE f,
INT  fancy,
INT  ws,
INT  ws_inc,
ARRAY_DIRECTED_GRAPH16 dg,
WN **  list,
WN parent,
BOOL  recursive 
)

WN* Enclosing_Do_Loop ( WN wn  ) 

WN* Enclosing_Loop ( WN wn  ) 

WN* Enclosing_Loop_Body ( WN wn  ) 

WN* Enclosing_Proper_Do_Loop ( WN wn_ref  ) 

BOOL Equivalent_Access_Arrays ( ACCESS_ARRAY array1,
ACCESS_ARRAY array2,
WN wn1,
WN wn2 
)

Definition at line 3632 of file lnoutils.cxx.

References FALSE, FmtAssert, INT, ACCESS_ARRAY::Non_Const_Loops(), NULL, Num_Common_Loops(), and TRUE.

Referenced by BS_Matching_Load(), and Process_Store().

static BOOL Exp_Depends_On_Outer_Loop ( WN wn_exp,
SYMBOL  index_var,
ARRAY_DIRECTED_GRAPH16 dg,
DU_MANAGER du 
) [static]

INT Factorial ( INT  n  ) 

Definition at line 4761 of file lnoutils.cxx.

References FmtAssert, i, and INT.

Referenced by Choose(), and Is_Legal_Permutation_Class().

void FB_Sanity_Check ( WN wn  ) 

void Finalize_Index_Variable ( WN loop,
BOOL  insert_after_loop,
BOOL  try_sink 
)

void Finalize_Index_Variable_For_Remove_Unity_Trip_Loop ( WN loop,
BOOL  insert_after_loop,
BOOL  try_sink 
)

HASH_TABLE<WN*,BOOL>* Find_Loops_Within ( WN orig,
MEM_POOL pool 
)

Definition at line 3529 of file lnoutils.cxx.

References CXX_NEW, and Find_Loops_Within_Walk().

Referenced by SX_INFO::Make_Sx_Info().

static void Find_Loops_Within_Walk ( WN wn,
HASH_TABLE< WN *, BOOL > *  ht 
) [static]

WN* Find_Node ( SYMBOL  sym,
WN wn_tree 
)

static void Flip_Le_And_Ge ( WN wn  )  [static]

RID* Get_Enclosing_Region_ID ( WN wn  ) 

ST* Get_ST_Base ( WN load  ) 

static ST* Get_ST_Base ( ST st  )  [static]

INT Good_Do_Depth ( WN wn,
WN **  loops,
INT  mx 
)

BOOL Identity_Permutation ( INT  permutation[],
INT  nloops 
)

BOOL Index_Variable ( WN wn_index  ) 

BOOL Index_Variable_Live_At_Entry ( WN loop  ) 

Definition at line 2022 of file lnoutils.cxx.

References Is_Used(), WN_index, and WN_start.

Referenced by Minimal_Kernel(), and SNL_Is_Transformable().

BOOL Index_Variable_Live_At_Exit ( WN loop  ) 

static void Initialize_Symbols ( STACK< SYMBOL > &  symbols,
STACK< WN * > &  loops,
WN wn 
) [static]

Definition at line 3227 of file lnoutils.cxx.

References LWN_Get_Parent, OPC_DO_LOOP, STACK< T >::Push(), WN_index, and WN_opcode().

Referenced by IV_Loop_Stmt_Check().

BOOL Is_Lex_Before ( WN wn1,
WN wn2 
)

BOOL Is_Local_Array_Reference ( WN array  ) 

BOOL Is_Loop_Invariant_Exp ( WN wn,
WN outerloop 
)

BOOL Is_Loop_Invariant_Use ( WN wn,
WN outerloop 
)

BOOL Is_Mp_Region ( WN wn  ) 

Definition at line 3945 of file lnoutils.cxx.

References FALSE, FmtAssert, NULL, OPC_REGION, REGION_get_rid(), RID_TYPE_mp, TRUE, and WN_opcode().

BOOL Is_Nested_Doacross ( WN wn_loop  ) 

BOOL Is_Permutation_Vector ( const INT  order[],
INT  nloops 
)

static BOOL Is_Used ( WN wn,
const SYMBOL sym 
) [static]

void IV_Loop_Stmt_Check ( WN wn,
MEM_POOL pool 
)

Definition at line 3240 of file lnoutils.cxx.

References Initialize_Symbols(), IV_Loop_Stmt_Check_X(), LWN_Get_Parent, and symbols.

Referenced by Du_Sanity_Check().

static void IV_Loop_Stmt_Check_X ( STACK< SYMBOL > &  symbols,
STACK< WN * > &  loops,
WN wn 
) [static]

WN* LNO_Common_Loop ( WN wn1,
WN wn2 
)

Definition at line 3584 of file lnoutils.cxx.

void LNO_Erase_Vertices_In_Loop ( WN wn,
ARRAY_DIRECTED_GRAPH16 dg 
)

static void LNO_Erase_Vertices_In_Loop_Rec ( WN wn,
ARRAY_DIRECTED_GRAPH16 dg 
) [static]

ST* Lookup_Function_Name ( const char *  name  ) 

INT Loop_Depth ( WN stat  ) 

BOOL Loop_Is_Trapezoidal ( WN wn_loop,
ARRAY_DIRECTED_GRAPH16 dg,
DU_MANAGER du 
)

Definition at line 3773 of file lnoutils.cxx.

References Exp_Depends_On_Outer_Loop(), FALSE, TRUE, WN_end, WN_start, and WN_step.

Referenced by Inner_Loop_Is_Trapezoidal().

WN* Loop_Step ( WN wn_loop  ) 

INT64 LWN_Get_Linenum ( const WN wn  ) 

WN* LWN_Integer_Cast ( WN tree,
TYPE_ID  to,
TYPE_ID  from 
)

WN* LWN_Integer_Casts ( WN tree,
TYPE_ID  to,
TYPE_ID  from 
)

WN* LWN_Make_Icon ( TYPE_ID  wtype,
INT64  i 
)

Definition at line 93 of file lnoutils.cxx.

References MTYPE_V, OPCODE_make_op(), OPR_INTCONST, and WN_CreateIntconst.

Referenced by Add_To_Symbol(), Affinity_Array_Lower_Bound(), Affinity_Array_Upper_Bound(), BND_Max_Expr(), BND_Min_Expr(), DISTR_DIM::Chunksize(), Constant_Propogate(), Copy_Array(), Create_Array_Load(), Create_Array_Store(), Create_Initialize_Loop(), ARRAY_LOWER_REF::Create_Local_Blkcyc_Dim(), ARRAY_LOWER_REF::Create_Local_Block_Dim(), ARRAY_LOWER_REF::Create_Local_Cyclic_Dim(), LEGO_INFO::Create_Local_Index(), ARA_LOOP_INFO::Create_New_IF_Clause(), ARA_LOOP_INFO::Create_Old_IF_Clause(), Create_Positive_Divceil(), Create_Tmp_Array(), Current_Numprocs(), ARRAY_DESCRIPTOR::Distribute_Array(), EC_Array_Portion_Calls(), Extended_Lower_Bound(), Extended_Upper_Bound(), Fold_Base(), Fold_Offset(), Fuse(), Gather_Scatter_Scalar_Expand(), Gen_Alloc_DART(), Gen_Init_DART(), Gen_Malloc_Cart(), PF_LG::Gen_Pref_Node(), Generate_Blkcyc_Bounds(), Generate_Block_Bounds(), Generate_Block_Bounds_Negative(), ARA_LOOP_INFO::Generate_Copyout_Loop(), Generate_Cyclic_Bounds(), Generate_Dynamic_Bounds(), ARA_LOOP_INFO::Generate_Parallel_Pragma(), Generate_Runtime_Cyclic_Bounds(), Generate_Simple_Bounds(), generate_tree_add(), generate_tree_from_bounds_info_row(), generate_tree_from_row(), Get_Array_Dimension_LB(), Get_Array_Dimension_Size(), Get_Runtime_Numthreads_Ldid(), Increase_By(), Initialize_Pdo_Last_Local_Index(), Instrument_Address(), Interleaved_Pragma_Chunksize(), Lego_Index_From_Access_Vector(), Lego_Skew_Offset(), ARRAY_LOWER_REF::Lower_Array_Expr(), Lower_Bound_In_Affinity_Range(), Mark_Code(), Mp_Coordinate_Call(), Mp_Layout_Call(), Mp_Layout_Copy_In_Onto(), Mp_Version_Loop(), Mp_Version_Parallel_Region(), New_DACT(), Parallelize_Doacross_Loop(), Perform_Gather_Scatter(), Post_loop_peeling(), Pre_loop_peeling(), Processor_Update_Outer_Tile(), Promote_Pointer(), Rewrite_Bounds(), SE_Array(), SE_Findxs(), SE_Indxs_and_Bounds(), SE_Wrap_Array(), SNL_Access_Index_Section(), SNL_Access_Linear_Section(), SNL_Access_Nonlinear_Section(), SNL_GEN_2D_Regtile(), SNL_INV_Cache_Block(), SNL_Optimize_LB_With_Access_Vectors(), SNL_Optimize_UB_With_Access_Vectors(), SNL_Peel_Iteration(), SNL_SPL_Fix_First_Outer_Loop_Limits(), STD_Canonicalize_Upper_Bound(), Step_Size(), Thread_Affinity_Lower(), Trip_Count(), Trip_Reduce_Loop(), Upper_Bound_In_Affinity_Range(), Upper_Bound_Standardize(), Version_Loop(), and Version_Region().

void LWN_Parentize_One_Level ( const WN wn  ) 

static WN* LWN_Short_Integer_Cast ( WN tree,
TYPE_ID to,
TYPE_ID  from 
) [static]

LOOP_MAPPING* Make_Loop_Mapping ( WN orig,
WN copy,
MEM_POOL pool 
)

OPCODE Matching_Load_Opcode ( OPCODE  store_op  ) 

TYPE_ID Max_Wtype ( TYPE_ID  a,
TYPE_ID  b 
)

WN* Messy_Subscript ( WN wn_array  ) 

static WN* Normal_Outer_Tile ( WN wn_loop,
DU_MANAGER du 
) [static]

INT Num_Common_Loops ( WN wn1,
WN wn2 
)

WN* Outer_Tile ( WN wn_loop,
DU_MANAGER du 
)

WN* Outermost_Enclosing_Good_Loop ( WN loop  ) 

WN* Outermost_Enclosing_Loop ( WN loop  ) 

Definition at line 2271 of file lnoutils.cxx.

References Do_Loop_Depth(), LWN_Get_Parent, OPC_DO_LOOP, and WN_opcode().

static void Patch_Uses_In_Loop ( WN wn_asg,
WN wn_loop 
) [static]

void Permutation ( INT  order,
INT  nloops,
INT  permutation[] 
)

Definition at line 4776 of file lnoutils.cxx.

References CXX_NEW_ARRAY, i, INT, Is_Permutation_Vector(), Is_True, LNO_local_pool, and next_index.

void Print_Def_Use ( WN wn,
FILE fp 
)

static void printws ( FILE f,
INT  ws 
) [static]

Definition at line 350 of file lnoutils.cxx.

References buf, fprintf(), i, INT, and MIN.

Referenced by Dump_WN().

INT Reduce_Permutation ( INT  permutation[],
INT  nloops,
INT  spermutation[],
INT  max_reduction 
)

Definition at line 4698 of file lnoutils.cxx.

References i, and INT.

void Remark_Depth ( WN wn,
mUINT8  depth 
)

void Remove_Redundant_Stids ( WN wn_start,
DU_MANAGER du 
)

void Replace_Index_Variable ( WN loop,
WN cp_loop,
const char  prefix[] 
)

void Replace_Ldid_With_Exp_Copy ( SYMBOL  symbol,
WN wn,
WN expr,
DU_MANAGER du,
ARRAY_DIRECTED_GRAPH16 dep_graph 
)

WN* Replace_Scalar_Store_With_Array_Store ( WN scalar_store,
WN array_store,
DU_MANAGER du 
)

void Replace_Symbol ( WN wn,
SYMBOL  symold,
SYMBOL  symnew,
WN alias_wn,
WN ancestor 
)

void Replace_Symbols ( WN wn,
SYMBOL sold,
SYMBOL snew,
INT  count,
WN **  alias_wn,
WN **  ancestors 
)

WN* Replace_Wnexp_With_Exp_Copy ( WN wn,
WN expr,
DU_MANAGER du,
BOOL added_cvt,
ARRAY_DIRECTED_GRAPH16 dep_graph 
)

static void reset_do ( WN body,
INT  depth 
) [static]

void Reset_Do_Loop_Depths ( WN loop,
INT  depth 
)

WN* Return_Node ( WN wn_func_nd  ) 

static void SNL_Make_Loop_Mapping_Inside ( WN orig,
WN copy,
LOOP_MAPPING ht 
) [static]

BOOL Solve_For ( WN wn_top,
const SYMBOL sym 
)

BOOL Statically_Safe_Exp ( WN wn  ) 

BOOL Statically_Safe_Node ( WN wn  ) 

Definition at line 1495 of file lnoutils.cxx.

References Alias_Mgr, and WN_Can_Be_Speculative().

Referenced by Hoist_Place(), and Is_Loop_Invariant_Exp().

INT64 Step_Size ( WN loop  ) 

Definition at line 194 of file lnoutils.cxx.

References Step_Size().

INT64 Step_Size ( WN loop,
INT64  newstep 
)

INT Symbol_Count ( WN wn,
const SYMBOL sym 
)

static BOOL Symbol_In_Expression ( WN wn_exp,
SYMBOL  sym,
DU_MANAGER du 
) [static]

INT sz ( TYPE_ID  wtype  )  [inline]

Definition at line 1162 of file lnoutils.cxx.

References FmtAssert, MTYPE_I4, MTYPE_I8, MTYPE_U4, and MTYPE_U8.

Referenced by _bfd_coff_final_link(), _bfd_elf_mips_get_relocated_section_contents(), _bfd_generic_get_section_contents(), _bfd_generic_get_section_contents_in_window(), _bfd_mips_elf_modify_segment_map(), _bfd_xcoff_bfd_final_link(), _bfd_xcoff_slurp_armap(), _wf_setup(), CODEMAP::Add_idef(), alpha_ecoff_get_relocated_section_contents(), array_type_nelts_total(), bfd_coff_reloc16_get_relocated_section_contents(), bfd_ecoff_debug_accumulate(), bfd_generic_get_relocated_section_contents(), bfd_get_section_contents(), bfd_malloc_and_get_section(), bfd_set_section_contents(), bfin_valid_add(), Cache_Model(), cache_presence(), compare_states_for_equiv(), Convert_Alloca_To_Intrinsic(), Convert_Intrinsic_To_Alloca_Dealloca(), cwh_addr_adjust_array(), cwh_addr_mstore(), cwh_addr_temp_section(), cwh_dope_initialize(), cwh_dst_dope_bounds(), cwh_expr_compare_char(), cwh_intrin_ieee_intrin_call_helper(), cwh_intrin_ieee_intrin_helper(), cwh_intrin_sync_intrin(), cwh_stmt_character_icall(), cwh_types_dim_struct_TY(), cwh_types_dim_TY(), cwh_types_mk_common_TY(), cwh_types_mk_equiv_TY(), cwh_types_shared_dope(), Dump_Rta_Scns(), elf64_alpha_relax_got_load(), elf64_alpha_relax_tls_get_addr(), elf64_alpha_relax_with_lituse(), elf_link_add_object_symbols(), examine_objects(), Expand_Statement(), fei_as_ref(), fei_concat(), fei_free(), fei_malloc(), fei_mfree(), fei_substr(), ffebld_size_max(), ffecom_arg_ptr_to_expr(), ffecom_char_enhance_arg_(), ffecom_concat_list_gather_(), ffecom_gen_sfuncdef_(), ffecom_prepare_expr_(), ffeexpr_collapse_convert(), ffeintrin_check_(), ffeintrin_fulfill_generic(), ffeintrin_fulfill_specific(), ffetarget_real1(), ffetarget_real2(), function_prologue(), Gather_Scatter_Scalar_Expand(), ip2k_gen_sCOND(), ip2k_gen_signed_comp_branch(), ip2k_gen_unsigned_comp_branch(), LNO_Update_Indx_Range(), LWN_Integer_Cast(), MTYPE_size(), NAME(), PF_UGS::PF_UGS(), ppc64_elf_edit_toc(), ppc_bfd_coff_final_link(), push_fields_onto_fieldstack(), read_indirect_string(), rs6000_emit_prologue(), save_restore_insns(), Scalar_Expand(), SE_Indxs_and_Bounds(), Section_Variable_TY(), MEM_RANGE::Set_access_range(), VN_EXPR_MAP::set_map(), PF_LG::Split_LG(), state_is_differed(), unwind_frame(), warn_about_normalization(), write_replacement(), and xcoff64_slurp_armap().

WN* Trip_Count ( WN wn_loop  ) 

WN* UBexp ( WN end,
BOOL ne 
)

WN* UBvar ( WN end  ) 

Definition at line 4064 of file lnoutils.cxx.

static WN* Unique_Ldid_Symbol ( WN wn_exp,
DU_MANAGER du 
) [static]

static WN* Unique_Stid_Definition ( WN wn_ldid,
DU_MANAGER du 
) [static]

void Unrolled_DU_Update ( WN **  bodies,
UINT  u,
INT  loopno,
BOOL  update_pointers,
BOOL  cross_index 
)

static void Unrolled_DU_Update_E ( UINT  u,
INT  loopno,
HASH_TABLE< WN *, WN ** > *  hash_table,
STACK< WN * > *  load_stack,
STACK< WN * > *  store_stack,
BOOL  update_pointers,
SYMBOL index_loopno 
) [static]

static void Unrolled_DU_Update_V ( WN **  bodies,
UINT  u,
HASH_TABLE< WN *, WN ** > *  hash_table,
STACK< WN * > *  load_stack,
STACK< WN * > *  store_stack 
) [static]

void Update_MP_Local_Var ( ST st,
WN_OFFSET  offset,
WN wn 
)

static void Update_Nest_Depth ( WN wn_tree  )  [static]

Definition at line 2359 of file lnoutils.cxx.

References Update_Nest_Depth_Traverse().

Referenced by Finalize_Index_Variable().

static void Update_Nest_Depth_Traverse ( WN wn_tree  )  [static]

BOOL Upper_Bound_Standardize ( WN ub,
BOOL  ok_to_fail 
)

Definition at line 2218 of file lnoutils.cxx.

References BOOL, Do_Loop_Is_Unsigned(), FALSE, FmtAssert, LWN_Copy_Frequency_Tree(), LWN_CreateExp2(), LWN_Get_Parent, LWN_Make_Icon(), LWN_Set_Parent, MTYPE_is_integral, MTYPE_V, Name, NULL, ok(), opc, OPC_DO_LOOP, OPCODE_desc(), OPCODE_make_op(), OPCODE_name(), OPCODE_operator(), OPCODE_rtype(), OPR_LE, OPR_LT, OPR_SUB, Solve_For(), TYPE_ID, UBvar(), WN_index, WN_kid1(), WN_opcode(), WN_operator(), and WN_set_opcode().

Referenced by ARA_LOOP_INFO::Const_Work_Estimate(), ARA_LOOP_INFO::Create_New_IF_Clause(), Eliminate_Dead_Do(), fast_fuse_check_ok(), Finalize_Index_Variable(), Find_Do_Loop_With_Min(), Fuse(), Gather_Scatter_Scalar_Expand(), Generate_Bounds(), Handle_Sink_Promotion_Case(), Handle_Sink_Symbolic_Non_Promotion_Case(), HMB_Maximum_Point(), HoistIf(), Invariant_Loops(), ARA_LOOP_INFO::Is_OK_Parallel(), ARA_LOOP_INFO::Is_Parallel(), Iterations(), Lego_Loop_Want_Skew(), Loop_Bounds_Simple(), Maybe_Handle_Sink_Promotion_Case(), Minimal_Kernel(), Mp_Tile_Single_Loop(), Perfect_Nested_Outer_Loop(), Post_loop_peeling(), ARA_LOOP_INFO::Print_Loop_Property(), Print_Prompf_Msgs(), Print_Prompl_Msgs(), Scalar_Expandable(), SE_Tile_Inner_Loop(), Simd_Pre_Analysis(), SNL_Finalize_Loops(), SNL_INV_Cache_Block(), SNL_Is_Transformable(), SNL_Optimize_UB_With_Access_Vectors(), SNL_Peel_Iteration(), SNL_SPL_Loop_Is_Inner_Tile(), SNL_TRANS_INDEX_DATA::SNL_TRANS_INDEX_DATA(), SNL_UB_Worth_Optimizing(), SNL_Upper_Bound_Standardize(), Standardize_For_Tiling(), Statement_Sinkable_Out_Of_Loop(), Tile_Loop(), Trip_Count(), Twod_Setbound(), Upper_Bound_In_Affinity_Range(), and Vintrinsic_Fission().

static WN* Wind_Down_Parent ( WN wn_loop,
DU_MANAGER du 
) [static]

void wn_dumpexpr ( WN wn,
INT  fancy,
FILE f,
ARRAY_DIRECTED_GRAPH16 dg,
WN **  list,
WN parent,
BOOL  recursive 
)

BOOL Wn_Is_Inside ( WN inner,
const WN outer 
)

WN* WN_next_executable ( WN wn  ) 

WN* WN_prev_executable ( WN wn  ) 

INT WN_Whirl_Linenum ( WN wn_ref  ) 


Variable Documentation


Generated on Wed Apr 8 14:33:40 2009 for Open64 by  doxygen 1.5.6