mirror of
https://github.com/inspircd/inspircd.git
synced 2025-03-09 10:39:02 -04:00
Optimized membership lookup for large servers
On our server hosting 150K users we noticed that std::map lookups for user membership were high on the profile. Since there seemed to be no ordered iteration needed we were able to shave a few % off of the profile by changing this to a std::unordered_map
This commit is contained in:
parent
5084eca9ba
commit
41293a058d
@ -43,7 +43,7 @@ class CoreExport Channel final
|
||||
public:
|
||||
/** A map of Memberships on a channel keyed by User pointers
|
||||
*/
|
||||
typedef std::map<User*, insp::aligned_storage<Membership>> MemberMap;
|
||||
typedef std::unordered_map<User*, insp::aligned_storage<Membership>> MemberMap;
|
||||
|
||||
private:
|
||||
/** Set default modes for the channel on creation
|
||||
|
Loading…
x
Reference in New Issue
Block a user