From: Marek Olšák Date: Sun, 22 Jan 2017 01:36:48 +0000 (+0100) Subject: gallivm,ac: add LP_FUNC_ATTR_CONVERGENT X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=ef883fc5542f642ea547f9865b3310e6343533c7;p=mesa.git gallivm,ac: add LP_FUNC_ATTR_CONVERGENT Reviewed-by: Dave Airlie --- diff --git a/src/amd/common/ac_llvm_util.c b/src/amd/common/ac_llvm_util.c index 2598875ab70..4b5d2fe8ab0 100644 --- a/src/amd/common/ac_llvm_util.c +++ b/src/amd/common/ac_llvm_util.c @@ -174,6 +174,7 @@ static const char *attr_to_str(enum ac_func_attr attr) case AC_FUNC_ATTR_READONLY: return "readonly"; case AC_FUNC_ATTR_WRITEONLY: return "writeonly"; case AC_FUNC_ATTR_INACCESSIBLE_MEM_ONLY: return "inaccessiblememonly"; + case AC_FUNC_ATTR_CONVERGENT: return "convergent"; default: fprintf(stderr, "Unhandled function attribute: %x\n", attr); return 0; diff --git a/src/amd/common/ac_llvm_util.h b/src/amd/common/ac_llvm_util.h index e786bb73371..4b0ccdd38ff 100644 --- a/src/amd/common/ac_llvm_util.h +++ b/src/amd/common/ac_llvm_util.h @@ -43,6 +43,7 @@ enum ac_func_attr { AC_FUNC_ATTR_READONLY = (1 << 6), AC_FUNC_ATTR_WRITEONLY = HAVE_LLVM >= 0x0400 ? (1 << 7) : 0, AC_FUNC_ATTR_INACCESSIBLE_MEM_ONLY = HAVE_LLVM >= 0x0400 ? (1 << 8) : 0, + AC_FUNC_ATTR_CONVERGENT = HAVE_LLVM >= 0x0400 ? (1 << 9) : 0, /* Legacy intrinsic that needs attributes on function declarations * and they must match the internal LLVM definition exactly, otherwise diff --git a/src/gallium/auxiliary/gallivm/lp_bld_intr.c b/src/gallium/auxiliary/gallivm/lp_bld_intr.c index 07d31029c3e..19f98bb781f 100644 --- a/src/gallium/auxiliary/gallivm/lp_bld_intr.c +++ b/src/gallium/auxiliary/gallivm/lp_bld_intr.c @@ -152,6 +152,7 @@ static const char *attr_to_str(enum lp_func_attr attr) case LP_FUNC_ATTR_READONLY: return "readonly"; case LP_FUNC_ATTR_WRITEONLY: return "writeonly"; case LP_FUNC_ATTR_INACCESSIBLE_MEM_ONLY: return "inaccessiblememonly"; + case LP_FUNC_ATTR_CONVERGENT: return "convergent"; default: _debug_printf("Unhandled function attribute: %x\n", attr); return 0; diff --git a/src/gallium/auxiliary/gallivm/lp_bld_intr.h b/src/gallium/auxiliary/gallivm/lp_bld_intr.h index 7bd6efa4568..0a929c51970 100644 --- a/src/gallium/auxiliary/gallivm/lp_bld_intr.h +++ b/src/gallium/auxiliary/gallivm/lp_bld_intr.h @@ -56,6 +56,7 @@ enum lp_func_attr { LP_FUNC_ATTR_READONLY = (1 << 6), LP_FUNC_ATTR_WRITEONLY = HAVE_LLVM >= 0x0400 ? (1 << 7) : 0, LP_FUNC_ATTR_INACCESSIBLE_MEM_ONLY = HAVE_LLVM >= 0x0400 ? (1 << 8) : 0, + LP_FUNC_ATTR_CONVERGENT = HAVE_LLVM >= 0x0400 ? (1 << 9) : 0, /* Legacy intrinsic that needs attributes on function declarations * and they must match the internal LLVM definition exactly, otherwise