summaryrefslogtreecommitdiffstats
path: root/src/amd/vulkan/radv_private.h
diff options
context:
space:
mode:
authorDave Airlie <[email protected]>2018-06-27 09:27:03 +1000
committerDave Airlie <[email protected]>2018-07-04 10:29:16 +1000
commit7398913a62a59282e742758a7e789ed3df27e49c (patch)
treee64e59eb906fccde70a2c19b72c6244a0f263dc2 /src/amd/vulkan/radv_private.h
parentd853d3a59bd5f8720a5b021bcd64a193d370b623 (diff)
ac/radv: move llvm compiler info to struct and init in one place
This ports radv to the shared code, however due to a bug in LLVM version prior to 7, radv cannot add target info at this stage, as it would leak one for every shader compile, however I'd prefer to keep this llvm damage in the shared code, since it isn't the driver at fault here. We just add a flag to denote if the driver can support leaking the target info or not, and the common code does the right thing depending on the llvm version. Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/amd/vulkan/radv_private.h')
-rw-r--r--src/amd/vulkan/radv_private.h7
1 files changed, 3 insertions, 4 deletions
diff --git a/src/amd/vulkan/radv_private.h b/src/amd/vulkan/radv_private.h
index cf416fbe8f6..0a34d79a206 100644
--- a/src/amd/vulkan/radv_private.h
+++ b/src/amd/vulkan/radv_private.h
@@ -58,6 +58,7 @@
#include "ac_gpu_info.h"
#include "ac_surface.h"
#include "ac_llvm_build.h"
+#include "ac_llvm_util.h"
#include "radv_descriptor_set.h"
#include "radv_extensions.h"
#include "radv_cs.h"
@@ -1795,16 +1796,14 @@ struct radv_fence {
struct radv_shader_variant_info;
struct radv_nir_compiler_options;
-void radv_compile_gs_copy_shader(LLVMTargetMachineRef tm,
- LLVMPassManagerRef passmgr,
+void radv_compile_gs_copy_shader(struct ac_llvm_compiler *ac_llvm,
struct nir_shader *geom_shader,
struct ac_shader_binary *binary,
struct ac_shader_config *config,
struct radv_shader_variant_info *shader_info,
const struct radv_nir_compiler_options *option);
-void radv_compile_nir_shader(LLVMTargetMachineRef tm,
- LLVMPassManagerRef passmgr,
+void radv_compile_nir_shader(struct ac_llvm_compiler *ac_llvm,
struct ac_shader_binary *binary,
struct ac_shader_config *config,
struct radv_shader_variant_info *shader_info,