`RewindBlockIndex` was made to allow nodes upgrading to new consensus rules post-segwit fork to 
download new consensus data (i.e witnesses) without having to go through a whole IBD. It has been pointed than now really few pre-segwit nodes care to upgrade and that this logic may be irrelevant.

See https://github.com/bitcoin/bitcoin/pull/17737#discussion_r358514335 in review  of #17737 for more context pointers.
}
        }
    }
    
    while (true) {
        if (ShutdownRequested()) break;
        
        LimitValidationInterfaceQueue();
        LOCK(cs_main);
        LOCK(m_mempool.cs); 
        if (!m_chain.Contains(pindex)) break;
        pindex_was_in_chain = true;
        CBlockIndex *invalid_walk_tip = m_chain.Tip();
        
        
        DisconnectedBlockTransactions disconnectpool;
        bool ret = DisconnectTip(state, chainparams, &disconnectpool);
        
        
        
        
        
        assert(std::addressof(::ChainstateActive()) == std::addressof(*this));
        UpdateMempoolForReorg(*this, m_mempool, disconnectpool,  (++disconnected <= 10) && ret);
        if (!ret) return false;
        assert(invalid_walk_tip->pprev == m_chain.Tip());