forked from OSchip/llvm-project
[MachineFunction] Make comment for TracksLiveness more clearer
As discussed in https://lists.llvm.org/pipermail/llvm-dev/2021-April/150225.html, the current comments for TracksLiveness property and isKill flag are confusing. This patch makes the comments more clearer. Differential Revision: https://reviews.llvm.org/D101500
This commit is contained in:
parent
511f2cecf7
commit
b817ea7b17
|
@ -124,11 +124,14 @@ public:
|
||||||
// NoPHIs: The machine function does not contain any PHI instruction.
|
// NoPHIs: The machine function does not contain any PHI instruction.
|
||||||
// TracksLiveness: True when tracking register liveness accurately.
|
// TracksLiveness: True when tracking register liveness accurately.
|
||||||
// While this property is set, register liveness information in basic block
|
// While this property is set, register liveness information in basic block
|
||||||
// live-in lists and machine instruction operands (e.g. kill flags, implicit
|
// live-in lists and machine instruction operands (e.g. implicit defs) is
|
||||||
// defs) is accurate. This means it can be used to change the code in ways
|
// accurate, kill flags are conservatively accurate (kill flag correctly
|
||||||
// that affect the values in registers, for example by the register
|
// indicates the last use of a register, an operand without kill flag may or
|
||||||
// scavenger.
|
// may not be the last use of a register). This means it can be used to
|
||||||
// When this property is clear, liveness is no longer reliable.
|
// change the code in ways that affect the values in registers, for example
|
||||||
|
// by the register scavenger.
|
||||||
|
// When this property is cleared at a very late time, liveness is no longer
|
||||||
|
// reliable.
|
||||||
// NoVRegs: The machine function does not use any virtual registers.
|
// NoVRegs: The machine function does not use any virtual registers.
|
||||||
// Legalized: In GlobalISel: the MachineLegalizer ran and all pre-isel generic
|
// Legalized: In GlobalISel: the MachineLegalizer ran and all pre-isel generic
|
||||||
// instructions have been legalized; i.e., all instructions are now one of:
|
// instructions have been legalized; i.e., all instructions are now one of:
|
||||||
|
|
|
@ -99,8 +99,11 @@ private:
|
||||||
unsigned IsImp : 1;
|
unsigned IsImp : 1;
|
||||||
|
|
||||||
/// IsDeadOrKill
|
/// IsDeadOrKill
|
||||||
/// For uses: IsKill - True if this instruction is the last use of the
|
/// For uses: IsKill - Conservatively indicates the last use of a register
|
||||||
/// register on this path through the function.
|
/// on this path through the function. A register operand with true value of
|
||||||
|
/// this flag must be the last use of the register, a register operand with
|
||||||
|
/// false value may or may not be the last use of the register. After regalloc
|
||||||
|
/// we can use recomputeLivenessFlags to get precise kill flags.
|
||||||
/// For defs: IsDead - True if this register is never used by a subsequent
|
/// For defs: IsDead - True if this register is never used by a subsequent
|
||||||
/// instruction.
|
/// instruction.
|
||||||
/// This is only valid on register operands.
|
/// This is only valid on register operands.
|
||||||
|
|
Loading…
Reference in New Issue