head 1.4; access; symbols pkgsrc-2013Q2:1.4.0.54 pkgsrc-2013Q2-base:1.4 pkgsrc-2012Q4:1.4.0.52 pkgsrc-2012Q4-base:1.4 pkgsrc-2011Q4:1.4.0.50 pkgsrc-2011Q4-base:1.4 pkgsrc-2011Q2:1.4.0.48 pkgsrc-2011Q2-base:1.4 pkgsrc-2009Q4:1.4.0.46 pkgsrc-2009Q4-base:1.4 pkgsrc-2008Q4:1.4.0.44 pkgsrc-2008Q4-base:1.4 pkgsrc-2008Q3:1.4.0.42 pkgsrc-2008Q3-base:1.4 cube-native-xorg:1.4.0.40 cube-native-xorg-base:1.4 pkgsrc-2008Q2:1.4.0.38 pkgsrc-2008Q2-base:1.4 pkgsrc-2008Q1:1.4.0.36 pkgsrc-2008Q1-base:1.4 pkgsrc-2007Q4:1.4.0.34 pkgsrc-2007Q4-base:1.4 pkgsrc-2007Q3:1.4.0.32 pkgsrc-2007Q3-base:1.4 pkgsrc-2007Q2:1.4.0.30 pkgsrc-2007Q2-base:1.4 pkgsrc-2007Q1:1.4.0.28 pkgsrc-2007Q1-base:1.4 pkgsrc-2006Q4:1.4.0.26 pkgsrc-2006Q4-base:1.4 pkgsrc-2006Q3:1.4.0.24 pkgsrc-2006Q3-base:1.4 pkgsrc-2006Q2:1.4.0.22 pkgsrc-2006Q2-base:1.4 pkgsrc-2006Q1:1.4.0.20 pkgsrc-2006Q1-base:1.4 pkgsrc-2005Q4:1.4.0.18 pkgsrc-2005Q4-base:1.4 pkgsrc-2005Q3:1.4.0.16 pkgsrc-2005Q3-base:1.4 pkgsrc-2005Q2:1.4.0.14 pkgsrc-2005Q2-base:1.4 pkgsrc-2005Q1:1.4.0.12 pkgsrc-2005Q1-base:1.4 pkgsrc-2004Q4:1.4.0.10 pkgsrc-2004Q4-base:1.4 pkgsrc-2004Q3:1.4.0.8 pkgsrc-2004Q3-base:1.4 pkgsrc-2004Q2:1.4.0.6 pkgsrc-2004Q2-base:1.4 pkgsrc-2004Q1:1.4.0.4 pkgsrc-2004Q1-base:1.4 pkgsrc-2003Q4:1.4.0.2 pkgsrc-2003Q4-base:1.4 buildlink2-base:1.4 netbsd-1-5-PATCH001:1.3 netbsd-1-5-RELEASE:1.3 netbsd-1-4-PATCH003:1.3 netbsd-1-4-PATCH002:1.2 comdex-fall-1999:1.1 netbsd-1-4-PATCH001:1.1; locks; strict; comment @# @; 1.4 date 2001.08.26.21.39.33; author kristerw; state dead; branches; next 1.3; 1.3 date 2000.07.13.20.54.04; author martin; state Exp; branches; next 1.2; 1.2 date 99.11.10.08.01.29; author soren; state Exp; branches; next 1.1; 1.1 date 99.05.10.02.17.51; author ross; state Exp; branches; next ; desc @@ 1.4 log @Update xmame to 0.54.1. Changes since 0.53.1: - Everything from MAME 0.54. - Fixed a compile error in the xgl target caused by a change in the core. (Sven Goethel) - Applied a patch that fixes CPS2 games. (Aaron Giles) @ text @$NetBSD: patch-am,v 1.3 2000/07/13 20:54:04 martin Exp $ --- src/cpuintrf.c.orig Fri Jun 23 12:05:01 2000 +++ src/cpuintrf.c Thu Jul 13 00:02:05 2000 @@@@ -126,13 +126,34 @@@@ #define LOG(x) #endif -#define CPUINFO_SIZE (5*sizeof(int)+4*sizeof(void*)+2*sizeof(double)) +/* + * The filler object and the CPUINFO_* defs have various problems. (1) If + * there is a hole at the end of the struct, the first few bytes of filler + * won't extend the size. This is the case if the last object isn't one with + * the maximum alignment restriction. (2) The calculation of CPUINFO_SIZE + * ignores internal holes added by the compiler for field alignment. That + * can be fixed by reordering fields, but then you get problem #1. + */ + +typedef struct cpuinfo_test_struct +{ + struct cpu_interface *intf; /* pointer to the interface functions */ + int iloops; /* number of interrupts remaining this frame */ + int totalcycles; /* total CPU cycles executed */ + int vblankint_countdown; /* number of vblank callbacks left until we interrupt */ + int vblankint_multiplier; /* number of vblank callbacks per interrupt */ + void *vblankint_timer; /* reference to elapsed time counter */ + double vblankint_period; /* timing period of the VBLANK interrupt */ + void *timedint_timer; /* reference to this CPU's timer */ + double timedint_period; /* timing period of the timed interrupt */ + int save_context; /* need to context switch this CPU? yes or no */ + void *context; /* dynamically allocated context buffer */ + UINT8 filler[0]; /* make the array aligned to next power of 2 */ +} cpuinfo_test; + /* How do I calculate the next power of two from CPUINFO_SIZE using a macro? */ -#ifdef __LP64__ -#define CPUINFO_ALIGN (128-CPUINFO_SIZE) -#else -#define CPUINFO_ALIGN (64-CPUINFO_SIZE) -#endif + +#define CPUINFO_ALIGN ((sizeof(cpuinfo_test) > 64 ? 128 : 64) - sizeof(cpuinfo_test)) struct cpuinfo { @ 1.3 log @Update pkg to version 0.37b4.1 @ text @d1 1 a1 1 $NetBSD$ @ 1.2 log @Changed patches. @ text @d2 3 a4 4 --- src/cpuintrf.c.orig Thu Nov 4 09:13:49 1999 +++ src/cpuintrf.c Wed Nov 10 07:26:25 1999 @@@@ -94,13 +94,34 @@@@ d36 1 a36 1 -#define CPUINFO_ALIGN (128-CPUINFO_SIZE) d38 1 a38 1 -#define CPUINFO_ALIGN (64-CPUINFO_SIZE) @ 1.1 log @Fix compile problems. Enable on alpha. @ text @d1 5 a5 3 --- src/cpuintrf.c.orig Fri Mar 26 10:03:35 1999 +++ src/cpuintrf.c Sun May 9 14:41:55 1999 @@@@ -82,9 +82,34 @@@@ d36 5 a40 1 -#define CPUINFO_ALIGN (64-CPUINFO_SIZE) @