public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug inline-asm/29808]  New: [4.2 Regression] Error: suffix or operands invalid for `mov' when optimization is enabled
@ 2006-11-12  9:06 bero at arklinux dot org
  2006-11-12 11:10 ` [Bug inline-asm/29808] " segher at kernel dot crashing dot org
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: bero at arklinux dot org @ 2006-11-12  9:06 UTC (permalink / raw)
  To: gcc-bugs

The following code (extracted from the Linux kernel) fails to compile with
optimization enabled:

static void load_fs(unsigned short sel)
{
        asm("mov %0, %%fs" : : "g"(sel));
}

int main(int argc, char **argv)
{
        load_fs(0);
}


[bero@dhcppc1 arklinux]$ gcc test.c
[bero@dhcppc1 arklinux]$ gcc -O1 test.c
/tmp/ccSpA5Rm.s: Assembler messages:
/tmp/ccSpA5Rm.s:13: Error: suffix or operands invalid for `mov'

gcc is 4.2 SVN revision 118519 (20061106).


-- 
           Summary: [4.2 Regression] Error: suffix or operands invalid for
                    `mov' when optimization is enabled
           Product: gcc
           Version: 4.2.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: inline-asm
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: bero at arklinux dot org
 GCC build triplet: i586-pc-linux-gnu
  GCC host triplet: i586-pc-linux-gnu
GCC target triplet: i586-pc-linux-gnu


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


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

end of thread, other threads:[~2006-11-12 17:15 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2006-11-12  9:06 [Bug inline-asm/29808] New: [4.2 Regression] Error: suffix or operands invalid for `mov' when optimization is enabled bero at arklinux dot org
2006-11-12 11:10 ` [Bug inline-asm/29808] " segher at kernel dot crashing dot org
2006-11-12 13:27 ` rguenth at gcc dot gnu dot org
2006-11-12 13:40 ` bero at arklinux dot org
2006-11-12 14:01 ` segher at kernel dot crashing dot org
2006-11-12 17:15 ` pinskia at gcc dot gnu dot org

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).