mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-07-25 13:24:46 +00:00
IR: Expose the method 'getLocalSlot' in the module slot tracker.
This commit publicly exposes the method 'getLocalSlot' in the 'ModuleSlotTracker' class. This change is useful for MIR serialization, to serialize the unnamed basic block and unnamed alloca references. Reviewers: Duncan P. N. Exon Smith git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@243336 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -17,6 +17,7 @@ namespace llvm {
|
||||
class Module;
|
||||
class Function;
|
||||
class SlotTracker;
|
||||
class Value;
|
||||
|
||||
/// Manage lifetime of a slot tracker for printing IR.
|
||||
///
|
||||
@@ -61,6 +62,13 @@ public:
|
||||
/// Purge the currently incorporated function and incorporate \c F. If \c F
|
||||
/// is currently incorporated, this is a no-op.
|
||||
void incorporateFunction(const Function &F);
|
||||
|
||||
/// Return the slot number of the specified local value.
|
||||
///
|
||||
/// A function that defines this value should be incorporated prior to calling
|
||||
/// this method.
|
||||
/// Return -1 if the value is not in the function's SlotTracker.
|
||||
int getLocalSlot(const Value *V);
|
||||
};
|
||||
|
||||
} // end namespace llvm
|
||||
|
Reference in New Issue
Block a user