> This looks good. OK for the trunk. FWIW I disagree. The patch completely shuns the existing implementation of the pass, which is based on a forward scan within basic blocks to identify the various interesting instructions and record them, and uses full-blown def-use and use-def chains instead, which are much more costly to compute. It's not clear to me why the existing implementation couldn't have been extended.
The result is that, for targets for which the pass was initially written, i.e. targets for which most (all) arithmetic instructions clobber the flags, the pass will be slower for absolutely no benefits, as the existing implementation would already have caught all the interesting cases. So it's again a case of a generic change made for a specific target without consideration for other, admittedly less mainstream, targets... -- Eric Botcazou