Subject: Re: [boost] [OT?] SIMD and Auto-Vectorization (was Re: How to structurate libraries ?)
From: David Abrahams (dave_at_[hidden])
Date: 2009-01-20 19:51:04
on Tue Jan 20 2009, "David A. Greene" <greened-AT-obbligato.org> wrote:
> On Tuesday 20 January 2009 06:58, David Abrahams wrote:
>> > Actually, I think you're missing the point (at least from what I'm
>> > saying).
>> > I'm saying SIMD code generation ought to be the job of the compiler(s)
>> > for the platforms where they make sense.
>> Why are these SIMD operations different in that respect from, say, large
>> matrix multiplications?
> A matrix multiplication is a higher-level construct. Still, most compilers
> will pattern-match matrix multiplication to an optimal routine.
Not hardly. No compiler is going to introduce register and cache-level
> SIMD code generation is extremely low-level.
> Programmers want to think in a
> higher level.
Naturally. But are the algorithms implemented by SIMD instructions
lower-level than std::for_each or std::accumulate? If not, maybe they
deserve to be in a library.
-- Dave Abrahams BoostPro Computing http://www.boostpro.com
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk