[PATCH] D17663: [JumpThreading] See through Cast Instructions
Haicheng Wu via llvm-commits
llvm-commits at lists.llvm.org
Mon Feb 29 11:18:06 PST 2016
haicheng added a comment.
In http://reviews.llvm.org/D17663#364437, @gberry wrote:
> Would it not be better to fix SimplifyICmpInst to have some way of returning that it has done some simplification?
I am not sure. Currently, SimplifyICmpInst either return a ConstantInt or an existing value. Is it safe to let it return a new value? Will it break anything?
.
ComputeValueKnownInPredecessors() is very similar to SimplifyInstruction(). Many cases handled in ComputeValueKnownInPredecessors() (e.g., xor 1 x => not x ) are also the targets of SimplifyInstruction(). However, there are still some subtle differences between them (e.g. they treat undef differently) so that we cannot replace one by the other. So, I think it might be better just enhancing ComputeValueKnownInPredecessors().
Repository:
rL LLVM
http://reviews.llvm.org/D17663
More information about the llvm-commits
mailing list