Skip to content
  • Bob Wilson's avatar
    Clean up some problems with extra CFG edges being introduced during · c72da6bb
    Bob Wilson authored
    if-conversion.  The RemoveExtraEdges function doesn't work for blocks that
    end with unanalyzable branches, so in those cases, the "extra" edges must
    be explicitly removed.  The CopyAndPredicateBlock and MergeBlocks methods
    can also avoid copying successor edges due to branches that have already
    been removed.  The latter case is especially helpful when MergeBlocks is
    called for handling "diamond" if-conversions, where otherwise you can end
    up with some weird intermediate states in the CFG.  Unfortunately I've
    been unable to find cases where this cleanup actually makes a significant
    difference in the code.  There is one test where we manage to remove an
    empty block at the end of a function.  Radar 6911268.
    
    llvm-svn: 106939
    c72da6bb
Loading