-
Notifications
You must be signed in to change notification settings - Fork 13.6k
llvm-reduce: Add reduceOperandsToPoison reduction #132862
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
llvm-reduce: Add reduceOperandsToPoison reduction #132862
Conversation
This stack of pull requests is managed by Graphite. Learn more about stacking. |
2eab5bb
to
633b42c
Compare
7271ac9
to
e40a40c
Compare
I'm not personally a fan of reducing to poison. this can make test cases smaller but the cognitive load of understanding poison is significant, so I'm not sure this is really a win |
The alternative for target extension types that don't support zero initializer is to do nothing, which is not a win |
e40a40c
to
705dd28
Compare
705dd28
to
7e067d4
Compare
@@ -168,3 +166,18 @@ void llvm::reduceOperandsNaNDeltaPass(Oracle &O, ReducerWorkItem &WorkItem) { | |||
}; | |||
extractOperandsFromModule(O, WorkItem, ReduceValue); | |||
} | |||
|
|||
void llvm::reduceOperandsPoisonDeltaPass(Oracle &O, ReducerWorkItem &WorkItem) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can you add a comment that we're only doing this for non-constant TargetExtTypes?
For now use it only for TargetExtTypes, which do not always support zero initializers.
7e067d4
to
0d4807e
Compare
For now use it only for TargetExtTypes, which do not always support
zero initializers.