[Mesa-dev] [PATCH 1/3] ac/nir: Fix include for LLVMAddPromoteMemoryToRegisterPass

Mike Lothian mike at fireburn.co.uk
Sun Apr 1 00:32:20 UTC 2018


Include llvm-c/Transforms/Utils.h with the newest LLVM 7

Signed-of-by: Mike Lothian <mike at fireburn.co.uk>
Reviewed-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
Tested-by: Dieter Nützel <Dieter at nuetzel-hh.de>
---
 src/amd/vulkan/radv_nir_to_llvm.c | 3 +++
 1 file changed, 3 insertions(+)

diff --git a/src/amd/vulkan/radv_nir_to_llvm.c b/src/amd/vulkan/radv_nir_to_llvm.c
index c6b4e8b532..2f0864da46 100644
--- a/src/amd/vulkan/radv_nir_to_llvm.c
+++ b/src/amd/vulkan/radv_nir_to_llvm.c
@@ -32,6 +32,9 @@
 #include <llvm-c/Core.h>
 #include <llvm-c/TargetMachine.h>
 #include <llvm-c/Transforms/Scalar.h>
+#if HAVE_LLVM >= 0x0700
+#include <llvm-c/Transforms/Utils.h>
+#endif
 
 #include "sid.h"
 #include "gfx9d.h"
-- 
2.16.3



More information about the mesa-dev mailing list