[eigen] Re: SSE square root |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/eigen Archives
]
- To: eigen@xxxxxxxxxxxxxxxxxxx
- Subject: [eigen] Re: SSE square root
- From: Rohit Garg <rpg.314@xxxxxxxxx>
- Date: Fri, 27 Mar 2009 14:07:07 +0530
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:content-type :content-transfer-encoding; bh=fAV/vPY1qSHL8w1+0iCQj9oa5O0+kINOipDBcHw53cQ=; b=CmXqr/D5rndPDjJdvdA4sYbwBOPKHP93V8DDS116daEt4GcKCfg7gb6nkFNhkUfwSX k7a9bjdwYfmA14wmQllbqfBDsUr5RNA8Nnp/Svdb3g4JbFtGMSGUk3LQlKFukWQmX2/l GKbFCwC9R6NINh7ni1uEkNRR+WR0m8acD/K0s=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type:content-transfer-encoding; b=PK/LV1BZ4wCZU+EvwkXCIMfj+SqKtmTeCELuZRkAfhXgGhjwBRjiQdpVN4+p7VL54Q Tu5MR9dgIN4zTgPzMz1VITybib4JLke/hT2UPoQaNiVAYRyK7UMus3N178K9IfAdvngB UasXFkuWe8UkNu5onskqROaVyT7nKzGyzHQ4g=
I compared the absolute accuracy in the [0,1] interval and I found
that only one iteration is enough for accuracy purposes, which seems
about right.
On Fri, Mar 27, 2009 at 1:02 PM, Rohit Garg <rpg.314@xxxxxxxxx> wrote:
> This file has my sse float implementation for square root. The SSE
> square root instruction has only 12 bits of precision so extra
> iterations of Newton Raphson may be neccessary. How many of the are
> neccessary, I don't know. the max error I was getting was O(1e-8) in
> [0,1]. The cephes implementation has square root only for limited
> range. They do some other hacks to take care of range. I'll look into
> implementing those later. For now, this should be an acceptable for
> the fast implementations of square root atleast.
>
> Regards,
>
> --
> Rohit Garg
>
> http://rpg-314.blogspot.com/
>
> Senior Undergraduate
> Department of Physics
> Indian Institute of Technology
> Bombay
>
--
Rohit Garg
http://rpg-314.blogspot.com/
Senior Undergraduate
Department of Physics
Indian Institute of Technology
Bombay