This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


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

Re: SH, MN10300 and cross-install documentation


On Jun 10, 2001, "Joseph S. Myers" <jsm28@cam.ac.uk> wrote:

> On 10 Jun 2001, Alexandre Oliva wrote:
>> In response to earlier requests by Gerald and Joseph, I went over the
>> documentation of the ports I maintain and of the cross tool-chain

> Could you check that all the __attribute__s your ports provide are
> properly documented?

mn10300 doesn't provide any attributes.  SH does, but I'm not 100%
sure about their behavior.  I've written down what I could grasp from
the implementation, but I'm not sure we really want to take the risk
of having something mis-documented rather than undocumented.  Do we?
If we do, ok to install?

BTW, the branch fails to `make dvi', while in mainline it works fine.
I have verified that it was not any of my patches that broke it, but
haven't started hunting down the actual problem.  LaTeX just complains
about line 58 of some file, where @gol is defined as an alias.

Index: gcc/ChangeLog
from  Alexandre Oliva  <aoliva@redhat.com>

	* doc/extend.texi (Function Attributes): Document SH's sp_switch
	and trap_exit.

Index: gcc/doc/extend.texi
===================================================================
RCS file: /cvs/gcc/egcs/gcc/doc/extend.texi,v
retrieving revision 1.1.2.1
diff -u -p -r1.1.2.1 extend.texi
--- gcc/doc/extend.texi 2001/06/07 22:04:42 1.1.2.1
+++ gcc/doc/extend.texi 2001/06/11 00:52:15
@@ -1929,13 +1929,6 @@ and 64 entries on the H8/300H) and share
 You must use GAS and GLD from GNU binutils version 2.7 or later for
 this option to work correctly.
 
-@item interrupt_handler
-@cindex interrupt handler functions on the H8/300 processors
-Use this option on the H8/300 and H8/300H to indicate that the specified
-function is an interrupt handler.  The compiler will generate function
-entry and exit sequences suitable for use in an interrupt handler when this
-attribute is present.
-
 @item interrupt
 @cindex interrupt handler functions
 Use this option on the ARM, AVR and M32R/D ports to indicate that the
@@ -1943,8 +1936,8 @@ specified function is an interrupt handl
 function entry and exit sequences suitable for use in an interrupt
 handler when this attribute is present.
 
-Note, interrupt handlers for the H8/300 and H8/300H processors can be
-specified via the @code{interrupt_handler} attribute.
+Note, interrupt handlers for the H8/300, H8/300H and SH processors can
+be specified via the @code{interrupt_handler} attribute.
 
 Note, on the AVR interrupts will be enabled inside the function.
 
@@ -1956,6 +1949,29 @@ void f () __attribute__ ((interrupt ("IR
 @end smallexample
 
 Permissible values for this parameter are: IRQ, FIQ, SWI, ABORT and UNDEF.
+
+@item interrupt_handler
+@cindex interrupt handler functions on the H8/300 and SH processors
+Use this option on the H8/300, H8/300H and SH to indicate that the
+specified function is an interrupt handler.  The compiler will generate
+function entry and exit sequences suitable for use in an interrupt
+handler when this attribute is present.
+
+@item sp_switch
+Use this option on the SH to indicate an @code{interrupt_handler}
+function should switch to an alternate stack.  It expects a string
+argument that names a global variable holding the address of the
+alternate stack.
+
+@smallexample
+void *alt_stack;
+void f () __attribute__ ((interrupt_handler, sp_switch ("alt_stack")));
+@end smallexample
+
+@item trap_exit
+Use this option on the SH for an @code{interrupt_handle} to return using
+@code{trapa} instead of @code{rte}.  This attribute expects an integer
+argument specifying the trap number to be used.
 
 @item eightbit_data
 @cindex eight bit data on the H8/300 and H8/300H

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                  aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist    *Please* write to mailing lists, not to me

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