public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug inline-asm/54450] New: Extended asm in global scope
@ 2012-09-01 10:07 just.serejko at gmail dot com
  2012-09-01 10:10 ` [Bug inline-asm/54450] " just.serejko at gmail dot com
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: just.serejko at gmail dot com @ 2012-09-01 10:07 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54450

             Bug #: 54450
           Summary: Extended asm in global scope
    Classification: Unclassified
           Product: gcc
           Version: 4.6.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: inline-asm
        AssignedTo: unassigned@gcc.gnu.org
        ReportedBy: just.serejko@gmail.com


This code compiles fine:

    __asm__ (
        "my_function:\n\t"
        "jmp *%eax\n\t"
    );

but this doesn't:

    void *ptr;

    __asm__ (
        "my_function:\n\t"
        "jmp *%0\n\t" : : "r"(ptr)
    );

error: expected ')' before ':' token (on the jmp line)


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug inline-asm/54450] Extended asm in global scope
  2012-09-01 10:07 [Bug inline-asm/54450] New: Extended asm in global scope just.serejko at gmail dot com
@ 2012-09-01 10:10 ` just.serejko at gmail dot com
  2012-09-01 10:59 ` polacek at redhat dot com
                   ` (3 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: just.serejko at gmail dot com @ 2012-09-01 10:10 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54450

Sergey Zolotarev <just.serejko at gmail dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Target|                            |x86
               Host|                            |x86

--- Comment #1 from Sergey Zolotarev <just.serejko at gmail dot com> 2012-09-01 10:10:25 UTC ---
I'd be happy to use __attribute__((naked)) but it's not supported on x86 for
some reason.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug inline-asm/54450] Extended asm in global scope
  2012-09-01 10:07 [Bug inline-asm/54450] New: Extended asm in global scope just.serejko at gmail dot com
  2012-09-01 10:10 ` [Bug inline-asm/54450] " just.serejko at gmail dot com
@ 2012-09-01 10:59 ` polacek at redhat dot com
  2012-09-01 11:10 ` polacek at redhat dot com
                   ` (2 subsequent siblings)
  4 siblings, 0 replies; 6+ messages in thread
From: polacek at redhat dot com @ 2012-09-01 10:59 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54450

Marek Polacek <polacek at redhat dot com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |polacek at redhat dot com

--- Comment #2 from Marek Polacek <polacek at redhat dot com> 2012-09-01 10:59:21 UTC ---
Probably dup of http://gcc.gnu.org/bugzilla/show_bug.cgi?id=41045


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug inline-asm/54450] Extended asm in global scope
  2012-09-01 10:07 [Bug inline-asm/54450] New: Extended asm in global scope just.serejko at gmail dot com
  2012-09-01 10:10 ` [Bug inline-asm/54450] " just.serejko at gmail dot com
  2012-09-01 10:59 ` polacek at redhat dot com
@ 2012-09-01 11:10 ` polacek at redhat dot com
  2012-09-01 12:44 ` just.serejko at gmail dot com
  2012-09-01 13:16 ` polacek at redhat dot com
  4 siblings, 0 replies; 6+ messages in thread
From: polacek at redhat dot com @ 2012-09-01 11:10 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54450

--- Comment #3 from Marek Polacek <polacek at redhat dot com> 2012-09-01 11:10:10 UTC ---
Also, __attribute__((naked)) for x86 will never be implemented.


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug inline-asm/54450] Extended asm in global scope
  2012-09-01 10:07 [Bug inline-asm/54450] New: Extended asm in global scope just.serejko at gmail dot com
                   ` (2 preceding siblings ...)
  2012-09-01 11:10 ` polacek at redhat dot com
@ 2012-09-01 12:44 ` just.serejko at gmail dot com
  2012-09-01 13:16 ` polacek at redhat dot com
  4 siblings, 0 replies; 6+ messages in thread
From: just.serejko at gmail dot com @ 2012-09-01 12:44 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54450

--- Comment #4 from Sergey Zolotarev <just.serejko at gmail dot com> 2012-09-01 12:43:52 UTC ---
> Also, __attribute__((naked)) for x86 will never be implemented.

May I ask why?


^ permalink raw reply	[flat|nested] 6+ messages in thread

* [Bug inline-asm/54450] Extended asm in global scope
  2012-09-01 10:07 [Bug inline-asm/54450] New: Extended asm in global scope just.serejko at gmail dot com
                   ` (3 preceding siblings ...)
  2012-09-01 12:44 ` just.serejko at gmail dot com
@ 2012-09-01 13:16 ` polacek at redhat dot com
  4 siblings, 0 replies; 6+ messages in thread
From: polacek at redhat dot com @ 2012-09-01 13:16 UTC (permalink / raw)
  To: gcc-bugs

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54450

--- Comment #5 from Marek Polacek <polacek at redhat dot com> 2012-09-01 13:15:46 UTC ---
(In reply to comment #4)
> May I ask why?

See e.g. http://gcc.gnu.org/ml/gcc/2004-02/msg00943.html


^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2012-09-01 13:16 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-09-01 10:07 [Bug inline-asm/54450] New: Extended asm in global scope just.serejko at gmail dot com
2012-09-01 10:10 ` [Bug inline-asm/54450] " just.serejko at gmail dot com
2012-09-01 10:59 ` polacek at redhat dot com
2012-09-01 11:10 ` polacek at redhat dot com
2012-09-01 12:44 ` just.serejko at gmail dot com
2012-09-01 13:16 ` polacek at redhat dot com

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).