This is the mail archive of the gdb-patches@sources.redhat.com mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[patch][rfa]: igen: Define prefixed version of semantic_illegal


Hi,

The attached patch generates a prefixed mapping of the helper function
'semantic_illegal" similar to the way 'instruction_word' and
'idecode_issue' are handled. Necessary for simulators which support
more than one model.

ok to commit?

Dave
sim/igen/ChangeLog:
2002-08-15  Dave Brolley  <brolley@redhat.com>

	* gen-support.c (gen_support_h): Generate
	'#define semantic_illegal <PREFIX>_semantic_illegal'.

Index: sim/igen/gen-support.c
===================================================================
RCS file: /cvs/src/src/sim/igen/gen-support.c,v
retrieving revision 1.1.1.1
diff -c -p -r1.1.1.1 gen-support.c
*** sim/igen/gen-support.c	16 Apr 1999 01:35:04 -0000	1.1.1.1
--- sim/igen/gen-support.c	15 Aug 2002 19:58:52 -0000
*************** gen_support_h (lf *file,
*** 141,150 ****
    lf_printf(file, "#define _SD SD_ /* deprecated */\n");
    lf_printf(file, "\n");
  
!   /* Map <PREFIX>_instruction_word and <PREFIX>_idecode_issue onto the
!      shorter instruction_word and idecode_issue.  Map defined here as,
!      name space problems are created when the name is defined in
!      idecode.h */
    if (strcmp (options.module.idecode.prefix.l, "") != 0)
      {
        lf_indent_suppress (file);
--- 141,154 ----
    lf_printf(file, "#define _SD SD_ /* deprecated */\n");
    lf_printf(file, "\n");
  
!   /* Map <PREFIX>_xxxx onto the shorter xxxx for the following names:
! 
!        instruction_word
!        idecode_issue
!        semantic_illegal
! 
!      Map defined here as name space problems are created when the name is
!      defined in idecode.h  */
    if (strcmp (options.module.idecode.prefix.l, "") != 0)
      {
        lf_indent_suppress (file);
*************** gen_support_h (lf *file,
*** 158,163 ****
--- 162,173 ----
  		 "idecode_issue",
  		 options.module.idecode.prefix.l,
  		 "idecode_issue");
+       lf_printf (file, "\n");
+       lf_indent_suppress (file);
+       lf_printf (file, "#define %s %s%s\n",
+ 		 "semantic_illegal",
+ 		 options.module.idecode.prefix.l,
+ 		 "semantic_illegal");
        lf_printf (file, "\n");
      }
  

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