[Fwd: Re: [PATCH] MIPS32 DSP instructions again]
Chao-ying Fu
fu@mips.com
Mon Jun 13 22:08:00 GMT 2005
More information about the Binutils mailing list
Mon Jun 13 22:08:00 GMT 2005
- Previous message (by thread): [Fwd: Re: [PATCH] MIPS32 DSP instructions again]
- Next message (by thread): [Fwd: Re: [PATCH] MIPS32 DSP instructions again]
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hello, 1. I think I put extra tab, so that the table is aligned for all cases. 2. Someone complained about that I put some magic number inside my code. So, I generated the magic number using the existing mask. I can change it back to use the number (ex: 64) directly. 3. I reuse the 'c' format, so that I don't need to create a new format for the same shift and the same mask and the same immediate. I can create a new mask and the new shift, if you want. 4. Some DSP instructions write or read accumulators which may be $ac0, $ac1, $ac2, $ac3. Because $ac0 is HI/LO, these DSP instructions need the attritubes (WR_HILO/RD_HILO) to inform the assembler to maintain correct HI/LO dependences. Or, if the dependences of accumulators and HI/LO are not necessary at all, I can remove all WR_a and RD_a. Regards, Chao-ying ----- Original Message ----- From: "Eric Christopher" <echristo@redhat.com> To: "Chao-ying Fu" <fu@mips.com> Cc: "Thiemo Seufer" <ths@networkno.de>; <dom@mips.com>; <ian@airs.com>; "Paul Koning" <pkoning@equallogic.com>; <nigel@mips.com>; "Richard Sandiford" <rsandifo@nildram.co.uk>; <radhika@mips.com>; <binutils@sourceware.org> Sent: Monday, June 13, 2005 2:52 PM Subject: Re: [Fwd: Re: [PATCH] MIPS32 DSP instructions again] > On Mon, 2005-06-13 at 14:47 -0700, Chao-ying Fu wrote: > > Hello, > > > > 1. I didn't see any new line after case '5' from my patch. > > The tabs in the table. > > > 3. For checking the immediate range, my original code is > > as follows. > > > > case ':': /* dsp 7-bit signed immediate in bit 19 */ > > my_getExpression (&imm_expr, s); > > check_absolute_expr (ip, &imm_expr); > > if ((unsigned long) (imm_expr.X_add_number + 64) > 127) > > { > > as_warn (_("DSP immediate not in range -64..63 (%ld)"), > > (long) imm_expr.X_add_number); > > } > > > > But, I changed the magic number 64 to > > ((OP_MASK_DSPSFT_7 + 1) >> 1). > > And, I changed the comparison of 127 to "AND" the inverse > > of the mask. Do you prefer my original code or may I put > > some comments to explain the code? > > > > Both ways are pretty foul. I suppose as long as the warning message > contains the actual number range I'm ok with it. But why don't you just > check that the number is in the range, as opposed to the bizarre > addition and shifts? > > > 4. For case 'c', I change the warning message, because > > our DSP instructions reuse this 'c' format. The old > > warning message said "Illegal break code" which is not suitable > > for DSP instructions. > > > > Why are you reusing? > > > 6. WR_a/RD_a reuse WR_HILO/RD_HILO, because DSP accumulators > > may map to the old HI/LO and we want to maintain correct > > dependences of reading and writing HI/LO. > > What do you mean "map to the old HI/LO"? > > -eric > >
- Previous message (by thread): [Fwd: Re: [PATCH] MIPS32 DSP instructions again]
- Next message (by thread): [Fwd: Re: [PATCH] MIPS32 DSP instructions again]
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Binutils mailing list