Changeset 36170 in vbox for trunk/src/recompiler/exec-all.h
- Timestamp:
- Mar 4, 2011 12:49:02 PM (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/recompiler/exec-all.h
r36140 r36170 16 16 * You should have received a copy of the GNU Lesser General Public 17 17 * License along with this library; if not, write to the Free Software 18 * Foundation, Inc., 5 9 Temple Place, Suite 330, Boston, MA 02111-1307USA18 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston MA 02110-1301 USA 19 19 */ 20 20 … … 27 27 * of the LGPL is applied is otherwise unspecified. 28 28 */ 29 30 #ifndef _EXEC_ALL_H_ 31 #define _EXEC_ALL_H_ 32 33 #include "qemu-common.h" 29 34 30 35 /* allow to see translation results - the slowdown should be negligible, so we leave it */ … … 74 79 extern target_ulong gen_opc_jump_pc[2]; 75 80 extern uint32_t gen_opc_hflags[OPC_BUF_SIZE]; 76 77 typedef void (GenOpFunc)(void);78 typedef void (GenOpFunc1)(long);79 typedef void (GenOpFunc2)(long, long);80 typedef void (GenOpFunc3)(long, long, long);81 81 82 82 #include "qemu-log.h" … … 103 103 int cflags); 104 104 void cpu_exec_init(CPUState *env); 105 void QEMU_NORETURN cpu_loop_exit(void); 105 106 int page_unprotect(target_ulong address, unsigned long pc, void *puc); 106 107 void tb_invalidate_phys_page_range(target_phys_addr_t start, target_phys_addr_t end, … … 137 138 #endif 138 139 139 #if defined(_ _powerpc__) || defined(__x86_64__) || defined(__arm__)140 #if defined(_ARCH_PPC) || defined(__x86_64__) || defined(__arm__) 140 141 #define USE_DIRECT_JUMP 141 142 #endif … … 220 221 #if defined(USE_DIRECT_JUMP) 221 222 222 #if defined(_ _powerpc__)223 #if defined(_ARCH_PPC) 223 224 extern void ppc_tb_set_jmp_target(unsigned long jmp_addr, unsigned long addr); 224 225 #define tb_set_jmp_target1 ppc_tb_set_jmp_target … … 233 234 static inline void tb_set_jmp_target1(unsigned long jmp_addr, unsigned long addr) 234 235 { 236 #if QEMU_GNUC_PREREQ(4, 1) 237 void __clear_cache(char *beg, char *end); 238 #else 235 239 register unsigned long _beg __asm ("a1"); 236 240 register unsigned long _end __asm ("a2"); 237 241 register unsigned long _flg __asm ("a3"); 242 #endif 238 243 239 244 /* we could use a ldr pc, [pc, #-4] kind of branch and avoid the flush */ 240 245 *(uint32_t *)jmp_addr |= ((addr - (jmp_addr + 8)) >> 2) & 0xffffff; 241 246 247 #if QEMU_GNUC_PREREQ(4, 1) 248 __clear_cache((char *) jmp_addr, (char *) jmp_addr + 4); 249 #else 242 250 /* flush icache */ 243 251 _beg = jmp_addr; … … 245 253 _flg = 0; 246 254 __asm __volatile__ ("swi 0x9f0002" : : "r" (_beg), "r" (_end), "r" (_flg)); 255 #endif 247 256 } 248 257 #endif … … 286 295 287 296 TranslationBlock *tb_find_pc(unsigned long pc_ptr); 288 289 #if defined(_WIN32)290 #define ASM_DATA_SECTION ".section \".data\"\n"291 #define ASM_PREVIOUS_SECTION ".section .text\n"292 #elif defined(__APPLE__)293 #define ASM_DATA_SECTION ".data\n"294 #define ASM_PREVIOUS_SECTION ".text\n"295 #else296 #define ASM_DATA_SECTION ".section \".data\"\n"297 #define ASM_PREVIOUS_SECTION ".previous\n"298 #endif299 300 #define ASM_OP_LABEL_NAME(n, opname) \301 ASM_NAME(__op_label) #n "." ASM_NAME(opname)302 297 303 298 extern CPUWriteMemoryFunc *io_mem_write[IO_MEM_NB_ENTRIES][4]; … … 432 427 433 428 #endif 429 430 typedef void (CPUDebugExcpHandler)(CPUState *env); 431 432 CPUDebugExcpHandler *cpu_set_debug_excp_handler(CPUDebugExcpHandler *handler); 433 #endif
Note:
See TracChangeset
for help on using the changeset viewer.