summaryrefslogtreecommitdiff
path: root/include/llvm/CodeGen/FastISel.h
diff options
context:
space:
mode:
authorDan Gohman <gohman@apple.com>2010-07-07 19:20:32 +0000
committerDan Gohman <gohman@apple.com>2010-07-07 19:20:32 +0000
commit4df83ed159f21fdf73a57729c3e9d8c9fcd73607 (patch)
treeabee7270365c3f2f5299e810db3d44482dae9504 /include/llvm/CodeGen/FastISel.h
parentf423a69839c4810b890f8a8b09fb8cfbd6bf0139 (diff)
downloadllvm-4df83ed159f21fdf73a57729c3e9d8c9fcd73607.tar.gz
llvm-4df83ed159f21fdf73a57729c3e9d8c9fcd73607.tar.bz2
llvm-4df83ed159f21fdf73a57729c3e9d8c9fcd73607.tar.xz
Implement bottom-up fast-isel. This has the advantage of not requiring
a separate DCE pass over MachineInstrs. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@107804 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'include/llvm/CodeGen/FastISel.h')
-rw-r--r--include/llvm/CodeGen/FastISel.h11
1 files changed, 7 insertions, 4 deletions
diff --git a/include/llvm/CodeGen/FastISel.h b/include/llvm/CodeGen/FastISel.h
index 2067ca8132..24499dd9ff 100644
--- a/include/llvm/CodeGen/FastISel.h
+++ b/include/llvm/CodeGen/FastISel.h
@@ -19,6 +19,7 @@
#include "llvm/ADT/SmallSet.h"
#endif
#include "llvm/CodeGen/ValueTypes.h"
+#include "llvm/CodeGen/MachineBasicBlock.h"
namespace llvm {
@@ -55,15 +56,17 @@ protected:
const TargetInstrInfo &TII;
const TargetLowering &TLI;
const TargetRegisterInfo &TRI;
- bool IsBottomUp;
+ MachineBasicBlock::iterator LastLocalValue;
public:
+ /// getLastLocalValue - Return the position of the last instruction
+ /// emitted for materializing constants for use in the current block.
+ MachineBasicBlock::iterator getLastLocalValue() { return LastLocalValue; }
+
/// startNewBlock - Set the current block to which generated machine
/// instructions will be appended, and clear the local CSE map.
///
- void startNewBlock() {
- LocalValueMap.clear();
- }
+ void startNewBlock();
/// getCurDebugLoc() - Return current debug location information.
DebugLoc getCurDebugLoc() const { return DL; }