spirv-fuzz: Improve the handling of equation facts#3281
Merged
afd merged 3 commits intoKhronosGroup:masterfrom Apr 7, 2020
Merged
spirv-fuzz: Improve the handling of equation facts#3281afd merged 3 commits intoKhronosGroup:masterfrom
afd merged 3 commits intoKhronosGroup:masterfrom
Conversation
The management of equation facts suffered from two problems:
(1) The processing of an equation fact required the data descriptors
used in the equation to be in canonical form. However, during
fact processing it can be deduced that certain data descriptors
are equivalent, causing their equivalence classes to be merged,
and that could cause previously canonical data descriptors to no
longer be canonical.
(2) Related to this, if id equations were known about a canonical data
descriptor dd1, and other id equations known about a different
canonical data descriptor dd2, the equation facts about these data
descriptors were not being merged in the event that dd1 and dd2
were deduced to be equivalent.
This changes solves (1) by not requiring equation facts to be in
canonical form while processing them, but instead always checking
whether (not necessary canonical) data descriptors are equivalent when
looking for corollaries of equation facts, rather than comparing them
using ==.
Problem (2) is solved by adding logic to merge sets of equations when
data descriptors are made equivalent.
In addition, the change also requires elements to be registered in an
equivalence relation before they can be made equivalent, rather than
being added (if not already present) at the point of being made
equivalent.
paulthomson
approved these changes
Apr 7, 2020
dneto0
pushed a commit
to dneto0/SPIRV-Tools
that referenced
this pull request
Sep 14, 2024
Roll third_party/glslang/ b5757b9..4d2298b (5 commits) KhronosGroup/glslang@b5757b9...4d2298b $ git log b5757b9..4d2298b --date=short --no-merges --format='%ad %ae %s' 2020-04-13 cnorthrop Support multiple swizzled out operands (KhronosGroup#2175) 2020-04-12 cepheus Fix KhronosGroup#2178: Allow specialization constants for texel offsets. 2020-04-10 h.baensch.92 Get rid of all warnings with MSVC and clang-cl (KhronosGroup#2177) 2020-04-08 40001162+alelenv Add support for EXT_ray_flags_primitive_culling. (KhronosGroup#2173) 2020-04-07 cepheus Error message: Finish addressing KhronosGroup#2097, better texture error message. Roll third_party/re2/ 58141dc9c..ac65d4531 (2 commits) google/re2@58141dc...ac65d45 $ git log 58141dc9c..ac65d4531 --date=short --no-merges --format='%ad %ae %s' 2020-04-09 junyer Remove deprecated APIs. Bump SONAME accordingly. 2020-04-06 junyer Go back to using __builtin_ctzll(). Sigh. Roll third_party/spirv-cross/ 6637610b1..54658d625 (3 commits) KhronosGroup/SPIRV-Cross@6637610...54658d6 $ git log 6637610b1..54658d625 --date=short --no-merges --format='%ad %ae %s' 2020-04-10 cdavis MSL: Add options to control emission of fragment outputs. 2020-04-09 h.baensch.92 Improve compatibility with clang-cl 2020-04-07 post MSL: Do not use base expression with PhysicalTypeID OpCompositeExtract. Roll third_party/spirv-headers/ f8bf11a..2ad0492 (1 commit) KhronosGroup/SPIRV-Headers@f8bf11a...2ad0492 $ git log f8bf11a..2ad0492 --date=short --no-merges --format='%ad %ae %s' 2020-04-13 cepheus Discuss generator magic number reservations. Roll third_party/spirv-tools/ e95fbfb..ca57515 (9 commits) KhronosGroup/SPIRV-Tools@e95fbfb...ca57515 $ git log e95fbfb..ca57515 --date=short --no-merges --format='%ad %ae %s' 2020-04-14 dneto If SPIRV-Headers is in our tree, include it as subproject (KhronosGroup#3299) 2020-04-13 stevenperron Struct CFG analysus and single block loop (KhronosGroup#3293) 2020-04-13 jaebaek Preserve debug info in eliminate-dead-functions (KhronosGroup#3251) 2020-04-13 stevenperron Update acorn version (KhronosGroup#3294) 2020-04-09 stevenperron Handle more cases in dead member elim (KhronosGroup#3289) 2020-04-09 h.baensch.92 Fix pch macro to ignore clang-cl (KhronosGroup#3283) 2020-04-07 afdx spirv-fuzz: Improve the handling of equation facts (KhronosGroup#3281) 2020-04-07 afdx spirv-fuzz: Handle more general SPIR-V in donation (KhronosGroup#3280) 2020-04-06 afdx spirv-fuzz: Improve support for compute shaders in donation (KhronosGroup#3277) Created with: roll-dep third_party/effcee third_party/glslang third_party/googletest third_party/re2 third_party/spirv-cross third_party/spirv-headers third_party/spirv-tools
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The management of equation facts suffered from two problems:
(1) The processing of an equation fact required the data descriptors
used in the equation to be in canonical form. However, during
fact processing it can be deduced that certain data descriptors
are equivalent, causing their equivalence classes to be merged,
and that could cause previously canonical data descriptors to no
longer be canonical.
(2) Related to this, if id equations were known about a canonical data
descriptor dd1, and other id equations known about a different
canonical data descriptor dd2, the equation facts about these data
descriptors were not being merged in the event that dd1 and dd2
were deduced to be equivalent.
This changes solves (1) by not requiring equation facts to be in
canonical form while processing them, but instead always checking
whether (not necessary canonical) data descriptors are equivalent when
looking for corollaries of equation facts, rather than comparing them
using ==.
Problem (2) is solved by adding logic to merge sets of equations when
data descriptors are made equivalent.
In addition, the change also requires elements to be registered in an
equivalence relation before they can be made equivalent, rather than
being added (if not already present) at the point of being made
equivalent.