aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/llvm/CodeGen/MachineBasicBlock.h22
-rw-r--r--include/llvm/CodeGen/MachineCodeForBasicBlock.h22
-rw-r--r--include/llvm/CodeGen/MachineCodeForMethod.h19
-rw-r--r--include/llvm/CodeGen/MachineFunction.h26
-rw-r--r--include/llvm/Target/MachineInstrInfo.h2
-rw-r--r--include/llvm/Target/TargetFrameInfo.h20
-rw-r--r--include/llvm/Target/TargetInstrInfo.h2
7 files changed, 62 insertions, 51 deletions
diff --git a/include/llvm/CodeGen/MachineBasicBlock.h b/include/llvm/CodeGen/MachineBasicBlock.h
index a95103f35f..1a3c7a00f6 100644
--- a/include/llvm/CodeGen/MachineBasicBlock.h
+++ b/include/llvm/CodeGen/MachineBasicBlock.h
@@ -1,27 +1,31 @@
-//===-- llvm/CodeGen/MachineCodeForBasicBlock.h -----------------*- C++ -*--=//
+//===-- llvm/CodeGen/MachineBasicBlock.h ------------------------*- C++ -*--=//
//
// Collect the sequence of machine instructions for a basic block.
//
//===---------------------------------------------------------------------===//
-#ifndef LLVM_CODEGEN_MACHINECODEFORBASICBLOCK_H
-#define LLVM_CODEGEN_MACHINECODEFORBASICBLOCK_H
+#ifndef LLVM_CODEGEN_MACHINEBASICBLOCK_H
+#define LLVM_CODEGEN_MACHINEBASICBLOCK_H
#include "llvm/BasicBlock.h"
class MachineInstr;
extern AnnotationID MCFBB_AID;
-class MachineCodeForBasicBlock : public Annotation {
+// FIXME: this should go away soon
+class MachineBasicBlock;
+typedef MachineBasicBlock MachineCodeForBasicBlock;
+
+class MachineBasicBlock: public Annotation {
std::vector<MachineInstr*> Insts;
public:
- MachineCodeForBasicBlock();
- ~MachineCodeForBasicBlock() {}
+ MachineBasicBlock();
+ ~MachineBasicBlock() {}
- // Static methods to retrieve or destroy the MachineCodeForBasicBlock
+ // Static methods to retrieve or destroy the MachineBasicBlock
// object for a given basic block.
- static MachineCodeForBasicBlock& get(const BasicBlock *bb) {
- return *(MachineCodeForBasicBlock*)bb->getOrCreateAnnotation(MCFBB_AID);
+ static MachineBasicBlock& get(const BasicBlock *bb) {
+ return *(MachineBasicBlock*)bb->getOrCreateAnnotation(MCFBB_AID);
}
static void destroy(const BasicBlock *bb) {
diff --git a/include/llvm/CodeGen/MachineCodeForBasicBlock.h b/include/llvm/CodeGen/MachineCodeForBasicBlock.h
index a95103f35f..1a3c7a00f6 100644
--- a/include/llvm/CodeGen/MachineCodeForBasicBlock.h
+++ b/include/llvm/CodeGen/MachineCodeForBasicBlock.h
@@ -1,27 +1,31 @@
-//===-- llvm/CodeGen/MachineCodeForBasicBlock.h -----------------*- C++ -*--=//
+//===-- llvm/CodeGen/MachineBasicBlock.h ------------------------*- C++ -*--=//
//
// Collect the sequence of machine instructions for a basic block.
//
//===---------------------------------------------------------------------===//
-#ifndef LLVM_CODEGEN_MACHINECODEFORBASICBLOCK_H
-#define LLVM_CODEGEN_MACHINECODEFORBASICBLOCK_H
+#ifndef LLVM_CODEGEN_MACHINEBASICBLOCK_H
+#define LLVM_CODEGEN_MACHINEBASICBLOCK_H
#include "llvm/BasicBlock.h"
class MachineInstr;
extern AnnotationID MCFBB_AID;
-class MachineCodeForBasicBlock : public Annotation {
+// FIXME: this should go away soon
+class MachineBasicBlock;
+typedef MachineBasicBlock MachineCodeForBasicBlock;
+
+class MachineBasicBlock: public Annotation {
std::vector<MachineInstr*> Insts;
public:
- MachineCodeForBasicBlock();
- ~MachineCodeForBasicBlock() {}
+ MachineBasicBlock();
+ ~MachineBasicBlock() {}
- // Static methods to retrieve or destroy the MachineCodeForBasicBlock
+ // Static methods to retrieve or destroy the MachineBasicBlock
// object for a given basic block.
- static MachineCodeForBasicBlock& get(const BasicBlock *bb) {
- return *(MachineCodeForBasicBlock*)bb->getOrCreateAnnotation(MCFBB_AID);
+ static MachineBasicBlock& get(const BasicBlock *bb) {
+ return *(MachineBasicBlock*)bb->getOrCreateAnnotation(MCFBB_AID);
}
static void destroy(const BasicBlock *bb) {
diff --git a/include/llvm/CodeGen/MachineCodeForMethod.h b/include/llvm/CodeGen/MachineCodeForMethod.h
index 742d4b5c0f..00f3cdee58 100644
--- a/include/llvm/CodeGen/MachineCodeForMethod.h
+++ b/include/llvm/CodeGen/MachineCodeForMethod.h
@@ -1,4 +1,4 @@
-//===-- llvm/CodeGen/MachineCodeForMethod.h ----------------------*- C++ -*--=//
+//===-- llvm/CodeGen/MachineFunction.h ----------------------*- C++ -*--=//
//
// Purpose:
// Collect native machine code information for a method.
@@ -6,8 +6,8 @@
// to be stored with each method.
//===----------------------------------------------------------------------===//
-#ifndef LLVM_CODEGEN_MACHINECODEFORMETHOD_H
-#define LLVM_CODEGEN_MACHINECODEFORMETHOD_H
+#ifndef LLVM_CODEGEN_MACHINEFUNCTION_H
+#define LLVM_CODEGEN_MACHINEFUNCTION_H
#include "llvm/Annotation.h"
#include "Support/NonCopyable.h"
@@ -19,8 +19,11 @@ class Constant;
class Type;
class TargetMachine;
+// FIXME: this should go away soon
+class MachineFunction;
+typedef MachineFunction MachineCodeForMethod;
-class MachineCodeForMethod : private Annotation {
+class MachineFunction : private Annotation {
hash_set<const Constant*> constantsForConstPool;
hash_map<const Value*, int> offsets;
const Function* method;
@@ -36,20 +39,20 @@ class MachineCodeForMethod : private Annotation {
bool automaticVarsAreaFrozen;
public:
- /*ctor*/ MachineCodeForMethod(const Function* function,
+ /*ctor*/ MachineFunction(const Function* function,
const TargetMachine& target);
// The next two methods are used to construct and to retrieve
- // the MachineCodeForMethod object for the given method.
+ // the MachineFunction object for the given method.
// construct() -- Allocates and initializes for a given method and target
// get() -- Returns a handle to the object.
// This should not be called before "construct()"
// for a given Method.
//
- static MachineCodeForMethod& construct(const Function *method,
+ static MachineFunction& construct(const Function *method,
const TargetMachine &target);
static void destruct(const Function *F);
- static MachineCodeForMethod& get(const Function* function);
+ static MachineFunction& get(const Function* function);
//
// Accessors for global information about generated code for a method.
diff --git a/include/llvm/CodeGen/MachineFunction.h b/include/llvm/CodeGen/MachineFunction.h
index 742d4b5c0f..141838f600 100644
--- a/include/llvm/CodeGen/MachineFunction.h
+++ b/include/llvm/CodeGen/MachineFunction.h
@@ -1,13 +1,13 @@
-//===-- llvm/CodeGen/MachineCodeForMethod.h ----------------------*- C++ -*--=//
+//===-- llvm/CodeGen/MachineFunction.h ---------------------------*- C++ -*--=//
//
-// Purpose:
-// Collect native machine code information for a method.
-// This allows target-specific information about the generated code
-// to be stored with each method.
+// Collect native machine code information for a method. This allows
+// target-specific information about the generated code to be stored with each
+// method.
+//
//===----------------------------------------------------------------------===//
-#ifndef LLVM_CODEGEN_MACHINECODEFORMETHOD_H
-#define LLVM_CODEGEN_MACHINECODEFORMETHOD_H
+#ifndef LLVM_CODEGEN_MACHINEFUNCTION_H
+#define LLVM_CODEGEN_MACHINEFUNCTION_H
#include "llvm/Annotation.h"
#include "Support/NonCopyable.h"
@@ -20,7 +20,7 @@ class Type;
class TargetMachine;
-class MachineCodeForMethod : private Annotation {
+class MachineFunction : private Annotation {
hash_set<const Constant*> constantsForConstPool;
hash_map<const Value*, int> offsets;
const Function* method;
@@ -36,20 +36,20 @@ class MachineCodeForMethod : private Annotation {
bool automaticVarsAreaFrozen;
public:
- /*ctor*/ MachineCodeForMethod(const Function* function,
- const TargetMachine& target);
+ /*ctor*/ MachineFunction(const Function* function,
+ const TargetMachine& target);
// The next two methods are used to construct and to retrieve
- // the MachineCodeForMethod object for the given method.
+ // the MachineFunction object for the given method.
// construct() -- Allocates and initializes for a given method and target
// get() -- Returns a handle to the object.
// This should not be called before "construct()"
// for a given Method.
//
- static MachineCodeForMethod& construct(const Function *method,
+ static MachineFunction& construct(const Function *method,
const TargetMachine &target);
static void destruct(const Function *F);
- static MachineCodeForMethod& get(const Function* function);
+ static MachineFunction& get(const Function* function);
//
// Accessors for global information about generated code for a method.
diff --git a/include/llvm/Target/MachineInstrInfo.h b/include/llvm/Target/MachineInstrInfo.h
index 6bfe7e5d67..8fe4d3b4f6 100644
--- a/include/llvm/Target/MachineInstrInfo.h
+++ b/include/llvm/Target/MachineInstrInfo.h
@@ -275,7 +275,7 @@ public:
// The generated instructions are returned in `mvec'.
// Any temp. registers (TmpInstruction) created are recorded in mcfi.
// Symbolic constants or constants that must be accessed from memory
- // are added to the constant pool via MachineCodeForMethod::get(F).
+ // are added to the constant pool via MachineFunction::get(F).
//
virtual void CreateCodeToLoadConst(const TargetMachine& target,
Function* F,
diff --git a/include/llvm/Target/TargetFrameInfo.h b/include/llvm/Target/TargetFrameInfo.h
index c6d2a94316..699966a35e 100644
--- a/include/llvm/Target/TargetFrameInfo.h
+++ b/include/llvm/Target/TargetFrameInfo.h
@@ -10,7 +10,7 @@
#include "Support/NonCopyable.h"
#include <vector>
-class MachineCodeForMethod;
+class MachineFunction;
class TargetMachine;
struct MachineFrameInfo : public NonCopyableV {
@@ -41,24 +41,24 @@ public:
// The first few methods have default machine-independent implementations.
// The rest must be implemented by the machine-specific subclass.
//
- virtual int getIncomingArgOffset (MachineCodeForMethod& mcInfo,
+ virtual int getIncomingArgOffset (MachineFunction& mcInfo,
unsigned argNum) const;
- virtual int getOutgoingArgOffset (MachineCodeForMethod& mcInfo,
+ virtual int getOutgoingArgOffset (MachineFunction& mcInfo,
unsigned argNum) const;
- virtual int getFirstIncomingArgOffset (MachineCodeForMethod& mcInfo,
+ virtual int getFirstIncomingArgOffset (MachineFunction& mcInfo,
bool& growUp) const=0;
- virtual int getFirstOutgoingArgOffset (MachineCodeForMethod& mcInfo,
+ virtual int getFirstOutgoingArgOffset (MachineFunction& mcInfo,
bool& growUp) const=0;
- virtual int getFirstOptionalOutgoingArgOffset (MachineCodeForMethod&,
+ virtual int getFirstOptionalOutgoingArgOffset (MachineFunction&,
bool& growUp) const=0;
- virtual int getFirstAutomaticVarOffset (MachineCodeForMethod& mcInfo,
+ virtual int getFirstAutomaticVarOffset (MachineFunction& mcInfo,
bool& growUp) const=0;
- virtual int getRegSpillAreaOffset (MachineCodeForMethod& mcInfo,
+ virtual int getRegSpillAreaOffset (MachineFunction& mcInfo,
bool& growUp) const=0;
- virtual int getTmpAreaOffset (MachineCodeForMethod& mcInfo,
+ virtual int getTmpAreaOffset (MachineFunction& mcInfo,
bool& growUp) const=0;
- virtual int getDynamicAreaOffset (MachineCodeForMethod& mcInfo,
+ virtual int getDynamicAreaOffset (MachineFunction& mcInfo,
bool& growUp) const=0;
//
diff --git a/include/llvm/Target/TargetInstrInfo.h b/include/llvm/Target/TargetInstrInfo.h
index 6bfe7e5d67..8fe4d3b4f6 100644
--- a/include/llvm/Target/TargetInstrInfo.h
+++ b/include/llvm/Target/TargetInstrInfo.h
@@ -275,7 +275,7 @@ public:
// The generated instructions are returned in `mvec'.
// Any temp. registers (TmpInstruction) created are recorded in mcfi.
// Symbolic constants or constants that must be accessed from memory
- // are added to the constant pool via MachineCodeForMethod::get(F).
+ // are added to the constant pool via MachineFunction::get(F).
//
virtual void CreateCodeToLoadConst(const TargetMachine& target,
Function* F,