Add a NextMBBNumber field w/ incrementing accessor method, for
function-level unique numbering of MBBs. llvm-svn: 13513
This commit is contained in:
parent
00db6be879
commit
379e609e3d
|
@ -49,6 +49,9 @@ class MachineFunction : private Annotation {
|
||||||
// Keep track of constants which are spilled to memory
|
// Keep track of constants which are spilled to memory
|
||||||
MachineConstantPool *ConstantPool;
|
MachineConstantPool *ConstantPool;
|
||||||
|
|
||||||
|
// Function-level unique numbering for MachineBasicBlocks
|
||||||
|
int NextMBBNumber;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
MachineFunction(const Function *Fn, const TargetMachine &TM);
|
MachineFunction(const Function *Fn, const TargetMachine &TM);
|
||||||
~MachineFunction();
|
~MachineFunction();
|
||||||
|
@ -82,6 +85,10 @@ public:
|
||||||
///
|
///
|
||||||
MachineFunctionInfo *getInfo() const { return MFInfo; }
|
MachineFunctionInfo *getInfo() const { return MFInfo; }
|
||||||
|
|
||||||
|
/// getNextMBBNumber - Returns the next unique number to be assigned
|
||||||
|
/// to a MachineBasicBlock in this MachineFunction.
|
||||||
|
///
|
||||||
|
int getNextMBBNumber() { return NextMBBNumber++; }
|
||||||
|
|
||||||
/// print - Print out the MachineFunction in a format suitable for debugging
|
/// print - Print out the MachineFunction in a format suitable for debugging
|
||||||
/// to the specified stream.
|
/// to the specified stream.
|
||||||
|
|
Loading…
Reference in New Issue