Ask Your Question
0

Neon support for basic matrix operations

asked 2017-10-22 06:28:18 -0600

NadavB gravatar image

Is there a Neon support for add/subtract operations? If not, is there a plan to add such support?

edit retag flag offensive close merge delete

Comments

if you build WITH_NEON, it will use carotene in a lot of places. just grep a bit.

berak gravatar imageberak ( 2017-10-22 09:04:49 -0600 )edit

1 answer

Sort by ยป oldest newest most voted
2

answered 2017-10-22 08:59:51 -0600

matman gravatar image

updated 2017-10-22 09:09:52 -0600

Neon seems to be supported (see here). Currently there are some pull requests like this which replaces explicit Neon and SSE operations with OpenCV's vector wrapper which saves double work.

So to answer your question: As far as I can see there should be Neon support for most arithmetic functions, because with the use of OpenCV's vector wrapper Neon support will be added automaticly.

Edit: Some wrong linkings fixed.

edit flag offensive delete link more

Comments

Can you understand from the code if Neon is supported for when two matrices are added?

NadavB gravatar imageNadavB ( 2017-10-22 09:21:01 -0600 )edit

This code is currently a mixture of using SSE, Neon and the wrapper interface as well as using functors. I try to give you the chain when calling cv::add.

  1. arithm_op

  2. getAddTab

  3. add8u

  4. vBinOp using FUNCTOR_CLOSURE_2arg(Vadd, ...)

So Neon should be used for adding two matrices, except for double.

matman gravatar imagematman ( 2017-10-22 10:35:11 -0600 )edit

Thanks. The strange thing is that when I set cv::setUseOptimized(false) at the beginning of my code, I don't see any performance change, which makes me wonder of the implementation of the optimization in the first place...

NadavB gravatar imageNadavB ( 2017-10-24 14:04:03 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2017-10-22 06:28:18 -0600

Seen: 586 times

Last updated: Oct 22 '17