mirror of
https://github.com/UberGames/ioef.git
synced 2025-01-31 13:00:46 +00:00
Support vm syscalls with up to 15 args using 64 bit compiled vm (like interprated vms).
This commit is contained in:
parent
b7fa3e7073
commit
f7a20068ee
2 changed files with 4 additions and 4 deletions
|
@ -442,7 +442,7 @@ static void DoSyscall(void)
|
||||||
int *data;
|
int *data;
|
||||||
#if idx64
|
#if idx64
|
||||||
int index;
|
int index;
|
||||||
intptr_t args[11];
|
intptr_t args[16];
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
data = (int *) (savedVM->dataBase + programStack + 4);
|
data = (int *) (savedVM->dataBase + programStack + 4);
|
||||||
|
|
|
@ -86,8 +86,8 @@ static intptr_t CROSSCALL callAsmCall(intptr_t callProgramStack, int64_t callSys
|
||||||
{
|
{
|
||||||
vm_t *savedVM;
|
vm_t *savedVM;
|
||||||
intptr_t ret = 0x77;
|
intptr_t ret = 0x77;
|
||||||
intptr_t args[11];
|
intptr_t args[16];
|
||||||
// int iargs[11];
|
// int iargs[16];
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
// Dfprintf(stderr, "callAsmCall(%ld, %ld)\n", callProgramStack, callSyscallNum);
|
// Dfprintf(stderr, "callAsmCall(%ld, %ld)\n", callProgramStack, callSyscallNum);
|
||||||
|
@ -100,7 +100,7 @@ static intptr_t CROSSCALL callAsmCall(intptr_t callProgramStack, int64_t callSys
|
||||||
|
|
||||||
args[0] = callSyscallNum;
|
args[0] = callSyscallNum;
|
||||||
// iargs[0] = callSyscallNum;
|
// iargs[0] = callSyscallNum;
|
||||||
for(i = 0; i < 10; ++i)
|
for(i = 0; i < ARRAY_LEN(args)-1; ++i)
|
||||||
{
|
{
|
||||||
// iargs[i+1] = *(int *)((byte *)currentVM->dataBase + callProgramStack + 8 + 4*i);
|
// iargs[i+1] = *(int *)((byte *)currentVM->dataBase + callProgramStack + 8 + 4*i);
|
||||||
args[i+1] = *(int *)((byte *)currentVM->dataBase + callProgramStack + 8 + 4*i);
|
args[i+1] = *(int *)((byte *)currentVM->dataBase + callProgramStack + 8 + 4*i);
|
||||||
|
|
Loading…
Reference in a new issue