[Mesa-dev] [PATCH v2 23/25] spirv: enable SpvCapabilityFloat64 only to supported platforms

Jason Ekstrand jason at jlekstrand.net
Tue Jan 3 16:59:09 UTC 2017


Dave recently added a spirv-specific structure for this sort of feature
enabling.  I think it would be better to use that rather than nir_options.

On Dec 16, 2016 8:56 AM, "Juan A. Suarez Romero" <jasuarez at igalia.com>
wrote:

> From: Samuel Iglesias Gonsálvez <siglesias at igalia.com>
>
> Signed-off-by: Samuel Iglesias Gonsálvez <siglesias at igalia.com>
> ---
>  src/compiler/spirv/spirv_to_nir.c | 8 +++++++-
>  1 file changed, 7 insertions(+), 1 deletion(-)
>
> diff --git a/src/compiler/spirv/spirv_to_nir.c
> b/src/compiler/spirv/spirv_to_nir.c
> index 11f6248..f4bf3b4 100644
> --- a/src/compiler/spirv/spirv_to_nir.c
> +++ b/src/compiler/spirv/spirv_to_nir.c
> @@ -2525,6 +2525,13 @@ vtn_handle_preamble_instruction(struct vtn_builder
> *b, SpvOp opcode,
>        case SpvCapabilityInputAttachment:
>           break;
>
> +      case SpvCapabilityFloat64:
> +         if (!b->nir_options->native_float64) {
> +            vtn_warn("Unsupported SPIR-V capability: %s",
> +                     spirv_capability_to_string(cap));
> +         }
> +         break;
> +
>        case SpvCapabilityGeometryStreams:
>        case SpvCapabilityTessellation:
>        case SpvCapabilityTessellationPointSize:
> @@ -2532,7 +2539,6 @@ vtn_handle_preamble_instruction(struct vtn_builder
> *b, SpvOp opcode,
>        case SpvCapabilityVector16:
>        case SpvCapabilityFloat16Buffer:
>        case SpvCapabilityFloat16:
> -      case SpvCapabilityFloat64:
>        case SpvCapabilityInt64:
>        case SpvCapabilityInt64Atomics:
>        case SpvCapabilityAtomicStorage:
> --
> 2.9.3
>
> _______________________________________________
> 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/20170103/ed2251ab/attachment.html>


More information about the mesa-dev mailing list