Intel® oneAPI Base Toolkit
Support for the core tools and libraries within the base toolkit that are used to build and deploy high-performance data-centric applications.

__cpuid compilation error

Laszlo
Beginner
1,636 Views

I think I have found a bug in Intel(R) oneAPI DPC++/C++ Compiler , Version 2021.2.0 Build 20210317. When compiling __cpuid,  the following assembly is produced and not surprisingly it gives and exception:

xorl %edi, %edi
xorl %eax, %eax
xorl %ecx, %ecx
#APP
cpuid
#NO_APP
movl %eax, 48(%rbx)
movl %ebx, 52(%rbx)
movl %ecx, 56(%rbx)
movl %edx, 60(%rbx)

To reproduce the error copy the example from the following website (to Instructionset.cpp):
https://docs.microsoft.com/en-us/cpp/intrinsics/cpuid-cpuidex?view=msvc-160
compile it with:  icx -mavx2 -EHsc Instructionset.cpp

Note that both -mavx2 and -EHsc flags are required to produce the error.

0 Kudos
5 Replies
AbhishekD_Intel
Moderator
1,611 Views

Hi Laszlo,


Thanks for reaching out to us.

Please send us complete details of your environment where you are getting the error, we will try to reproduce it and will update you with the details.



Warm Regards,

Abhishek


0 Kudos
Laszlo
Beginner
1,599 Views

I am using Win 10 Pro, Version 1909 (OSBuild 18363.1440). Intel(R) oneAPI DPC++/C++ Compiler for applications running on Intel(R) 64, Version 2021.2.0 Build 20210317
Do you need something else?

0 Kudos
AbhishekD_Intel
Moderator
1,583 Views

Hi Laszlo,


Thank you for the details.

We are able to reproduce the problem you are getting(only with -mavx2 flag) on the same mentioned environment, we are working on this internally and will update you with the details.

Thanks for reporting the issue.



Warm Regards,

Abhishek


0 Kudos
Alina_S_Intel
Employee
1,565 Views

Thank you for letting us know about the issue. It is escalated to the internal development team.



0 Kudos
ShanmukhS_Intel
Moderator
1,368 Views

Hi,


Thank you for your patience. The issue raised by you has been fixed in 2021.4 version. Please download and let us know if this resolves your issue.


Best Regards,

Shanmukh.SS


0 Kudos
Reply