MCPcopy Create free account
hub / github.com/Xtra-Computing/thundersvm / setThreadName

Method setThreadName

include/thundersvm/util/log.h:2721–2725  ·  view source on GitHub ↗

@brief Sets thread name for current thread. Requires std::thread

Source from the content-addressed store, hash-verified

2719
2720 /// @brief Sets thread name for current thread. Requires std::thread
2721 inline void setThreadName(const std::string& name) {
2722 if (name.empty()) return;
2723 base::threading::ScopedLock scopedLock(lock());
2724 m_threadNames[base::threading::getCurrentThreadId()] = name;
2725 }
2726
2727 inline std::string getThreadName(const std::string& threadId) {
2728 std::map<std::string, std::string>::const_iterator it = m_threadNames.find(threadId);

Callers 1

setThreadNameMethod · 0.45

Calls 2

getCurrentThreadIdFunction · 0.85
emptyMethod · 0.45

Tested by

no test coverage detected