fixed a couple remaining 64-bit pointer truncations
This commit is contained in:
parent
354cf1bf5d
commit
a53526163b
|
@ -754,9 +754,10 @@ void CompilerLinkBlocks(void) {
|
||||||
x86_SetBranch32b(RecompPos - 4, KnownCode);
|
x86_SetBranch32b(RecompPos - 4, KnownCode);
|
||||||
}
|
}
|
||||||
|
|
||||||
void CompilerRSPBlock ( void ) {
|
void CompilerRSPBlock(void)
|
||||||
DWORD Count, Padding, X86BaseAddress = (DWORD)RecompPos;
|
{
|
||||||
BYTE * IMEM_SAVE = (BYTE *)malloc(0x1000);
|
BYTE * IMEM_SAVE = (BYTE *)malloc(0x1000);
|
||||||
|
const size_t X86BaseAddress = (size_t)RecompPos;
|
||||||
|
|
||||||
NextInstruction = NORMAL;
|
NextInstruction = NORMAL;
|
||||||
CompilePC = *PrgCount;
|
CompilePC = *PrgCount;
|
||||||
|
@ -766,8 +767,11 @@ void CompilerRSPBlock ( void ) {
|
||||||
CurrentBlock.CurrPC = CompilePC;
|
CurrentBlock.CurrPC = CompilePC;
|
||||||
|
|
||||||
/* Align the block to a boundary */
|
/* Align the block to a boundary */
|
||||||
if (X86BaseAddress & 7) {
|
if (X86BaseAddress & 7)
|
||||||
Padding = (8 - (X86BaseAddress & 7)) & 7;
|
{
|
||||||
|
register size_t Count;
|
||||||
|
const size_t Padding = (8 - (X86BaseAddress & 7)) & 7;
|
||||||
|
|
||||||
for (Count = 0; Count < Padding; Count++) {
|
for (Count = 0; Count < Padding; Count++) {
|
||||||
CPU_Message("%08X: nop", RecompPos);
|
CPU_Message("%08X: nop", RecompPos);
|
||||||
*(RecompPos++) = 0x90;
|
*(RecompPos++) = 0x90;
|
||||||
|
|
|
@ -427,7 +427,11 @@ void BreakPointNotification (const char * const FileName, const int LineNumber)
|
||||||
void X86BreakPoint (LPCSTR FileName, int LineNumber) {
|
void X86BreakPoint (LPCSTR FileName, int LineNumber) {
|
||||||
Pushad();
|
Pushad();
|
||||||
PushImm32("LineNumber",LineNumber);
|
PushImm32("LineNumber",LineNumber);
|
||||||
|
#if defined(_M_IX86)
|
||||||
PushImm32("FileName",(DWORD)FileName);
|
PushImm32("FileName",(DWORD)FileName);
|
||||||
|
#else
|
||||||
|
DisplayError("PushImm64\nUnimplemented.");
|
||||||
|
#endif
|
||||||
Call_Direct(BreakPointNotification,"BreakPointNotification");
|
Call_Direct(BreakPointNotification,"BreakPointNotification");
|
||||||
AddConstToX86Reg(x86_ESP, 8);
|
AddConstToX86Reg(x86_ESP, 8);
|
||||||
Popad();
|
Popad();
|
||||||
|
|
Loading…
Reference in New Issue