#include <limits.h>#include <float.h>#include "defs.h"#include "errors.h"#include "tracing.h"#include "mempool.h"#include "register.h"#include "priority_queue.h"#include "cg_flags.h"#include "gra_bb.h"#include "gra.h"#include "gra_region.h"#include "gra_trace.h"#include "gra_lrange.h"#include "gra_split.h"#include "gra_grant.h"#include "gra_spill.h"#include "gra_interfere.h"

Go to the source code of this file.
Data Types | |
| module | LRANGE_PREF_ITER |
Functions/Subroutines | |
| static void | Initialize (void) |
| static void | Update_Register_Info (LRANGE *lrange, REGISTER reg, BOOL reclaim=FALSE) |
| static BOOL | Choose_Best_Register (REGISTER *reg, ISA_REGISTER_CLASS rc, REGISTER_SET allowed, BOOL remove_global_callees, BOOL prefer_caller_stacked) |
| static BOOL | Choose_Preference (LRANGE *lrange, REGISTER_SET allowed, GRA_REGION *region) |
| static BOOL | Choose_Avoiding_Neighbor_Preferences (LRANGE *lrange, REGISTER_SET allowed) |
| static BOOL | Allocate_Stacked_Register (LRANGE *lrange) |
| static BOOL | Choose_Noones_Preference (LRANGE *lrange, REGISTER_SET allowed) |
Variables | |
| INT32 | GRA_local_forced_max = DEFAULT_FORCED_LOCAL_MAX |
| BOOL | GRA_avoid_glue_references_for_locals = TRUE |
| static REGISTER_SET | non_prefrenced_regs [ISA_REGISTER_CLASS_MAX+1] |
| static REGISTER_SET | callee_saves_used [ISA_REGISTER_CLASS_MAX+1] |
| static REGISTER_SET | regs_used [ISA_REGISTER_CLASS_MAX+1] |
| static MEM_POOL | prq_pool |
| static GRA_REGION * | GRA_current_region |
Definition at line 536 of file gra_color.cxx.
References FALSE, GRA_use_stacked_regs, INT, LRANGE::Rc(), REGISTER_Has_Stacked_Registers(), REGISTER_Request_Stacked_Register(), REGISTER_UNDEFINED, LRANGE::Spans_A_Call(), LRANGE::Spans_A_Setjmp(), TRUE, and Update_Register_Info().
| static BOOL Choose_Avoiding_Neighbor_Preferences | ( | LRANGE * | lrange, | |
| REGISTER_SET | allowed | |||
| ) | [static] |
Definition at line 471 of file gra_color.cxx.
References LRANGE::Allocated(), Choose_Best_Register(), GRA_PREF_LRANGE_ITER::Current(), LRANGE_NEIGHBOR_ITER::Current(), LRANGE_NEIGHBOR_ITER::Done(), GRA_PREF_LRANGE_ITER::Done(), FALSE, LRANGE_PREF_ITER::Init(), LRANGE_NEIGHBOR_ITER::Init(), LRANGE_TYPE_COMPLEMENT, LRANGE::Rc(), rc, LRANGE::Reg(), REGISTER_Has_Stacked_Registers(), REGISTER_SET_Difference1(), REGISTER_SET_EmptyP(), LRANGE::Spans_A_Call(), LRANGE::Spans_Infreq_Call(), LRANGE_NEIGHBOR_ITER::Step(), GRA_PREF_LRANGE_ITER::Step(), LRANGE::Tn(), TN_is_save_reg, TRUE, LRANGE::Type(), and Update_Register_Info().
| static BOOL Choose_Best_Register | ( | REGISTER * | reg, | |
| ISA_REGISTER_CLASS | rc, | |||
| REGISTER_SET | allowed, | |||
| BOOL | remove_global_callees, | |||
| BOOL | prefer_caller_stacked | |||
| ) | [static] |
Definition at line 358 of file gra_color.cxx.
References callee_saves_used, FALSE, REGISTER_CLASS_callee_saves, REGISTER_CLASS_caller_saves, REGISTER_Get_Stacked_Avail_Set(), REGISTER_Has_Stacked_Registers(), REGISTER_Request_Stacked_Register(), REGISTER_SET_Choose(), REGISTER_SET_Choose_Intersection(), REGISTER_SET_Difference(), REGISTER_SET_EmptyP(), REGISTER_SET_Union(), REGISTER_UNDEFINED, and TRUE.
Referenced by Choose_Avoiding_Neighbor_Preferences(), and Choose_Noones_Preference().
| static BOOL Choose_Noones_Preference | ( | LRANGE * | lrange, | |
| REGISTER_SET | allowed | |||
| ) | [static] |
Definition at line 581 of file gra_color.cxx.
References Choose_Best_Register(), FALSE, non_prefrenced_regs, LRANGE::Rc(), rc, REGISTER_Has_Stacked_Registers(), REGISTER_SET_Intersection(), LRANGE::Spans_A_Call(), LRANGE::Spans_Infreq_Call(), TRUE, and Update_Register_Info().
| static BOOL Choose_Preference | ( | LRANGE * | lrange, | |
| REGISTER_SET | allowed, | |||
| GRA_REGION * | region | |||
| ) | [static] |
Definition at line 434 of file gra_color.cxx.
References GRA_PREF_LRANGE_ITER::Current(), GRA_PREF_LRANGE_ITER::Done(), FALSE, GRA_Trace_Preference_Attempt(), LRANGE_PREF_ITER::Init(), iter, LRANGE::Reg(), region, REGISTER_SET_MemberP(), GRA_PREF_LRANGE_ITER::Step(), TRUE, and Update_Register_Info().
Definition at line 215 of file gra_color.cxx.
References BOOL, GRA_PARA_REGION_MGR::Build_Map_For_Pair_Region(), callee_saves_used, FALSE, FOR_ALL_ISA_REGISTER_CLASS(), gra_para_region_mgr, GRA_pool, MEM_POOL_Initialize, non_prefrenced_regs, GRA_PARA_REGION_MGR::Pre_Reserve_Registers_For_Minor(), PU_BB_Count, rc, REGISTER_CLASS_allocatable, REGISTER_SET_EMPTY_SET, regs_used, and TRUE.
Definition at line 288 of file gra_color.cxx.
References GRA_PARA_REGION::Add_One_Exclude_Register(), LRANGE::Allocate_Register(), GRA_BB::Bb(), callee_saves_used, GRA_REGION::First_Gbb(), LRANGE::Gbb(), GRA_PARA_REGION_MGR::Get(), GRA_PARA_REGION_MGR::Get_Pair_Rid(), gra_para_region_mgr, GRA_pool, LRANGE::Has_Preference(), HAS_STACKED_REGISTERS, LRANGE::Has_Wired_Register(), Is_Predicate_REGISTER_CLASS(), Is_True, iter, GRA_REGION::Last_Gbb(), LRANGE::Live_BB_Set(), LRANGE_TYPE_COMPLEMENT, LRANGE_TYPE_LOCAL, non_prefrenced_regs, LRANGE::Rc(), rc, LRANGE::Region(), GRA_BB::Region_Next(), REGISTER_CLASS_callee_saves, REGISTER_Is_Stacked_Local(), REGISTER_SET_Difference1(), REGISTER_SET_MemberP(), REGISTER_SET_Union1(), regs_used, LRANGE::Tn_Is_Save_Reg(), and LRANGE::Type().
Referenced by Allocate_Stacked_Register(), Choose_Avoiding_Neighbor_Preferences(), Choose_Noones_Preference(), and Choose_Preference().
REGISTER_SET callee_saves_used[ISA_REGISTER_CLASS_MAX+1] [static] |
Definition at line 113 of file gra_color.cxx.
Referenced by Choose_Best_Register(), Initialize(), and Update_Register_Info().
Definition at line 106 of file gra_color.cxx.
GRA_REGION* GRA_current_region [static] |
Definition at line 120 of file gra_color.cxx.
| INT32 GRA_local_forced_max = DEFAULT_FORCED_LOCAL_MAX |
Definition at line 98 of file gra_color.cxx.
REGISTER_SET non_prefrenced_regs[ISA_REGISTER_CLASS_MAX+1] [static] |
Definition at line 110 of file gra_color.cxx.
Referenced by Choose_Noones_Preference(), Initialize(), and Update_Register_Info().
Definition at line 118 of file gra_color.cxx.
REGISTER_SET regs_used[ISA_REGISTER_CLASS_MAX+1] [static] |
Definition at line 116 of file gra_color.cxx.
Referenced by choose_reload_regs(), find_invariants_to_move(), gen_block_redirect(), Identify_Max_Colorable_Neighborhood(), Initialize(), Max_Colorable_LUNIT(), output_function_prologue(), regs_used(), and Update_Register_Info().
1.5.6