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

Fix Win32 errors from Errno #18026

Merged
merged 1 commit into from
Sep 14, 2020
Merged

Fix Win32 errors from Errno #18026

merged 1 commit into from
Sep 14, 2020

Conversation

atoomic
Copy link
Member

@atoomic atoomic commented Aug 3, 2020

Fix #18025

This is fixing these two errors under windows:

"Never use <avx512bwintrin.h> directly; include <immintrin.h> instead."
"Never use <avx512vpopcntdqvlintrin.h> directly; include <immintrin.h> instead."

@atoomic atoomic requested review from Leont and tonycoz August 3, 2020 05:09
@tonycoz
Copy link
Contributor

tonycoz commented Aug 4, 2020

Your title here says cygwin, the change and the original issue only discussed MSWin32.

Looking at immintrin.h I see it including many more files that include a similar error than just the two listed:

#include <mmintrin.h>

#include <xmmintrin.h>

#include <emmintrin.h>

#include <pmmintrin.h>

#include <tmmintrin.h>

#include <smmintrin.h>

#include <wmmintrin.h>

#include <avxintrin.h>

#include <avx2intrin.h>

#include <avx512fintrin.h>

#include <avx512erintrin.h>

#include <avx512pfintrin.h>

#include <avx512cdintrin.h>

#include <avx512vlintrin.h>

#include <avx512bwintrin.h>

#include <avx512dqintrin.h>

#include <avx512vlbwintrin.h>

#include <avx512vldqintrin.h>

#include <avx512ifmaintrin.h>

#include <avx512ifmavlintrin.h>

#include <avx512vbmiintrin.h>

#include <avx512vbmivlintrin.h>

#include <avx5124fmapsintrin.h>

#include <avx5124vnniwintrin.h>

#include <avx512vpopcntdqintrin.h>

#include <avx512vbmi2intrin.h>

#include <avx512vbmi2vlintrin.h>

#include <avx512vnniintrin.h>

#include <avx512vnnivlintrin.h>

#include <avx512vpopcntdqvlintrin.h>

#include <avx512bitalgintrin.h>

#include <shaintrin.h>

#include <lzcntintrin.h>

#include <bmiintrin.h>

#include <bmi2intrin.h>

#include <fmaintrin.h>

#include <f16cintrin.h>

#include <rtmintrin.h>

#include <xtestintrin.h>

#include <cetintrin.h>

#include <gfniintrin.h>

#include <vaesintrin.h>

#include <vpclmulqdqintrin.h>

#include <movdirintrin.h>

Another file x86intrin.h includes a similar list:

#include <mmintrin.h>

#include <xmmintrin.h>

#include <emmintrin.h>

#include <pmmintrin.h>

#include <tmmintrin.h>

#include <ammintrin.h>

#include <smmintrin.h>

#include <wmmintrin.h>

/* For including AVX instructions */
#include <immintrin.h>

#include <mm3dnow.h>

#include <fma4intrin.h>

#include <xopintrin.h>

#include <lwpintrin.h>

#include <bmiintrin.h>

#include <bmi2intrin.h>

#include <tbmintrin.h>

#include <lzcntintrin.h>

#include <popcntintrin.h>

#include <rdseedintrin.h>

#include <prfchwintrin.h>

#include <fxsrintrin.h>

#include <xsaveintrin.h>

#include <xsaveoptintrin.h>

#include <sgxintrin.h>

#include <pconfigintrin.h>

#endif /* __iamcu__ */

#include <adxintrin.h>

#ifndef __iamcu__

#include <clwbintrin.h>

#include <clflushoptintrin.h>

#include <xsavesintrin.h>

#include <xsavecintrin.h>

#include <mwaitxintrin.h>

#include <clzerointrin.h>

#include <wbnoinvdintrin.h>

#include <pkuintrin.h>

of which the few I checked produce a similar error (though immintrin.h doesn't, despite being included by x86intrin.h)

@tonycoz
Copy link
Contributor

tonycoz commented Aug 25, 2020

Do have an example of the failure without this change? I don't see an from CI for blead and a local build didn't show any problems building or testing Errno.

@atoomic
Copy link
Member Author

atoomic commented Aug 27, 2020

Hi @tonycoz here is an extract output from a CI build

Build log: https://github.com/Perl/perl5/runs/938816804?check_suite_focus=true
Raw log: https://pipelines.actions.githubusercontent.com/F8yobFedDMKReLD2lUI49NJpt8TNtEKo3DptPtnjfqw2qokl1r/_apis/pipelines/1/runs/10518/signedlogcontent/29?urlExpires=2020-08-27T16%3A00%3A22.4052667Z&urlSigningMethod=HMACV1&urlSignature=DKQSXBBwQZ3P%2BWUfp3MaMYlm6l0uAnSzCOkBfqUKF4c%3D

2020-08-03T02:17:22.7451153Z gmake[1]: Entering directory 'd:/a/perl5/perl5/ext/Errno'
2020-08-03T02:17:23.3302592Z "d:\a\perl5\perl5\miniperl.exe" "-I..\..\lib" Errno_pm.PL Errno.pm 
2020-08-03T02:17:24.1692083Z In file included from includes.c:3:
2020-08-03T02:17:24.2872956Z C:/strawberry/c/lib/gcc/x86_64-w64-mingw32/8.3.0/include/avx512bitalgintrin.h:25:3: error: #error "Never use <avx512bitalgintrin.h> directly; include <x86intrin.h> instead."
2020-08-03T02:17:24.3616424Z  # error "Never use <avx512bitalgintrin.h> directly; include <x86intrin.h> instead."
2020-08-03T02:17:24.4783273Z    ^~~~~
2020-08-03T02:17:24.5502954Z In file included from includes.c:4:
2020-08-03T02:17:24.6663322Z C:/strawberry/c/lib/gcc/x86_64-w64-mingw32/8.3.0/include/xsavesintrin.h:25:3: error: #error "Never use <xsavesintrin.h> directly; include <x86intrin.h> instead."
2020-08-03T02:17:24.7436215Z  # error "Never use <xsavesintrin.h> directly; include <x86intrin.h> instead."
2020-08-03T02:17:24.8300688Z    ^~~~~
2020-08-03T02:17:25.5629065Z gmake[1]: Leaving directory 'd:/a/perl5/perl5/ext/Errno'

@tonycoz
Copy link
Contributor

tonycoz commented Aug 28, 2020

So it is Win32 and not cygwin (which is in the title of the PR)

@atoomic atoomic changed the title Fix cygwin errors from Errno Fix Win32 errors from Errno Aug 28, 2020
Fix Perl#18025

This is fixing these two errors under windows:

"Never use <avx512bwintrin.h> directly; include <immintrin.h> instead."
"Never use <avx512vpopcntdqvlintrin.h> directly; include <immintrin.h> instead."
@atoomic
Copy link
Member Author

atoomic commented Aug 28, 2020

@tonycoz I updated the PR title and commit title via 89aa8d4 at least the branch name was correct

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

Successfully merging this pull request may close these issues.

Errno error on windows/cygwin
2 participants