diff options
author | Lang Hames <lhames@gmail.com> | 2019-10-25 17:59:17 -0700 |
---|---|---|
committer | Lang Hames <lhames@gmail.com> | 2019-10-25 18:19:25 -0700 |
commit | 4141bb50a871c28ed7504e88e4ddb4f924a93bce (patch) | |
tree | 44cd6ab9332815c7a16b99189aeb24abc2db66b3 | |
parent | 93b29d3882baf7df42e4e9bc26b977b00373ef56 (diff) | |
download | bcm5719-llvm-4141bb50a871c28ed7504e88e4ddb4f924a93bce.tar.gz bcm5719-llvm-4141bb50a871c28ed7504e88e4ddb4f924a93bce.zip |
[ORC] Avoid SymbolStringPtr copies in DynamicLibrarySearchGenerator predicate.
Pass SymbolStringPtr by const-ref to avoid copies (which require atomic
ref-count operations).
-rw-r--r-- | llvm/include/llvm/ExecutionEngine/Orc/ExecutionUtils.h | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/include/llvm/ExecutionEngine/Orc/ExecutionUtils.h b/llvm/include/llvm/ExecutionEngine/Orc/ExecutionUtils.h index cf0a428662e..b9bbace6f63 100644 --- a/llvm/include/llvm/ExecutionEngine/Orc/ExecutionUtils.h +++ b/llvm/include/llvm/ExecutionEngine/Orc/ExecutionUtils.h @@ -242,7 +242,7 @@ public: /// passes the 'Allow' predicate will be added to the JITDylib. class DynamicLibrarySearchGenerator : public JITDylib::DefinitionGenerator { public: - using SymbolPredicate = std::function<bool(SymbolStringPtr)>; + using SymbolPredicate = std::function<bool(const SymbolStringPtr &)>; /// Create a DynamicLibrarySearchGenerator that searches for symbols in the /// given sys::DynamicLibrary. |