[NewGVN] add context instruction for SimplifyQuery
NewGVN will find operator from other context. ValueTracking currently doesn't have a way to run completely without context instruction. So it will use operator itself as conext instruction. If the operator in another branch will never be executed but it has an assume, it may caused value tracking use the assume to do wrong simpilfy. It would be better to make these simplification queries not use context at all, but that would require some API changes. For now we just use the orignial instruction as context instruction to fix the issue. Fix #56039 Reviewed By: nikic Differential Revision: https://reviews.llvm.org/D127942
Loading
Please sign in to comment