Function at 0x1800850e0
Capabilities:
Check for time delay via queryperformancecounter
Get thread local storage value

Disassembly:
push rbp
push r13
lea rbp, [rsp - 0x48]
sub rsp, 0x148
cmp qword [rcx + 0x40], 0
mov r13, rcx
jne 0x18008512a
mov r9, qword [rbp + 0x58]
lea rax, [0x1800eb948]
mov r8d, 0x12a
mov qword [rsp + 0x20], rax
lea rdx, str.C:BuildAgent2work78a794e88763017dUE4EngineSourceRuntimeCorePublicAsyncAsyncWork.h
lea rcx, str.QueuedPool
call qword [sym.imp.FactoryServer_Core.dll_public:_static_bool___cdecl_FDebug::CheckVerifyFailedImpl_char_const____ptr64__char_const____ptr64__int__void____ptr64__wchar_t_const____ptr64_]
test al, al
je 0x18008512a
nop
int3
cmp qword [r13 + 0x38], 0
je 0x1800857b7
mov qword [rsp + 0x140], rbx
mov qword [rsp + 0x130], rdi
mov rdi, qword [r13 + 0x60]
mov qword [rsp + 0x128], r12
xor r12b, r12b
mov qword [rsp + 0x120], r14
xor r14d, r14d
mov qword [rsp + 0x118], r15
mov rbx, qword [rdi]
mov qword [rsp + 0x138], rsi
mov qword [rbp - 0x80], r14
test ebx, ebx
jne 0x180085185
mov rax, rbx
shr rax, 0x20
test eax, eax
je 0x1800851f8
mov rax, qword [sym.imp.FactoryServer_Core.dll_int_GCycleStatsShouldEmitNamedEvents]
cmp dword [rax], r14d
je 0x1800851e0
mov rdx, qword [rdi + 0x10]
lea rcx, [rsp + 0x68]
mov dword [rsp + 0x68], r14d
call qword [sym.imp.FactoryServer_Core.dll_public:_static_void___cdecl_FWindowsPlatformMisc::BeginNamedEvent_struct_FColor_const____ptr64__char_const____ptr64_]
mov rax, qword [sym.imp.FactoryServer_Core.dll_class_UE::Trace::FChannel____ptr64___ptr64_CpuChannel]
mov r12b, 1
mov rcx, qword [rax]
mov eax, dword [rcx + 0x18]
test eax, eax
js 0x1800851e0
mov rdx, qword [rdi + 8]
mov rax, rbx
shr rax, 0x20
xor r9d, r9d
mov dword [rsp + 0x64], eax
xor r8d, r8d
mov dword [rsp + 0x60], ebx
mov rcx, qword [rsp + 0x60]
call qword [sym.imp.FactoryServer_Core.dll_public:_static_void___cdecl_FCpuProfilerTrace::OutputBeginDynamicEventWithId_class_FName__wchar_t_const____ptr64__char_const____ptr64__unsigned_int_]
mov r12b, 3
mov rax, qword [sym.imp.FactoryServer_Core.dll_bool_FThreadStats::bPrimaryDisableForever]
cmp byte [rax], r14b
je 0x180085201
mov rax, qword [sym.imp.FactoryServer_Core.dll_bool_FThreadStats::bPrimaryEnable]
cmp byte [rax], r14b
jne 0x180085201
mov rsi, qword [rbp - 0x80]
jmp 0x180085300
mov rax, rbx
mov dword [rsp + 0x60], ebx
shr rax, 0x20
mov dword [rsp + 0x64], eax
mov rax, qword [sym.imp.FactoryServer_Core.dll_unsigned_int_FThreadStats::TlsSlot]
mov rsi, qword [rsp + 0x60]
mov qword [rbp - 0x80], rsi
mov ecx, dword [rax]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
test rax, rax
jne 0x180085242
call qword [sym.imp.FactoryServer_Core.dll_public:_static_struct_FThreadStatsPool____ptr64___cdecl_FThreadStatsPool::Get_void_]
mov rcx, rax
call qword [sym.imp.FactoryServer_Core.dll_public:_class_FThreadStats____ptr64___cdecl_FThreadStatsPool::GetFromPool_void____ptr64]
mov rdi, rax
inc dword [rdi + 0x44]
lea rcx, [rbp - 0x70]
mov rax, rsi
mov dword [rbp - 0x28], ebx
shr rax, 0x20
and eax, 0xffff4fff
bts eax, 0xe
mov dword [rbp - 0x24], eax
call qword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov eax, dword [rbp - 0x70]
mov qword [rbp - 0x30], rax
mov rax, qword [sym.imp.FactoryServer_Core.dll_bool_FLowLevelMemTracker::bIsDisabled]
mov word [rbp + 0x60], r14w
cmp byte [rax], r14b
jne 0x180085299
mov byte [rsp + 0x28], 1
lea rcx, [rbp + 0x60]
xor r9d, r9d
mov byte [rsp + 0x20], 1
xor r8d, r8d
mov dl, 0x2d
call qword [sym.imp.FactoryServer_Core.dll_protected:_void___cdecl_FLLMScope::Init_enum_ELLMTag__bool__enum_ELLMTagSet__enum_ELLMTracker__bool____ptr64]
mov r8b, 1
lea rcx, [rbp - 0x68]
mov dl, 0x2d
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FMemScope::constructor_enum_ELLMTag__bool____ptr64]
inc dword [rdi + 0x4c]
lea rdx, [rdi + 0x18]
mov ecx, 0x10
call fcn.180073980
test rax, rax
je 0x1800852c5
movups xmm0, xmmword [rbp - 0x30]
movups xmmword [rax], xmm0
dec dword [rdi + 0x4c]
lea rcx, [rbp - 0x68]
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FMemScope::destructor_void____ptr64]
cmp byte [rbp + 0x61], r14b
je 0x1800852e2
lea rcx, [rbp + 0x60]
call qword [sym.imp.FactoryServer_Core.dll_protected:_void___cdecl_FLLMScope::Destruct_void____ptr64]
mov rax, qword [sym.imp.FactoryServer_Core.dll_bool_FThreadStats::bIsRawStatsActive]
cmp byte [rax], r14b
je 0x1800852fc
xor r8d, r8d
xor edx, edx
mov rcx, rdi
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FThreadStats::FlushRawStats_bool__bool____ptr64]
or r12b, 4
mov ecx, dword [0x180128694]
lea rdi, str.ThreadPool_Async_Tasks
mov rax, qword gs:[0x58]
lea r15, str.STATCAT_Advanced
mov edx, 0x38
mov rax, qword [rax + rcx*8]
mov eax, dword [rdx + rax]
cmp dword [0x180128428], eax
jg 0x1800857d3
mov rbx, qword [0x180128420]
test rbx, rbx
jne 0x180085391
mov dword [rsp + 0x58], r14d
lea r9, str.STATGROUP_ThreadPoolAsyncTasks
mov byte [rsp + 0x50], r14b
lea r8, str.FAsyncTask::FinishThreadedWork
mov byte [rsp + 0x48], 1
lea rdx, str.STAT_FAsyncTask_FinishThreadedWork
mov dword [rsp + 0x40], 2
lea rcx, [0x180128420]
mov byte [rsp + 0x38], 1
mov byte [rsp + 0x30], 1
mov qword [rsp + 0x28], rdi
mov qword [rsp + 0x20], r15
call qword [sym.imp.FactoryServer_Core.dll_protected:_struct_TStatIdData_const____ptr64___cdecl_FThreadSafeStaticStatBase::DoSetup_char_const____ptr64__wchar_t_const____ptr64__char_const____ptr64__char_const____ptr64__wchar_t_const____ptr64__bool__bool__enum_EStatDataType::Type__bool__bool__enum_FWindowsPlatformMemory::EMemoryCounterRegion_const___ptr64]
mov rbx, rax
mov rdi, qword [rbx]
xor r15b, r15b
mov qword [rsp + 0x70], r14
test edi, edi
jne 0x1800853ba
mov rax, rdi
shr rax, 0x20
test eax, eax
jne 0x1800853ba
mov rcx, qword [r13 + 0x38]
mov rax, qword [rcx]
call qword [rax + 0x10]
jmp 0x18008565f
mov rax, qword [sym.imp.FactoryServer_Core.dll_int_GCycleStatsShouldEmitNamedEvents]
cmp dword [rax], r14d
je 0x180085412
mov rdx, qword [rbx + 0x10]
lea rcx, [rsp + 0x60]
mov dword [rsp + 0x60], r14d
call qword [sym.imp.FactoryServer_Core.dll_public:_static_void___cdecl_FWindowsPlatformMisc::BeginNamedEvent_struct_FColor_const____ptr64__char_const____ptr64_]
mov rax, qword [sym.imp.FactoryServer_Core.dll_class_UE::Trace::FChannel____ptr64___ptr64_CpuChannel]
mov r15b, 1
mov rcx, qword [rax]
mov eax, dword [rcx + 0x18]
test eax, eax
js 0x180085412
mov rdx, qword [rbx + 8]
mov rax, rdi
shr rax, 0x20
xor r9d, r9d
mov dword [rbp + 0x64], eax
xor r8d, r8d
mov dword [rbp + 0x60], edi
mov rcx, qword [rbp + 0x60]
call qword [sym.imp.FactoryServer_Core.dll_public:_static_void___cdecl_FCpuProfilerTrace::OutputBeginDynamicEventWithId_class_FName__wchar_t_const____ptr64__char_const____ptr64__unsigned_int_]
mov r15b, 3
mov rax, qword [sym.imp.FactoryServer_Core.dll_bool_FThreadStats::bPrimaryEnable]
cmp byte [rax], r14b
je 0x18008552a
mov rax, rdi
mov dword [rbp + 0x60], edi
shr rax, 0x20
mov dword [rbp + 0x64], eax
mov rax, qword [sym.imp.FactoryServer_Core.dll_unsigned_int_FThreadStats::TlsSlot]
mov rbx, qword [rbp + 0x60]
mov qword [rsp + 0x70], rbx
mov ecx, dword [rax]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov r14, rax
test rax, rax
jne 0x180085461
call qword [sym.imp.FactoryServer_Core.dll_public:_static_struct_FThreadStatsPool____ptr64___cdecl_FThreadStatsPool::Get_void_]
mov rcx, rax
call qword [sym.imp.FactoryServer_Core.dll_public:_class_FThreadStats____ptr64___cdecl_FThreadStatsPool::GetFromPool_void____ptr64]
mov r14, rax
inc dword [r14 + 0x44]
lea rcx, [rbp - 0x60]
mov rax, rbx
mov dword [rbp - 0x18], edi
shr rax, 0x20
and eax, 0xffff4fff
bts eax, 0xe
mov dword [rbp - 0x14], eax
call qword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov eax, dword [rbp - 0x60]
mov qword [rbp - 0x20], rax
mov rax, qword [sym.imp.FactoryServer_Core.dll_bool_FLowLevelMemTracker::bIsDisabled]
mov word [rbp + 0x68], 0
cmp byte [rax], 0
jne 0x1800854ba
mov byte [rsp + 0x28], 1
lea rcx, [rbp + 0x68]
xor r9d, r9d
mov byte [rsp + 0x20], 1
xor r8d, r8d
mov dl, 0x2d
call qword [sym.imp.FactoryServer_Core.dll_protected:_void___cdecl_FLLMScope::Init_enum_ELLMTag__bool__enum_ELLMTagSet__enum_ELLMTracker__bool____ptr64]
mov r8b, 1
lea rcx, [rbp - 0x58]
mov dl, 0x2d
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FMemScope::constructor_enum_ELLMTag__bool____ptr64]
inc dword [r14 + 0x4c]
lea rdx, [r14 + 0x18]
mov ecx, 0x10
call fcn.180073980
test rax, rax
je 0x1800854e7
movups xmm0, xmmword [rbp - 0x20]
movups xmmword [rax], xmm0
dec dword [r14 + 0x4c]
lea rcx, [rbp - 0x58]
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FMemScope::destructor_void____ptr64]
cmp byte [rbp + 0x69], 0
je 0x180085505
lea rcx, [rbp + 0x68]
call qword [sym.imp.FactoryServer_Core.dll_protected:_void___cdecl_FLLMScope::Destruct_void____ptr64]
mov rax, qword [sym.imp.FactoryServer_Core.dll_bool_FThreadStats::bIsRawStatsActive]
cmp byte [rax], 0
je 0x18008551f
xor r8d, r8d
xor edx, edx
mov rcx, r14
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FThreadStats::FlushRawStats_bool__bool____ptr64]
mov r14d, dword [rsp + 0x70]
or r15b, 4
jmp 0x18008552f
mov rbx, qword [rsp + 0x70]
mov rcx, qword [r13 + 0x38]
mov rax, qword [rcx]
call qword [rax + 0x10]
test r15b, 1
je 0x180085545
call qword [sym.imp.FactoryServer_Core.dll_public:_static_void___cdecl_FWindowsPlatformMisc::EndNamedEvent_void_]
test r15b, 2
je 0x180085551
call qword [sym.imp.FactoryServer_Core.dll_public:_static_void___cdecl_FCpuProfilerTrace::OutputEndEvent_void_]
test r15b, 4
je 0x18008565f
mov rax, qword [sym.imp.FactoryServer_Core.dll_unsigned_int_FThreadStats::TlsSlot]
mov ecx, dword [rax]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rdi, rax
test rax, rax
jne 0x180085584
call qword [sym.imp.FactoryServer_Core.dll_public:_static_struct_FThreadStatsPool____ptr64___cdecl_FThreadStatsPool::Get_void_]
mov rcx, rax
call qword [sym.imp.FactoryServer_Core.dll_public:_class_FThreadStats____ptr64___cdecl_FThreadStatsPool::GetFromPool_void____ptr64]
mov rdi, rax
mov eax, dword [rdi + 0x48]
cmp dword [rdi + 0x44], eax
jle 0x18008565f
shr rbx, 0x20
lea rcx, [rbp - 0x50]
and ebx, 0xffff5fff
mov dword [rbp - 8], r14d
or ebx, 0x5000
mov dword [rbp - 4], ebx
call qword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov eax, dword [rbp - 0x50]
mov qword [rbp - 0x10], rax
mov rax, qword [sym.imp.FactoryServer_Core.dll_bool_FLowLevelMemTracker::bIsDisabled]
mov word [rbp + 0x70], 0
cmp byte [rax], 0
jne 0x1800855e6
mov byte [rsp + 0x28], 1
lea rcx, [rbp + 0x70]
xor r9d, r9d
mov byte [rsp + 0x20], 1
xor r8d, r8d
mov dl, 0x2d
call qword [sym.imp.FactoryServer_Core.dll_protected:_void___cdecl_FLLMScope::Init_enum_ELLMTag__bool__enum_ELLMTagSet__enum_ELLMTracker__bool____ptr64]
mov r8b, 1
lea rcx, [rbp - 0x48]
mov dl, 0x2d
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FMemScope::constructor_enum_ELLMTag__bool____ptr64]
inc dword [rdi + 0x4c]
lea rdx, [rdi + 0x18]
mov ecx, 0x10
call fcn.180073980
test rax, rax
je 0x180085612
movups xmm0, xmmword [rbp - 0x10]
movups xmmword [rax], xmm0
dec dword [rdi + 0x4c]
lea rcx, [rbp - 0x48]
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FMemScope::destructor_void____ptr64]
cmp byte [rbp + 0x71], 0
je 0x18008562f
lea rcx, [rbp + 0x70]
call qword [sym.imp.FactoryServer_Core.dll_protected:_void___cdecl_FLLMScope::Destruct_void____ptr64]
sub dword [rdi + 0x44], 1
jne 0x180085645
xor r8d, r8d
xor edx, edx
mov rcx, rdi
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FThreadStats::Flush_bool__bool____ptr64]
jmp 0x18008565f
mov rax, qword [sym.imp.FactoryServer_Core.dll_bool_FThreadStats::bIsRawStatsActive]
cmp byte [rax], 0
je 0x18008565f
xor r8d, r8d
xor edx, edx
mov rcx, rdi
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FThreadStats::FlushRawStats_bool__bool____ptr64]
mov r15, qword [rsp + 0x118]
mov r14, qword [rsp + 0x120]
mov rdi, qword [rsp + 0x130]
test r12b, 1
je 0x180085683
call qword [sym.imp.FactoryServer_Core.dll_public:_static_void___cdecl_FWindowsPlatformMisc::EndNamedEvent_void_]
test r12b, 2
je 0x18008568f
call qword [sym.imp.FactoryServer_Core.dll_public:_static_void___cdecl_FCpuProfilerTrace::OutputEndEvent_void_]
test r12b, 4
mov r12, qword [rsp + 0x128]
je 0x1800857a7
mov rax, qword [sym.imp.FactoryServer_Core.dll_unsigned_int_FThreadStats::TlsSlot]
mov ecx, dword [rax]
call qword [sym.imp.KERNEL32.dll_TlsGetValue]
mov rbx, rax
test rax, rax
jne 0x1800856ca
call qword [sym.imp.FactoryServer_Core.dll_public:_static_struct_FThreadStatsPool____ptr64___cdecl_FThreadStatsPool::Get_void_]
mov rcx, rax
call qword [sym.imp.FactoryServer_Core.dll_public:_class_FThreadStats____ptr64___cdecl_FThreadStatsPool::GetFromPool_void____ptr64]
mov rbx, rax
mov eax, dword [rbx + 0x48]
cmp dword [rbx + 0x44], eax
jle 0x1800857a7
mov eax, dword [rbp - 0x80]
lea rcx, [rbp - 0x40]
shr rsi, 0x20
and esi, 0xffff5fff
mov dword [rbp + 8], eax
or esi, 0x5000
mov dword [rbp + 0xc], esi
call qword [sym.imp.KERNEL32.dll_QueryPerformanceCounter]
mov eax, dword [rbp - 0x40]
mov qword [rbp], rax
mov rax, qword [sym.imp.FactoryServer_Core.dll_bool_FLowLevelMemTracker::bIsDisabled]
mov word [rbp + 0x78], 0
cmp byte [rax], 0
jne 0x18008572e
mov byte [rsp + 0x28], 1
lea rcx, [rbp + 0x78]
xor r9d, r9d
mov byte [rsp + 0x20], 1
xor r8d, r8d
mov dl, 0x2d
call qword [sym.imp.FactoryServer_Core.dll_protected:_void___cdecl_FLLMScope::Init_enum_ELLMTag__bool__enum_ELLMTagSet__enum_ELLMTracker__bool____ptr64]
mov r8b, 1
lea rcx, [rbp - 0x38]
mov dl, 0x2d
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FMemScope::constructor_enum_ELLMTag__bool____ptr64]
inc dword [rbx + 0x4c]
lea rdx, [rbx + 0x18]
mov ecx, 0x10
call fcn.180073980
test rax, rax
je 0x18008575a
movups xmm0, xmmword [rbp]
movups xmmword [rax], xmm0
dec dword [rbx + 0x4c]
lea rcx, [rbp - 0x38]
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FMemScope::destructor_void____ptr64]
cmp byte [rbp + 0x79], 0
je 0x180085777
lea rcx, [rbp + 0x78]
call qword [sym.imp.FactoryServer_Core.dll_protected:_void___cdecl_FLLMScope::Destruct_void____ptr64]
sub dword [rbx + 0x44], 1
jne 0x18008578d
xor r8d, r8d
xor edx, edx
mov rcx, rbx
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FThreadStats::Flush_bool__bool____ptr64]
jmp 0x1800857a7
mov rax, qword [sym.imp.FactoryServer_Core.dll_bool_FThreadStats::bIsRawStatsActive]
cmp byte [rax], 0
je 0x1800857a7
xor r8d, r8d
xor edx, edx
mov rcx, rbx
call qword [sym.imp.FactoryServer_Core.dll_public:_void___cdecl_FThreadStats::FlushRawStats_bool__bool____ptr64]
mov rsi, qword [rsp + 0x138]
mov rbx, qword [rsp + 0x140]
add rsp, 0x148
pop r13
pop rbp
ret
lea rcx, [0x180128428]
call fcn.1800e2ff0
jmp 0x180085335
lea rcx, [0x180128428]
call fcn.1800e3060
cmp dword [0x180128428], 0xffffffff
jne 0x180085335
mov rax, qword [0x180128420]
test rax, rax
jne 0x1800857c2
mov dword [rsp + 0x58], r14d
lea r9, str.STATGROUP_ThreadPoolAsyncTasks
mov byte [rsp + 0x50], r14b
lea r8, str.FAsyncTask::FinishThreadedWork
mov byte [rsp + 0x48], 1
lea rdx, str.STAT_FAsyncTask_FinishThreadedWork
mov dword [rsp + 0x40], 2
lea rcx, [0x180128420]
mov byte [rsp + 0x38], 1
mov byte [rsp + 0x30], 1
mov qword [rsp + 0x28], rdi
mov qword [rsp + 0x20], r15
call qword [sym.imp.FactoryServer_Core.dll_protected:_struct_TStatIdData_const____ptr64___cdecl_FThreadSafeStaticStatBase::DoSetup_char_const____ptr64__wchar_t_const____ptr64__char_const____ptr64__char_const____ptr64__wchar_t_const____ptr64__bool__bool__enum_EStatDataType::Type__bool__bool__enum_FWindowsPlatformMemory::EMemoryCounterRegion_const___ptr64]
jmp 0x1800857c2