From: Samuel Pitoiset Date: Fri, 24 Jan 2020 09:16:56 +0000 (+0100) Subject: spirv: add support for SpvDecorationExplicitInterpAMD X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=5c053cc6ec310481e61631515e0ae7044faf9335;p=mesa.git spirv: add support for SpvDecorationExplicitInterpAMD Signed-off-by: Samuel Pitoiset Reviewed-by: Bas Nieuwenhuizen Part-of: --- diff --git a/src/compiler/spirv/spirv_to_nir.c b/src/compiler/spirv/spirv_to_nir.c index abf27d5e6b0..258e33b723b 100644 --- a/src/compiler/spirv/spirv_to_nir.c +++ b/src/compiler/spirv/spirv_to_nir.c @@ -779,6 +779,9 @@ struct_member_decoration_cb(struct vtn_builder *b, case SpvDecorationFlat: ctx->fields[member].interpolation = INTERP_MODE_FLAT; break; + case SpvDecorationExplicitInterpAMD: + ctx->fields[member].interpolation = INTERP_MODE_EXPLICIT; + break; case SpvDecorationCentroid: ctx->fields[member].centroid = true; break; @@ -984,6 +987,7 @@ type_decoration_cb(struct vtn_builder *b, case SpvDecorationPatch: case SpvDecorationCentroid: case SpvDecorationSample: + case SpvDecorationExplicitInterpAMD: case SpvDecorationVolatile: case SpvDecorationCoherent: case SpvDecorationNonWritable: diff --git a/src/compiler/spirv/vtn_variables.c b/src/compiler/spirv/vtn_variables.c index 77595742933..b86a0bcd391 100644 --- a/src/compiler/spirv/vtn_variables.c +++ b/src/compiler/spirv/vtn_variables.c @@ -1530,6 +1530,9 @@ apply_var_decoration(struct vtn_builder *b, case SpvDecorationFlat: var_data->interpolation = INTERP_MODE_FLAT; break; + case SpvDecorationExplicitInterpAMD: + var_data->interpolation = INTERP_MODE_EXPLICIT; + break; case SpvDecorationCentroid: var_data->centroid = true; break;