HalpTimerInitializeProfiling
INT64 __fastcall HalpTimerInitializeProfiling(){
KDPC *v0;
int v1;
INT64 v2;
void *v4;
void *v5;
void *v6;
__int64 v7;
void *v8;
void *v9;
void *v10;
__int64 v11;
int v12;
__int128 v13;
v0 = (KDPC *)HalpProfileTimer;
v1 = 0;
v13 = 0i64;
if( HalpProfileData || (HalpProfileData = (__int64)HalpMmAllocatePerProcessorMemory(32)) != 0 )
{
v12 = 10000;
(*((void(__fastcall **)(_QWORD, int *))HalpProfileInterface[0] + 3))(0i64, &v12);
if( *((_DWORD *)KeGetPcr() + 105) )
{
if( v0 )
{
HalpInterruptSetIdtEntry(0xFDui64, HalpTimerProfileInterrupt, 15, v2, (UINT64 *)0xFFFFFFFFFFFFFFFDi64);
if( ((__int64)v0[3].DeferredContext & 1) != 0 )
{
HalpTimerGetInternalData(v0, v4, v5, v6);
v1 = ((__int64(__fastcall *)(__int64))v0[1].SystemArgument1)(v7);
if( v1 >= 0 )
{
HalpTimerGetInternalData(v0, v8, v9, v10);
((void(__fastcall *)(__int64))v0[2].DpcListEntry.Next)(v11);
}
}
}
}
else if( v0 )
{
*((_QWORD *)&v13 + 1) = (unsigned __int16)((unsigned int)KiProcessorIndexToNumberMappingTable[0] >> 6);
*(_QWORD *)&v13 = 1i64 << (KiProcessorIndexToNumberMappingTable[0] & 0x3F);
return(unsigned int)HalpTimerConfigureInterrupt(
(__int64)v0,
0xFDu,
15,
v2,
-3i64,
1,
&v13,
(__int64(__fastcall *)(__int64, __int64))HalpTimerProfileInterrupt);
}
}
else
{
return(unsigned int)-1073741801;
}
return(unsigned int)v1;
}Referenced by:
No references.