[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-kimageshop
Subject: Re: cpu detection
From: Andre Gemuend <scroogie () scroogie ! de>
Date: 2012-10-31 9:12:26
Message-ID: 5090EB7A.60109 () scroogie ! de
[Download RAW message or body]
On 10/30/2012 11:49 PM, JL VT wrote:
> On Mon, Oct 29, 2012 at 9:18 AM, Dmitry Kazakov <dimula73@gmail.com> wrot=
e:
>> Well, the integer solution might be quite good idea for some of the
>> composite ops. When I investigated into the topic, I thought about it, b=
ut I
>> faced with two problems I had no idea how to solve it:
>>
>> 1) The sse instruction set does not have integer division instruction. S=
o it
>> will have to be workarounded somehow.
>> 2) Integer multiplication instructions change the size of the operands. I
>> didn't know how to solve it properly.
> Forgive me if I say something completely out of place, but if you mean
> you get out-of-bond errors with integer multiplication, there are MMX
> operations that solve the bound problem by clipping values.
Yes, for multiplication you use a biased keep-low 16 bit unsigned =
multiplication (there is no keep high unsigned version) and subsequent =
shifts. It does not change the size of the operands (though you need to =
use 16 bit anyway).
But the division is not so easy. You either cast to float and back or =
have to implement your own division algorithm.
Greetings
Andr=E9
_______________________________________________
kimageshop mailing list
kimageshop@kde.org
https://mail.kde.org/mailman/listinfo/kimageshop
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic