[llvm] r221318 - Analysis: Make isSafeToSpeculativelyExecute fire less for divides

Sanjoy Das sanjoy at playingwithpointers.com
Sat Nov 8 22:59:10 PST 2014


> If a poison value enters select, is the entire select poisoned?
Going with the obvious:

 * if the condition is poison then the select is poison.
 * otherwise the poison'ness of the select is the poison'ness of the
input value that was dynamically selected.

> If not, that means select can _never_ be decomposed into arithmetic because
> arithmetic propagates poison.

It can be, if the condition is a poison-propagating function of the
two other inputs; which are the case where I think you'd want to
arithmetize a select anyway.  Are there cases of selects which can be
turned into arithmetic that have a condition that isn't poison when
one or two of the inputs to the select are?

-- Sanjoy



More information about the llvm-commits mailing list