mirror of https://github.com/PCSX2/pcsx2.git
Regression fix for GT4, crashes presumably due to the zero division on this check
git-svn-id: http://pcsx2.googlecode.com/svn/trunk@1007 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
parent
71e391d010
commit
a4abcf1206
|
@ -732,7 +732,8 @@ static void VIFunpack(u32 *data, vifCode *v, unsigned int size, const unsigned i
|
|||
else /* filling write */
|
||||
{
|
||||
|
||||
if((u32)(((size / ft->gsize) / vifRegs->cycle.cl) * vifRegs->cycle.wl) < vifRegs->num && vifRegs->cycle.cl != 0)
|
||||
if(vifRegs->cycle.cl > 0) // Quicker and avoids zero division :P
|
||||
if((u32)(((size / ft->gsize) / vifRegs->cycle.cl) * vifRegs->cycle.wl) < vifRegs->num)
|
||||
DevCon::Notice("Filling write warning! %x < %x and CL = %x WL = %x", params (size / ft->gsize), vifRegs->num, vifRegs->cycle.cl, vifRegs->cycle.wl);
|
||||
|
||||
VIFUNPACK_LOG("filling write %d cl %d, wl %d mask %x mode %x unpacktype %x", vifRegs->num, vifRegs->cycle.cl, vifRegs->cycle.wl, vifRegs->mask, vifRegs->mode, unpackType);
|
||||
|
|
Loading…
Reference in New Issue