<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "http://bugs.gentoo.org/bugzilla.dtd">

<bugzilla version="2.22.7"
          urlbase="http://bugs.gentoo.org/"
          maintainer="bugzilla@gentoo.org"
>

    <bug>
          <bug_id>108417</bug_id>
          
          <creation_ts>2005-10-07 11:52 0000</creation_ts>
          <short_desc>media-video/mjpegtools-1.8.0: enable-simd-accel works for amd64</short_desc>
          <delta_ts>2005-11-01 12:48:10 0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Gentoo Linux</product>
          <component>Applications</component>
          <version>unspecified</version>
          <rep_platform>AMD64</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>j.romildo@gmail.com</reporter>
          <assigned_to>amd64@gentoo.org</assigned_to>
          

      

      
          <long_desc isprivate="0">
            <who>j.romildo@gmail.com</who>
            <bug_when>2005-10-07 11:52:02 0000</bug_when>
            <thetext>One of the improvements of the new mjpegtools version (1.8.0) is assembly
optimizations (simd-accel) for amd64. But on the ebuild in portage, it is enable
only for the x86 arch. Please, enable simd-accel also for amd64. I have been
using it on my Athlon64 machine for some months now (from CVS and now with the
released version), and it works for me.

Reproducible: Always
Steps to Reproduce:</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>j.romildo@gmail.com</who>
            <bug_when>2005-10-07 12:17:49 0000</bug_when>
            <thetext>I have been using mjpegtools-1.8.0 (and prior release candidates) on amd64,
compiled with enable-simd-accel and without the flag -mno-sse2 with gcc-3.4.4,
without problems. So, I believe that the ebuild line

    [[ $(gcc-major-version) -eq 3 ]] &amp;&amp; append-flags -mno-sse2

(which is already executed for the x86 arch) should not be aplied to the amd64 arch.
</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>j.romildo@gmail.com</who>
            <bug_when>2005-10-07 12:21:43 0000</bug_when>
            <thetext>Created an attachment (id=70111)
mjpegtools-1.8.0.ebuild.diff

Here is my patch for mjpegtools-1.8.0.ebuild from portage. It will use the
following configure options with the amd64 arch:

   --enable-simd-accel
   --enable-cmov-extension</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>blubb@gentoo.org</who>
            <bug_when>2005-10-07 15:41:27 0000</bug_when>
            <thetext>Created an attachment (id=70121)
patch including dependencies

i think we need a dependency upon nasm too, since the amd64 masks all assembler
use flags. can&apos;t test it though as avifile doesn&apos;t build here :/</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>j.romildo@gmail.com</who>
            <bug_when>2005-10-07 19:19:14 0000</bug_when>
            <thetext>I do not think nasm is needed. Without nasm installed on my system, I get the
following from configure:

[...]
checking if C compiler accepts inline MMX assembly... yes
[...]
configure:  MJPEG tools 1.8.0 build configuration :
configure:
configure:   - X86 Optimizations:
configure:     - MMX/3DNow!/SSE enabled      : true
configure:   - arch/cpu compiler flags       : -march=x86-64 -mcpu=x86-64
[...]

Regardless of nasm being installed on my system, it is not mentioned on the
output of &quot;emerge -v mjpegtools&quot;.

So, I believe nasm is neither needed nor used for SIMD multimedia instructions
on amd64, and the dependency on nasm is wrong.

The assembly use flags (mmx, sse, ...) is not used to enable the optimizations.
They are _always_ enabled with the enable-simd-accel option for the amd64 arch.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>blubb@gentoo.org</who>
            <bug_when>2005-10-08 02:20:23 0000</bug_when>
            <thetext>(From update of attachment 70111)
oh well, sorry then :)
</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>blubb@gentoo.org</who>
            <bug_when>2005-11-01 12:48:10 0000</bug_when>
            <thetext>-r1 enables SIMD, thanks for the patch!</thetext>
          </long_desc>
      
          <attachment
              isobsolete="0"
              ispatch="1"
              isprivate="0"
          >
            <attachid>70111</attachid>
            <date>2005-10-07 12:21 0000</date>
            <desc>mjpegtools-1.8.0.ebuild.diff</desc>
            <filename>mjpegtools-1.8.0.ebuild.diff</filename>
            <type>text/plain</type>
            <data encoding="base64">LS0tIC91c3IvcG9ydGFnZS9tZWRpYS12aWRlby9tanBlZ3Rvb2xzL21qcGVndG9vbHMtMS44LjAu
