Re: [eigen] Re: 4x4 matrix inverse |

[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]

*To*: eigen@xxxxxxxxxxxxxxxxxxx*Subject*: Re: [eigen] Re: 4x4 matrix inverse*From*: Hauke Heibel <hauke.heibel@xxxxxxxxxxxxxx>*Date*: Tue, 15 Dec 2009 10:46:11 +0100*Dkim-signature*: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type; bh=E3+nDKnuFKhPNBquoYNXWfiTuDn+ZQ57bK+IrMsiG/0=; b=gBRB5RpaGew5ot95O1vHsfqmvUc8JD4rPJ+zkvuYDS5igV519n+oTQgutHnwiXMkYH 3T8KCDtlbJOJZ7h09lo5FfuDYKdxZ/H01/wl+Tfv8aTQ1qUmCT8PMLWjB0e6FtqeIMPj 0wj7tMgQzK0jU/6XlWoP7wrLiUmTuxb2NzibI=*Domainkey-signature*: a=rsa-sha1; c=nofws; d=googlemail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; b=jhcUZxTYwigMW/0xUOiHwm+0Ku6hq/OGD9NI+6tcYfTO4q6aP80/2oVt1KMiKrRZxJ A2ViROeHptLogF2qNiYEyHphCJAWKDqGwbFa+JPd40+8MbwV/X/suL+abR+RFeVE1Z1U uWUNoc8TOPUUqaYtEey61AJYg+4m1p1aCXMA4=

On Tue, Dec 15, 2009 at 10:27 AM, Gael Guennebaud <gael.guennebaud@xxxxxxxxx> wrote:

Are the vectorized versions of sin and cos less precise? If not, why not always use vectorized sin and cos when vectorization is available and not explicitly disabled. I see ffast-fast and EIGEN_FAST_MATH as indications to go for approximating algorithms. Well, if that is already the case, then forget about this mail.

I am just asking since I think these (http://gruntthepeon.free.fr/ssemath/) SSE versions approximate only slightly but then they are still not IEEE compliant. Maybe in the end you are right and EIGEN_FAST_MATH indicates that we are not guaranteeing IEEE compliance anymore.

- Hauke

sorry what I said is wrong. So currently we have by default EIGEN_FAST_MATH==1, and defining EIGEN_FAST_MATH==0 disable the vectorized version of sin and cos. If we want to be safe I suggest the following rules:

1- set EIGEN_FAST_MATH==0 by default

2- if "-ffast-fast" and EIGEN_FAST_MATH is not defined then we set EIGEN_FAST_MATH==1

3- EIGEN_FAST_MATH==0 => no vectorized version of sin and cos and the use of _mm_sqrt_p* for ei_psqrt

4- EIGEN_FAST_MATH==1 => vectorized version of sin and cos + the use of an optimized version of ei_psqrt

Are the vectorized versions of sin and cos less precise? If not, why not always use vectorized sin and cos when vectorization is available and not explicitly disabled. I see ffast-fast and EIGEN_FAST_MATH as indications to go for approximating algorithms. Well, if that is already the case, then forget about this mail.

I am just asking since I think these (http://gruntthepeon.free.fr/ssemath/) SSE versions approximate only slightly but then they are still not IEEE compliant. Maybe in the end you are right and EIGEN_FAST_MATH indicates that we are not guaranteeing IEEE compliance anymore.

- Hauke

**References**:**[eigen] 4x4 matrix inverse***From:*Benoit Jacob

**[eigen] Re: 4x4 matrix inverse***From:*Benoit Jacob

**Re: [eigen] Re: 4x4 matrix inverse***From:*Hauke Heibel

**Re: [eigen] Re: 4x4 matrix inverse***From:*Gael Guennebaud

**Re: [eigen] Re: 4x4 matrix inverse***From:*Gael Guennebaud

**Messages sorted by:**[ date | thread ]- Prev by Date:
**Re: [eigen] Re: 4x4 matrix inverse** - Next by Date:
**Re: [eigen] Re: 4x4 matrix inverse** - Previous by thread:
**Re: [eigen] Re: 4x4 matrix inverse** - Next by thread:
**Re: [eigen] Re: 4x4 matrix inverse**

Mail converted by MHonArc 2.6.19+ | http://listengine.tuxfamily.org/ |