This is the mail archive of the binutils@sources.redhat.com mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]

Re: patch for opcodes/cgen-dis.in


Isn't this what the NO-DIS attribute on the macro insn in the
.cpu file is for?

Dave

matthew green wrote:
> 
> 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.  */

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]