[LVI] Don't bail on overdefined value in select
authorNikita Popov <nikita.ppv@gmail.com>
Sun, 4 Apr 2021 08:52:22 +0000 (10:52 +0200)
committerNikita Popov <nikita.ppv@gmail.com>
Sun, 4 Apr 2021 09:11:01 +0000 (11:11 +0200)
commit72e0846ef87d0d3b5960238bc47fc0cc6f04d848
tree3ef5473196d88d352af9ce933bbf4b3ae6b01222
parent3ac2541b5c31fd13fa60e7b0692b7f9bf4a41733
[LVI] Don't bail on overdefined value in select

Even if one of the operands is overdefined, we may still produce
a non-overdefined result, e.g. due to a min/max operation. This
matches our handling elsewhere, e.g. for binary operators.

The slot poisoning comment refers to a much older LVI cache
implementation.
llvm/lib/Analysis/LazyValueInfo.cpp
llvm/test/Transforms/CorrelatedValuePropagation/and.ll