amd64 arch and sse optimization

Reinhard Tartler siretart at gmail.com
Mon Feb 3 16:27:10 UTC 2014


On Mon, Feb 3, 2014 at 11:20 AM, Felipe Sateler <fsateler at debian.org> wrote:

>> Please note that Jaromir proposed to use the following flags:
>>
>> ifeq ($(DEB_HOST_ARCH_CPU),amd64)
>> CFLAGS += -msse -msse2 -mfpmath=sse
>> endif
>>
>>
>> None of them fall in the "mtune" category, that is, none of them are
>> "safe" to use without further precaution measures!
>
> Hmm, I'm now not sure if they help and are harmless. If sse is
> required by the amd64 spec, then gcc should enable it by default (in
> -O2?). I can't say if the previous is true.

Well, all amd64 machines do have SSE, so there is no point in GCC not
emitting SSE instructions. It is nevertheless pointless to explicitly
request GCC to do so, because our system compiler does that
automatically (and regardless of optimization levels).

If the switch would make a difference, it would be most likely be
"dangerous" to use (in the sense that it may break on some machines).

> Perhaps we should take
> this to a more knowledgeable audience? debian-devel or debian-gcc
> lists would be better, perhaps.

Feel free to forward this email to get more input on this.

-- 
regards,
    Reinhard



More information about the pkg-multimedia-maintainers mailing list