After upgrade CH from 20.8 to 21.3 I noticed RAM used by dictionary with `hashed` layout was increased exactly in **4** times.

OS: Ubuntu 20.04
Processor: AMD EPYC 7502P 32-Core Processor
RAM: 252 GB

`<dictionaries_lazy_load>false</dictionaries_lazy_load>
`

In 20.8 release CH was using less memory for dictionaries with `hashed` layout.
The problem was not detected for dictionaries with `ComplexKeyHashed` layout. But they have a small amount of data (up to 500 MB).
After server restart with 20.8 version memory usage is increasing up to 30 GB (all dictionaries RAM usage) step by step during dictionaries loading.
After server restart with 21.3 version memory usage is increasing up to 112 GB almost immediately and then decreasing to 91 GB.

Maybe it's a consequence after #18236

20.8 version dictionary
```
┌─status─┬─type───┬─key────┬─attribute.types─┬─element_count─┬─formatReadableSize(bytes_allocated)─┐
│ LOADED │ Hashed │ UInt64 │ ['Float64']     │     428492347 │ 16.00 GiB                           │
└────────┴────────┴────────┴─────────────────┴───────────────┴─────────────────────────────────────┘
```

21.3 version dictionary
```
┌─status─┬─type───┬─key────┬─attribute.types─┬─element_count─┬─formatReadableSize(bytes_allocated)─┐
│ LOADED │ Hashed │ UInt64 │ ['Float64']     │     428492347 │ 64.00 GiB                           │
└────────┴────────┴────────┴─────────────────┴───────────────┴─────────────────────────────────────┘
```

Dictionaries with the same scheme but another amount of data also have this problem.
{
    const auto size = dict_struct.attributes.size();
    attributes.reserve(size);
    for (const auto & attribute : dict_struct.attributes)
    {
        attribute_index_by_name.emplace(attribute.name, attributes.size());
        attributes.push_back(createAttribute(attribute, attribute.null_value));
        if (attribute.hierarchical)
        {
            hierarchical_attribute = &attributes.back();
            if (hierarchical_attribute->type != AttributeUnderlyingType::utUInt64)
                throw Exception{full_name + ": hierarchical attribute must be UInt64.", ErrorCodes::TYPE_MISMATCH};
        }
    }
}
void HashedDictionary::blockToAttributes(const Block & block)
{
    const auto & id_column = *block.safeGetByPosition(0).column;
    for (const size_t attribute_idx : ext::range(0, attributes.size()))
    {
        const IColumn & attribute_column = *block.safeGetByPosition(attribute_idx + 1).column;
        auto & attribute = attributes[attribute_idx];
        for (const auto row_idx : ext::range(0, id_column.size()))
            if (setAttributeValue(attribute, id_column[row_idx].get<UInt64>(), attribute_column[row_idx]))
                ++element_count;
    }
}
void HashedDictionary::updateData()