On Wed, 2010-06-30 at 11:09 +1000, Beau Henderson wrote:
> On 06/30/10 08:07, Paul Hartman wrote:
[...]
> > You can see which options -march=native would use by running this command:
> >
> > gcc -Q --help=target -march=native
> >
> > (thanks to Daniel Iliev for the tip)
> >
>
> Perhaps I'm missing something but running the above gives me the impression that -march=native
> actually only configures the bare minimal install. I'm not seeing -mmmx or -msse3 enabled on my
> k8-sse3 for instance ( amongst much else ).
>
-march sometimes implies a some things. E.g., anything above a pentium2
implies MMX. My hunch is that k8-sse3 implies... sse3.
06-30-2010, 02:26 PM
Paul Hartman
-march=native
On Tue, Jun 29, 2010 at 8:54 PM, Albert Hopkins <marduk@letterboxes.org> wrote:
> On Wed, 2010-06-30 at 11:09 +1000, Beau Henderson wrote:
>> On 06/30/10 08:07, Paul Hartman wrote:
> [...]
>> > You can see which options -march=native would use by running this command:
>> >
>> > gcc -Q --help=target -march=native
>> >
>> > (thanks to Daniel Iliev for the tip)
>> >
>>
>> Perhaps I'm missing something but running the above gives me the impression that -march=native
>> actually only configures the bare minimal install. I'm not seeing -mmmx or -msse3 enabled on my
>> k8-sse3 for instance ( amongst much else ).
>>
>
> -march sometimes implies a some things. E.g., anything above a pentium2
> implies MMX. My hunch is that k8-sse3 implies... sse3.
See this page of the GCC documentation for some info about what is
enabled in the different arches:
On Tue, Jun 29, 2010 at 8:09 PM, Beau Henderson <beau@thehenderson.com> wrote:
> On 06/30/10 08:07, Paul Hartman wrote:
>>
>> 2010/6/29 Hasan SAHIN<hasan.sahin@gmx.com>:
>>>
>>> Hello all,
>>>
>>> I am using Athlon64 X2 processor with the
>>> CFLAGS="-march=k8 -O2 -pipe -fomit-frame-pointer" option.
>>>
>>> Can I use the -march=native option instead of that?
>>
>> You can see which options -march=native would use by running this command:
>>
>> gcc -Q --help=target -march=native
>>
>> (thanks to Daniel Iliev for the tip)
>>
>
> Perhaps I'm missing something but running the above gives me the impression
> that -march=native actually only configures the bare minimal install. I'm
> not seeing -mmmx or -msse3 enabled on my k8-sse3 for instance ( amongst much
> else ).
What -march setting is it showing in that output? The MMX (etc) may be
enabled implicitly instead of explicitly.
It's also possible that the CPU detection is failing to identify your
CPU. In that case you could probably file a bug report about it.
06-30-2010, 10:21 PM
Beau Henderson
-march=native
On 07/01/10 00:30, Paul Hartman wrote:
On Tue, Jun 29, 2010 at 8:09 PM, Beau Henderson<beau@thehenderson.com> wrote:
On 06/30/10 08:07, Paul Hartman wrote:
2010/6/29 Hasan SAHIN<hasan.sahin@gmx.com>:
Hello all,
I am using Athlon64 X2 processor with the
CFLAGS="-march=k8 -O2 -pipe -fomit-frame-pointer" option.
Can I use the -march=native option instead of that?
You can see which options -march=native would use by running this command:
gcc -Q --help=target -march=native
(thanks to Daniel Iliev for the tip)
Perhaps I'm missing something but running the above gives me the impression
that -march=native actually only configures the bare minimal install. I'm
not seeing -mmmx or -msse3 enabled on my k8-sse3 for instance ( amongst much
else ).
What -march setting is it showing in that output? The MMX (etc) may be
enabled implicitly instead of explicitly.
It's also possible that the CPU detection is failing to identify your
CPU. In that case you could probably file a bug report about it.
The correct -march is being displayed, I just can't make sense of the options showing as [disabled].
While the option may be implied by the -march settings, it just makes sense to me that the option
should show as enabled. Indeed, with my core2 machine the majority of the options do display as
enable as expected, just not with my k8-see3 @native.
I wonder if perhaps it might be possible to compile an application that uses all these functions and
then assess ( somehow ) the binaries afterwards to see if they were compiled in and working correctly ?
Here's what I'm seeing on my k8-sse3: http://pastebin.com/PfMiTnx5
BH> The correct -march is being displayed, I just can't make sense of the
BH> options showing as [disabled]. While the option may be implied by the
BH> -march settings, it just makes sense to me that the option should show
BH> as enabled. Indeed, with my core2 machine the majority of the options
BH> do display as enable as expected, just not with my k8-see3 @native.
FWIW, a tests on -march=amdfam10 on both gentoo and debian also show odd
enabled/disabled results, as do debian k8-sse3 and core2 boxen. The
fedora core2 box I have access to, however, shows reasonable enableds.
Odd.
-JimC
--
James Cloos <cloos@jhcloos.com> OpenPGP: 1024D/ED7DAEA6