#include "nsan_thread.h"
#include <pthread.h>
#include "nsan.h"
#include "sanitizer_common/sanitizer_tls_get_addr.h"
usingnamespace__nsan;
NsanThread *NsanThread::Create(thread_callback_t start_routine, void *arg) { … }
void NsanThread::SetThreadStackAndTls() { … }
void NsanThread::ClearShadowForThreadStackAndTLS() { … }
void NsanThread::Init() { … }
void NsanThread::TSDDtor(void *tsd) { … }
void NsanThread::Destroy() { … }
thread_return_t NsanThread::ThreadStart() { … }
NsanThread::StackBounds NsanThread::GetStackBounds() const { … }
uptr NsanThread::stack_top() { … }
uptr NsanThread::stack_bottom() { … }
bool NsanThread::AddrIsInStack(uptr addr) { … }
void NsanThread::StartSwitchFiber(uptr bottom, uptr size) { … }
void NsanThread::FinishSwitchFiber(uptr *bottom_old, uptr *size_old) { … }
static pthread_key_t tsd_key;
static bool tsd_key_inited;
void __nsan::NsanTSDInit(void (*destructor)(void *tsd)) { … }
static THREADLOCAL NsanThread *nsan_current_thread;
NsanThread *__nsan::GetCurrentThread() { … }
void __nsan::SetCurrentThread(NsanThread *t) { … }
void __nsan::NsanTSDDtor(void *tsd) { … }