Re: [eigen] NEON PacketMath.h questions
• To: eigen@xxxxxxxxxxxxxxxxxxx
• Subject: Re: [eigen] NEON PacketMath.h questions
• From: Josh Bleecher Snyder <josharian@xxxxxxxxx>
• Date: Wed, 4 Jul 2012 10:03:05 -0700
• Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :content-type; bh=SIbJZN7YHa1KNwPPBSINpcsy9h7JNOwU9RKkE9fQgrQ=; b=sD0u+opxLMBpKi9iyZrsImVi5nkq/+DYLv5IAQ4tnxIQIJVnM1s7R4gz7NevyfJn2T oca8BY+8nVuaKdwSu8GKV6n9X1XHrhjQ/4Om5ZIEit7Nm1KgsLGU/kQjc7Rjs979ZTAP oW6nTGIvlz3kwjlUMgdF2Ulxq0RINkX04l+vovKwkuweDWCNbVEugH9tCJ4RLGJX000p b54mVafsN36+w16Pe8wGal+almDNZhwiluSxp7bwX89J3AqVPn6QcWPgGTSHWF5WOnk+ 38lBHvAu/8lg0TY7e8tPZ1mul7rFgMKX4zAIJpDK/IDF9yVURQjg9M3Yv/Onl2k5rxvp TJ4w==

```>> One could also force the use of the vmla instruction via inline
>> assembly. This would require distinguishing multiply+add (return a
>> value) from multiply+accumulate (modify one of the inputs).
>> Multiply+accumulate is extremely common in gemm/gemv and probably
>> worth optimizing for. I'm willing to take a crack at adding such a
>> method (pmacc? pmadd_inplace? pfma?), although I might need a few
>> pointers -- I'm new to both C++ templating and Eigen -- and would
>> probably need help with SSE/AltiVec. So before I start on it: Is there
>> interest in such an addition?
>
> Don't worry, when we do c = pmadd(a,b,c), then the compiler is smart
> enough to recognize that 'c' is on both sides and that we are doing an
> accumulation. No need for a specific path here.

Yep, totally. I was just contemplating this as a means to work around
the current compiler shortcomings when it comes to NEON. I'll go
pester the compiler folks about it instead, though -- that's the right
fix. :)

>> (3)
>>
>> Is there a good way to run the existing Eigen unit tests on an iOS or
>> Android device? (E.g. is there an Xcode-friendly test wrapper? Is
>> there interest in one?) I don't have -- or intend to acquire -- a
>> beagle board, so testing NEON changes is currently a bit manual and ad
>> hoc.
>
> There is clearly a need for a simple way to test Eigen on iOS.

IIRC, cmake can generate Xcode projects, so that's a start, but it
takes extra work to make tests that run on a device instead of the
simulator. Anyway, will see what I can do...

-josh

```

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