From 299704cc243433de33ba0c59d01a8fc96d99ea17 Mon Sep 17 00:00:00 2001 From: Chris Moeller Date: Wed, 2 Apr 2014 17:02:44 -0700 Subject: [PATCH] Updated lazyusf --- Frameworks/lazyusf/lazyusf/interpreter_ops.c | 10 +++++----- Frameworks/lazyusf/lazyusf/rsp/rsp.h | 5 ++++- Frameworks/lazyusf/lazyusf/rsp_hle/alist.c | 4 ++-- Frameworks/lazyusf/lazyusf/rsp_hle/arithmetics.h | 2 +- Frameworks/lazyusf/lazyusf/rsp_hle/audio.h | 2 +- Frameworks/lazyusf/lazyusf/rsp_hle/memory.h | 2 +- 6 files changed, 14 insertions(+), 11 deletions(-) diff --git a/Frameworks/lazyusf/lazyusf/interpreter_ops.c b/Frameworks/lazyusf/lazyusf/interpreter_ops.c index f30297c53..ba9faa82c 100644 --- a/Frameworks/lazyusf/lazyusf/interpreter_ops.c +++ b/Frameworks/lazyusf/lazyusf/interpreter_ops.c @@ -34,7 +34,7 @@ #ifdef _MSC_VER #define INLINE __forceinline #else -#define INLINE __attribute__((always_inline)) +#define INLINE inline __attribute__((always_inline)) #endif #include "usf_internal.h" @@ -1047,11 +1047,11 @@ void r4300i_COP1_BCTL (usf_state_t * state) { } } /************************** COP1: S functions ************************/ -INLINE void Float_RoundToInteger32( int32_t * Dest, float * Source ) { +static INLINE void Float_RoundToInteger32( int32_t * Dest, float * Source ) { *Dest = (int32_t)*Source; } -INLINE void Float_RoundToInteger64( int64_t * Dest, float * Source ) { +static INLINE void Float_RoundToInteger64( int64_t * Dest, float * Source ) { *Dest = (int64_t)*Source; } @@ -1183,11 +1183,11 @@ void r4300i_COP1_S_CMP (usf_state_t * state) { } /************************** COP1: D functions ************************/ -INLINE void Double_RoundToInteger32( int32_t * Dest, double * Source ) { +static INLINE void Double_RoundToInteger32( int32_t * Dest, double * Source ) { *Dest = (int32_t)*Source; } -INLINE void Double_RoundToInteger64( int64_t * Dest, double * Source ) { +static INLINE void Double_RoundToInteger64( int64_t * Dest, double * Source ) { *Dest = (int64_t)*Source; } diff --git a/Frameworks/lazyusf/lazyusf/rsp/rsp.h b/Frameworks/lazyusf/lazyusf/rsp/rsp.h index eb5311ff2..0b40ccc91 100644 --- a/Frameworks/lazyusf/lazyusf/rsp/rsp.h +++ b/Frameworks/lazyusf/lazyusf/rsp/rsp.h @@ -19,7 +19,7 @@ #define NOINLINE __declspec(noinline) #define ALIGNED _declspec(align(16)) #else -#define INLINE __attribute__((always_inline)) +#define INLINE inline __attribute__((always_inline)) #define NOINLINE __attribute__((noinline)) #define ALIGNED __attribute__((aligned(16))) #endif @@ -34,6 +34,9 @@ #ifdef ARCH_MIN_SSE2 #include #endif +#ifdef ARCH_MIN_ARM_NEON +#include +#endif typedef unsigned char byte; diff --git a/Frameworks/lazyusf/lazyusf/rsp_hle/alist.c b/Frameworks/lazyusf/lazyusf/rsp_hle/alist.c index 4ecb8bad8..056d8529c 100644 --- a/Frameworks/lazyusf/lazyusf/rsp_hle/alist.c +++ b/Frameworks/lazyusf/lazyusf/rsp_hle/alist.c @@ -413,8 +413,8 @@ void alist_envmix_lin( *(int16_t *)(save_buffer + 0) = wet; /* 0-1 */ *(int16_t *)(save_buffer + 2) = dry; /* 2-3 */ - *(int16_t *)(save_buffer + 4) = (int16_t)ramps[0].target >> 16; /* 4-5 */ - *(int16_t *)(save_buffer + 6) = (int16_t)ramps[1].target >> 16; /* 6-7 */ + *(int16_t *)(save_buffer + 4) = (int16_t)(ramps[0].target >> 16); /* 4-5 */ + *(int16_t *)(save_buffer + 6) = (int16_t)(ramps[1].target >> 16); /* 6-7 */ *(int32_t *)(save_buffer + 8) = (int32_t)ramps[0].step; /* 8-9 (save_buffer is a 16bit pointer) */ *(int32_t *)(save_buffer + 10) = (int32_t)ramps[1].step; /* 10-11 */ *(int32_t *)(save_buffer + 16) = (int32_t)ramps[0].value; /* 16-17 */ diff --git a/Frameworks/lazyusf/lazyusf/rsp_hle/arithmetics.h b/Frameworks/lazyusf/lazyusf/rsp_hle/arithmetics.h index 090fc383d..817447265 100644 --- a/Frameworks/lazyusf/lazyusf/rsp_hle/arithmetics.h +++ b/Frameworks/lazyusf/lazyusf/rsp_hle/arithmetics.h @@ -27,7 +27,7 @@ #ifdef _MSC_VER #define INLINE __forceinline #else -#define INLINE __attribute__((always_inline)) +#define INLINE inline __attribute__((always_inline)) #endif INLINE static int16_t clamp_s16(int_fast32_t x) diff --git a/Frameworks/lazyusf/lazyusf/rsp_hle/audio.h b/Frameworks/lazyusf/lazyusf/rsp_hle/audio.h index 6e0221144..9c4449c66 100644 --- a/Frameworks/lazyusf/lazyusf/rsp_hle/audio.h +++ b/Frameworks/lazyusf/lazyusf/rsp_hle/audio.h @@ -32,7 +32,7 @@ int32_t rdot(size_t n, const int16_t *x, const int16_t *y); #ifdef _MSC_VER #define INLINE __forceinline #else -#define INLINE __attribute__((always_inline)) +#define INLINE inline __attribute__((always_inline)) #endif INLINE static int16_t adpcm_predict_sample(uint8_t byte, uint8_t mask, diff --git a/Frameworks/lazyusf/lazyusf/rsp_hle/memory.h b/Frameworks/lazyusf/lazyusf/rsp_hle/memory.h index ef2e57fba..ff951824a 100644 --- a/Frameworks/lazyusf/lazyusf/rsp_hle/memory.h +++ b/Frameworks/lazyusf/lazyusf/rsp_hle/memory.h @@ -60,7 +60,7 @@ enum { #ifdef _MSC_VER #define INLINE __forceinline #else -#define INLINE __attribute__((always_inline)) +#define INLINE inline __attribute__((always_inline)) #endif INLINE static unsigned int align(unsigned int x, unsigned amount)