From: Tim Rowley Date: Fri, 7 Apr 2017 15:58:38 +0000 (-0500) Subject: swr: [rasterizer jitter] Remove unused function X-Git-Tag: upstream/17.1.0~277 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=54d11b3c95f7baec6fda8583876f696bac17a1a2;p=platform%2Fupstream%2Fmesa.git swr: [rasterizer jitter] Remove unused function Reviewed-by: Bruce Cherniak --- diff --git a/src/gallium/drivers/swr/rasterizer/jitter/JitManager.cpp b/src/gallium/drivers/swr/rasterizer/jitter/JitManager.cpp index 8d1d259..5d8ad27 100644 --- a/src/gallium/drivers/swr/rasterizer/jitter/JitManager.cpp +++ b/src/gallium/drivers/swr/rasterizer/jitter/JitManager.cpp @@ -187,40 +187,6 @@ void JitManager::SetupNewModule() mIsModuleFinalized = false; } -////////////////////////////////////////////////////////////////////////// -/// @brief Create new LLVM module from IR. -bool JitManager::SetupModuleFromIR(const uint8_t *pIR, size_t length) -{ - std::unique_ptr pMem = MemoryBuffer::getMemBuffer(StringRef((const char*)pIR, length), ""); - - SMDiagnostic Err; - std::unique_ptr newModule = parseIR(pMem.get()->getMemBufferRef(), Err, mContext); - - - SWR_REL_ASSERT( - !(newModule == nullptr), - "Parse failed!\n" - "%s", Err.getMessage().data()); - if (newModule == nullptr) - { - return false; - } - - newModule->setDataLayout(mpExec->getDataLayout()); - - mpCurrentModule = newModule.get(); -#if defined(_WIN32) - // Needed for MCJIT on windows - Triple hostTriple(sys::getProcessTriple()); - hostTriple.setObjectFormat(Triple::ELF); - newModule->setTargetTriple(hostTriple.getTriple()); -#endif // _WIN32 - - mpExec->addModule(std::move(newModule)); - mIsModuleFinalized = false; - - return true; -} ////////////////////////////////////////////////////////////////////////// /// @brief Dump function x86 assembly to file. diff --git a/src/gallium/drivers/swr/rasterizer/jitter/JitManager.h b/src/gallium/drivers/swr/rasterizer/jitter/JitManager.h index d97ae87..97d9312 100644 --- a/src/gallium/drivers/swr/rasterizer/jitter/JitManager.h +++ b/src/gallium/drivers/swr/rasterizer/jitter/JitManager.h @@ -172,7 +172,6 @@ struct JitManager std::string mCore; void SetupNewModule(); - bool SetupModuleFromIR(const uint8_t *pIR, size_t length); void DumpAsm(llvm::Function* pFunction, const char* fileName); static void DumpToFile(llvm::Function *f, const char *fileName);