Intel® C++ Compiler
Support and discussions for creating C++ code that runs on platforms based on Intel® processors.
Announcements
The Intel sign-in experience has changed to support enhanced security controls. If you sign in, click here for more information.
7763 Discussions

How to verify whether value is loaded into xmm register in C or not?

shahedabegum
Beginner
175 Views
Hi everyone,

How to check whether the value is loaded into the xmm register in C ??I am using GCC. For eg,
typedef struct
{
int val[4];
}state;
int main()
{
int *m;
state a;
asm(" movups (%eax),%xmm0:"=r"(m):"r"(a.val);
}
Here i am not able to print the m value. I need help in this issue. Thank you in advance.

0 Kudos
1 Reply
ILevi1
Valued Contributor I
175 Views

Well if you tell the CPU to load a value to XMM register it will do it or die trying. Perhaps you meant to ask how to check the loaded value from the XMM register? The only way is to write it back to memory and print it out using traditional C or C++ code.

Reply