Fxed up section functions in HLE database in most common XDKs

These functions have barely changed since 3911, so it is possible to have a catch all signature.
This commit is contained in:
Luke Usher 2016-08-27 19:24:22 +01:00
parent bebf8be3fd
commit ceb196d663
6 changed files with 69 additions and 217 deletions

View File

@ -1058,6 +1058,7 @@ SOOVPA<7> ConvertThreadToFiber_1_0_3911 =
// ******************************************************************
// * XLoadSectionA
// FF742404E8........83F8FF740850E8........EB0233C0C20400..........
// ******************************************************************
SOOVPA<10> XLoadSectionA_1_0_3911 =
{
@ -1093,6 +1094,7 @@ SOOVPA<10> XLoadSectionA_1_0_3911 =
// ******************************************************************
// * XFreeSectionA
// FF742404E8........83F8FF740850E8........EB0233C0C20400..........
// ******************************************************************
SOOVPA<11> XFreeSectionA_1_0_3911 =
{
@ -1425,41 +1427,36 @@ SOOVPA<7> XGetLaunchInfo_1_0_3911 =
// ******************************************************************
// * XGetSectionHandleA
// 558BEC83EC10538B1D........5657FF75088D45F050FFD38B351C0101008B3D
// ******************************************************************
SOOVPA<13> XGetSectionHandleA_1_0_3911 =
SOOVPA<12> XGetSectionHandleA_1_0_3911 =
{
0, // Large == 0
13, // Count == 0
12, // Count == 0
-1, // XRef not saved
0, // XRef not used
{
// XGetSectionaHandleA+0x03 : sub esp, 0x10
{ 0x00, 0x55 },
{ 0x01, 0x8B },
{ 0x02, 0xEC },
{ 0x03, 0x83 },
{ 0x04, 0xEC },
{ 0x05, 0x10 },
{ 0x06, 0x53 },
{ 0x07, 0x8B },
{ 0x08, 0x1D },
// XGetSectionaHandleA+0x24 : imul esi, 0x38
{ 0x24, 0x6B },
{ 0x25, 0xF6 },
{ 0x26, 0x38 },
// XGetSectionaHandleA+0x4F : push 0x490
{ 0x4F, 0x68 },
{ 0x50, 0x90 },
{ 0x51, 0x04 },
{ 0x52, 0x00 },
{ 0x53, 0x00 },
// XGetSectionaHandleA+0x60 : retn 4
{ 0x60, 0xC2 },
{ 0x61, 0x04 }
{ 0x0D, 0x56 },
{ 0x0E, 0x57 },
{ 0x0F, 0xFF }
}
};
// ******************************************************************
// * XLoadSectionByHandle
// 568B74240856FF15........85C07D0A50E8........33C0EB038B46045EC204
// ******************************************************************
SOOVPA<11> XLoadSectionByHandle_1_0_3911 =
{
@ -1493,6 +1490,7 @@ SOOVPA<11> XLoadSectionByHandle_1_0_3911 =
// ******************************************************************
// * XFreeSectionByHandle
// FF742404FF15........85C07D0A50E8........33C0EB0333C040C20400....
// ******************************************************************
SOOVPA<11> XFreeSectionByHandle_1_0_3911 =
{

View File

@ -278,111 +278,6 @@ SOOVPA<10> XInputPoll_1_0_4134 =
}
};
// ******************************************************************
// * XGetSectionHandleA
// ******************************************************************
SOOVPA<13> XGetSectionHandleA_1_0_4134 =
{
0, // Large == 0
13, // Count == 0
-1, // XRef not saved
0, // XRef not used
{
// XGetSectionaHandleA+0x03 : sub esp, 0x10
{ 0x03, 0x83 },
{ 0x04, 0xEC },
{ 0x05, 0x10 },
// XGetSectionaHandleA+0x24 : imul esi, 0x38
{ 0x24, 0x6B },
{ 0x25, 0xF6 },
{ 0x26, 0x38 },
// XGetSectionaHandleA+0x4F : push 0x490
{ 0x4F, 0x68 },
{ 0x50, 0x90 },
{ 0x51, 0x04 },
{ 0x52, 0x00 },
{ 0x53, 0x00 },
// XGetSectionaHandleA+0x60 : retn 4
{ 0x60, 0xC2 },
{ 0x61, 0x04 }
}
};
// ******************************************************************
// * XLoadSectionByHandle
// ******************************************************************
SOOVPA<11> XLoadSectionByHandle_1_0_4134 =
{
0, // Large == 0
11, // Count == 11
-1, // XRef not saved
0, // XRef not used
{
// XLoadSectionByHandle+0x01 : mov esi, [esp+4+arg_0]
{ 0x01, 0x8B },
{ 0x02, 0x74 },
{ 0x03, 0x24 },
{ 0x04, 0x08 },
// XLoadSectionByHandle+0x0C : test eax, eax
{ 0x0C, 0x85 },
{ 0x0D, 0xC0 },
// XLoadSectionByHandle+0x1A : mov eax, [esi+4]
{ 0x1A, 0x8B },
{ 0x1B, 0x46 },
{ 0x1C, 0x04 },
// XLoadSectionByHandle+0x1E : retn 4
{ 0x1E, 0xC2 },
{ 0x1F, 0x04 }
}
};
// ******************************************************************
// * XFreeSectionByHandle
// ******************************************************************
SOOVPA<11> XFreeSectionByHandle_1_0_4134 =
{
0, // Large == 0
11, // Count == 11
-1, // XRef not saved
0, // XRef not used
{
// XFreeSectionByHandle+0x00 : push esp
{ 0x00, 0xFF },
{ 0x01, 0x74 },
{ 0x02, 0x24 },
{ 0x03, 0x04 },
// XFreeSectionByHandle+0x0A : test eax, eax
{ 0x0A, 0x85 },
{ 0x0B, 0xC0 },
// XFreeSectionByHandle+0x18 : xor eax, eax
{ 0x18, 0x33 },
{ 0x19, 0xC0 },
// XFreeSectionByHandle+0x1A : inc eax
{ 0x1A, 0x40 },
// XFreeSectionByHandle+0x1B : retn 4
{ 0x1B, 0xC2 },
{ 0x1C, 0x04 }
}
};
// ******************************************************************
// * RtlDestroyHeap
// ******************************************************************
@ -732,7 +627,7 @@ OOVPATable XAPI_1_0_4134[] =
},
// XGetSectionHandleA
{
(OOVPA*)&XGetSectionHandleA_1_0_4134,
(OOVPA*)&XGetSectionHandleA_1_0_3911,
XTL::EmuXGetSectionHandleA,
@ -742,7 +637,7 @@ OOVPATable XAPI_1_0_4134[] =
},
// XLoadSectionByHandle
{
(OOVPA*)&XLoadSectionByHandle_1_0_4134,
(OOVPA*)&XLoadSectionByHandle_1_0_3911,
XTL::EmuXLoadSectionByHandle,
@ -752,7 +647,7 @@ OOVPATable XAPI_1_0_4134[] =
},
// XFreeSectionByHandle
{
(OOVPA*)&XFreeSectionByHandle_1_0_4134,
(OOVPA*)&XFreeSectionByHandle_1_0_3911,
XTL::EmuXFreeSectionByHandle,

View File

@ -772,6 +772,36 @@ OOVPATable XAPI_1_0_4361[] =
"EmuXFreeSectionA"
#endif
},
// XGetSectionHandleA
{
(OOVPA*)&XGetSectionHandleA_1_0_3911,
XTL::EmuXGetSectionHandleA,
#ifdef _DEBUG_TRACE
"EmuXGetSectionHandleA"
#endif
},
// XLoadSectionByHandle
{
(OOVPA*)&XLoadSectionByHandle_1_0_3911,
XTL::EmuXLoadSectionByHandle,
#ifdef _DEBUG_TRACE
"EmuXLoadSectionByHandle"
#endif
},
// XFreeSectionByHandle
{
(OOVPA*)&XFreeSectionByHandle_1_0_3911,
XTL::EmuXFreeSectionByHandle,
#ifdef _DEBUG_TRACE
"EmuXFreeSectionByHandle"
#endif
},
// GetTimeZoneInformation (* unchanged since 3911 *)
{
(OOVPA*)&GetTimeZoneInformation_1_0_3911,

View File

@ -634,77 +634,6 @@ SOOVPA<12> XInputGetCapabilities5_1_0_4831 =
}
};
// ******************************************************************
// * XLoadSectionA
// ******************************************************************
SOOVPA<10> XLoadSectionA_1_0_4627 =
{
0, // Large == 0
10, // Count == 10
-1, // XRef not saved
0, // XRef not used
{
// XLoadSectionA+0x0F : call XLoadSectionByHandle
// { 0x10, XREF_XLoadSectionByHandle },
// XLoadSectionA+0x0: push dword ptr [esp+4]
{ 0x00, 0xFF },
{ 0x01, 0x74 },
{ 0x02, 0x24 },
{ 0x03, 0x04 },
// XLoadSectionA+0x9: cmp eax, 0xFFFFFFFF
{ 0x09, 0x83 },
{ 0x0A, 0xF8 },
{ 0x0B, 0xFF },
// XLoadSectionA+0xE: push eax
{ 0x0E, 0x50 },
// XLoadSectionA+0x18: ret 4
{ 0x18, 0xC2 },
{ 0x19, 0x04 },
}
};
// ******************************************************************
// * XFreeSectionA
// ******************************************************************
SOOVPA<11> XFreeSectionA_1_0_4627 =
{
0, // Large == 0
11, // Count == 11
-1, // XRef not saved
0, // XRef not used
{
// XFreeSectionA+0x0F : call XFreeSectionByHandle
// { 0x10, XREF_XFreeSectionByHandle },
// XLoadSectionA+0x0: push dword ptr [esp+4]
{ 0x00, 0xFF },
{ 0x01, 0x74 },
{ 0x02, 0x24 },
{ 0x03, 0x04 },
// XLoadSectionA+0x9: cmp eax, 0xFFFFFFFF
{ 0x09, 0x83 },
{ 0x0A, 0xF8 },
{ 0x0B, 0xFF },
// XLoadSectionA+0x14: jz 0x2
{ 0x14, 0xEB },
{ 0x15, 0x02 },
// XLoadSectionA+0x18: ret 4
{ 0x18, 0xC2 },
{ 0x19, 0x04 },
}
};
// ******************************************************************
// * GetOverlappedResult
// ******************************************************************
@ -1425,9 +1354,9 @@ OOVPATable XAPI_1_0_4627[] =
"EmuXInputGetCapabilities6_4928"
#endif
},
// XGetSectionHandleA (* unchanged since 4134 *)
// XGetSectionHandleA (* unchanged since 3911 *)
{
(OOVPA*)&XGetSectionHandleA_1_0_4134,
(OOVPA*)&XGetSectionHandleA_1_0_3911,
XTL::EmuXGetSectionHandleA,
@ -1435,9 +1364,9 @@ OOVPATable XAPI_1_0_4627[] =
"EmuXGetSectionHandleA"
#endif
},
// XLoadSectionByHandle (* unchanged since 4134 *)
// XLoadSectionByHandle (* unchanged since 3911 *)
{
(OOVPA*)&XLoadSectionByHandle_1_0_4134,
(OOVPA*)&XLoadSectionByHandle_1_0_3911,
XTL::EmuXLoadSectionByHandle,
@ -1445,9 +1374,9 @@ OOVPATable XAPI_1_0_4627[] =
"EmuXLoadSectionByHandle"
#endif
},
// XFreeSectionByHandle (* unchanged since 4134 *)
// XFreeSectionByHandle (* unchanged since 3911 *)
{
(OOVPA*)&XFreeSectionByHandle_1_0_4134,
(OOVPA*)&XFreeSectionByHandle_1_0_3911,
XTL::EmuXFreeSectionByHandle,
@ -1457,7 +1386,7 @@ OOVPATable XAPI_1_0_4627[] =
},
// XLoadSectionA
{
(OOVPA*)&XLoadSectionA_1_0_4627,
(OOVPA*)&XLoadSectionA_1_0_3911,
XTL::EmuXLoadSectionA,
@ -1467,7 +1396,7 @@ OOVPATable XAPI_1_0_4627[] =
},
// XFreeSectionA
{
(OOVPA*)&XFreeSectionA_1_0_4627,
(OOVPA*)&XFreeSectionA_1_0_3911,
XTL::EmuXFreeSectionA,

View File

@ -666,9 +666,9 @@ OOVPATable XAPI_1_0_5558[] =
"GetFileAttributesA"
#endif
},
// XGetSectionHandleA (* unchanged since 4134 *)
// XGetSectionHandleA (* unchanged since 3911 *)
{
(OOVPA*)&XGetSectionHandleA_1_0_4134,
(OOVPA*)&XGetSectionHandleA_1_0_3911,
XTL::EmuXGetSectionHandleA,
@ -676,9 +676,9 @@ OOVPATable XAPI_1_0_5558[] =
"EmuXGetSectionHandleA"
#endif
},
// XLoadSectionByHandle (* unchanged since 4134 *)
// XLoadSectionByHandle (* unchanged since 3911 *)
{
(OOVPA*)&XLoadSectionByHandle_1_0_4134,
(OOVPA*)&XLoadSectionByHandle_1_0_3911,
XTL::EmuXLoadSectionByHandle,
@ -686,9 +686,9 @@ OOVPATable XAPI_1_0_5558[] =
"EmuXLoadSectionByHandle"
#endif
},
// XFreeSectionByHandle (* unchanged since 4134 *)
// XFreeSectionByHandle (* unchanged since 3911 *)
{
(OOVPA*)&XFreeSectionByHandle_1_0_4134,
(OOVPA*)&XFreeSectionByHandle_1_0_3911,
XTL::EmuXFreeSectionByHandle,

View File

@ -370,9 +370,9 @@ OOVPATable XAPI_1_0_5849[] =
"GetThreadPriorityBoost"
#endif
},*/
// XGetSectionHandleA (* unchanged since 4134 *)
// XGetSectionHandleA (* unchanged since 3911 *)
{
(OOVPA*)&XGetSectionHandleA_1_0_4134,
(OOVPA*)&XGetSectionHandleA_1_0_3911,
XTL::EmuXGetSectionHandleA,
@ -380,9 +380,9 @@ OOVPATable XAPI_1_0_5849[] =
"EmuXGetSectionHandleA"
#endif
},
// XLoadSectionByHandle (* unchanged since 4134 *)
// XLoadSectionByHandle (* unchanged since 3911 *)
{
(OOVPA*)&XLoadSectionByHandle_1_0_4134,
(OOVPA*)&XLoadSectionByHandle_1_0_3911,
XTL::EmuXLoadSectionByHandle,
@ -390,9 +390,9 @@ OOVPATable XAPI_1_0_5849[] =
"EmuXLoadSectionByHandle"
#endif
},
// XFreeSectionByHandle (* unchanged since 4134 *)
// XFreeSectionByHandle (* unchanged since 3911 *)
{
(OOVPA*)&XFreeSectionByHandle_1_0_4134,
(OOVPA*)&XFreeSectionByHandle_1_0_3911,
XTL::EmuXFreeSectionByHandle,