Search
lxdream.org :: lxdream/src/sh4/sh4trans.h :: diff
lxdream 0.9.1
released Jun 29
Download Now
filename src/sh4/sh4trans.h
changeset 359:c588dce7ebde
next389:3e354da62264
author nkeynes
date Wed Sep 12 09:16:47 2007 +0000 (16 years ago)
permissions -rw-r--r--
last change Add disassembly dump function to xltcache
file annotate diff log raw
1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/src/sh4/sh4trans.h Wed Sep 12 09:16:47 2007 +0000
1.3 @@ -0,0 +1,46 @@
1.4 +/**
1.5 + * $Id: sh4trans.h,v 1.1 2007-08-23 12:33:27 nkeynes Exp $
1.6 + *
1.7 + * SH4->x86 translation module
1.8 + *
1.9 + * Copyright (c) 2005 Nathan Keynes.
1.10 + *
1.11 + * This program is free software; you can redistribute it and/or modify
1.12 + * it under the terms of the GNU General Public License as published by
1.13 + * the Free Software Foundation; either version 2 of the License, or
1.14 + * (at your option) any later version.
1.15 + *
1.16 + * This program is distributed in the hope that it will be useful,
1.17 + * but WITHOUT ANY WARRANTY; without even the implied warranty of
1.18 + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1.19 + * GNU General Public License for more details.
1.20 + */
1.21 +
1.22 +#include "dream.h"
1.23 +#include "mem.h"
1.24 +
1.25 +/** Maximum size of a translated instruction, in bytes. This includes potentially
1.26 + * writing the entire epilogue
1.27 + */
1.28 +#define MAX_INSTRUCTION_SIZE 32
1.29 +
1.30 +/**
1.31 +
1.32 + */
1.33 +uint32_t sh4_xlat_run_slice( uint32_t nanosecs );
1.34 +
1.35 +/**
1.36 + * Translate the specified block of code starting from the specified start
1.37 + * address until the first branch/jump instruction.
1.38 + */
1.39 +void *sh4_translate_basic_block( sh4addr_t start );
1.40 +
1.41 +extern uint8_t *xlat_output;
1.42 +
1.43 +/************** Output generation ***************/
1.44 +
1.45 +void sh4_translate_begin_block();
1.46 +
1.47 +uint32_t sh4_x86_translate_instruction( sh4addr_t pc );
1.48 +
1.49 +void sh4_translate_end_block( sh4addr_t pc );
.