mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-20 18:29:23 +00:00
Add maximum limitation for query count in CreateQuerySet
- Limit the maximum query count to 8192 to fit Metal restriction. - Add unittest tests of query count and remove the test of buffer size overflow validation on 32-bits. Bug: dawn:434 Change-Id: Ie573b715cc3f67ec158996119a8b4a49e493680a Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/36021 Commit-Queue: Hao Li <hao.x.li@intel.com> Reviewed-by: Austin Eng <enga@chromium.org>
This commit is contained in:
committed by
Commit Bot service account
parent
700809a7f7
commit
c08276644f
@@ -43,6 +43,10 @@ namespace dawn_native {
|
||||
return DAWN_VALIDATION_ERROR("nextInChain must be nullptr");
|
||||
}
|
||||
|
||||
if (descriptor->count > kMaxQueryCount) {
|
||||
return DAWN_VALIDATION_ERROR("Max query count exceeded");
|
||||
}
|
||||
|
||||
DAWN_TRY(ValidateQueryType(descriptor->type));
|
||||
|
||||
switch (descriptor->type) {
|
||||
|
||||
Reference in New Issue
Block a user