aboutsummaryrefslogtreecommitdiff
path: root/include/llvm/CodeGen/MachineFunction.h
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2002-10-28 05:58:46 +0000
committerChris Lattner <sabre@nondot.org>2002-10-28 05:58:46 +0000
commit335d5c399b52c2507ad11048310edc51462f4811 (patch)
tree04ea2c3ac76215362a0fe827f8ac8090050a9763 /include/llvm/CodeGen/MachineFunction.h
parentd0aa0cdbc6fee00f2b2019633a9b9d00d301ac68 (diff)
s/method/function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@4338 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/CodeGen/MachineFunction.h')
-rw-r--r--include/llvm/CodeGen/MachineFunction.h18
1 files changed, 13 insertions, 5 deletions
diff --git a/include/llvm/CodeGen/MachineFunction.h b/include/llvm/CodeGen/MachineFunction.h
index 33f9efc281..e429fc4f11 100644
--- a/include/llvm/CodeGen/MachineFunction.h
+++ b/include/llvm/CodeGen/MachineFunction.h
@@ -27,7 +27,8 @@ Pass *createMachineCodeConstructionPass(TargetMachine &Target);
Pass *createMachineCodeDestructionPass();
class MachineFunction : private Annotation {
- const Function *method;
+ const Function *Fn;
+ const TargetMachine &Target;
// List of machine basic blocks in function
iplist<MachineBasicBlock> BasicBlocks;
@@ -47,8 +48,15 @@ class MachineFunction : private Annotation {
bool automaticVarsAreaFrozen;
public:
- MachineFunction(const Function* function,
- const TargetMachine& target);
+ MachineFunction(const Function *Fn, const TargetMachine& target);
+
+ /// getFunction - Return the LLVM function that this machine code represents
+ ///
+ const Function *getFunction() const { return Fn; }
+
+ /// getTarget - Return the target machine this machine code is compiled with
+ ///
+ const TargetMachine &getTarget() const { return Target; }
// The next two methods are used to construct and to retrieve
// the MachineFunction object for the given method.
@@ -57,8 +65,8 @@ public:
// This should not be called before "construct()"
// for a given Method.
//
- static MachineFunction& construct(const Function *method,
- const TargetMachine &target);
+ static MachineFunction& construct(const Function *Fn,
+ const TargetMachine &target);
static void destruct(const Function *F);
static MachineFunction& get(const Function *F);