[hatari-devel] 68030 Debug mode and new CPU

Eero Tamminen oak at helsinkinet.fi
Thu Feb 17 22:25:49 CET 2011


Hi,

On keskiviikko 16 helmikuu 2011, Laurent Sallafranque wrote:
> > You could add:
> > 	#define f_out fprintf
> > 
> > to one of the headers, remove the f_out stuff from cpu/custom.c and
> > replace all "void *" args for functions calling f_out() with "FILE *".
>
> Done, it works well now.
> And it seems to have removed some compiling warnings.

Actually, as f_out() seems to be used only in newcpu.c, the define could
be there too.  Unless you want all this kind of stuff to be in compat.h so
that it's easier to find.


While looking into newcpu.c more, I noticed that the "buf" & "bufsize"
arguments to function:
void m68k_disasm_2 (TCHAR *buf, int bufsize, uaecptr addr, uaecptr *nextpc, 
int cnt, uae_u32 *seaddr, uae_u32 *deaddr, int safemode)

Are redundant with your changes (instead of using buf_out(), you're calling
printf() directly and not buffering the string for later printing).

Attached (untested) patch would clean that.


	- Eero

-------------- next part --------------
A non-text attachment was scrubbed...
Name: disasm.diff
Type: text/x-patch
Size: 4388 bytes
Desc: not available
URL: <https://lists.berlios.de/pipermail/hatari-devel/attachments/20110217/f3a3b42f/attachment.bin>


More information about the hatari-devel mailing list