bebbo / gcc

Bebbo's gcc-6-branch for m68k-amigaos
GNU General Public License v2.0
33 stars 11 forks source link

-fbbb=e causing more trouble #95

Closed mheyer32 closed 5 years ago

mheyer32 commented 5 years ago

At some point ScummVM stopped recognizing certain games. It does this by calculating MD5s for certain game files and comparing them to known values extracted from supported games.

-fbbb=e is causing this calculation to go haywire.

md5_bug.txt md5_no_bug.txt

As you can see here, the optimization seems to suppress a number of masking operations that are probably vital :-)

To repro https://github.com/mheyer32/scummvm-amigaos3

Change the _machine_flags line in configure to:

_machine_flags="-noixemul -m68030 -fbbb=abcfilmnprsz" << this disables e and makes it work

./configure --host=m68k-amigaos --disable-all-engines --enable-engine=tinsel --disable-mt32emu --enable-debug --disable-optimizations --disable-hq-scalers --with-amiga-prefix=/media/sf_Amiga/ScummVM --enable-c++11

make amigaos3dist -j8

make common/md5.o will build the individual file

and try to start DiscWorld. If it starts, the code is working, if it complains incompatible data, its broken.

bebbo commented 5 years ago

4f17acfdb8d9456513a62facc3115e89d97658d6 fix flag tracking in 'eor' insns

bebbo commented 5 years ago

LOL - I xor'ed the tracked bits instead to or 'em...

mheyer32 commented 5 years ago

Glad you're fixing it before I used it to compile control_nuclear_powerplants.exe ;-)

bebbo commented 5 years ago

Glad you're fixing it before I used it to compile control_nuclear_powerplants.exe ;-)

.exe -> not a valid Amiga executable name^^

bebbo commented 5 years ago

fix is live - please test

mheyer32 commented 5 years ago

Looks like its working again! Thanks!