]> Git Repo - qemu.git/blob - target/mips/rel6_translate.c
osdep: protect qemu/osdep.h with extern "C"
[qemu.git] / target / mips / rel6_translate.c
1 /*
2  *  MIPS emulation for QEMU - # Release 6 translation routines
3  *
4  *  Copyright (c) 2004-2005 Jocelyn Mayer
5  *  Copyright (c) 2006 Marius Groeger (FPU operations)
6  *  Copyright (c) 2006 Thiemo Seufer (MIPS32R2 support)
7  *  Copyright (c) 2020 Philippe Mathieu-Daudé
8  *
9  * This code is licensed under the GNU GPLv2 and later.
10  */
11
12 #include "qemu/osdep.h"
13 #include "tcg/tcg-op.h"
14 #include "exec/helper-gen.h"
15 #include "translate.h"
16
17 /* Include the auto-generated decoder.  */
18 #include "decode-mips32r6.c.inc"
19 #include "decode-mips64r6.c.inc"
20
21 bool trans_REMOVED(DisasContext *ctx, arg_REMOVED *a)
22 {
23     gen_reserved_instruction(ctx);
24
25     return true;
26 }
27
28 static bool trans_LSA(DisasContext *ctx, arg_rtype *a)
29 {
30     return gen_lsa(ctx, a->rd, a->rt, a->rs, a->sa);
31 }
32
33 static bool trans_DLSA(DisasContext *ctx, arg_rtype *a)
34 {
35     return gen_dlsa(ctx, a->rd, a->rt, a->rs, a->sa);
36 }
37
38 bool decode_isa_rel6(DisasContext *ctx, uint32_t insn)
39 {
40     if (TARGET_LONG_BITS == 64 && decode_mips64r6(ctx, insn)) {
41         return true;
42     }
43     return decode_mips32r6(ctx, insn);
44 }
This page took 0.027797 seconds and 4 git commands to generate.