This is core MAME code but no one on mametesters is doing
64-bit work yet.  I hope someone here can shed some light on
this first.

There are a number of games that work fine in 32-bit X86 xmame,
but crash on 64-bit amd64 xmame regardless of gcc version or
setting.  This also has nothing to do with ASM or DRC.

I started looking at stunrun and have documented my efforts so
far here:
http://www.anthrofox.org/code/mame/64bitclean/index.html

stunrun will segfault during attract mode on X86-64 right when
the car hits the yellow plate.

The dirty ugly disgusting hack patch I have on the URL above
actually gets around this segfault.  The problem is
src/sound/ym2151.c.  And the behavior is interesting.
1.  This line:
INT32 mod_ind = PSG->lfp;               /* -128..+127 (8bits
signed) */
often goes below -200!
2.  Is UINT32 supposed to clamp mod_ind to zero?  Because for
whatever reason it does not work on X86-64!
UINT32 kc_channel =     op->kc_i + mod_ind;
Here, kc_channel becomes negative and causes an out-of-bounds
access later on.

Details are on the link above.  Can someone else help with this
before I beg mametesters to look at 64-bit updates again?  I'd
like to know the right thing to do in this code before giving
them a dirty patch.

Thanks!


                
__________________________________
Do you Yahoo!?
Yahoo! Mail Address AutoComplete - You start. We finish.
http://promotions.yahoo.com/new_mail 

_______________________________________________
Xmame mailing list
[EMAIL PROTECTED]
http://toybox.twisted.org.uk/mailman/listinfo/xmame

Reply via email to