1
- // ===-- MachineSSAUpdater.h - Unstructured SSA Update Tool ------*- C++ -*-===//
1
+ // ===- MachineSSAUpdater.h - Unstructured SSA Update Tool - ------*- C++ -*-===//
2
2
//
3
3
// The LLVM Compiler Infrastructure
4
4
//
14
14
#ifndef LLVM_CODEGEN_MACHINESSAUPDATER_H
15
15
#define LLVM_CODEGEN_MACHINESSAUPDATER_H
16
16
17
- #include " llvm/Support/Compiler.h"
18
-
19
17
namespace llvm {
20
- class MachineBasicBlock ;
21
- class MachineFunction ;
22
- class MachineInstr ;
23
- class MachineOperand ;
24
- class MachineRegisterInfo ;
25
- class TargetInstrInfo ;
26
- class TargetRegisterClass ;
27
- template <typename T> class SmallVectorImpl ;
28
- template <typename T> class SSAUpdaterTraits ;
18
+
19
+ class MachineBasicBlock ;
20
+ class MachineFunction ;
21
+ class MachineInstr ;
22
+ class MachineOperand ;
23
+ class MachineRegisterInfo ;
24
+ class TargetInstrInfo ;
25
+ class TargetRegisterClass ;
26
+ template <typename T> class SmallVectorImpl ;
27
+ template <typename T> class SSAUpdaterTraits ;
29
28
30
29
// / MachineSSAUpdater - This class updates SSA form for a set of virtual
31
30
// / registers defined in multiple blocks. This is used when code duplication
@@ -38,7 +37,7 @@ class MachineSSAUpdater {
38
37
// / AvailableVals - This keeps track of which value to use on a per-block
39
38
// / basis. When we insert PHI nodes, we keep track of them here.
40
39
// typedef DenseMap<MachineBasicBlock*, unsigned > AvailableValsTy;
41
- void *AV;
40
+ void *AV = nullptr ;
42
41
43
42
// / VR - Current virtual register whose uses are being updated.
44
43
unsigned VR;
@@ -52,11 +51,14 @@ class MachineSSAUpdater {
52
51
53
52
const TargetInstrInfo *TII;
54
53
MachineRegisterInfo *MRI;
54
+
55
55
public:
56
56
// / MachineSSAUpdater constructor. If InsertedPHIs is specified, it will be
57
57
// / filled in with all PHI Nodes created by rewriting.
58
58
explicit MachineSSAUpdater (MachineFunction &MF,
59
59
SmallVectorImpl<MachineInstr*> *InsertedPHIs = nullptr );
60
+ MachineSSAUpdater (const MachineSSAUpdater &) = delete ;
61
+ MachineSSAUpdater &operator =(const MachineSSAUpdater &) = delete ;
60
62
~MachineSSAUpdater ();
61
63
62
64
// / Initialize - Reset this object to get ready for a new set of SSA
@@ -93,7 +95,6 @@ class MachineSSAUpdater {
93
95
// / their respective blocks. However, the use of X happens in the *middle* of
94
96
// / a block. Because of this, we need to insert a new PHI node in SomeBB to
95
97
// / merge the appropriate values, and this value isn't live out of the block.
96
- // /
97
98
unsigned GetValueInMiddleOfBlock (MachineBasicBlock *BB);
98
99
99
100
// / RewriteUse - Rewrite a use of the symbolic value. This handles PHI nodes,
@@ -105,11 +106,8 @@ class MachineSSAUpdater {
105
106
106
107
private:
107
108
unsigned GetValueAtEndOfBlockInternal (MachineBasicBlock *BB);
108
-
109
- void operator =(const MachineSSAUpdater&) = delete ;
110
- MachineSSAUpdater (const MachineSSAUpdater&) = delete ;
111
109
};
112
110
113
- } // End llvm namespace
111
+ } // end namespace llvm
114
112
115
- #endif
113
+ #endif // LLVM_CODEGEN_MACHINESSAUPDATER_H
0 commit comments