sceKernelAioInitializeParam (#208)

This commit is contained in:
Ordinary205 2024-04-03 00:45:28 +04:00 committed by GitHub
parent 72a5a16616
commit ad0b0240a8
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 54 additions and 0 deletions

View File

@ -14,6 +14,37 @@ uses
Classes, Classes,
SysUtils; SysUtils;
const
SCE_KERNEL_AIO_DISABLE_SPLIT=0;
SCE_KERNEL_AIO_ENABLE_SPLIT =1;
SCE_KERNEL_AIO_SCHED_WINDOW_MAX =128;
SCE_KERNEL_AIO_DELAYED_COUNT_MAX =128;
SCE_KERNEL_AIO_SPLIT_SIZE_MAX =$1000000;
SCE_KERNEL_AIO_SPLIT_CHUNK_SIZE_MAX=$1000000;
SCE_KERNEL_AIO_SCHED_WINDOW_DEFAULT =32;
SCE_KERNEL_AIO_DELAYED_COUNT_DEFAULT =32;
SCE_KERNEL_AIO_SPLIT_SIZE_DEFAULT =$100000;
SCE_KERNEL_AIO_SPLIT_CHUNK_SIZE_DEFAULT=$100000;
type
pSceKernelAioSchedulingParam=^SceKernelAioSchedulingParam;
SceKernelAioSchedulingParam=packed record
schedulingWindowSize:Integer;
delayedCountLimit :Integer;
enableSplit :DWORD;
splitSize :DWORD;
splitChunkSize :DWORD;
end;
pSceKernelAioParam=^SceKernelAioParam;
SceKernelAioParam=packed record
low :SceKernelAioSchedulingParam;
mid :SceKernelAioSchedulingParam;
high:SceKernelAioSchedulingParam;
end;
function ps4_open(path:PChar;flags,mode:Integer):Integer; SysV_ABI_CDecl; function ps4_open(path:PChar;flags,mode:Integer):Integer; SysV_ABI_CDecl;
function ps4_sceKernelOpen(path:PChar;flags,mode:Integer):Integer; SysV_ABI_CDecl; function ps4_sceKernelOpen(path:PChar;flags,mode:Integer):Integer; SysV_ABI_CDecl;
@ -91,6 +122,8 @@ function ps4_access(path:PChar;mode:Integer):Integer; SysV_ABI_CDecl;
function ps4_getdtablesize:Integer; SysV_ABI_CDecl; function ps4_getdtablesize:Integer; SysV_ABI_CDecl;
function ps4_sceKernelGetFsSandboxRandomWord:PChar; SysV_ABI_CDecl; function ps4_sceKernelGetFsSandboxRandomWord:PChar; SysV_ABI_CDecl;
procedure ps4_sceKernelAioInitializeParam(param:pSceKernelAioParam); SysV_ABI_CDecl;
implementation implementation
uses uses
@ -1267,5 +1300,24 @@ begin
Result:=fs_word; Result:=fs_word;
end; end;
procedure ps4_sceKernelAioInitializeParam(param:pSceKernelAioParam); SysV_ABI_CDecl;
begin
param^.low.schedulingWindowSize :=$20;
param^.low.delayedCountLimit :=$20;
param^.low.enableSplit :=1;
param^.low.splitSize :=$100000;
param^.low.splitChunkSize :=$100000;
param^.mid.schedulingWindowSize :=$20;
param^.mid.delayedCountLimit :=$20;
param^.mid.enableSplit :=1;
param^.mid.splitSize :=$100000;
param^.mid.splitChunkSize :=$100000;
param^.high.schedulingWindowSize:=$20;
param^.high.delayedCountLimit :=$20;
param^.high.enableSplit :=0;
param^.high.splitSize :=0;
param^.high.splitChunkSize :=0;
end;
end. end.

View File

@ -1972,6 +1972,8 @@ begin
lib^.set_proc($B19BB06833C04CAB,@ps4_getdtablesize); lib^.set_proc($B19BB06833C04CAB,@ps4_getdtablesize);
lib^.set_proc($2467D330139D509A,@ps4_sceKernelGetFsSandboxRandomWord); lib^.set_proc($2467D330139D509A,@ps4_sceKernelGetFsSandboxRandomWord);
lib^.set_proc($9EEE1AD3F6AB422B,@ps4_sceKernelAioInitializeParam);
//file //file
//socket //socket