**Describe the bug**
1. https://clickhouse-test-reports.s3.yandex.net/19736/68c542aec681bbf841f45fc879c1e97052449555/fuzzer_ubsan/server.log
2. https://clickhouse-test-reports.s3.yandex.net/19736/68c542aec681bbf841f45fc879c1e97052449555/fuzzer_asan/server.log
3. https://clickhouse-test-reports.s3.yandex.net/19736/68c542aec681bbf841f45fc879c1e97052449555/fuzzer_msan/server.log
4. https://clickhouse-test-reports.s3.yandex.net/19736/342326978f2bb2fe5c108c2801cdbabaf407fa68/fuzzer_debug/server.log
5. https://clickhouse-test-reports.s3.yandex.net/19736/342326978f2bb2fe5c108c2801cdbabaf407fa68/fuzzer_tsan/server.log

CC @zhang2014 
key_columns.reserve(num_key_columns);
    
    Columns materialized_columns;
    materialized_columns.reserve(num_key_columns);
    for (size_t i = 0; i < num_key_columns; ++i)
    {
        ColumnPtr result;
        const auto & column_before_cast = block.safeGetByPosition(i);
        ColumnWithTypeAndName column_to_cast
            = {column_before_cast.column->convertToFullColumnIfConst(), column_before_cast.type, column_before_cast.name};
        if (!transform_null_in && data_types[i]->canBeInsideNullable())
        {
            result = castColumnAccurateOrNull(column_to_cast, data_types[i]);
        }
        else
        {
            result = castColumnAccurate(column_to_cast, data_types[i]);
        }
        materialized_columns.emplace_back() = result;
        key_columns.emplace_back() = materialized_columns.back().get();
    }
    
    ConstNullMapPtr null_map{};
    ColumnPtr null_map_holder;
    if (!transform_null_in)
        null_map_holder = extractNestedColumnsAndNullMap(key_columns, null_map);
    executeOrdinary(key_columns, vec_res, negative, null_map);
    return res;
}
bool Set::empty() const