PfpLogEventRequest

__int64 __fastcall PfpLogEventRequest(int *a1){
  unsigned int v2; 
  int v3; 
  __int64 v5; 
  UINT64 DefaultPagePriority; 
  unsigned int SystemInformation; 

  if( (*a1 & 0x1Fu) - 2 <= 1 )
  {
    v5 = *((_QWORD *)a1 + 1);
    *(_OWORD *)v5 = xmmword_140C4FC10;
    *(_QWORD *)(v5 + 16) = unk_140C4FC20;
    if( (*a1 & 0x1F) == 2 )
      DefaultPagePriority = (*(_DWORD *)(v5 + 24) >> 5) & 7;
    else
      DefaultPagePriority = (unsigned int)MmGetDefaultPagePriority();
    PfTSetTracingPriority(DefaultPagePriority);
  }
  if( (*(_BYTE *)a1 & 0x1F) == 27 && (*(_DWORD *)(*((_QWORD *)a1 + 1) + 8i64) & 3) == 1 )
    _InterlockedAnd((volatile signed __int32 *)&PfKernelGlobals.Flags, 0xFFFFFFFE);
  v2 = *a1;
  v3 = dword_140C5001C
     + ((((KUSER_SHARED_DATA.TickCountMultiplier * (unsigned __int64)KUSER_SHARED_DATA.ReservedTickCountOverlay[1]) << 8)
       + ((KUSER_SHARED_DATA.TickCountMultiplier * (unsigned __int64)KUSER_SHARED_DATA.TickCount.LowPart) >> 24)) >> 10);
  if( (*a1 & 0x20) != 0 )
  {
    SystemInformation = ((unsigned int)*a1 >> 6) & 1;
    MmIssueMemoryListCommand(&SystemInformation, 4ui64, 0);
    PfGenerateTrace((PFP_LOGGING_WORKER_CONTEXT *)&stru_140C4DB30 + 1934, 0i64);
    v2 = *a1;
  }
  return PfLogEvent(v2 & 0x1F, v3, *((const VOID **)a1 + 1), v2 >> 7);
}

Referenced by:

PfSetSuperfetchInformation