Identifier "simd" may be treated as reserved attribute keyword, resulting in compiler errors and "warning #2621: attribute "simd" does not apply here"

Reference Number: DPD200240885

Version: Intel® C++ Composer XE 2013 Update 2 (Intel® C++ Compiler XE 13.1.0)

Operating System: Windows* and Linux*

Problem Description:

If the word "simd" is used as an identifier in C/C++ code (for example, as a typename, or as a function parameter name), there is the chance that the compiler may treat this identifier as a reserved attribute keyword and you will then run into compilation errors. This issue should only result in compilation errors. Link-time or runtime problems are not expected. An example follows:

$ cat test-simd.cpp
void foo(float * simd);
$ icc -V -c test-simd.cpp
Intel(R) C Intel(R) 64 Compiler XE for applications running on Intel(R) 64, Version Build 20130121
Copyright (C) 1985-2013 Intel Corporation.  All rights reserved.
Edison Design Group C/C++ Front End, version 4.4.1 (Jan 23 2013 18:16:41)
Copyright 1988-2011 Edison Design Group, Inc.
test-simd.cpp(1): error: expected a ","
  void foo(float * simd);
test-simd.cpp(1): warning #2621: attribute "simd" does not apply here
  void foo(float * simd);
compilation aborted for test-simd.cpp (code 2)

Problem Resolution:

This issue is resolved in the Intel Composer XE 2013 update 3 compiler (13.1.1).

For more complete information about compiler optimizations, see our Optimization Notice.


Brandon Hewitt (Intel)'s picture

Hello Pavithra,

No, this indicates that the Intel compiler isn't supporting the __declspec(uuid(x)) attribute on this typedef. I suspect (although am not positive) that Microsoft's compiler also doesn't do anything with this typedef in regards to assigning a UUID, but Microsoft's compiler doesn't warn about it. And we probably shouldn't either. I would go ahead and submit a Premier Support issue on this ( It is a different issue than the one described in this article though.

PAVITHRA DEEPA S. (Intel)'s picture

I would like to know whether uuid is also treated as a keyword in the same way.
The statement to be considered is as follows
File name: ocidl.h
File path: Windows Kits\8.0\Include\um\ocidl


typedef /* [hidden][uuid] */ DECLSPEC_UUID("xxxxx") UNIT OLE_HANDLE;

Here xxxxx refers to some unique code

warning #2651: attribute "uuid" does not apply here

Add a Comment

Have a technical question? Visit our forums. Have site or software product issues? Contact support.