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

Name demangling

albl500
Beginner
662 Views

Does the Intel Compiler suite provide a public function for name demangling?

GCC provides the abi::__cxa_demangle function specifically for this purpose. Is there an equivalent provided for the Intel compilers?

Cheers,

Alex

 

 

0 Kudos
5 Replies
TimP
Honored Contributor III
662 Views

Intel C++ for linux has to use the same demangling as g++; did you try it?  Intel C++ for Windows has to match MSVC++ demangling.

0 Kudos
albl500
Beginner
662 Views

 Thanks for the reply. Okay, it must be a problem in the library I'm using then..

Boost Python uses demangling to generate docstrings for function objects, but it doesn't work when using the Intel compiler, on Linux at least. The Boost headers must have some preprocessor macros that cause the discrepancy..

Cheers,

Alex 

0 Kudos
SergeyKostrov
Valued Contributor II
662 Views
Please take a look at C++ compiler Predefined ANSI C Macros ( Platform Dependent ), like __FUNCTION__ __FUNCDNAME__ __FUNCSIG__ but I'm Not sure that it will resolve your problem.
0 Kudos
TimP
Honored Contributor III
662 Views

articles on building boost and boost python with Intel compilers have been posted:

http://software.intel.com/en-us/articles/building-the-boost-library-to-run-natively-on-intelr-xeon-phitm-coprocessor

http://software.intel.com/en-us/articles/building-boost-with-intel-c

http://software.intel.com/en-us/blogs/2008/01/28/integrating-python-and-threading-building-blocks-part-3

but you haven't given enough information to know whether these could answer your questions.  I don't even know why you would follow such a track for boost python.

0 Kudos
albl500
Beginner
662 Views

Ah no! Just lost a post I spent 20 minutes writing!

Don't have time to repeat everything I just wrote, but basically what worked for me was to compile with the preprocessor definition "BOOST_PYTHON_HAVE_GCC_CP_DEMANGLE".

Hopefully the fix will be as simple as inserting the following line (24) to <boost/python/type_id.hpp>:-

  || (defined(__linux) && defined(__ICC))

Cheers,

Alex

0 Kudos
Reply