From e7375e17958993b90d9f01d76dbc7eacdbf8c195 Mon Sep 17 00:00:00 2001 From: Dave Airlie Date: Thu, 13 Feb 2020 10:35:51 +1000 Subject: [PATCH] gallivm/s390: fix pass init order on s390 with llvm 8 (v2) MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit llvm 8 has some missing pass dependencies, fix the s390 case as well. v2: add ARM also (Michel) Reviewed-by: Michel Dänzer Reviewed-by: Adam Jackson Part-of: --- src/gallium/auxiliary/gallivm/lp_bld_init.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/gallium/auxiliary/gallivm/lp_bld_init.c b/src/gallium/auxiliary/gallivm/lp_bld_init.c index 6206d79cc54..4047f2bd781 100644 --- a/src/gallium/auxiliary/gallivm/lp_bld_init.c +++ b/src/gallium/auxiliary/gallivm/lp_bld_init.c @@ -46,7 +46,7 @@ #endif #include #if GALLIVM_HAVE_CORO -#if LLVM_VERSION_MAJOR <= 8 && defined(PIPE_ARCH_AARCH64) +#if LLVM_VERSION_MAJOR <= 8 && (defined(PIPE_ARCH_AARCH64) || defined (PIPE_ARCH_ARM) || defined(PIPE_ARCH_S390)) #include #endif #include @@ -137,7 +137,8 @@ create_pass_manager(struct gallivm_state *gallivm) } #if GALLIVM_HAVE_CORO -#if LLVM_VERSION_MAJOR <= 8 && defined(PIPE_ARCH_AARCH64) +#if LLVM_VERSION_MAJOR <= 8 && (defined(PIPE_ARCH_AARCH64) || defined (PIPE_ARCH_ARM) || defined(PIPE_ARCH_S390)) + LLVMAddArgumentPromotionPass(gallivm->cgpassmgr); LLVMAddFunctionAttrsPass(gallivm->cgpassmgr); #endif LLVMAddCoroEarlyPass(gallivm->cgpassmgr); -- 2.30.2