[Bug c/108134] New: A description bug for Extended Asm document

liweifriends at gmail dot com gcc-bugzilla@gcc.gnu.org
Thu Dec 15 18:58:14 GMT 2022


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=108134

            Bug ID: 108134
           Summary: A description bug for Extended Asm document
           Product: gcc
           Version: unknown
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: c
          Assignee: unassigned at gcc dot gnu.org
          Reporter: liweifriends at gmail dot com
  Target Milestone: ---

In document
(https://github.com/gcc-mirror/gcc/blob/master/gcc/doc/extend.texi), there are
the following description:

The rest of this discussion uses the following code for illustrative purposes.

```
int main()
{
   int iInt = 1;

top:

   asm volatile goto ("some assembler instructions here"
   : /* No outputs. */
   : "q" (iInt), "X" (sizeof(unsigned char) + 1), "i" (42)
   : /* No clobbers. */
   : top);
}

With no modifiers, this is what the output from the operands would be for the
‘att’ and ‘intel’ dialects of assembler:
Operand ‘att’   ‘intel’
%0      %eax    eax
%1      $2      2
%3      $.L3    OFFSET FLAT:.L3
%4      $8      8
%5      %xmm0   xmm0
%7      $0      0
```

However, for the inline asm code, there is no %4, %5, and %7 at all. And in the
following table, it also shows something like "%y6", but there is no %6 at all.
So the reader cannot understand the meaning of them.


More information about the Gcc-bugs mailing list