forked from Imagelibrary/binutils-gdb
[ARC] Force the disassam to use the hexadecimal number for printing
Force printing of the short/signed values using hexadecimal representation via disassembler option. opcode/ 2017-11-03 Claudiu Zissulescu <claziss@synopsys.com> * arc-dis.c (print_hex): New variable. (parse_option): Check for hex option. (print_insn_arc): Use hexadecimal representation for short immediate values when requested. (print_arc_disassembler_options): Add hex option to the list. binutils/ 2017-11-03 Claudiu Zissulescu <claziss@synopsys.com> * doc/binutils.texi (ARC): Update disassembler options. * testsuite/binutils-all/arc/hexprint.s: New file. * testsuite/binutils-all/arc/objdump.exp: Test hex printing feature.
This commit is contained in:
2
binutils/testsuite/binutils-all/arc/hexprint.s
Normal file
2
binutils/testsuite/binutils-all/arc/hexprint.s
Normal file
@@ -0,0 +1,2 @@
|
||||
.cpu EM
|
||||
st r0,[r1,-9]
|
||||
@@ -91,4 +91,9 @@ check_assembly "arc double_store -Mcpu=em,fpus" $objfile \
|
||||
# Make sure that the last cpu= value is used.
|
||||
check_assembly "arc double_store -Mcpu=hs,cpu=em" $objfile \
|
||||
$double_store_em_expected "-Mcpu=hs,cpu=em"
|
||||
|
||||
# Check the hex printing for short immediates.
|
||||
set thexobj [do_objfile hexprint.s]
|
||||
check_assembly "arc hex printing" $thexobj \
|
||||
{st\s*r0,\[r1,0xfffffff7\]} "-Mhex"
|
||||
check_assembly "arc normal printing" $thexobj \
|
||||
{st\s*r0,\[r1,-9\]}
|
||||
|
||||
Reference in New Issue
Block a user