-
Notifications
You must be signed in to change notification settings - Fork 3.5k
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
GH-44249: [C++] Unify simd header includings #44250
Conversation
|
Hi @pitrou , what do you think if we do this? And if you agree with this change, shall we move forward to add some lint rules to forbid system simd header including? Thanks. |
@github-actions crossbow submit -g cpp |
Revision: d202127 Submitted crossbow builds: ursacomputing/crossbow @ actions-1cab231bec |
'immintrin.h', | ||
'intrin.h', | ||
'nmmintrin.h', | ||
'x86intrin.h', | ||
'xmmintrin.h', |
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.
Technically not related to the purpose of this change. Just saw it and fixed.
Thanks for looking at this @pitrou , much appreciated! And what do you think about this? The lint rule seems not trivial so I want to check with you first. |
We could, yes, though I'm not sure how useful that would be. What would be the rationale? |
Right. After a second thought, I think the rational is not strong enough. One reason is that it doesn't really hurt anything if one uses system headers directly (except that one will have to write own platform-specific checking code) so maybe we shouldn't mandate that. The other is that intrinsics are not all simd related so requiring including simd.h (as opposed to including system intrinsic headers) for cases otherwise (like what we did for querying hardware flags) doesn't make much sense. Let's just forget it for now. Thanks for reminding. |
The remaining CI failure is unrelated, thanks a lot @zanmato1984 ! |
After merging your PR, Conbench analyzed the 4 benchmarking runs that have been run so far on merge-commit 60f29e9. There was 1 benchmark result indicating a performance regression:
The full Conbench report has more details. It also includes information about 6 possible false positives for unstable benchmarks that are known to sometimes produce them. |
Rationale for this change
#44249
What changes are included in this PR?
Change all the system header inclusions to
simd.h
.Also removed some duplicated defines.
Are these changes tested?
Existing tests should be good.
Are there any user-facing changes?
None.