ZWJ1aWxkCTIwMDUtMTAtMDUgMDU6MDY6MzIuMDAwMDAwMDAwIC0wMzAwCisrKyAvdXNyL2xvY2Fs
L3BvcnRhZ2UvbWVkaWEtdmlkZW8vbWpwZWd0b29scy9tanBlZ3Rvb2xzLTEuOC4wLmVidWlsZAky
MDA1LTEwLTA3IDE2OjExOjA3LjAwMDAwMDAwMCAtMDMwMApAQCAtNjksNiArNjksMTEgQEAKIAkJ
W1sgJChnY2MtbWFqb3ItdmVyc2lvbikgLWVxIDMgXV0gJiYgYXBwZW5kLWZsYWdzIC1tbm8tc3Nl
MgogCWZpCiAKKwlpZiB1c2UgYW1kNjQ7IHRoZW4KKwkJbXljb25mPSIke215Y29uZn0gLS1lbmFi
bGUtc2ltZC1hY2NlbCIKKwkJbXljb25mPSIke215Y29uZn0gLS1lbmFibGUtY21vdi1leHRlbnNp
b24iCisJZmkKKwogCWVjb25mIFwKIAkJJCh1c2Vfd2l0aCBYIHgpIFwKIAkJJCh1c2VfZW5hYmxl
IGRnYSB4ZnJlZS1leHQpIFwK
</data>        

          </attachment>
          <attachment
              isobsolete="1"
              ispatch="1"
              isprivate="0"
          >
            <attachid>70121</attachid>
            <date>2005-10-07 15:41 0000</date>
            <desc>patch including dependencies</desc>
            <filename>mjpegtools-1.8.0-simd.patch</filename>
            <type>text/plain</type>
            <data encoding="base64">ZGlmZiAtdSAtYiAtQiAtcjEuMSBtanBlZ3Rvb2xzLTEuOC4wLmVidWlsZAotLS0gbWpwZWd0b29s
cy0xLjguMC5lYnVpbGQgICAgIDUgT2N0IDIwMDUgMDg6MDY6MzIgLTAwMDAgICAgICAgMS4xCisr
KyBtanBlZ3Rvb2xzLTEuOC4wLmVidWlsZCAgICAgNyBPY3QgMjAwNSAyMjozNDoxOSAtMDAwMApA
QCAtMjgsMTAgKzI4LDEwIEBACiAgICAgICAgWD8gKCB2aXJ0dWFsL3gxMSApIgoKIERFUEVORD0i
JHtSREVQRU5EfQotICAgICAgIHg4Nj8gKCBtbXg/ICggZGV2LWxhbmcvbmFzbSApCisgICAgICAg
bW14PyAoIGRldi1sYW5nL25hc20gKQogICAgICAgICAgICAgICAgM2Rub3c/ICggZGV2LWxhbmcv
bmFzbSApCiAgICAgICAgICAgICAgICBzc2U/ICggZGV2LWxhbmcvbmFzbSApCi0gICAgICAgICAg
ICAgICApCisgICAgICAgYW1kNjQ/ICggZGV2LWxhbmcvbmFzbSApCiAgICAgICAgPj1zeXMtYXBw
cy9zZWQtNAogICAgICAgIHN5cy1kZXZlbC9hdXRvY29uZgogICAgICAgID1zeXMtZGV2ZWwvYXV0
b21ha2UtMS41KiIKQEAgLTY5LDYgKzY5LDEwIEBACiAgICAgICAgICAgICAgICBbWyAkKGdjYy1t
YWpvci12ZXJzaW9uKSAtZXEgMyBdXSAmJiBhcHBlbmQtZmxhZ3MgLW1uby1zc2UyCiAgICAgICAg
ZmkKCisgICAgICAgaWYgdXNlIGFtZDY0OyB0aGVuCisgICAgICAgICAgICAgICBteWNvbmY9IiR7
bXljb25mfSAtLWVuYWJsZS1zaW1kLWFjY2VsIgorICAgICAgIGZpCisKICAgICAgICBlY29uZiBc
CiAgICAgICAgICAgICAgICAkKHVzZV93aXRoIFggeCkgXAogICAgICAgICAgICAgICAgJCh1c2Vf
ZW5hYmxlIGRnYSB4ZnJlZS1leHQpIFwK
</data>        

          </attachment>
    </bug>

</bugzilla>