Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 292811 - media-video/ffmpeg should SSE3 flag be forced enabled?
Summary: media-video/ffmpeg should SSE3 flag be forced enabled?
Status: RESOLVED INVALID
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: High minor (vote)
Assignee: Gentoo Linux bug wranglers
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-11-11 16:20 UTC by Marcin Mirosław
Modified: 2009-11-12 18:55 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Marcin Mirosław 2009-11-11 16:20:35 UTC
In ebuild variable IUSE has +ssse3. On AMD64 it's ok, but when somebody is using older processor and x86 arch this isn't right.
At AMD64 SIMD flags are provided from profile so there is no reason to use +sse3 in IUSE. x86 profiles are designed for older arch, which often can't execute sse3 instructions.
I think it's isn't safe idea to forced enabled SSE3.

Reproducible: Always
Comment 1 Rafał Mużyło 2009-11-11 16:33:25 UTC
Look at the ebuild first -
those flags are treated differently than usual,
ebuild doesn't enable anything, it just disables
stuff once flags are unset. It's caused by the custom build system
of ffmpeg. Standard build automagically detects your processor features
and you have only an option to disable them, once detected.
Comment 2 Marcin Mirosław 2009-11-11 17:21:47 UTC
I'm not sure yet. Look at this:
# emerge -1 ffmpeg
[...]
C compiler                i686-pc-linux-gnu-gcc
.align is power-of-two    no
ARCH                      x86 (athlon-4)
big-endian                no
runtime cpu detection     no
yasm                      yes
MMX enabled               yes
MMX2 enabled              yes
3DNow! enabled            yes
3DNow! extended enabled   yes
SSE enabled               yes
SSSE3 enabled             yes
CMOV enabled              yes

#  USE="-ssse3" emerge -v1 ffmpeg
[...]
>>> Configuring source in /var/tmp/portage/media-video/ffmpeg-0.5_p20373/work/ffmpeg-0.5_p20373 ...
true
install prefix            /usr
source path               /var/tmp/portage/media-video/ffmpeg-0.5_p20373/work/ffmpeg-0.5_p20373
C compiler                i686-pc-linux-gnu-gcc
.align is power-of-two    no
ARCH                      x86 (athlon-4)
big-endian                no
runtime cpu detection     no
yasm                      yes
MMX enabled               yes
MMX2 enabled              yes
3DNow! enabled            yes
3DNow! extended enabled   yes
SSE enabled               yes
SSSE3 enabled             no

And i have not neither set or unset "ssse3" flag in make.conf .
Probably ffmpeg will work correctly with ssse3 enabled, but i'm not sure if sse3 instruction are not used.
Comment 3 Marcin Mirosław 2009-11-11 20:42:42 UTC
# emerge -1 ffmpeg
# ls -l /usr/lib/libavcodec.so.52.37.1
-rwxr-xr-x 1 root root 5440804 11-11 21:13 /usr/lib/libavcodec.so.52.37.1
# USE="-ssse3" emerge -1 ffmpeg
# ls -l /usr/lib/libavcodec.so.52.37.1
-rwxr-xr-x 1 root root 5465380 11-11 18:33 libavcodec.so.52.37.1

Sizes are diffrent.
Comment 4 Rafał Mużyło 2009-11-12 18:55:54 UTC
(In reply to comment #3)
> # emerge -1 ffmpeg
> # ls -l /usr/lib/libavcodec.so.52.37.1
> -rwxr-xr-x 1 root root 5440804 11-11 21:13 /usr/lib/libavcodec.so.52.37.1
> # USE="-ssse3" emerge -1 ffmpeg
> # ls -l /usr/lib/libavcodec.so.52.37.1
> -rwxr-xr-x 1 root root 5465380 11-11 18:33 libavcodec.so.52.37.1
> 
> Sizes are diffrent.
> 
As they should be.
Read bug 265089.