OSDN Git Service

various: Fix missing DumpModule with recent LLVM.
authorBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Sat, 28 Jan 2017 16:32:05 +0000 (17:32 +0100)
committerBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Sun, 29 Jan 2017 09:25:00 +0000 (10:25 +0100)
commit0fca80b3db64dc1d004f78e22b9de86a07e9de96
tree8352bb49a65abfc372d6c7c8efaf714944e706f5
parentce7a045feeef8cad155f1c9aa07f166e146e3d00
various: Fix missing DumpModule with recent LLVM.

Since LLVM revision 293359 DumpModule gets only implemented when
either a debug build or LLVM_ENABLE_DUMP is set.

This patch adds a direct replacement for the function for radv and
radeonsi, However, as I don't know a good place to put common LLVM
code for all three I inlined the implementation for LLVMPipe.

v2: Use the new code for LLVM 3.4+ instead of LLVM 5+ & fixed indentation

Signed-off-by: Bas Nieuwenhuizen <basni@google.com>
Reviewed-by: Roland Scheidegger <sroland@vmware.com>
src/amd/common/ac_llvm_util.c
src/amd/common/ac_llvm_util.h
src/amd/common/ac_nir_to_llvm.c
src/gallium/drivers/llvmpipe/lp_jit.c
src/gallium/drivers/radeonsi/si_shader.c