MCPcopy Create free account
hub / github.com/FEX-Emu/FEX / GetThreadCPUArea

Function GetThreadCPUArea

Source/Windows/ARM64EC/Module.cpp:143–147  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

141std::unordered_map<DWORD, FEXCore::Core::InternalThreadState*> Threads;
142
143std::pair<NTSTATUS, ThreadCPUArea> GetThreadCPUArea(HANDLE Thread) {
144 THREAD_BASIC_INFORMATION Info;
145 const NTSTATUS Err = NtQueryInformationThread(Thread, ThreadBasicInformation, &Info, sizeof(Info), nullptr);
146 return {Err, ThreadCPUArea(reinterpret_cast<_TEB*>(Info.TebBaseAddress))};
147}
148
149ThreadCPUArea GetCPUArea() {
150 return ThreadCPUArea(NtCurrentTeb());

Callers 1

ThreadTermFunction · 0.85

Calls 1

ThreadCPUAreaClass · 0.85

Tested by

no test coverage detected