mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-15 08:06:19 +00:00
Validate that in/out storage classes are not used
Use a DisableValidationDecoration to allow these storage classes only for variables generated by the SPIR-V sanitizer. This is also used in the Inspector tests, since the Inspector is currently run *after* the SPIR-V sanitizer. These tests will be removed when this is no longer the case. Also validate that builtin/location decorations are not used on variables (unless they have input/output storage class). Fix or delete all of the other tests that were wrongly using these storage classes and attributes. Bug: tint:697 Change-Id: I8be7fb16191f5e2bed9f7dfb700e51f3b97fd1fe Reviewed-on: https://dawn-review.googlesource.com/c/tint/+/55862 Auto-Submit: James Price <jrprice@google.com> Commit-Queue: Ben Clayton <bclayton@google.com> Kokoro: Kokoro <noreply+kokoro@google.com> Reviewed-by: Ben Clayton <bclayton@google.com>
This commit is contained in:
committed by
Tint LUCI CQ
parent
ffd28e2e1a
commit
14c0b8acbf
@@ -34,8 +34,8 @@ std::string DisableValidationDecoration::InternalName() const {
|
||||
return "disable_validation__function_has_no_body";
|
||||
case DisabledValidation::kBindingPointCollision:
|
||||
return "disable_validation__binding_point_collision";
|
||||
case DisabledValidation::kFunctionVarStorageClass:
|
||||
return "disable_validation__function_var_storage_class";
|
||||
case DisabledValidation::kIgnoreStorageClass:
|
||||
return "disable_validation__ignore_storage_class";
|
||||
case DisabledValidation::kEntryPointParameter:
|
||||
return "disable_validation__entry_point_parameter";
|
||||
}
|
||||
|
||||
@@ -31,9 +31,9 @@ enum class DisabledValidation {
|
||||
/// When applied to a module-scoped variable, the validator will not complain
|
||||
/// if two resource variables have the same binding points.
|
||||
kBindingPointCollision,
|
||||
/// When applied to a function-scoped variable, the validator will not
|
||||
/// complain if the storage class is not `function`.
|
||||
kFunctionVarStorageClass,
|
||||
/// When applied to a variable, the validator will not complain about the
|
||||
/// declared storage class.
|
||||
kIgnoreStorageClass,
|
||||
/// When applied to an entry-point function parameter, the validator will not
|
||||
/// check for entry IO decorations.
|
||||
kEntryPointParameter,
|
||||
|
||||
Reference in New Issue
Block a user