diff options
Diffstat (limited to 'tools/lto/LTOCodeGenerator.cpp')
-rw-r--r-- | tools/lto/LTOCodeGenerator.cpp | 20 |
1 files changed, 1 insertions, 19 deletions
diff --git a/tools/lto/LTOCodeGenerator.cpp b/tools/lto/LTOCodeGenerator.cpp index daeb964..3fe7af2 100644 --- a/tools/lto/LTOCodeGenerator.cpp +++ b/tools/lto/LTOCodeGenerator.cpp @@ -74,7 +74,7 @@ LTOCodeGenerator::LTOCodeGenerator() _linker(new Module("ld-temp.o", _context)), _target(NULL), _emitDwarfDebugInfo(false), _scopeRestrictionsDone(false), _codeModel(LTO_CODEGEN_PIC_MODEL_DYNAMIC), - _nativeObjectFile(NULL), ObjBufVect(0) { + _nativeObjectFile(NULL) { InitializeAllTargets(); InitializeAllTargetMCs(); InitializeAllAsmPrinters(); @@ -85,7 +85,6 @@ LTOCodeGenerator::~LTOCodeGenerator() { delete _target; delete _nativeObjectFile; delete _linker.getModule(); - delete[] ObjBufVect; for (std::vector<char*>::iterator I = _codegenOptions.begin(), E = _codegenOptions.end(); I != E; ++I) @@ -247,23 +246,6 @@ const void* LTOCodeGenerator::compile(size_t* length, std::string& errMsg) { return _nativeObjectFile->getBufferStart(); } -// Currently compile() and compile_parallel() have no difference. -NativeObjectFile *LTOCodeGenerator::compile_parallel(size_t *count, - std::string &ErrMsg) { - assert(ObjBufVect == 0 && "Should be NULL"); - - size_t Len; - const void *Buf = compile(&Len, ErrMsg); - if (!Buf) - return 0; - - *count = 1; - ObjBufVect = new NativeObjectFile[1]; - ObjBufVect[0].content = Buf; - ObjBufVect[0].length = Len; - return ObjBufVect; -} - bool LTOCodeGenerator::determineTarget(std::string &errMsg) { if (_target != NULL) return true; |