1 |
|
/* |
2 |
|
* sysdeps.h - System dependent definitions for Windows |
3 |
|
* |
4 |
< |
* SheepShaver (C) 1997-2005 Christian Bauer and Marc Hellwig |
4 |
> |
* SheepShaver (C) 1997-2008 Christian Bauer and Marc Hellwig |
5 |
|
* |
6 |
|
* This program is free software; you can redistribute it and/or modify |
7 |
|
* it under the terms of the GNU General Public License as published by |
37 |
|
#include <stdlib.h> |
38 |
|
#include <stdint.h> |
39 |
|
#include <string.h> |
40 |
+ |
#include <time.h> |
41 |
+ |
#ifdef __WIN32__ |
42 |
|
#include <windows.h> |
43 |
+ |
#endif |
44 |
+ |
#include <sys/types.h> |
45 |
+ |
|
46 |
|
|
47 |
|
// Define for external components |
48 |
|
#define SHEEPSHAVER 1 |
49 |
|
#define POWERPC_ROM 1 |
50 |
|
#define EMULATED_PPC 1 |
51 |
+ |
#define CONFIG_WIN32 1 |
52 |
|
|
53 |
|
// Use Direct Addressing mode |
54 |
|
#define DIRECT_ADDRESSING 1 |
55 |
< |
#define NATMEM_OFFSET 0x02000000 |
55 |
> |
#define NATMEM_OFFSET 0x11000000 |
56 |
> |
|
57 |
> |
// Always use the complete (non-stubs based) Ethernet driver |
58 |
> |
#if DIRECT_ADDRESSING |
59 |
> |
#define USE_ETHER_FULL_DRIVER 1 |
60 |
> |
#endif |
61 |
|
|
62 |
|
// Mac ROM is write protected when banked memory is used |
63 |
|
#if REAL_ADDRESSING || DIRECT_ADDRESSING |
75 |
|
#define PPC_PROFILE_GENERIC_CALLS 0 |
76 |
|
#define KPX_MAX_CPUS 1 |
77 |
|
#if ENABLE_DYNGEN |
67 |
– |
// Don't bother with predecode cache when using JIT |
78 |
|
#define PPC_ENABLE_JIT 1 |
69 |
– |
#undef PPC_DECODE_CACHE |
79 |
|
#endif |
80 |
|
#if defined(__i386__) |
81 |
|
#define DYNGEN_ASM_OPTS 1 |
125 |
|
#error "Unsupported size of pointer" |
126 |
|
#endif |
127 |
|
|
128 |
+ |
// Define if the host processor supports fast unaligned load/stores |
129 |
+ |
#if defined __i386__ || defined __x86_64__ |
130 |
+ |
#define UNALIGNED_PROFITABLE 1 |
131 |
+ |
#endif |
132 |
+ |
|
133 |
|
|
134 |
|
/** |
135 |
|
* Helper functions to byteswap data |
392 |
|
#endif |
393 |
|
|
394 |
|
// Misc platform specific definitions |
395 |
+ |
#ifdef __WIN32__ |
396 |
|
typedef int64 loff_t; |
397 |
+ |
#endif |
398 |
|
#define ATTRIBUTE_PACKED __attribute__((__packed__)) |
399 |
|
|
400 |
|
#endif |