aboutsummaryrefslogtreecommitdiff
path: root/sim/lm32
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2023-12-24 04:07:32 -0500
committerMike Frysinger <vapier@gentoo.org>2023-12-24 04:07:32 -0500
commitaea0b94653b6a5dff6f12ec14fd344db73b3a9f8 (patch)
tree72b35360e77181c94fb61dcbd1784bfa97eaf6a0 /sim/lm32
parent43fbcdcd03fec85a9ea147000c3feec9d4989d6c (diff)
downloadgdb-aea0b94653b6a5dff6f12ec14fd344db73b3a9f8.zip
gdb-aea0b94653b6a5dff6f12ec14fd344db73b3a9f8.tar.gz
gdb-aea0b94653b6a5dff6f12ec14fd344db73b3a9f8.tar.bz2
sim: cgen: regenerate decode tables
Integrate some changes from upstream cgen that tightened up the generated output. Shouldn't be any functional changes here.
Diffstat (limited to 'sim/lm32')
-rw-r--r--sim/lm32/decode.c130
1 files changed, 65 insertions, 65 deletions
diff --git a/sim/lm32/decode.c b/sim/lm32/decode.c
index 2bfbf13..00b1ab6 100644
--- a/sim/lm32/decode.c
+++ b/sim/lm32/decode.c
@@ -190,158 +190,158 @@ lm32bf_decode (SIM_CPU *current_cpu, IADDR pc,
unsigned int val0 = (((insn >> 26) & (63 << 0)));
switch (val0)
{
- case 0 : itype = LM32BF_INSN_SRUI; goto extract_sfmt_addi;
- case 1 : itype = LM32BF_INSN_NORI; goto extract_sfmt_andi;
- case 2 : itype = LM32BF_INSN_MULI; goto extract_sfmt_addi;
- case 3 : itype = LM32BF_INSN_SH; goto extract_sfmt_sh;
- case 4 : itype = LM32BF_INSN_LB; goto extract_sfmt_lb;
- case 5 : itype = LM32BF_INSN_SRI; goto extract_sfmt_addi;
- case 6 : itype = LM32BF_INSN_XORI; goto extract_sfmt_andi;
- case 7 : itype = LM32BF_INSN_LH; goto extract_sfmt_lh;
- case 8 : itype = LM32BF_INSN_ANDI; goto extract_sfmt_andi;
- case 9 : itype = LM32BF_INSN_XNORI; goto extract_sfmt_andi;
- case 10 : itype = LM32BF_INSN_LW; goto extract_sfmt_lw;
- case 11 : itype = LM32BF_INSN_LHU; goto extract_sfmt_lh;
- case 12 : itype = LM32BF_INSN_SB; goto extract_sfmt_sb;
- case 13 : itype = LM32BF_INSN_ADDI; goto extract_sfmt_addi;
- case 14 : itype = LM32BF_INSN_ORI; goto extract_sfmt_ori;
- case 15 : itype = LM32BF_INSN_SLI; goto extract_sfmt_addi;
- case 16 : itype = LM32BF_INSN_LBU; goto extract_sfmt_lb;
- case 17 : itype = LM32BF_INSN_BE; goto extract_sfmt_be;
- case 18 : itype = LM32BF_INSN_BG; goto extract_sfmt_be;
- case 19 : itype = LM32BF_INSN_BGE; goto extract_sfmt_be;
- case 20 : itype = LM32BF_INSN_BGEU; goto extract_sfmt_be;
- case 21 : itype = LM32BF_INSN_BGU; goto extract_sfmt_be;
- case 22 : itype = LM32BF_INSN_SW; goto extract_sfmt_sw;
- case 23 : itype = LM32BF_INSN_BNE; goto extract_sfmt_be;
- case 24 : itype = LM32BF_INSN_ANDHII; goto extract_sfmt_andhii;
- case 25 : itype = LM32BF_INSN_CMPEI; goto extract_sfmt_addi;
- case 26 : itype = LM32BF_INSN_CMPGI; goto extract_sfmt_addi;
- case 27 : itype = LM32BF_INSN_CMPGEI; goto extract_sfmt_addi;
- case 28 : itype = LM32BF_INSN_CMPGEUI; goto extract_sfmt_andi;
- case 29 : itype = LM32BF_INSN_CMPGUI; goto extract_sfmt_andi;
- case 30 : itype = LM32BF_INSN_ORHII; goto extract_sfmt_andhii;
- case 31 : itype = LM32BF_INSN_CMPNEI; goto extract_sfmt_addi;
- case 32 :
+ case 0: itype = LM32BF_INSN_SRUI; goto extract_sfmt_addi;
+ case 1: itype = LM32BF_INSN_NORI; goto extract_sfmt_andi;
+ case 2: itype = LM32BF_INSN_MULI; goto extract_sfmt_addi;
+ case 3: itype = LM32BF_INSN_SH; goto extract_sfmt_sh;
+ case 4: itype = LM32BF_INSN_LB; goto extract_sfmt_lb;
+ case 5: itype = LM32BF_INSN_SRI; goto extract_sfmt_addi;
+ case 6: itype = LM32BF_INSN_XORI; goto extract_sfmt_andi;
+ case 7: itype = LM32BF_INSN_LH; goto extract_sfmt_lh;
+ case 8: itype = LM32BF_INSN_ANDI; goto extract_sfmt_andi;
+ case 9: itype = LM32BF_INSN_XNORI; goto extract_sfmt_andi;
+ case 10: itype = LM32BF_INSN_LW; goto extract_sfmt_lw;
+ case 11: itype = LM32BF_INSN_LHU; goto extract_sfmt_lh;
+ case 12: itype = LM32BF_INSN_SB; goto extract_sfmt_sb;
+ case 13: itype = LM32BF_INSN_ADDI; goto extract_sfmt_addi;
+ case 14: itype = LM32BF_INSN_ORI; goto extract_sfmt_ori;
+ case 15: itype = LM32BF_INSN_SLI; goto extract_sfmt_addi;
+ case 16: itype = LM32BF_INSN_LBU; goto extract_sfmt_lb;
+ case 17: itype = LM32BF_INSN_BE; goto extract_sfmt_be;
+ case 18: itype = LM32BF_INSN_BG; goto extract_sfmt_be;
+ case 19: itype = LM32BF_INSN_BGE; goto extract_sfmt_be;
+ case 20: itype = LM32BF_INSN_BGEU; goto extract_sfmt_be;
+ case 21: itype = LM32BF_INSN_BGU; goto extract_sfmt_be;
+ case 22: itype = LM32BF_INSN_SW; goto extract_sfmt_sw;
+ case 23: itype = LM32BF_INSN_BNE; goto extract_sfmt_be;
+ case 24: itype = LM32BF_INSN_ANDHII; goto extract_sfmt_andhii;
+ case 25: itype = LM32BF_INSN_CMPEI; goto extract_sfmt_addi;
+ case 26: itype = LM32BF_INSN_CMPGI; goto extract_sfmt_addi;
+ case 27: itype = LM32BF_INSN_CMPGEI; goto extract_sfmt_addi;
+ case 28: itype = LM32BF_INSN_CMPGEUI; goto extract_sfmt_andi;
+ case 29: itype = LM32BF_INSN_CMPGUI; goto extract_sfmt_andi;
+ case 30: itype = LM32BF_INSN_ORHII; goto extract_sfmt_andhii;
+ case 31: itype = LM32BF_INSN_CMPNEI; goto extract_sfmt_addi;
+ case 32:
if ((entire_insn & 0xfc0007ff) == 0x80000000)
{ itype = LM32BF_INSN_SRU; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 33 :
+ case 33:
if ((entire_insn & 0xfc0007ff) == 0x84000000)
{ itype = LM32BF_INSN_NOR; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 34 :
+ case 34:
if ((entire_insn & 0xfc0007ff) == 0x88000000)
{ itype = LM32BF_INSN_MUL; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 35 :
+ case 35:
if ((entire_insn & 0xfc0007ff) == 0x8c000000)
{ itype = LM32BF_INSN_DIVU; goto extract_sfmt_divu; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 36 :
+ case 36:
if ((entire_insn & 0xfc1f07ff) == 0x90000000)
{ itype = LM32BF_INSN_RCSR; goto extract_sfmt_rcsr; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 37 :
+ case 37:
if ((entire_insn & 0xfc0007ff) == 0x94000000)
{ itype = LM32BF_INSN_SR; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 38 :
+ case 38:
if ((entire_insn & 0xfc0007ff) == 0x98000000)
{ itype = LM32BF_INSN_XOR; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 40 :
+ case 40:
if ((entire_insn & 0xfc0007ff) == 0xa0000000)
{ itype = LM32BF_INSN_AND; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 41 :
+ case 41:
if ((entire_insn & 0xfc0007ff) == 0xa4000000)
{ itype = LM32BF_INSN_XNOR; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 43 :
+ case 43:
{
unsigned int val1 = (((insn >> 1) & (1 << 1)) | ((insn >> 0) & (1 << 0)));
switch (val1)
{
- case 0 :
+ case 0:
if ((entire_insn & 0xffffffff) == 0xac000002)
{ itype = LM32BF_INSN_BREAK; goto extract_sfmt_break; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 3 :
+ case 3:
if ((entire_insn & 0xffffffff) == 0xac000007)
{ itype = LM32BF_INSN_SCALL; goto extract_sfmt_break; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- default : itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
+ default: itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
}
}
- case 44 :
+ case 44:
if ((entire_insn & 0xfc1f07ff) == 0xb0000000)
{ itype = LM32BF_INSN_SEXTB; goto extract_sfmt_sextb; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 45 :
+ case 45:
if ((entire_insn & 0xfc0007ff) == 0xb4000000)
{ itype = LM32BF_INSN_ADD; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 46 :
+ case 46:
if ((entire_insn & 0xfc0007ff) == 0xb8000000)
{ itype = LM32BF_INSN_OR; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 47 :
+ case 47:
if ((entire_insn & 0xfc0007ff) == 0xbc000000)
{ itype = LM32BF_INSN_SL; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 48 :
+ case 48:
if ((entire_insn & 0xfc1fffff) == 0xc0000000)
{ itype = LM32BF_INSN_B; goto extract_sfmt_b; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 49 :
+ case 49:
if ((entire_insn & 0xfc0007ff) == 0xc4000000)
{ itype = LM32BF_INSN_MODU; goto extract_sfmt_divu; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 50 :
+ case 50:
if ((entire_insn & 0xfc0007ff) == 0xc8000000)
{ itype = LM32BF_INSN_SUB; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 51 : itype = LM32BF_INSN_USER; goto extract_sfmt_user;
- case 52 :
+ case 51: itype = LM32BF_INSN_USER; goto extract_sfmt_user;
+ case 52:
if ((entire_insn & 0xfc00ffff) == 0xd0000000)
{ itype = LM32BF_INSN_WCSR; goto extract_sfmt_wcsr; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 54 :
+ case 54:
if ((entire_insn & 0xfc1fffff) == 0xd8000000)
{ itype = LM32BF_INSN_CALL; goto extract_sfmt_call; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 55 :
+ case 55:
if ((entire_insn & 0xfc1f07ff) == 0xdc000000)
{ itype = LM32BF_INSN_SEXTH; goto extract_sfmt_sextb; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 56 : itype = LM32BF_INSN_BI; goto extract_sfmt_bi;
- case 57 :
+ case 56: itype = LM32BF_INSN_BI; goto extract_sfmt_bi;
+ case 57:
if ((entire_insn & 0xfc0007ff) == 0xe4000000)
{ itype = LM32BF_INSN_CMPE; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 58 :
+ case 58:
if ((entire_insn & 0xfc0007ff) == 0xe8000000)
{ itype = LM32BF_INSN_CMPG; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 59 :
+ case 59:
if ((entire_insn & 0xfc0007ff) == 0xec000000)
{ itype = LM32BF_INSN_CMPGE; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 60 :
+ case 60:
if ((entire_insn & 0xfc0007ff) == 0xf0000000)
{ itype = LM32BF_INSN_CMPGEU; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 61 :
+ case 61:
if ((entire_insn & 0xfc0007ff) == 0xf4000000)
{ itype = LM32BF_INSN_CMPGU; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- case 62 : itype = LM32BF_INSN_CALLI; goto extract_sfmt_calli;
- case 63 :
+ case 62: itype = LM32BF_INSN_CALLI; goto extract_sfmt_calli;
+ case 63:
if ((entire_insn & 0xfc0007ff) == 0xfc000000)
{ itype = LM32BF_INSN_CMPNE; goto extract_sfmt_add; }
itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
- default : itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
+ default: itype = LM32BF_INSN_X_INVALID; goto extract_sfmt_empty;
}
}
}