mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2025-06-27 14:24:40 +00:00
The leak detector is dead, long live asan and valgrind.
In resent times asan and valgrind have found way more memory management bugs in llvm than the special purpose leak detector. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@224703 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@ -19,7 +19,6 @@
|
||||
#include "llvm/IR/Instructions.h"
|
||||
#include "llvm/IR/IntrinsicInst.h"
|
||||
#include "llvm/IR/LLVMContext.h"
|
||||
#include "llvm/IR/LeakDetector.h"
|
||||
#include "llvm/IR/Type.h"
|
||||
#include <algorithm>
|
||||
using namespace llvm;
|
||||
@ -47,9 +46,6 @@ BasicBlock::BasicBlock(LLVMContext &C, const Twine &Name, Function *NewParent,
|
||||
BasicBlock *InsertBefore)
|
||||
: Value(Type::getLabelTy(C), Value::BasicBlockVal), Parent(nullptr) {
|
||||
|
||||
// Make sure that we get added to a function
|
||||
LeakDetector::addGarbageObject(this);
|
||||
|
||||
if (NewParent)
|
||||
insertInto(NewParent, InsertBefore);
|
||||
else
|
||||
@ -94,14 +90,8 @@ BasicBlock::~BasicBlock() {
|
||||
}
|
||||
|
||||
void BasicBlock::setParent(Function *parent) {
|
||||
if (getParent())
|
||||
LeakDetector::addGarbageObject(this);
|
||||
|
||||
// Set Parent=parent, updating instruction symtab entries as appropriate.
|
||||
InstList.setSymTabObject(&Parent, parent);
|
||||
|
||||
if (getParent())
|
||||
LeakDetector::removeGarbageObject(this);
|
||||
}
|
||||
|
||||
void BasicBlock::removeFromParent() {
|
||||
|
Reference in New Issue
Block a user