This is the mail archive of the
cgen@sources.redhat.com
mailing list for the CGEN project.
patch for opcodes/cgen-dis.in
- To: binutils at sources dot redhat dot com
- subject: patch for opcodes/cgen-dis.in
- From: matthew green <mrg at cygnus dot com>
- Date: Fri, 13 Oct 2000 20:41:56 +1100
- Cc: cgen at sources dot redhat dot com
- organisation: Red Hat, Inc.
i'd like to propose this patch for the generated cgen disassembler. it
allows one to disable the printing of macro (alias) instructions, forcing
the "real" instruction name to be displayed.
it does not affect any other port's regenerated files, as it only is enabled
when CGEN_DISASSEMBLE_IGNORE_ALIASES is defined, similar to how
CGEN_VALIDATE_INSN_SUPPORTED is implemented.
.mrg.
2000-10-13 matthew green <mrg@cygnus.com>
* cgen-dis.in (print_insn): Ignore instruction aliases if compiled
with CGEN_DISASSEMBLE_IGNORE_ALIASES defined.
Index: cgen-dis.in
===================================================================
RCS file: /cvs/cvsfiles/devo/opcodes/cgen-dis.in,v
retrieving revision 1.26
diff -p -r1.26 cgen-dis.in
*** cgen-dis.in 2000/08/28 18:36:53 1.26
--- cgen-dis.in 2000/10/13 09:37:46
*************** print_insn (cd, pc, info, buf, buflen)
*** 271,276 ****
--- 271,285 ----
}
#endif
+ #ifdef CGEN_DISASSEMBLE_IGNORE_ALIASES
+ /* Don't use aliases when disassembling. */
+ if (CGEN_INSN_ATTR_VALUE (insn, CGEN_INSN_ALIAS) != 0)
+ {
+ insn_list = CGEN_DIS_NEXT_INSN (insn_list);
+ continue;
+ }
+ #endif
+
/* Basic bit mask must be correct. */
/* ??? May wish to allow target to defer this check until the extract
handler. */