This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [Fwd: Re: [PATCH] MIPS32 DSP instructions again]


Yes, I changed the option to "-mno-dsp", and modified
the code for checking immediate numbers.  The new patch
is attached. GAS "make check" is ok with
"--target=mipsisa32-elf".

Regards,
Chao-ying

gas/ChangeLog
2005-06-10  Chao-ying Fu  <fu@mips.com>

     * config/tc-mips.c (mips_set_options): Add ase_dsp for DSP
instructions.
     (mips_opts): Add -1 for ase_dsp initialization.
     (file_ase_dsp): New variable for -mdsp.
     (CPU_HAS_DSP): New define.
     (validate_mips_insn): Handle '3', '4', '5', '6', '7',
     '8', '9', '0', '\'', ':' format operands for DSP instructions.
     (mips_ip): Check ase_dsp to enable DSP instructions.
     Handle '3', '4', '5', '6', '7', 8', '9', '0', '\'', ':'.
     Change the warning message for 'c' operand format.
     (OPTION_DSP, OPTION_NO_DSP): New.
     (md_parse_option): Parse OPTION_DSP and OPTION_NO_DSP.
     (mips_after_parse_args): Set ase_dsp based on cpu.
     (s_mipsset): Handle .set dsp/nodsp.
     (mips_elf_final_processing): Remind us of adding elf
     header for DSP in the future.
     (md_show_usage): Show usage of -mdsp and -mno-dsp.

gas/testsuite/ChangeLog
2005-06-10  Chao-ying Fu  <fu@mips.com>

     * gas/mips/mips32-dsp.[sdl]: New test.
     * gas/mips/mips.exp: Run the new test.

include/opcode/ChangeLog
2005-06-10  Chao-ying Fu  <fu@mips.com>

     * mips.h (OP_SH_DSPACC, OP_MASK_DSPACC, OP_SH_DSPACC_S,
     OP_MASK_DSPACC_S, OP_SH_DSPSFT, OP_MASK_DSPSFT, OP_SH_DSPSFT_7,
     OP_MASK_DSPSFT_7, OP_SH_SA3, OP_MASK_SA3, OP_SH_SA4, OP_MASK_SA4,
     OP_SH_IMM8, OP_MASK_IMM8, OP_SH_WRDSP, OP_MASK_WRDSP, OP_SH_RDDSP,
     OP_MASK_RDDSP): New define.  Document 3, 4, 5, 6, 7, 8, 9, 0, :, '
     operand formats for DSP instructions.
     (INSN_ASE_MASK): Update to include DSP_ASE.
     (INSN_DSP): New define.

opcodes/ChangeLog
2005-06-10  Chao-ying Fu  <fu@mips.com>

     * mips-dis.c (mips_arch_choices): Add INSN_DSP to mips32,
     mips32r2, mips64, mips64r2.
     (print_insn_args): Add handing for 3, 4, 5, 6, 7, 8, 9, 0,
     :, ' for DSP instructions.
     * mips-opc.c: Add support for DSP instructions.
     (WR_a, RD_a, MOD_a, DSP_VOLA, D32): New define.

----- Original Message ----- 
From: "Thiemo Seufer" <ths@networkno.de>
To: "Chao-ying Fu" <fu@mips.com>
Cc: <echristo@redhat.com>; <dom@mips.com>; <ian@airs.com>; "Paul Koning"
<pkoning@equallogic.com>; <nigel@mips.com>; <rsandifo@nildram.co.uk>;
<radhika@mips.com>; <binutils@sourceware.org>
Sent: Friday, June 10, 2005 5:46 AM
Subject: Re: [Fwd: Re: [PATCH] MIPS32 DSP instructions again]


> Chao-ying Fu wrote:
> > Hello,
> >
> >   From the discussions, most people prefer having
> > the option to control generating DSP instructions.
> > So, I put DSP options back to GAS as follows.
> >
> > -mdsp                   generate DSP instructions
> > -no-dsp                 do not generate DSP instructions
>
> Please use -mno-dsp, and resend the patch with a mailer which doesn't
> mangle it with tab expansion and additional linebreaks (or send it as
> attachment).
>
> [snip]
> > *** 7965,7970 ****
> > --- 7985,8130 ----
> >     return;
> >          break;
> >
> > +      case '3': /* dsp 3-bit unsigned immediate in bit 21 */
> > +        my_getExpression (&imm_expr, s);
> > +        check_absolute_expr (ip, &imm_expr);
> > +        if ((unsigned long) imm_expr.X_add_number > 7)
>
> Could you use something like if (imm_expr.X_add_number & ~OP_MASK_SA3)
> instead of magic numbers for those?
>
>
> Thiemo
>

Attachment: mips32-dsp.s
Description: Binary data

Attachment: mips32-dsp.l
Description: Binary data

Attachment: mips32-dsp.d
Description: Binary data

Attachment: dsp06102005.patch
Description: Binary data


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]