-
Notifications
You must be signed in to change notification settings - Fork 321
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
Math: Cleanup FIR and IIR build type select #8108
Math: Cleanup FIR and IIR build type select #8108
Conversation
src/include/sof/math/fir_config.h
Outdated
#define FIR_GENERIC 0 | ||
#define FIR_HIFIEP 1 | ||
#define FIR_HIFI3 0 | ||
#else | ||
#define FIR_GENERIC 1 | ||
#define FIR_HIFIEP 0 | ||
#define FIR_HIFI3 0 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@singalsu @andrula-song can we make all these Kconfig options for v2.8. Thanks !
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I don't think we should do it. This wasn't intended for kconfig, no need to add complexity there for a simple developer aid to compare optimized versions, or develop generic version code within Xplorer. I did this as example for #7033, where a similar case is discussed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I dont mean a system wide HIFI level, but a per module Kconfig menu where we can set generic | hifi2 | hifi3 | avx etc
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, avx with gcc changes things, so we will have quite many options. Need to think a way.
ea62474
to
72a3bd6
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice cleanup.
Do you really need a different macro for each file?
PS: still draft?
72a3bd6
to
92f83a3
Compare
#elif XCHAL_HAVE_HIFI3 == 1 || XCHAL_HAVE_HIFI4 == 1 | ||
#define FIR_HIFI3 1 | ||
#define FIR_HIFIEP 0 | ||
#ifdef SOFM_FIR_FORCEARCH |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
where and how to define SOFM_FIR_FORCEARCH and SOF_IIR_DF2T_FORCEARCH? feel this patch make code more complex than before change, not sure whether we can have a more straightforward code clean.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
where and how to define SOFM_FIR_FORCEARCH and SOF_IIR_DF2T_FORCEARCH?
The answer is literally in the first line of the patch.
feel this patch make code more complex than before change,
That's a bold statement considering you didn't read the first line.
SOFCI TEST |
The normally undefined SOF_FIR_FORCEARCH or SOF_IIR_DF2T_FORCEARCH can be defined at command line to force the build of other code optimized version for any compiler. The usage is only for debugging, e.g. build generic FIR version with xcc. Signed-off-by: Seppo Ingalsuo <[email protected]>
The HiFi3 code is faster and compatible so it should be used instead of generic version for HiFi4. Signed-off-by: Seppo Ingalsuo <[email protected]>
92f83a3
to
6d70765
Compare
The normally undefined SOF_FIR_FORCEARCH or SOF_IIR_DF2T_FORCEARCH can be defined at command line to force the build of other code optimized version for any compiler. The usage is only for debugging, e.g. build generic FIR version with xcc.