This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Doubt about Pseudo register uses.
- From: Chunjiang Li <chunjiang at nudt dot edu dot cn>
- To: gcc at gcc dot gnu dot org
- Date: Mon, 1 Aug 2005 18:17:28 +0800 (HKT)
- Subject: Doubt about Pseudo register uses.
- Reply-to: Chunjiang Li <chunjiang at nudt dot edu dot cn>
Hi, all,
When I read the GCC source code about register allocation,
I wonder is it true that one Pseudo register is only corresponding to one basic block?
the reg_info struct is:
typedef struct reg_info_def
{ /* fields set by reg_scan */
int first_uid; /* UID of first insn to use (REG n) */
int last_uid; /* UID of last insn to use (REG n) */
/* fields set by reg_scan & flow_analysis */
int sets; /* # of times (REG n) is set */
/* fields set by flow_analysis */
int refs; /* # of times (REG n) is used or set */
int freq; /* # estimated frequency (REG n) is used or set */
int deaths; /* # of times (REG n) dies */
int live_length; /* # of instructions (REG n) is live */
int calls_crossed; /* # of calls (REG n) is live across */
int basic_block; /* # of basic blocks (REG n) is used in */
} reg_info;
It seems that one Pseudo register is only used in one basic block.
But I am not sure.
Please help me.
Creative Compiler Research Group,
National University of Defense Technology, China.