MCPcopy Create free account
hub / github.com/MJx0/KittyMemoryEx / findSymbol

Method findSymbol

KittyMemoryEx/KittyScanner.cpp:996–1001  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

994 for (unsigned char c : name)
995 h = ((h << 5) + h) + c;
996 return h;
997 };
998
999 // Direct O(1)-average lookup via DT_HASH: jump straight to the one bucket the name hashes
1000 // to and walk only its chain - never needs to know the table's total size.
1001 auto elfHashLookup = [&](uintptr_t hashAddr, KT_ElfW(Sym) & outSym) -> bool {
1002 if (!hashAddr)
1003 return false;
1004

Callers 5

findSymbolAllMethod · 0.80
findRemoteSymbolMethod · 0.80
initMethod · 0.80
mainFunction · 0.80
mainFunction · 0.80

Calls 1

endMethod · 0.80

Tested by

no test coverage detected