Re: immediate operands without dollar sign for inline asm

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Dec 16, 2013 at 10:47 PM, Florian Weimer <fweimer@xxxxxxxxxx> wrote:
> Isn't it specific to a subset of all the architectures?  If it's generic, it
> makes sense to add it to the Extended Asm documentation.

If I am to give opinion, here it is:

I have only used the x86/x64 architecture so far and don't know if it
is architecture specific or generic.
AFAIK the $ sign for immediate operands is for all architectures, so
i'd guess the feature is generic.

This feature is not a constraint modifier and has nothing to do with
the constraints because it is written in the assembly string itself
and not in the constraint descriptor string:
    asm ( "... %0 ..." : "+r" (...) : ); // the '+' here is a
constraint modifier
    asm ( "... %a0 ..." : : "i" (...) ); // the 'a' here is NOT a
constraint modifier
so I would say it's documentation should be located in Extended Asm
(or probably in a new section about "operand modifiers" or whatever
they are called) but not in the constraint section.

Best regards
Lucho.




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux