x86_64 runs now, although so far only with optimization flags lowered by hand.

This commit is contained in:
Clifford T. Matthews 2009-06-08 20:07:17 -06:00
parent 18131149d9
commit 41d5c6157b
5 changed files with 14 additions and 6 deletions

View File

@ -275,7 +275,8 @@ static uint32 _writeul_unswapped(uint16 *p, uint32 tmp)
| ((cpu_state.ccx != 0) << 4))
#if !defined(__alpha)
/* #if !defined(__alpha) */
#if SIZEOF_CHAR_P != 8
#define DEREF(typ, addr) (*(typ *)addr)
#else

View File

@ -1,3 +1,5 @@
#include "config.h"
#include "syn68k_private.h"
#include "backpatch.h"
#include "alloc.h"
@ -57,7 +59,7 @@ backpatch_apply_and_free (Block *b, backpatch_t *p)
*(uint16 *)((char *)b->compiled_code + first_byte) = value;
else if (length == 8)
*(uint8 *)((char *)b->compiled_code + first_byte) = value;
#if defined (__alpha)
#if SIZEOF_CHAR_P == 8
else if (length == 64)
*(uint64 *)((char *)b->compiled_code + first_byte) = value;
#endif

View File

@ -1,3 +1,5 @@
#include "config.h"
#include "syn68k_private.h"
#include "hash.h"
#include "rangetree.h"
@ -103,7 +105,7 @@ initialize_68k_emulator (void (*while_busy)(int), int native_p,
/* Create the magical block that contains an RTE. */
b = NULL;
#if !defined (__alpha)
#if SIZEOF_CHAR_P != 8
generate_block (NULL, US_TO_SYN68K (&rte), &b, TRUE);
#else
{

View File

@ -1,3 +1,5 @@
#include "config.h"
/* Global register to hold the PC. We put this up here so that
* the global register will be defined before any of the inline functions
* in syn68k_public.h are hit, but after uint16 is typedef'd.
@ -690,7 +692,7 @@ interpret_code (const uint16 *start_code)
* endian order. Since we know we're at the beginning of
* a block, we can check for the interrupt here.
*/
#if !defined (__alpha) /* FIXME -- TODO -- just use __alpha case for everyone */
#if SIZEOF_CHAR_P != 8
syn68k_addr_t addr = READUL (US_TO_SYN68K (code - PTR_WORDS - PTR_WORDS));
#else
syn68k_addr_t addr = READUL_US (code - PTR_WORDS - PTR_WORDS);

View File

@ -138,7 +138,8 @@ generate_c_code (const ParsedOpcodeInfo *info, const CCVariant *var,
else /* If we end a block, profile the next block. */
{
#if !defined (__alpha) /* FIXME -- TODO -- just use __alpha case for everyone */
/* #if !defined (__alpha) /* FIXME -- TODO -- just use __alpha case for everyone */
#if SIZEOF_CHAR_P != 8
fputs ("\n#ifdef PROFILE\n"
" profile_block (hash_lookup "
"(READUL (US_TO_SYN68K (code) - 4)));\n"
@ -154,7 +155,7 @@ generate_c_code (const ParsedOpcodeInfo *info, const CCVariant *var,
#if defined (SYNCHRONOUS_INTERRUPTS) && !defined (GENERATE_NATIVE_CODE)
fprintf (syn68k_c_stream,
"#if !defined (__alpha) /* FIXME -- TODO -- just use __alpha case for everyone */\n"
"#if SIZEOF_CHAR_P != 8\n"
" CHECK_FOR_INTERRUPT (READUL (US_TO_SYN68K (code - PTR_WORDS)));\n"
"#else\n"
" CHECK_FOR_INTERRUPT (READUL_US (code - PTR_WORDS));\n"