diff options
author | 2015-03-30 20:30:18 +0200 | |
---|---|---|
committer | 2015-03-30 20:30:18 +0200 | |
commit | de541d79eea8f7527ff33440f6081474606738e3 (patch) | |
tree | 459ce3fb21267b71553e0ca9360213855ed79b40 /src/osd/sdl | |
parent | 4e89e12e0269fb31b157d5064799985a730c0877 (diff) |
removed windows/osinline.h and placed MSVC dependent files in top folder (nw)
moved MSVC defines from winprefix.h to osdcomm.h
removed empty file compilation - porttime.c
removed osinline.h in windows and sdl and change files using them.
Diffstat (limited to 'src/osd/sdl')
-rw-r--r-- | src/osd/sdl/osinline.h | 92 | ||||
-rw-r--r-- | src/osd/sdl/sdlprefix.h | 5 | ||||
-rw-r--r-- | src/osd/sdl/watchdog.c | 4 |
3 files changed, 0 insertions, 101 deletions
diff --git a/src/osd/sdl/osinline.h b/src/osd/sdl/osinline.h deleted file mode 100644 index 20a5ad62509..00000000000 --- a/src/osd/sdl/osinline.h +++ /dev/null @@ -1,92 +0,0 @@ -//============================================================ -// -// osinline.h - GNU C inline functions -// -//============================================================ - -#ifndef __OSINLINE__ -#define __OSINLINE__ - -#include "eminline.h" - - -//============================================================ -// INLINE FUNCTIONS -//============================================================ - -#if defined(__i386__) || defined(__x86_64__) - - -INLINE void ATTR_FORCE_INLINE -osd_yield_processor(void) -{ - __asm__ __volatile__ ( " rep ; nop ;" ); -} - - -#if defined(__x86_64__) - -//============================================================ -// osd_exchange64 -//============================================================ - -INLINE INT64 ATTR_UNUSED ATTR_NONNULL(1) ATTR_FORCE_INLINE -_osd_exchange64(INT64 volatile *ptr, INT64 exchange) -{ - register INT64 ret; - __asm__ __volatile__ ( - " lock ; xchg %[exchange], %[ptr] ;" - : [ptr] "+m" (*ptr) - , [ret] "=r" (ret) - : [exchange] "1" (exchange) - ); - return ret; -} -#define osd_exchange64 _osd_exchange64 - -#endif /* __x86_64__ */ - - -#elif defined(__ppc__) || defined (__PPC__) || defined(__ppc64__) || defined(__PPC64__) - - -INLINE void ATTR_FORCE_INLINE -osd_yield_processor(void) -{ - __asm__ __volatile__ ( " nop \n nop \n" ); -} - - - -#if defined(__ppc64__) || defined(__PPC64__) - -//============================================================ -// osd_exchange64 -//============================================================ - -INLINE INT64 ATTR_UNUSED ATTR_NONNULL(1) ATTR_FORCE_INLINE -_osd_exchange64(INT64 volatile *ptr, INT64 exchange) -{ - register INT64 ret; - __asm__ __volatile__ ( - "1: ldarx %[ret], 0, %[ptr] \n" - " stdcx. %[exchange], 0, %[ptr] \n" - " bne- 1b \n" - : [ret] "=&r" (ret) - : [ptr] "r" (ptr) - , [exchange] "r" (exchange) - : "cr0" - ); - return ret; -} -#define osd_exchange64 _osd_exchange64 - -#endif /* __ppc64__ || __PPC64__ */ - -#else - -#error "no matching assembler implementations found - please compile with NOASM=1" - -#endif - -#endif /* __OSINLINE__ */ diff --git a/src/osd/sdl/sdlprefix.h b/src/osd/sdl/sdlprefix.h index 9aff11e17f0..617155dbe2a 100644 --- a/src/osd/sdl/sdlprefix.h +++ b/src/osd/sdl/sdlprefix.h @@ -77,11 +77,6 @@ struct _IO_FILE {}; //_IO_FILE is an opaque type in the emscripten libc which m #endif /* SDLMAME_UNIX */ -#ifdef _MSC_VER -void *__cdecl _alloca(size_t); -#define alloca _alloca -#endif - #ifdef __GNUC__ #define alloca __builtin_alloca #endif diff --git a/src/osd/sdl/watchdog.c b/src/osd/sdl/watchdog.c index d8456cdb15a..fa7ead22224 100644 --- a/src/osd/sdl/watchdog.c +++ b/src/osd/sdl/watchdog.c @@ -11,11 +11,7 @@ #include "osdcomm.h" #include "osdcore.h" -#ifdef SDLMAME_NOASM #include "eminline.h" -#else -#include "osinline.h" -#endif #include "watchdog.h" #include "modules/lib/osdlib.h" |