This is the mail archive of the cgen@sources.redhat.com mailing list for the CGEN 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]

More doc patches: call toplevel directory toplevel; *.cpu files are in cpu/


It seems docs weren't updated after *.cpu files (I guess) moved
to cpu/ at the beginning of time.  I think most people outside
Red Hat would be helped if the top-level directory is called
"toplevel" rather than "devo" without further explanation.

Ok to commit?

2002-01-28  Hans-Peter Nilsson  <hp@axis.com>

	* doc/porting.texi: When referring to *.opc, mention they are in
	the cpu subdir.  Call top-level directory toplevel, not devo.
	Close string in define-normal-insn example.

Index: porting.texi
===================================================================
RCS file: /cvs/src/src/cgen/doc/porting.texi,v
retrieving revision 1.4
diff -p -c -r1.4 porting.texi
*** porting.texi	2001/11/26 16:41:08	1.4
--- porting.texi	2002/01/28 18:58:05
*************** code and tables for each CPU that is por
*** 56,62 ****
  
  For opcodes, several files are generated.  No additional code need be
  written in the opcodes directory although as an escape hatch the user
! can add target specific code to file <arch>.opc in the CGEN source
  directory.  These functions will be included in the relevant generated
  files.  An example of when you need to create an <arch>.opc file is when
  there are special pseudo-ops that need to be parsed, for example the
--- 56,62 ----
  
  For opcodes, several files are generated.  No additional code need be
  written in the opcodes directory although as an escape hatch the user
! can add target specific code to file <arch>.opc in the CGEN cpu source
  directory.  These functions will be included in the relevant generated
  files.  An example of when you need to create an <arch>.opc file is when
  there are special pseudo-ops that need to be parsed, for example the
*************** high/shigh pseudo-ops of the M32R.
*** 65,71 ****
  
  For GAS, no files are generated (except test cases!) so the port is done
  more or less like the other GAS ports except that the assembler uses the
! CGEN-built opcode table plus @file{devo/gas/cgen.[ch]}.
  
  For the simulator, several files are built, and other support files need
  to be written.  @xref{Doing a simulator port}.
--- 65,71 ----
  
  For GAS, no files are generated (except test cases!) so the port is done
  more or less like the other GAS ports except that the assembler uses the
! CGEN-built opcode table plus @file{toplevel/gas/cgen.[ch]}.
  
  For the simulator, several files are built, and other support files need
  to be written.  @xref{Doing a simulator port}.
*************** of Guile.  I ran into this on Solaris 2.
*** 88,95 ****
  
  When doing porting or maintenance activity with CGEN, the build tree
  must be configured with the @code{--enable-cgen-maint} option.  This
! adds the necessary dependencies to the @file{devo/opcodes} and
! @file{devo/sim} directories.
  
  CGEN uses Guile so it must be installed.  At present the CGEN configury
  requires that if Guile isn't installed in @file{/usr/local} then the 
--- 88,95 ----
  
  When doing porting or maintenance activity with CGEN, the build tree
  must be configured with the @code{--enable-cgen-maint} option.  This
! adds the necessary dependencies to the @file{toplevel/opcodes} and
! @file{toplevel/sim} directories.
  
  CGEN uses Guile so it must be installed.  At present the CGEN configury
  requires that if Guile isn't installed in @file{/usr/local} then the 
