This is the mail archive of the
binutils@sources.redhat.com
mailing list for the binutils project.
Re: [PATCH] Add .set arch=FOO support to MIPS gas.
At Mon, 30 Jun 2003 19:20:15 +0000 (UTC), cgd@broadcom.com wrote:
> it looks like you're hard-coding assumptions about the register names
> used by the ABI, in the disassembly for the existing test.
Err, I take that back. it seems that the test is simply inconsistent,
but is failing in a fairly special way due to objdump.
e.g. consider two examples. with the default flags mips64-linux,
produces (and the script expects):
mul $6,$7,$8
regexp: 0000004c <[^>]*> mul a2,a3,t0
0000004c <text_label-0x4> 70e83002 mul a2,a3,t0
dmtc2 $8, $9, 7
regexp: 0000032c <[^>]*> dmtc2 a4,\$9,7
0000032c <text_label+0x2dc> 48a84807 dmtc2 a4,$9,7
with -M reg-names=numeric, those become:
0000004c <text_label-0x4> 70e83002 mul $6,$7,$8
0000032c <text_label+0x2dc> 48a84807 dmtc2 $8,$9,7
and afaict both opcodes use the 't' code for that register (so, the
same reg number is being disassembled two ways)!
Hmm. it looks like upon hitting <text_label>, the dissassembler
options get changed?!
OK, this is exceeding my pre-lunch ability to deal with alien
behaviour. anybody have a clue what's going on here?
(BTW, i'd also recommend including raw insns in the dump, for later
sanity, especially since the disassembly may not match the assembly at
all in this case, for conflicting instructions. 8-)
cgd