Rename builtin(sample_mask_{in,out}) to builtin(sample_mask)

Removes the need to pass the storage class to the SPIR-V reader
builtin mapping function.

Added a deprecation warning for sample_mask_{in,out}.

Bug: tint:715
Change-Id: I948ff2de2d5de7bd05e1c6ff45bd721c856900e3
Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/47743
Commit-Queue: James Price <jrprice@google.com>
Auto-Submit: James Price <jrprice@google.com>
Reviewed-by: Ben Clayton <bclayton@google.com>
This commit is contained in:
James Price
2021-04-14 16:44:38 +00:00
committed by Commit Bot service account
parent 88d7edcf7a
commit edd4d3cc3b
19 changed files with 144 additions and 86 deletions

View File

@@ -63,6 +63,10 @@ std::ostream& operator<<(std::ostream& out, Builtin builtin) {
out << "sample_index";
break;
}
case Builtin::kSampleMask: {
out << "sample_mask";
break;
}
case Builtin::kSampleMaskIn: {
out << "sample_mask_in";
break;

View File

@@ -33,8 +33,9 @@ enum class Builtin {
kLocalInvocationIndex,
kGlobalInvocationId,
kSampleIndex,
kSampleMaskIn,
kSampleMaskOut,
kSampleMask,
kSampleMaskIn, // TODO(crbug.com/tint/715): Remove this
kSampleMaskOut, // TODO(crbug.com/tint/715): Remove this
// Below are not currently WGSL builtins, but are included in this enum as
// they are used by certain backends.