On Thu, Jul 10, 2003 at 01:17:49PM +0200, Sven Neumann <[EMAIL PROTECTED]> wrote:
>   __asm__ __volatile__ ()
> while the new code in The GIMP seems to be using
>   asm()
> I don't know this stuff good enough to know the difference, but I'd

__keyword__-style keywords are always there, even if gcc extensions should
be disabled (strict ansi mode etc..

volatile means that there are side effects that are not (or can not) be
properly specified. unless you write a kernel or other arcane magic, the
need to use volatile indicates a bug in the constraints (i.e. forgetting
to tell the compiler properly about the effects of the statement).

for example, gcc will happily optimize away an asm() if the output
operands aren't used, as it can then assume that the computing isn't
necessary. volatile will keep it from doing that, but that might also keep
useful optimizations from doing their work.

      -----==-                                             |
      ----==-- _                                           |
      ---==---(_)__  __ ____  __       Marc Lehmann      +--
      --==---/ / _ \/ // /\ \/ /       [EMAIL PROTECTED]      |e|
      -=====/_/_//_/\_,_/ /_/\_\       XX11-RIPE         --+
    The choice of a GNU generation                       |
Gimp-developer mailing list

Reply via email to