From: Jan Vesely Date: Mon, 4 Aug 2014 22:50:02 +0000 (-0400) Subject: gallivm: Fix build with latest LLVM X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=e28136343b6aa7dfff8ec85f6463574d6625b5a6;p=mesa.git gallivm: Fix build with latest LLVM Signed-off-by: Jan Vesely Reviewed-and-Tested-by: Michel Dänzer --- diff --git a/src/gallium/auxiliary/gallivm/lp_bld_debug.cpp b/src/gallium/auxiliary/gallivm/lp_bld_debug.cpp index 413a0c2cd72..b6b52c80efc 100644 --- a/src/gallium/auxiliary/gallivm/lp_bld_debug.cpp +++ b/src/gallium/auxiliary/gallivm/lp_bld_debug.cpp @@ -34,6 +34,10 @@ #include #include +#if HAVE_LLVM >= 0x0306 +#include +#endif + #include #include @@ -271,7 +275,11 @@ disassemble(const void* func, llvm::raw_ostream & Out) #endif OwningPtr TM(T->createTargetMachine(Triple, sys::getHostCPUName(), "", options)); +#if HAVE_LLVM >= 0x0306 + const TargetInstrInfo *TII = TM->getSubtargetImpl()->getInstrInfo(); +#else const TargetInstrInfo *TII = TM->getInstrInfo(); +#endif /* * Wrap the data in a MemoryObject