Skip to content

Commit

Permalink
Tweaked: One less hash combination when calculating the query hash
Browse files Browse the repository at this point in the history
  • Loading branch information
richardbiely committed Dec 12, 2023
1 parent 64079e8 commit 59b6a11
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 5 deletions.
1 change: 0 additions & 1 deletion include/gaia/ecs/archetype.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@
#include "component.h"
#include "component_cache.h"
#include "component_utils.h"
#include "gaia/config/config_core.h"
#include "id.h"

namespace gaia {
Expand Down
4 changes: 2 additions & 2 deletions include/gaia/ecs/query_common.h
Original file line number Diff line number Diff line change
Expand Up @@ -184,9 +184,9 @@ namespace gaia {
hash = core::hash_combine(hash, (QueryLookupHash::Type)pair.id.value());
}
hash = core::hash_combine(hash, (QueryLookupHash::Type)pairs.size());

hash = core::hash_combine(hash, (QueryLookupHash::Type)data.readWriteMask);
hashLookup = core::hash_combine(hashLookup, hash);

hashLookup = hash;
}

// Filters
Expand Down
4 changes: 2 additions & 2 deletions single_include/gaia.h
Original file line number Diff line number Diff line change
Expand Up @@ -18368,9 +18368,9 @@ namespace gaia {
hash = core::hash_combine(hash, (QueryLookupHash::Type)pair.id.value());
}
hash = core::hash_combine(hash, (QueryLookupHash::Type)pairs.size());

hash = core::hash_combine(hash, (QueryLookupHash::Type)data.readWriteMask);
hashLookup = core::hash_combine(hashLookup, hash);

hashLookup = hash;
}

// Filters
Expand Down

0 comments on commit 59b6a11

Please sign in to comment.