This is a first effort to replace https://reviews.llvm.org/D90231, which aimed to exclude @llvm.is.constant() from value replacements. Instead, this patch takes the approach of improving GVN so that the failed test case compiles.
propagateEquality() calls replaceDominatedUsesWith() at the point where one Value can replace another one as long as it is dominated from a certain point. This patch makes sure that also the cases where a user that is not dominated by any such call can still be updated if all of its (parents) predecessors are dominated by such an equivalence. In other words, if there are multiple calls to replaceDominatedUsesWith() at different points with the same equivalency, they may together dominate a user.
This is needed to be able to compile Linux Kernel code with multiple __builtin_constant_p calls.
can probably use a range for here, too.