From 2cc4bfbe01bd27298833623977d050e2a80c5c94 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Marek=20Ol=C5=A1=C3=A1k?= Date: Thu, 9 Apr 2020 12:25:49 -0400 Subject: [PATCH] radeonsi: don't set any XNACK options on gfx10.3 Acked-by: Pierre-Eric Pelloux-Prayer Part-of: --- src/amd/llvm/ac_llvm_util.c | 4 ++-- src/gallium/drivers/radeonsi/si_pipe.c | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/amd/llvm/ac_llvm_util.c b/src/amd/llvm/ac_llvm_util.c index 9684101995b..5dc4c934ba0 100644 --- a/src/amd/llvm/ac_llvm_util.c +++ b/src/amd/llvm/ac_llvm_util.c @@ -177,8 +177,8 @@ static LLVMTargetMachineRef ac_create_target_machine(enum radeon_family family, LLVM_VERSION_MAJOR >= 11 ? "" : ",-fp32-denormals,+fp64-denormals", family >= CHIP_NAVI10 && !(tm_options & AC_TM_WAVE32) ? ",+wavefrontsize64,-wavefrontsize32" : "", - tm_options & AC_TM_FORCE_ENABLE_XNACK ? ",+xnack" : "", - tm_options & AC_TM_FORCE_DISABLE_XNACK ? ",-xnack" : "", + family <= CHIP_NAVI14 && tm_options & AC_TM_FORCE_ENABLE_XNACK ? ",+xnack" : "", + family <= CHIP_NAVI14 && tm_options & AC_TM_FORCE_DISABLE_XNACK ? ",-xnack" : "", tm_options & AC_TM_PROMOTE_ALLOCA_TO_SCRATCH ? ",-promote-alloca" : "", tm_options & AC_TM_NO_LOAD_STORE_OPT ? ",-load-store-opt" : ""); diff --git a/src/gallium/drivers/radeonsi/si_pipe.c b/src/gallium/drivers/radeonsi/si_pipe.c index 7fdbfa24c57..b8a1a8cc389 100644 --- a/src/gallium/drivers/radeonsi/si_pipe.c +++ b/src/gallium/drivers/radeonsi/si_pipe.c @@ -141,8 +141,8 @@ void si_init_compiler(struct si_screen *sscreen, struct ac_llvm_compiler *compil enum ac_target_machine_options tm_options = (sscreen->debug_flags & DBG(GISEL) ? AC_TM_ENABLE_GLOBAL_ISEL : 0) | - (sscreen->info.chip_class >= GFX9 ? AC_TM_FORCE_ENABLE_XNACK : 0) | - (sscreen->info.chip_class < GFX9 ? AC_TM_FORCE_DISABLE_XNACK : 0) | + (sscreen->info.chip_class <= GFX8 ? AC_TM_FORCE_DISABLE_XNACK : + sscreen->info.chip_class <= GFX10 ? AC_TM_FORCE_ENABLE_XNACK : 0) | (!sscreen->llvm_has_working_vgpr_indexing ? AC_TM_PROMOTE_ALLOCA_TO_SCRATCH : 0) | (sscreen->debug_flags & DBG(CHECK_IR) ? AC_TM_CHECK_IR : 0) | (create_low_opt_compiler ? AC_TM_CREATE_LOW_OPT : 0); -- 2.30.2