On Thu, Nov 19, 2015 at 03:20:22PM +0000, Kyrill Tkachov wrote: > Hmmm, so the answer to that is a bit further down the validate_replacement: > path. > It's the code after the big comment: > /* See if this is a PARALLEL of two SETs where one SET's destination is > a register that is unused and this isn't marked as an instruction that > might trap in an EH region. In that case, we just need the other SET. > We prefer this over the PARALLEL. > > This can occur when simplifying a divmod insn. We *must* test for this > case here because the code below that splits two independent SETs > doesn't > handle this case correctly when it updates the register status. > > It's pointless doing this if we originally had two sets, one from > i3, and one from i2. Combining then splitting the parallel results > in the original i2 again plus an invalid insn (which we delete). > The net effect is only to move instructions around, which makes > debug info less accurate. */ > > The code extracts all the valid sets inside the PARALLEL and calls > recog_for_combine on them > individually, ignoring the clobber.
Before I made this use is_parallel_of_n_reg_sets the code used to test if it is a parallel of two sets, and no clobbers allowed. So it would never allow a clobber of zero. But now it does. I'll fix this in is_parallel_of_n_reg_sets. Thanks for finding the problem! Segher