From d97275e42c0750fa74ce17de4f985c73c54a1bf4 Mon Sep 17 00:00:00 2001 From: Dave Airlie Date: Thu, 6 Jul 2017 03:01:56 +0100 Subject: [PATCH] ac/llvm: set xnack like radeonsi does. Use family, but only set xnack+ for gfx9. Reviewed-by: Bas Nieuwenhuizen Signed-off-by: Dave Airlie --- src/amd/common/ac_llvm_util.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/amd/common/ac_llvm_util.c b/src/amd/common/ac_llvm_util.c index 4f32d4bb974..84ed73f164e 100644 --- a/src/amd/common/ac_llvm_util.c +++ b/src/amd/common/ac_llvm_util.c @@ -126,7 +126,9 @@ LLVMTargetMachineRef ac_create_target_machine(enum radeon_family family, enum ac LLVMTargetRef target = ac_get_llvm_target(triple); snprintf(features, sizeof(features), - "+DumpCode,+vgpr-spilling,-fp32-denormals,-xnack"); + "+DumpCode,+vgpr-spilling,-fp32-denormals%s", + family >= CHIP_VEGA10 ? ",+xnack" : ",-xnack"); + LLVMTargetMachineRef tm = LLVMCreateTargetMachine( target, triple, -- 2.30.2