[llvm] [nfc]Make InstrProfSymtab non-copyable and non-movable (PR #86882)

Snehasish Kumar via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 27 15:48:05 PDT 2024


================
@@ -471,6 +471,15 @@ class InstrProfSymtab {
 public:
   InstrProfSymtab() = default;
 
+  // Not copyable or movable.
+  // Consider std::unique_ptr for move.
+  // InstrProfSymtab has a few containers as class members, so consider
+  // std::shared_ptr for read-only copy.
----------------
snehasish wrote:

std::shared_ptr has (some) overhead and since we aren't using it in this change, lets drop this comment.

https://github.com/llvm/llvm-project/pull/86882


More information about the llvm-commits mailing list