treelite
include
treelite
thread_local.h
Go to the documentation of this file.
1
7
#ifndef TREELITE_THREAD_LOCAL_H_
8
#define TREELITE_THREAD_LOCAL_H_
9
10
namespace
treelite
{
11
16
template
<
typename
T>
17
class
ThreadLocalStore
{
18
public
:
20
static
T*
Get
() {
21
static
thread_local T inst;
22
return
&inst;
23
}
24
};
25
26
}
// namespace treelite
27
28
#endif
// TREELITE_THREAD_LOCAL_H_
treelite::ThreadLocalStore
A thread-local storage.
Definition:
thread_local.h:17
treelite::ThreadLocalStore::Get
static T * Get()
Definition:
thread_local.h:20
treelite
Definition:
contiguous_array.h:14
Generated on Sat Feb 24 2024 00:20:49 for treelite by
1.9.1