public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug target/35599]  New: gcc --target-help on x86[-64] lists invalid values for -march/-mtune
@ 2008-03-15 18:53 dirtyepic at gentoo dot org
  2008-03-15 21:59 ` [Bug target/35599] " ubizjak at gmail dot com
  0 siblings, 1 reply; 2+ messages in thread
From: dirtyepic at gentoo dot org @ 2008-03-15 18:53 UTC (permalink / raw)
  To: gcc-bugs

dirtyepic@tycho ~/work $ gcc --target-help

[...]
  -march=CPU/-mtune=CPU   generate code/optimize for CPU, where CPU is one of:
                           i386, i486, pentium, pentiumpro, pentium4, nocona,
                           core, core2, k6, athlon, k8, generic32, generic64
[...]

dirtyepic@tycho ~/work $ touch temp.c
dirtyepic@tycho ~/work $ for t in i386 i486 pentium pentiumpro pentium4 nocona
core core2 k6 athlon k8 generic32 generic64; do gcc -c -mtune=$t temp.c; done
temp.c:1: error: bad value (core) for -mtune= switch
temp.c:1: error: bad value (generic32) for -mtune= switch
temp.c:1: error: bad value (generic64) for -mtune= switch
dirtyepic@tycho ~/work $ gcc -v
Using built-in specs.
Target: i686-pc-linux-gnu
Configured with:
/var/tmp/portage/sys-devel/gcc-4.3.1_pre20080314/work/gcc-4.3.1-20080314/configure
--prefix=/usr --bindir=/usr/i686-pc-linux-gnu/gcc-bin/4.3.1-pre20080314
--includedir=/usr/lib/gcc/i686-pc-linux-gnu/4.3.1-pre20080314/include
--datadir=/usr/share/gcc-data/i686-pc-linux-gnu/4.3.1-pre20080314
--mandir=/usr/share/gcc-data/i686-pc-linux-gnu/4.3.1-pre20080314/man
--infodir=/usr/share/gcc-data/i686-pc-linux-gnu/4.3.1-pre20080314/info
--with-gxx-include-dir=/usr/lib/gcc/i686-pc-linux-gnu/4.3.1-pre20080314/include/g++-v4
--host=i686-pc-linux-gnu --build=i686-pc-linux-gnu --disable-altivec
--disable-nls --with-system-zlib --disable-checking --disable-werror
--enable-secureplt --disable-libunwind-exceptions --disable-multilib
--disable-libmudflap --disable-libssp --disable-libgcj --with-arch=i686
--enable-languages=c,c++,treelang --enable-shared --enable-threads=posix
--enable-__cxa_atexit --enable-clocale=gnu --enable-linux-futex
Thread model: posix
gcc version 4.3.1-pre20080314  (Gentoo SVN ebuild) r133233 (GCC)


and with 4.2 which lists the same values in --target-help:

dirtyepic@tycho ~/work $ for t in i386 i486 pentium pentiumpro pentium4 nocona
core core2 k6 athlon k8 generic32 generic64; do gcc-4.2.4-pre20080223 -c
-mtune=$t temp.c; done
temp.c:1: error: bad value (core) for -mtune= switch
temp.c:1: error: bad value (core2) for -mtune= switch
temp.c:1: error: bad value (generic32) for -mtune= switch
temp.c:1: error: bad value (generic64) for -mtune= switch
dirtyepic@tycho ~/work $ gcc-4.2.4-pre20080223 -v
Using built-in specs.
Target: i686-pc-linux-gnu
Configured with:
/var/tmp/portage/sys-devel/gcc-4.2.4_pre20080223/work/gcc-4.2.4-20080223/configure
--prefix=/usr --bindir=/usr/i686-pc-linux-gnu/gcc-bin/4.2.4-pre20080223
--includedir=/usr/lib/gcc/i686-pc-linux-gnu/4.2.4-pre20080223/include
--datadir=/usr/share/gcc-data/i686-pc-linux-gnu/4.2.4-pre20080223
--mandir=/usr/share/gcc-data/i686-pc-linux-gnu/4.2.4-pre20080223/man
--infodir=/usr/share/gcc-data/i686-pc-linux-gnu/4.2.4-pre20080223/info
--with-gxx-include-dir=/usr/lib/gcc/i686-pc-linux-gnu/4.2.4-pre20080223/include/g++-v4
--host=i686-pc-linux-gnu --build=i686-pc-linux-gnu --disable-altivec
--disable-nls --with-system-zlib --disable-checking --disable-werror
--enable-secureplt --disable-libunwind-exceptions --disable-multilib
--disable-libmudflap --disable-libssp --disable-libgcj --with-arch=i686
--enable-languages=c,c++,treelang --enable-shared --enable-threads=posix
--enable-__cxa_atexit --enable-clocale=gnu --enable-linux-futex
Thread model: posix
gcc version 4.2.4-pre20080223  (prerelease) (rev. 132578)


-- 
           Summary: gcc --target-help on x86[-64] lists invalid values for -
                    march/-mtune
           Product: gcc
           Version: 4.3.1
            Status: UNCONFIRMED
          Severity: trivial
          Priority: P3
         Component: target
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: dirtyepic at gentoo dot org


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


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

* [Bug target/35599] gcc --target-help on x86[-64] lists invalid values for -march/-mtune
  2008-03-15 18:53 [Bug target/35599] New: gcc --target-help on x86[-64] lists invalid values for -march/-mtune dirtyepic at gentoo dot org
@ 2008-03-15 21:59 ` ubizjak at gmail dot com
  0 siblings, 0 replies; 2+ messages in thread
From: ubizjak at gmail dot com @ 2008-03-15 21:59 UTC (permalink / raw)
  To: gcc-bugs



------- Comment #1 from ubizjak at gmail dot com  2008-03-15 21:58 -------
This info is from assembler (as):

$ as --target-help
  -Q                      ignored
  -V                      print assembler version number
  -k                      ignored
  -n                      Do not optimize code alignment
  -q                      quieten some warnings
  -s                      ignored
  --32/--64               generate 32bit/64bit code
  --divide                ignored
  -march=CPU/-mtune=CPU   generate code/optimize for CPU, where CPU is one of:
                           i386, i486, pentium, pentiumpro, pentium4, nocona,
                           core, core2, k6, athlon, k8, generic32, generic64

It would be nice, if assembler displayed something like linker does:

Linker options
==============

Use "-Wl,OPTION" to pass "OPTION" to the linker.
...


-- 

ubizjak at gmail dot com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
             Status|UNCONFIRMED                 |RESOLVED
         Resolution|                            |INVALID


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


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

end of thread, other threads:[~2008-03-15 21:59 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-03-15 18:53 [Bug target/35599] New: gcc --target-help on x86[-64] lists invalid values for -march/-mtune dirtyepic at gentoo dot org
2008-03-15 21:59 ` [Bug target/35599] " ubizjak at gmail 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).