Tracking issue for the follow up comments in #22904. It seems that PR has introduced lock contentions, and/or the `checkqueue_tests` are now behaving very poorly, with long runtimes and generating GBs of log output in some cases. See comments starting here: https://github.com/bitcoin/bitcoin/pull/22904#issuecomment-930466935.

cc @ajtowns @theuni @martinus  
{
        return !fails;
    }
    void swap(FailingCheck& x)
    {
        std::swap(fails, x.fails);
    };
};
struct UniqueCheck {
    static Mutex m;
    static std::unordered_multiset<size_t> results GUARDED_BY(m);
    size_t check_id;
    UniqueCheck(size_t check_id_in) : check_id(check_id_in){};
    UniqueCheck() : check_id(0){};
    bool operator()()
    {
        LOCK(m);
        results.insert(check_id);
        return true;
    }
    void swap(UniqueCheck& x) { std::swap(x.check_id, check_id); };
};
struct MemoryCheck {
    static std::atomic<size_t> fake_allocated_memory;
    bool b {false};
    bool operator()() const
    {
        return true;
    }
    MemoryCheck(){};