From 2f3565a392130b00755a9dda411f9ac7d0255686 Mon Sep 17 00:00:00 2001 From: DJ Delorie Date: Wed, 27 May 2009 01:49:46 +0000 Subject: [PATCH] [cgen/cpu] * cpu/mep-ivc2.cpu (h-ccr-ivc2): Enable for C3 slots, fix accumulator names. (f-ivc2-ccrn-c3hi): New. (f-ivc2-ccrn-c3lo): New. (f-ivc2-ccrn-c3): New. (ivc2c3ccrn): Use it. [sid/component/cgen-cpu/mep] * mep-cop1-32-decode.cxx: Regenerate. * mep-cop1-32-decode.h: Regenerate. * mep-cop1-32-sem.cxx: Regenerate. * mep-cop1-48-sem.cxx: Regenerate. [opcodes] * mep-asm.c: Regenerate. * mep-desc.c: Regenerate. * mep-desc.h: Regenerate. * mep-dis.c: Regenerate. * mep-ibld.c: Regenerate. * mep-opc.c: Regenerate. * mep-opc.h: Regenerate. --- opcodes/ChangeLog | 10 ++++++++++ opcodes/mep-asm.c | 2 +- opcodes/mep-desc.c | 46 ++++++++++++++++++++++++++++------------------ opcodes/mep-desc.h | 9 +++++---- opcodes/mep-dis.c | 2 +- opcodes/mep-ibld.c | 22 +++++++++++----------- opcodes/mep-opc.c | 2 +- opcodes/mep-opc.h | 3 +++ 8 files changed, 60 insertions(+), 36 deletions(-) diff --git a/opcodes/ChangeLog b/opcodes/ChangeLog index a3b0f1b87f3..7a48ec9094f 100644 --- a/opcodes/ChangeLog +++ b/opcodes/ChangeLog @@ -1,3 +1,13 @@ +2009-05-26 DJ Delorie + + * mep-asm.c: Regenerate. + * mep-desc.c: Regenerate. + * mep-desc.h: Regenerate. + * mep-dis.c: Regenerate. + * mep-ibld.c: Regenerate. + * mep-opc.c: Regenerate. + * mep-opc.h: Regenerate. + 2009-05-26 Nick Clifton * po/id.po: Updated Indonesian translation. diff --git a/opcodes/mep-asm.c b/opcodes/mep-asm.c index 1feff818991..b0546f463c0 100644 --- a/opcodes/mep-asm.c +++ b/opcodes/mep-asm.c @@ -981,7 +981,7 @@ mep_cgen_parse_operand (CGEN_CPU_DESC cd, errmsg = cgen_parse_unsigned_integer (cd, strp, MEP_OPERAND_IVC_X_6_3, (unsigned long *) (& fields->f_ivc2_3u6)); break; case MEP_OPERAND_IVC2C3CCRN : - errmsg = cgen_parse_keyword (cd, strp, & mep_cgen_opval_h_ccr_ivc2, & fields->f_ccrn); + errmsg = cgen_parse_keyword (cd, strp, & mep_cgen_opval_h_ccr_ivc2, & fields->f_ivc2_ccrn_c3); break; case MEP_OPERAND_IVC2CCRN : errmsg = cgen_parse_keyword (cd, strp, & mep_cgen_opval_h_ccr_ivc2, & fields->f_ivc2_ccrn); diff --git a/opcodes/mep-desc.c b/opcodes/mep-desc.c index d8a19886f38..7c8510e4b39 100644 --- a/opcodes/mep-desc.c +++ b/opcodes/mep-desc.c @@ -473,22 +473,22 @@ static CGEN_KEYWORD_ENTRY mep_cgen_opval_h_ccr_ivc2_entries[] = { "$cofa0", 6, {0, {{{0, 0}}}}, 0, 0 }, { "$cofa1", 7, {0, {{{0, 0}}}}, 0, 0 }, { "$csar1", 15, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc00", 16, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc01", 17, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc02", 18, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc03", 19, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc04", 20, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc05", 21, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc06", 22, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc07", 23, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc10", 24, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc11", 25, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc12", 26, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc13", 27, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc14", 28, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc15", 29, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc16", 30, {0, {{{0, 0}}}}, 0, 0 }, - { "$acc17", 31, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc0_0", 16, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc0_1", 17, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc0_2", 18, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc0_3", 19, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc0_4", 20, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc0_5", 21, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc0_6", 22, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc0_7", 23, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc1_0", 24, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc1_1", 25, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc1_2", 26, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc1_3", 27, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc1_4", 28, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc1_5", 29, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc1_6", 30, {0, {{{0, 0}}}}, 0, 0 }, + { "$acc1_7", 31, {0, {{{0, 0}}}}, 0, 0 }, { "$ccr0", 0, {0, {{{0, 0}}}}, 0, 0 }, { "$ccr1", 1, {0, {{{0, 0}}}}, 0, 0 }, { "$ccr2", 2, {0, {{{0, 0}}}}, 0, 0 }, @@ -555,7 +555,7 @@ const CGEN_HW_ENTRY mep_cgen_hw_table[] = { "h-ccr", HW_H_CCR, CGEN_ASM_KEYWORD, (PTR) & mep_cgen_opval_h_ccr, { 0, { { { (1<f_ivc2_3u6, 0, pc, length); break; case MEP_OPERAND_IVC2C3CCRN : - print_keyword (cd, info, & mep_cgen_opval_h_ccr_ivc2, fields->f_ccrn, 0|(1<f_ivc2_ccrn_c3, 0|(1<f_ivc2_ccrn, 0|(1<> (4))) & (3)); - FLD (f_ccrn_lo) = ((FLD (f_ccrn)) & (15)); + FLD (f_ivc2_ccrn_c3hi) = ((((unsigned int) (FLD (f_ivc2_ccrn_c3)) >> (4))) & (3)); + FLD (f_ivc2_ccrn_c3lo) = ((FLD (f_ivc2_ccrn_c3)) & (15)); } - errmsg = insert_normal (cd, fields->f_ccrn_hi, 0, 0, 28, 2, 32, total_length, buffer); + errmsg = insert_normal (cd, fields->f_ivc2_ccrn_c3hi, 0, 0, 28, 2, 32, total_length, buffer); if (errmsg) break; - errmsg = insert_normal (cd, fields->f_ccrn_lo, 0, 0, 4, 4, 32, total_length, buffer); + errmsg = insert_normal (cd, fields->f_ivc2_ccrn_c3lo, 0, 0, 4, 4, 32, total_length, buffer); if (errmsg) break; } @@ -1461,11 +1461,11 @@ mep_cgen_extract_operand (CGEN_CPU_DESC cd, break; case MEP_OPERAND_IVC2C3CCRN : { - length = extract_normal (cd, ex_info, insn_value, 0, 0, 28, 2, 32, total_length, pc, & fields->f_ccrn_hi); + length = extract_normal (cd, ex_info, insn_value, 0, 0, 28, 2, 32, total_length, pc, & fields->f_ivc2_ccrn_c3hi); if (length <= 0) break; - length = extract_normal (cd, ex_info, insn_value, 0, 0, 4, 4, 32, total_length, pc, & fields->f_ccrn_lo); + length = extract_normal (cd, ex_info, insn_value, 0, 0, 4, 4, 32, total_length, pc, & fields->f_ivc2_ccrn_c3lo); if (length <= 0) break; - FLD (f_ccrn) = ((((FLD (f_ccrn_hi)) << (4))) | (FLD (f_ccrn_lo))); + FLD (f_ivc2_ccrn_c3) = ((((FLD (f_ivc2_ccrn_c3hi)) << (4))) | (FLD (f_ivc2_ccrn_c3lo))); } break; case MEP_OPERAND_IVC2CCRN : @@ -1918,7 +1918,7 @@ mep_cgen_get_int_operand (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED, value = fields->f_ivc2_3u6; break; case MEP_OPERAND_IVC2C3CCRN : - value = fields->f_ccrn; + value = fields->f_ivc2_ccrn_c3; break; case MEP_OPERAND_IVC2CCRN : value = fields->f_ivc2_ccrn; @@ -2301,7 +2301,7 @@ mep_cgen_get_vma_operand (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED, value = fields->f_ivc2_3u6; break; case MEP_OPERAND_IVC2C3CCRN : - value = fields->f_ccrn; + value = fields->f_ivc2_ccrn_c3; break; case MEP_OPERAND_IVC2CCRN : value = fields->f_ivc2_ccrn; @@ -2685,7 +2685,7 @@ mep_cgen_set_int_operand (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED, fields->f_ivc2_3u6 = value; break; case MEP_OPERAND_IVC2C3CCRN : - fields->f_ccrn = value; + fields->f_ivc2_ccrn_c3 = value; break; case MEP_OPERAND_IVC2CCRN : fields->f_ivc2_ccrn = value; @@ -3042,7 +3042,7 @@ mep_cgen_set_vma_operand (CGEN_CPU_DESC cd ATTRIBUTE_UNUSED, fields->f_ivc2_3u6 = value; break; case MEP_OPERAND_IVC2C3CCRN : - fields->f_ccrn = value; + fields->f_ivc2_ccrn_c3 = value; break; case MEP_OPERAND_IVC2CCRN : fields->f_ivc2_ccrn = value; diff --git a/opcodes/mep-opc.c b/opcodes/mep-opc.c index 1a8321e3bac..a9b09a54105 100644 --- a/opcodes/mep-opc.c +++ b/opcodes/mep-opc.c @@ -439,7 +439,7 @@ static const CGEN_IFMT ifmt_cmov_crn_rm ATTRIBUTE_UNUSED = { }; static const CGEN_IFMT ifmt_cmovc_ccrn_rm ATTRIBUTE_UNUSED = { - 32, 32, 0xf00ffff3, { { F (F_MAJOR) }, { F (F_CCRN) }, { F (F_RM) }, { F (F_SUB4) }, { F (F_IVC2_4U16) }, { F (F_IVC2_4U20) }, { F (F_IVC2_4U24) }, { F (F_30) }, { F (F_31) }, { 0 } } + 32, 32, 0xf00ffff3, { { F (F_MAJOR) }, { F (F_IVC2_CCRN_C3) }, { F (F_RM) }, { F (F_SUB4) }, { F (F_IVC2_4U16) }, { F (F_IVC2_4U20) }, { F (F_IVC2_4U24) }, { F (F_30) }, { F (F_31) }, { 0 } } }; static const CGEN_IFMT ifmt_cmov_crn_rm_p0 ATTRIBUTE_UNUSED = { diff --git a/opcodes/mep-opc.h b/opcodes/mep-opc.h index 0704c3001a7..27955199c33 100644 --- a/opcodes/mep-opc.h +++ b/opcodes/mep-opc.h @@ -484,6 +484,8 @@ struct cgen_fields long f_ivc2_3u25; long f_ivc2_imm16p0; long f_ivc2_simm16p0; + long f_ivc2_ccrn_c3hi; + long f_ivc2_ccrn_c3lo; long f_ivc2_crn; long f_ivc2_crm; long f_ivc2_ccrn_h1; @@ -492,6 +494,7 @@ struct cgen_fields long f_ivc2_cmov1; long f_ivc2_cmov2; long f_ivc2_cmov3; + long f_ivc2_ccrn_c3; long f_ivc2_ccrn; long f_ivc2_crnx; }; -- 2.30.2