14

Does the Intel compiler have its own standard library, e.g., implementations of std::cout etc. I want to adjust everything for Intel.

jogojapan
  • 68,383
  • 11
  • 101
  • 131
Shibli
  • 5,879
  • 13
  • 62
  • 126
  • 7
    Please don't say "for e.g." :-) – Kerrek SB Feb 05 '12 at 18:49
  • 1
    Standard library is _standard_, all compilers has same interface of standard library – Lol4t0 Feb 05 '12 at 18:52
  • 2
    This question is a brilliant one. Those who voted down will understand its value in future. – Shibli Feb 05 '12 at 18:58
  • 8
    /me votes -1 in order to understand its value in future too :-) (j/k) – Kos Feb 05 '12 at 19:09
  • 1
    @Shibli: This is a good question, but not "brilliant". I'm sure they downvoted because you didn't look it up yourself. This sort of thing appears to be a waste of our time. – Mooing Duck Jan 22 '13 at 00:54
  • 3
    @Shibli You just gave me a compelling reason to downvote: I ***want*** to _understand the value of this question in the future_. And your promise sounds like the only way to get there. – sehe Jul 19 '13 at 15:26

2 Answers2

22

Until version 8, ICC shipped with Dinkumware, i.e. the standard library implementation that also ships with Microsoft Visual Studio:

The Intel C++ Compiler for Windows uses the Microsoft Visual C++ header files, libraries and linker. Microsoft controls the header files that define the namespace.

However, as of version 8.1

-cxxlib-gcc Is Now the Default for C++
The STL and gcc* C++ libraries are now used by default when linking C++ applications, rather than those from Dinkumware* used in previous releases. If you wish to use the Dinkumware libraries, specify the new switch -cxxlib-icc. In a future release of the Intel C++ Compiler, support for using the Dinkumware libraries will be removed.

By "STL and gcc C++ libraries" one can only assume that they are referring to libstdc++.

  • So, does ICC ship with a standard library implementation? Yes.
  • Does it ship with a library implemented by Intel? No.
Lightness Races in Orbit
  • 378,754
  • 76
  • 643
  • 1,055
0

The C++ Standard Library is defined by the C++ Standard. Any standards-comformant compiler (which includes ICC) provides an implementation of this library, so yes, ICC has its own.

However, you don't need to "adjust everything", as the coding interface is generally the same everywhere. Just code standard C++ and ICC will be able to compile it.

Kos
  • 70,399
  • 25
  • 169
  • 233