mirror of
https://git.anonymousland.org/anonymousland/synapse.git
synced 2025-01-26 09:55:56 -05:00
fa5c2bc082
This line shows up as about 5% of cpu time on a synchrotron: not_known_entities = set(entities) - set(self._entity_to_key) Presumably the problem here is that _entity_to_key can be largeish, and building a set for its keys every time this function is called is slow. Here we rewrite the logic to avoid building so many sets.