[PATCH] D66967: [Attributor] ValueSimplify Abstract Attribute

Johannes Doerfert via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 5 10:15:44 PDT 2019


jdoerfert added inline comments.


================
Comment at: llvm/test/Transforms/FunctionAttrs/value-simplify.ll:117
+  ; CHECK: tail call void @use(i32 %select-not-same-undef)
+  tail call void @use(i32 %select-not-same-undef)
+
----------------
uenoku wrote:
> jdoerfert wrote:
> > This should arguably be
> >   `; CHECK: tail call void @use(i32 %phi-not-same)`
> > The pessimistic fixpoint should probably not revert to `nullptr` and cause a cascading failure but instead just go back to the original value.
> >
> > This should arguably be
> > 
> > `; CHECK: tail call void @use(i32 %phi-not-same)`
> In genericTraversal, `%phi-not-same` is  decomposed to i32 0, 1 so I think it is not currect.
> 
> > The pessimistic fixpoint should probably not revert to nullptr and cause a cascading failure but instead just go back to the original value.
> It looks good.
so `%phi-not-same` is not simplified, right?
But `%select-not-same-undef` is something or `undef` and then we should simplify it to "something". That would probably happen just fine if we do not use `nullptr` as pessimistic value but the original value itself. That is, the worst thing you can simplify an instruction to is itself.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D66967/new/

https://reviews.llvm.org/D66967





More information about the llvm-commits mailing list