[PATCH] D114394: Compile-time computation of string attribute hashes

Jon Chesterfield via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Nov 23 00:41:26 PST 2021


JonChesterfield added inline comments.


================
Comment at: llvm/include/llvm/IR/Attributes.h:79
+  bool operator<(AttributeKey const &other) const {
+    return strcmp(value_, other.value_) < 0;
+  }
----------------
Could order by size first here, then strncmp on equal sizes


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D114394/new/

https://reviews.llvm.org/D114394



More information about the cfe-commits mailing list