*************** indicated so with the `MACH' attribute. 
*** 316,322 ****
  
  @example
  (define-normal-insn
!   add "add instruction
    ((MACH mach1)) ; or (MACH mach1,mach2,...) for multiple variants
    ...
  )
--- 316,322 ----
  
  @example
  (define-normal-insn
!   add "add instruction"
    ((MACH mach1)) ; or (MACH mach1,mach2,...) for multiple variants
    ...
  )
*************** that is similar to the new port) and use
*** 496,507 ****
  @item @code{(load "dev.scm")}. This loads in a set of interactive
  development routines.
  @item @code{(load-opc)}. Load the opcodes support.
! @item Edit your @file{<arch>.cpu} and @file{<arch>.opc} files.
          @itemize @bullet
          @item The @file{.cpu} file is the main description file.
  	@item The @file{.opc} file provides additional C support code.
          @end itemize
! @item @code{(cload #:arch "<arch>")}
  @item Run each of:
          @itemize @bullet
          @item @code{(cgen-desc.h)}
--- 496,507 ----
  @item @code{(load "dev.scm")}. This loads in a set of interactive
  development routines.
  @item @code{(load-opc)}. Load the opcodes support.
! @item Edit your @file{cpu/<arch>.cpu} and @file{cpu/<arch>.opc} files.
          @itemize @bullet
          @item The @file{.cpu} file is the main description file.
  	@item The @file{.opc} file provides additional C support code.
          @end itemize
! @item @code{(cload #:arch "cpu/<arch>")}
  @item Run each of:
          @itemize @bullet
          @item @code{(cgen-desc.h)}
*************** script normally requires one command lin
*** 652,664 ****
  @file{gas} build directory.  If this argument is omitted, the script
  searches in @file{../gas} automatically.
  
! @item Copy @file{gas-allinsn.exp} to @file{devo/gas/testsuite/gas/<arch>/allinsn.exp}.
  @item @code{sh gas-build.sh}
  
  At this point directory tmpdir contains two files: @file{allinsn.s} and
  @file{allinsn.d}.  File @file{allinsn.d} usually needs a bit of massaging.
  
! @item Copy @file{tmpdir/allinsn.[sd]} to @file{devo/gas/testsuite/gas/<arch>}
  @item Run @code{make check} in the @file{gas} build directory and
  massage things until you're satisfied the files are correct.
  @item Check files into CVS.
--- 652,664 ----
  @file{gas} build directory.  If this argument is omitted, the script
  searches in @file{../gas} automatically.
  
! @item Copy @file{gas-allinsn.exp} to @file{toplevel/gas/testsuite/gas/<arch>/allinsn.exp}.
  @item @code{sh gas-build.sh}
  
  At this point directory tmpdir contains two files: @file{allinsn.s} and
  @file{allinsn.d}.  File @file{allinsn.d} usually needs a bit of massaging.
  
! @item Copy @file{tmpdir/allinsn.[sd]} to @file{toplevel/gas/testsuite/gas/<arch>}
  @item Run @code{make check} in the @file{gas} build directory and
  massage things until you're satisfied the files are correct.
  @item Check files into CVS.
*************** The same basic procedure for opcodes por
*** 675,682 ****
  @item Run @code{guile}.
  @item @code{(load "dev.scm")}
  @item @code{(load-sim)}
! @item Edit your @file{<arch>.cpu} file.
! @item @code{(cload #:arch "<arch>")}
  @item Run each of:
          @itemize @bullet
  	@item @code{(cgen-arch.h)}
--- 675,682 ----
  @item Run @code{guile}.
  @item @code{(load "dev.scm")}
  @item @code{(load-sim)}
! @item Edit your @file{cpu/<arch>.cpu} file.
! @item @code{(cload #:arch "cpu/<arch>")}
  @item Run each of:
          @itemize @bullet
  	@item @code{(cgen-arch.h)}
*************** The same basic procedure for opcodes por
*** 684,691 ****
  	@item @code{(cgen-cpuall.h)}
          @end itemize
  @item Repeat steps 4,5,6 until the output looks reasonable.
! @item Edit your <arch>.cpu file.
! @item @code{(cload #:arch "<arch>" #:machs "mach1[,mach2[,...]]")}
  @item Run each of:
          @itemize @bullet
  	@item @code{(cgen-cpu.h)}
--- 684,691 ----
  	@item @code{(cgen-cpuall.h)}
          @end itemize
  @item Repeat steps 4,5,6 until the output looks reasonable.
! @item Edit your cpu/<arch>.cpu file.
! @item @code{(cload #:arch "cpu/<arch>" #:machs "mach1[,mach2[,...]]")}
  @item Run each of:
          @itemize @bullet
  	@item @code{(cgen-cpu.h)}
*************** initial typing that is required.
*** 839,863 ****
  
  @enumerate 1
  @item @code{cd} to the CGEN build directory
! @item @code{make sim-test}
  
  At this point two files have been created in the CGEN build directory:
  @file{sim-allinsn.exp} and @file{sim-build.sh}.
  
  @item Copy @file{sim-allinsn.exp} to
! @file{devo/sim/testsuite/sim/<arch>/allinsn.exp}.
  @item @code{sh sim-build.sh}
  
  At this point a new subdirectory called @file{tmpdir} will be created
  and will contain one test case for each instruction.  The framework has
  been filled in but not the actual test case.  It's handy to write an
  ``include file'' containing assembler macros that simplify writing test
! cases.  See @file{devo/sim/testsuite/sim/m32r/testutils.inc} for an
  example.
  
  @item write testutils.inc
  @item finish each test case
! @item copy @file{tmpdir/*.cgs} to @file{devo/sim/testsuite/sim/<arch>}
  @item run @code{make check} in the sim build directory and massage things until you're satisfied the files are correct
  @item Check files into CVS.
  @end enumerate
--- 839,863 ----
  
  @enumerate 1
  @item @code{cd} to the CGEN build directory
! @item @code{make sim-test ISA=<arch>}
  
  At this point two files have been created in the CGEN build directory:
  @file{sim-allinsn.exp} and @file{sim-build.sh}.
  
  @item Copy @file{sim-allinsn.exp} to
! @file{toplevel/sim/testsuite/sim/<arch>/allinsn.exp}.
  @item @code{sh sim-build.sh}
  
  At this point a new subdirectory called @file{tmpdir} will be created
  and will contain one test case for each instruction.  The framework has
  been filled in but not the actual test case.  It's handy to write an
  ``include file'' containing assembler macros that simplify writing test
! cases.  See @file{toplevel/sim/testsuite/sim/m32r/testutils.inc} for an
  example.
  
  @item write testutils.inc
  @item finish each test case
! @item copy @file{tmpdir/*.cgs} to @file{toplevel/sim/testsuite/sim/<arch>}
  @item run @code{make check} in the sim build directory and massage things until you're satisfied the files are correct
  @item Check files into CVS.
  @end enumerate

brgds, H-P


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