Fix Linux - __pagesize as a #define was bad mojo.

git-svn-id: http://pcsx2.googlecode.com/svn/trunk@2114 96395faa-99c1-11dd-bbfe-3dabce05a288
This commit is contained in:
Jake.Stine 2009-11-02 07:43:51 +00:00
parent 94222f4aaf
commit 0bb589964f
2 changed files with 7 additions and 4 deletions

View File

@ -179,13 +179,15 @@
// Defines the memory page size for the target platform at compilation. All supported platforms
// (which means Intel only right now) have a 4k granularity.
#define __pagesize 0x1000
#define PCSX2_PAGESIZE 0x1000
static const int __pagesize = PCSX2_PAGESIZE;
#ifdef _MSC_VER
# define __aligned(alig) __declspec(align(alig))
# define __aligned16 __declspec(align(16))
# define __pagealigned __declspec(align(__pagesize))
# define __pagealigned __declspec(align(PCSX2_PAGESIZE))
// Deprecated; use __align instead.
# define PCSX2_ALIGNED(alig,x) __declspec(align(alig)) x
@ -232,7 +234,7 @@ This theoretically unoptimizes. Not having much luck so far.
# define __aligned(alig) __attribute__((aligned(alig)))
# define __aligned16 __attribute__((aligned(16)))
# define __pagealigned __attribute__((aligned(__pagesize)))
# define __pagealigned __attribute__((aligned(PCSX2_PAGESIZE)))
// Deprecated; use __align instead.
# define PCSX2_ALIGNED(alig,x) x __attribute((aligned(alig)))
# define PCSX2_ALIGNED16(x) x __attribute((aligned(16)))

View File

@ -78,7 +78,6 @@ typedef int BOOL;
#include "zlib/zlib.h"
#include "Pcsx2Defs.h"
#include "i18n.h"
#include "Config.h"
#include "Utilities/Assertions.h"
#include "Utilities/wxBaseTools.h"
@ -90,6 +89,8 @@ typedef int BOOL;
#include "Utilities/General.h"
#include "x86emitter/tools.h"
#include "Config.h"
// Linux isn't set up for svn version numbers yet.
#ifdef __LINUX__
# define SVN_REV 0