On Tue, May 17, 2016 at 10:05:57AM +0200, Eric Botcazou wrote: > > We should do CLEANUP_EXPENSIVE after shrink-wrapping, because shrink- > > wrapping creates constructs that CLEANUP_EXPENSIVE can optimise, and > > nothing runs CLEANUP_EXPENSIVE later. We don't need cleanup_cfg before > > shrink-wrapping, nothing in shrink-wrapping (or the other *logue insertion > > code) cares at all. > > Are you sure of that? I agree that CLEANUP_EXPENSIVE might be overkill, but > can't cleanup_cfg expose more opportunities to have multiple epilogues?
How would it? The shrink-wrapping algorithms do not much care how you write your control flow. The only things I can think of are drastic things like removing some dead code, or converting a switch to a direct jump, but those had better be done for the immediately preceding passes already (register allocation). I can put back a cleanup_cfg (0) in front if that seems less tricky (or just safer)? Segher