mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-12-18 21:38:10 +00:00
[CodeGen] Avoid access after runtime
Insts must be destroyd before xParent or it can read it with stack like this: 0 in llvm::MachineInstr::getMF() const MachineInstr.cpp:637:3 1 in getMF MachineInstr.h:302:50 2 in removeNodeFromList MachineBasicBlock.cpp:163:32
This commit is contained in:
parent
6ae13b74d6
commit
15972e37ba
@ -109,10 +109,10 @@ public:
|
||||
private:
|
||||
using Instructions = ilist<MachineInstr, ilist_sentinel_tracking<true>>;
|
||||
|
||||
Instructions Insts;
|
||||
const BasicBlock *BB;
|
||||
int Number;
|
||||
MachineFunction *xParent;
|
||||
Instructions Insts;
|
||||
|
||||
/// Keep track of the predecessor / successor basic blocks.
|
||||
std::vector<MachineBasicBlock *> Predecessors;
|
||||
|
Loading…
Reference in New Issue
Block a user