From 2d971cc1cafbe4396a890f60764ce532b4872c30 Mon Sep 17 00:00:00 2001 From: Vinson Lee Date: Fri, 13 Dec 2019 20:47:51 -0800 Subject: [PATCH] swr: Fix build with llvm-10.0. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Fix build error after llvm-10 commit 5d986953c8b9 ("[IR] Split out target specific intrinsic enums into separate headers"). ../src/gallium/drivers/swr/rasterizer/jitter/functionpasses/lower_x86.cpp:78:37: error: ‘x86_bmi_bextr_32’ is not a member of ‘llvm::Intrinsic’ {"meta.intrinsic.BEXTR_32", Intrinsic::x86_bmi_bextr_32}, ^ Signed-off-by: Vinson Lee Reviewed-by: Krzysztof Raszkowski Reviewed-by: Jan Zielinski --- src/gallium/drivers/swr/rasterizer/jitter/jit_pch.hpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/gallium/drivers/swr/rasterizer/jitter/jit_pch.hpp b/src/gallium/drivers/swr/rasterizer/jitter/jit_pch.hpp index 42b2d6d8096..6b9a6b3375f 100644 --- a/src/gallium/drivers/swr/rasterizer/jitter/jit_pch.hpp +++ b/src/gallium/drivers/swr/rasterizer/jitter/jit_pch.hpp @@ -49,6 +49,9 @@ #include "llvm/IR/Type.h" #include "llvm/IR/IRBuilder.h" #include "llvm/IR/IntrinsicInst.h" +#if LLVM_VERSION_MAJOR >= 10 +#include "llvm/IR/IntrinsicsX86.h" +#endif #include "llvm/ExecutionEngine/ObjectCache.h" #include "llvm/IR/Verifier.h" -- 2.30.2