[Mesa-dev] [PATCH 1/3] ac/nir: only use the new raw/struct image atomic intrinsics with LLVM 9+
Marek Olšák
maraeo at gmail.com
Mon Apr 22 17:19:25 UTC 2019
Is "XXX" in the comment really necessary?
Marek
On Thu, Apr 18, 2019 at 3:20 AM Samuel Pitoiset <samuel.pitoiset at gmail.com>
wrote:
> They are buggy with LLVM 8 because they weren't marked as source
> of divergence, see r358579.
>
> Fixes: dd0172e865f ("radv: Use structured intrinsics instead of indexing
> workaround for GFX9.")"
> Signed-off-by: Samuel Pitoiset <samuel.pitoiset at gmail.com>
> ---
> src/amd/common/ac_nir_to_llvm.c | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/src/amd/common/ac_nir_to_llvm.c
> b/src/amd/common/ac_nir_to_llvm.c
> index 3890aebc982..fcd75903088 100644
> --- a/src/amd/common/ac_nir_to_llvm.c
> +++ b/src/amd/common/ac_nir_to_llvm.c
> @@ -2634,7 +2634,10 @@ static LLVMValueRef visit_image_atomic(struct
> ac_nir_context *ctx,
> params[param_count++] =
> LLVMBuildExtractElement(ctx->ac.builder, get_src(ctx, instr->src[1]),
>
> ctx->ac.i32_0, ""); /* vindex */
> params[param_count++] = ctx->ac.i32_0; /* voffset */
> - if (HAVE_LLVM >= 0x800) {
> + if (HAVE_LLVM >= 0x900) {
> + /* XXX: The new raw/struct atomic intrinsics are
> buggy
> + * with LLVM 8, see r358579.
> + */
> params[param_count++] = ctx->ac.i32_0; /* soffset
> */
> params[param_count++] = ctx->ac.i32_0; /* slc */
>
> --
> 2.21.0
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/mesa-dev/attachments/20190422/724426a1/attachment-0001.html>
More information about the mesa-dev
mailing list