[PGO] Simplify computehash interface (NFC)
[oota-llvm.git] / include / llvm / ProfileData / InstrProf.h
index 6e813e24eb8aca053136e0a52c2a4524a5730e47..365656bb9d2ca1eb32b47beba6cb36a8f2577076 100644 (file)
@@ -575,6 +575,10 @@ const uint64_t Magic = 0x8169666f72706cff; // "\xfflprofi\x81"
 const uint64_t Version = INSTR_PROF_INDEX_VERSION;
 const HashT HashType = HashT::MD5;
 
+static inline uint64_t ComputeHash(StringRef K) {
+  return ComputeHash(HashType, K);
+}
+
 // This structure defines the file header of the LLVM profile
 // data file in indexed-format.
 struct Header {