This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: Problem with .req directive in arm-elf-as (2.15 branch)
- From: Nick Clifton <nickc at redhat dot com>
- To: "Peter S. Housel" <housel at acm dot org>
- Cc: binutils at sources dot redhat dot com
- Date: Fri, 30 Apr 2004 11:56:38 +0100
- Subject: Re: Problem with .req directive in arm-elf-as (2.15 branch)
- References: <00f501c428e0$38c115e0$dd22010a@housel7352a>
Hi Peter,
The current binutils-2_15-branch has a problem with the ARM ".req"
pseudo-op. The following code, which used to assemble correctly in 2.13,
now fails:
MMUPurgeTLBReg .req c6
MMUCP .req p15
MCR MMUCP, 0, a1, MMUPurgeTLBReg, c0, 0
Apparently this results because the alias names are already downcased by the
time md_assemble() (and therefore create_register_alias()) in tc-arm.c get
to see them.
Thanks for catching this. It was due to a small typo in the sources
which is fixed by the attached patch. I will be applying this patch to
the sources shortly.
Cheers
Nick
Index: gas/config/tc-arm.c
===================================================================
RCS file: /cvs/src/src/gas/config/tc-arm.c,v
retrieving revision 1.167
diff -c -3 -p -r1.167 tc-arm.c
*** gas/config/tc-arm.c 22 Apr 2004 16:18:29 -0000 1.167
--- gas/config/tc-arm.c 30 Apr 2004 10:37:21 -0000
*************** co_proc_number (str)
*** 3595,3601 ****
}
else
{
! inst.error = _("bad or missing co-processor number");
return FAIL;
}
}
--- 3595,3601 ----
}
else
{
! inst.error = all_reg_maps[REG_TYPE_CP].expected;
return FAIL;
}
}
*************** cp_reg_required_here (str, where)
*** 3650,3656 ****
/* In the few cases where we might be able to accept something else
this error can be overridden. */
! inst.error = _("co-processor register expected");
/* Restore the start point. */
*str = start;
--- 3650,3656 ----
/* In the few cases where we might be able to accept something else
this error can be overridden. */
! inst.error = all_reg_maps[REG_TYPE_CN].expected;
/* Restore the start point. */
*str = start;
*************** fp_reg_required_here (str, where)
*** 3673,3679 ****
/* In the few cases where we might be able to accept something else
this error can be overridden. */
! inst.error = _("floating point register expected");
/* Restore the start point. */
*str = start;
--- 3673,3679 ----
/* In the few cases where we might be able to accept something else
this error can be overridden. */
! inst.error = all_reg_maps[REG_TYPE_FN].expected;
/* Restore the start point. */
*str = start;
*************** create_register_alias (newname, p)
*** 11439,11445 ****
char *copy_of_str;
char *r;
! #ifdef IGNORE_OPCODE_CASE
newname = original_case_string;
#endif
copy_of_str = newname;
--- 11439,11445 ----
char *copy_of_str;
char *r;
! #ifndef IGNORE_OPCODE_CASE
newname = original_case_string;
#endif
copy_of_str = newname;