Intel® C++ Compiler
Community support and assistance for creating C++ code that runs on platforms based on Intel® processors.
7956 Discussions

Error :: register may not be specified as both modified and preserved

Naveen_Tulabandula
325 Views
Hi
I am trying to write code which uses intrinsics like
__cpuid(cpuinfo, 1);
and
xcr = _xgetbv(_XCR_XFEATURE_ENABLED_MASK); 
The code is compiling fine on win64
But i am seeing below error message in win32
"catastrophic error: register may not be specified as both modified and preserved in #pragma
 linkage"

The compilation is going fine with microsoft CL compiler.
Let me know when we see such error message.
I am unable to reproduce this in a standalone testcase
I am using icl 12.0.5.227
0 Kudos
1 Reply
Georg_Z_Intel
Employee
325 Views
Hello,

newer 12.1 versions (Intel® Composer XE 2011 Update 6 and higher) don't show this problem anymore.
I'm currently clarifying with engineering which exact version has fixed this problem.

Edit: Intel® Composer XE 2011 Update 11 is reported to have a fix for that.

Would it be possible for you to upgrade to the latest version: Intel® Composer XE 2011 Update 11?

Thank you & best regards,

Georg Zitzlsberger
0 Kudos
Reply