Fix degrading merge of stores that prevent absolute addressing
This commit is contained in:
parent
28e75a8fa2
commit
f5dff9620b
|
@ -23035,7 +23035,7 @@ void InterCodeProcedure::Close(void)
|
||||||
{
|
{
|
||||||
GrowingTypeArray tstack(IT_NONE);
|
GrowingTypeArray tstack(IT_NONE);
|
||||||
|
|
||||||
CheckFunc = !strcmp(mIdent->mString, "getActor");
|
CheckFunc = !strcmp(mIdent->mString, "enemies_iterate");
|
||||||
CheckCase = false;
|
CheckCase = false;
|
||||||
|
|
||||||
mEntryBlock = mBlocks[0];
|
mEntryBlock = mBlocks[0];
|
||||||
|
@ -24279,6 +24279,16 @@ bool InterCodeBasicBlock::SameExitCode(const InterCodeBasicBlock* block) const
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if (j0 >= 0)
|
||||||
|
{
|
||||||
|
if (mInstructions[j0]->mCode == IC_LEA && mInstructions[j0]->mSrc[1].mTemp < 0 && mInstructions[j0]->mSrc[0].IsUByte())
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
else if (j1 >= 0)
|
||||||
|
{
|
||||||
|
if (block->mInstructions[j1]->mCode == IC_LEA && block->mInstructions[j1]->mSrc[1].mTemp < 0 && block->mInstructions[j1]->mSrc[0].IsUByte())
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
|
||||||
if (InterTypeSize[ins0->mSrc[0].mType] == 4)
|
if (InterTypeSize[ins0->mSrc[0].mType] == 4)
|
||||||
{
|
{
|
||||||
|
@ -24359,6 +24369,8 @@ bool PartitionSameExitCode(GrowingArray<InterCodeBasicBlock* > & eblocks, Growin
|
||||||
|
|
||||||
bool InterCodeProcedure::ShortLeaMerge(FastNumberSet& activeSet)
|
bool InterCodeProcedure::ShortLeaMerge(FastNumberSet& activeSet)
|
||||||
{
|
{
|
||||||
|
DisassembleDebug("PreShortLeaMerge");
|
||||||
|
|
||||||
int silvused = mTemporaries.Size();
|
int silvused = mTemporaries.Size();
|
||||||
|
|
||||||
int n = 0;
|
int n = 0;
|
||||||
|
|
|
@ -48630,6 +48630,8 @@ bool NativeCodeBasicBlock::PeepHoleOptimizerIterate6(int i, int pass)
|
||||||
mIns[i + 5].mLive |= (mIns[i + 4].mLive & (LIVE_CPU_REG_C | LIVE_CPU_REG_Z));
|
mIns[i + 5].mLive |= (mIns[i + 4].mLive & (LIVE_CPU_REG_C | LIVE_CPU_REG_Z));
|
||||||
mIns[i + 0].mLive |= livexy;
|
mIns[i + 0].mLive |= livexy;
|
||||||
mIns[i + 1].mLive |= livexy;
|
mIns[i + 1].mLive |= livexy;
|
||||||
|
mIns[i + 2].mLive |= LIVE_CPU_REG_C | livexy;
|
||||||
|
mIns[i + 3].mLive |= LIVE_CPU_REG_C;
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue