From b11ffc9635204f11daac4f20596dc4e3da687eee Mon Sep 17 00:00:00 2001 From: Adam Ierymenko Date: Thu, 27 Aug 2015 16:17:21 -0700 Subject: Integrate Hashtable into Multicaster, where @mwarning found heaviest std::map() overhead. --- node/MulticastGroup.hpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'node/MulticastGroup.hpp') diff --git a/node/MulticastGroup.hpp b/node/MulticastGroup.hpp index 61fb55f2..fad433b5 100644 --- a/node/MulticastGroup.hpp +++ b/node/MulticastGroup.hpp @@ -141,6 +141,8 @@ public: */ inline uint32_t adi() const throw() { return _adi; } + inline unsigned long hashCode() const throw() { return (_mac.hashCode() ^ (unsigned long)_adi); } + inline bool operator==(const MulticastGroup &g) const throw() { return ((_mac == g._mac)&&(_adi == g._adi)); } inline bool operator!=(const MulticastGroup &g) const throw() { return ((_mac != g._mac)||(_adi != g._adi)); } inline bool operator<(const MulticastGroup &g) const throw() -- cgit v1.2.3