Convert moments in tile algorithms to HAL (1.3x faster for VSX).#15828
Merged
alalek merged 3 commits intoopencv:3.4from Nov 5, 2019
ChipKerchner:momentsToHal
Merged
Convert moments in tile algorithms to HAL (1.3x faster for VSX).#15828alalek merged 3 commits intoopencv:3.4from ChipKerchner:momentsToHal
alalek merged 3 commits intoopencv:3.4from
ChipKerchner:momentsToHal
Conversation
Contributor
Author
|
Found a "bug" in the NEON version of HAL. Creating registers does NOT initialize them to zero like SSE and VSX HAL. Wondering if this should be fixed for consistency. |
alalek
reviewed
Nov 1, 2019
| x0 = buf[0]; | ||
| x1 = buf[1]; | ||
| x2 = buf[2]; | ||
| x3 = buf64[0] + buf64[1]; |
Member
There was a problem hiding this comment.
Perhaps we don't need to force 64F here (at least in such complex form).
This is post-processing, so performance here is not critical.
Could you try this approach:
x0 = v_reduce_sum(v_x0);
x1 = v_reduce_sum(v_x1);
x2 = v_reduce_sum(v_x2);
int64 CV_DECL_ALIGNED(16) buf64[2]; // avoid declarations as class fields
v_store_aligned(buf64, v_reinterpret_as_s64(v_x3));
x3 = buf64[0] + buf64[1];
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Convert moments in tile algorithms to HAL (1.3x faster for VSX).