KeCompactServiceTable

VOID __stdcall KeCompactServiceTable(PVOID Table, PVOID Arguments, UINT64 Limit, UINT64 Flags, UINT64 ImageBase){
  _DWORD *v6; 
  __int64 v7; 
  unsigned int v8; 
  v6 = Table;
  if( (_DWORD)Limit )
  {
    v7 = (unsigned int)Limit;
    do
    {
      v8 = *(unsigned __int8 *)Arguments;
      Arguments = (char *)Arguments + 1;
      *v6 = (v8 >> 2) | (16 * (ImageBase + *v6 - (_DWORD)Table));
      ++v6;
      --v7;
    }
    while( v7 );
  }
  KiLockServiceTable(Table);
}

Referenced by:

KiInitializeKernel
MiCompactServiceTable