Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

usage of ABSDIFF macro in flow.c #125

Open
mike239x opened this issue Feb 7, 2020 · 0 comments
Open

usage of ABSDIFF macro in flow.c #125

mike239x opened this issue Feb 7, 2020 · 0 comments

Comments

@mike239x
Copy link
Collaborator

mike239x commented Feb 7, 2020

The commit 24b790d states:

Replace SAD function with assembly version ~ 25% faster

However ABSDIFF macro (the assembly version) uses hardcoded image width of 64 px, while compute_sad_8x8 has variable image width. So I made an experiment - I added timing + debug output to the code and measured compute_sad_8x8(..., (uint16_t) FRAME_SIZE) vs ABSDIFF(...) vs compute_sad_8x8(..., 64); and I got that the last one is actually the fastest. Also, the speed up from compute_sad_8x8(..., (uint16_t) FRAME_SIZE) to ABSDIFF(...) is far less than 25% for me - more like 8%.
Assuming somebody can reproduce my results - maybe we can just delete ABSDIFF macro and use compute_sad_8x8(..., 64) instead?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant