- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
I assume that this forum is trolled by the Intel C++ experts for answers the communal mind doesn't have.
I'm using Visual C++ 2008 (9.0.21022.8). And IC C++ 11.0.066.
I'm working on a module that uses old SSE 2 code. It compiles fine with VS but gets the following error using the IC:
1>Getblk_sse2.cpp
1>C:\Program Files\Microsoft SDKs\Windows\v6.0A\\include\winnt.h(3332): error #147: declaration is incompatible with "void __cdecl _mm_pause()" (declared at line 375 of "C:\Program Files\Intel\Compiler\11.0\066\cpp\include\emmintrin.h")
1> _mm_pause (
1> ^
1>
The only thing I can find is that errors similar to this can occur if you're using an older version of the IC with a newer version of VS. But I'm not.
Any ideas? I'm using Vista SP2.
Link Copied
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Jennifer
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Quoting - Jennifer Jiang (Intel) did you use "__cdecl (/Gd)"? Try to add it.
Jennifer
Jennifer,
Thanks. It worked.
MSDN has an explanation of the calling conventions (http://msdn.microsoft.com/en-us/library/46t77ak2.aspx), but I have to admit that I'm not sure about their advantages and disadvantages outside of __fastcall.
So I'm guessing that the problem was that winnt.h uses a __stdcall convention which didn't match with the __cdecl convention used in emmintrin.h. (Hey, if I'm wrong, correct me.)
--Taylor
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
So I'm guessing that the problem was that winnt.h uses a __stdcall convention which didn't match with the __cdecl convention used in emmintrin.h. (Hey, if I'm wrong, correct me.)
Jennifer
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page