Boost logo

Boost :

Subject: Re: [boost] Boost SIMD beta release
From: Domagoj Saric (dsaritz_at_[hidden])
Date: 2012-12-24 10:56:29


"Mathias Gaunard" wrote in message news:50D2F8D1.2030900_at_ens-lyon.org...
> While this works, if you do this you won't be able to use lazy branch
> evaluation in the scalar version.
>
> If you write
>
> c = if_else(a != 0, b/a, b);
>
> this is equivalent in scalar to
>
> c = (a != 0) ? b/a : b;
>
> except that in the case above you will always compute the division.

As mentinoned here https://github.com/MetaScale/nt2/issues/379, it should be
(re)considered whether this scalar-if special handling actually brings any
benefit (or it might actually even be a pessimization in the majority of
cases)...

-- 
"What Huxley teaches is that in the age of advanced technology, spiritual
devastation is more likely to come from an enemy with a smiling face than
from one whose countenance exudes suspicion and hate."
Neil Postman 

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk