Bug 1078 - Problems with attributes documentation
Summary: Problems with attributes documentation
Status: NEW
Alias: None
Product: gcc
Classification: Unclassified
Component: target (show other bugs)
Version: 2.97
: P3 normal
Target Milestone: ---
Assignee: Not yet assigned to anyone
Keywords: documentation
Depends on: 27543 27544
  Show dependency treegraph
Reported: 2000-12-16 15:36 UTC by Joseph S. Myers
Modified: 2007-09-04 03:37 UTC (History)
3 users (show)

See Also:
Host: i686-pc-linux-gnu
Target: i686-pc-linux-gnu
Build: i686-pc-linux-gnu
Known to work:
Known to fail:
Last reconfirmed: 2006-02-26 19:15:09


Note You need to log in before you can comment on or make changes to this bug.
Description Joseph S. Myers 2000-12-16 15:36:00 UTC
There are many problems with the documentation of attributes in

1) The syntax of attributes on labels is undocumented, though it's
   mentioned in invoke.texi that attributes can be placed on labels.

2) The data attributes eightbit_data and tiny_data are listed under
   function attributes.

3) There is no documentation for the attributes "common" and

4) There is no documentation for the C++ attributes "com_interface"
   and "init_priority" in extend.texi, though init_priority is
   mentioned in invoke.texi.

5) Several attributes have documented lists of targets for which they
   are implemented, but those lists are incomplete, not mentioning
   some implemented targets:

        Attribute       Machines not documented
        =========       =======================
        interrupt       ARC, C4X, V850, m68hc11
        dllimport       ARM/pe, MCore, i386 Windows NT
        dllexport       ARM/pe, MCore, i386 Windows NT
        stdcall         ns32k
        cdecl           ns32k
        naked           MCore
        interrupt_handler   SH, V850

6) Several machine-specific attributes are not documented:

        Attribute       Machine
        =========       =======
        overlaid        VMS on Alpha
        isr             ARM
        progmem         AVR
        assembler       C4X
        leaf_pretend    C4X
        OS_Task         H8/300
        monitor         H8/300
        syscall_linkage IA64
        sp_switch       SH
        trap_exit       SH
        sda             V850
        tda             V850
        zda             V850
        trap            m68hc11

2.97 20001216 (experimental)

System: Linux decomino 2.2.18 #1 Thu Dec 14 19:30:45 UTC 2000 i686 unknown
Architecture: i686

host: i686-pc-linux-gnu
build: i686-pc-linux-gnu
target: i686-pc-linux-gnu
configured with: ../gcc-cvs/configure --prefix=/opt/gcc/snapshot --disable-shared --enable-threads=posix --with-system-zlib

Find undocumented attributes in the source code or alluded to in other
bits of documentation.
Comment 1 Joseph S. Myers 2000-12-16 15:36:00 UTC
Document all attributes, using machine-specific knowledge where
Comment 2 Alexandre Oliva 2001-06-12 19:08:33 UTC
State-Changed-From-To: open->analyzed
State-Changed-Why: Documented interrupt_handler, sp_switch and trap_exit.
Comment 3 Joseph S. Myers 2001-09-10 22:25:08 UTC
From: "Joseph S. Myers" <jsm28@cam.ac.uk>
To: <gcc-gnats@gcc.gnu.org>,  <gcc-bugs@gcc.gnu.org>
Subject: other/1078
Date: Mon, 10 Sep 2001 22:25:08 +0100 (BST)

 PR other/1078 lists problems with the documentation of various attributes.  
 The following is an update to the list there:
 init_priority is now documented.
 The SH attributes interrupt_handler, sp_switch and trap_exit are now
 The ARM attribute interfacearm, not on the previous list, is undocumented.
 The stormy16 attribute interrupt is not documented.
 Could the ARC, ARM, AVR, C4X, H8/300, IA64, i386, m68hc11, MCore, ns32k,
 stormy16 and V850 maintainers update the documentation in extend.texi
 relating to their targets' attributes?
 Joseph S. Myers
Comment 4 Andrew Pinski 2006-05-11 02:16:39 UTC
PR 27544 is about a missing docs for an attribute for RS6000, altivec.
PR 27543 is about ms_struct attribute on rs6000/PowerPC as it just says x86 supports it which is no longer true.
Comment 5 Eric Weddington 2007-07-25 17:05:43 UTC
Patch to document AVR progmem attribute:
Comment 6 Eric Weddington 2007-09-04 03:37:09 UTC
(In reply to comment #5)
> Patch to document AVR progmem attribute:
> http://gcc.gnu.org/ml/gcc-patches/2007-07/msg01832.html

Now committed:

This bug is fixed for the AVR target.