Intel® C++ Compiler
Support and discussions for creating C++ code that runs on platforms based on Intel® processors.
7647 Discussions

undefined reference to `std::__failed_assertion() with icpc on Fedora 34

ChristophJunghans
616 Views

Compiling the following small program

#include <vector>

int main ()
{
  std::vector<int> foo (3,100);
  std::vector<int> bar (5,200);
  foo.swap(bar);
  return 0;
}

with icpc on Fedora 34 leads to:

$ icpc -g -std=c++14 exe.cpp
ld: /tmp/icpcKut7mX.o: in function `std::vector<int, std::allocator<int> >::swap(std::vector<int, std::allocator<int> >&)':
/usr/include/c++/11/bits/stl_vector.h:1483: undefined reference to `std::__failed_assertion()'

Also see:  https://github.com/kokkos/ci-containers/issues/15

Labels (1)
0 Kudos
7 Replies
ArpitaP_Intel
Moderator
589 Views

Hi,


Thanks for reaching out to us.

We tried the reproducer in GCC 10 and GCC 11. It worked fine with GCC 10 but we could reproduce the same error with GCC 11.

 It works fine with GCC 11, if icpx compiler is used. So, if compiler is not an issue you can use the above combination. Please find more about icpx compiler in the below links:


https://software.intel.com/content/www/us/en/develop/documentation/oneapi-dpcpp-cpp-compiler-dev-gui...


https://software.intel.com/content/www/us/en/develop/articles/porting-guide-for-icc-users-to-dpcpp-o...

 

We are working internally on the error, we will get back to you when we have some updates.  


Regards,

Arpita


Viet_H_Intel
Moderator
582 Views

Fedora* 34 is not yet an OS support by current Intel compilers.

Please refer Intel® oneAPI HPC Toolkit System Requirements for the list of OS supported.

Let us know if you still encounter the error on a supported OS.

Thanks,


ChristophJunghans
572 Views
The last Fedora listed as supported is Fedora 31, which is end-of-life since end of 2020.

Using Fedora 33 for now seems to be a reasonable workaround.

I made a toy reproducer using docker here:
https://github.com/junghans/intel_icpc/blob/main/Dockerfile
Viet_H_Intel
Moderator
569 Views

Future Intel Compilers will support Fedora* 34. Can we close this thread for now?

Thanks,


Viet_H_Intel
Moderator
511 Views

Let's close this thread. If you require additional assistance from Intel, please start a new thread. Any further interaction in this thread will be considered community only.

Thanks,


ChristophJunghans
502 Views

Is there an ETA for when Fedora 34 (and Fedora 35+) will be supported?

Viet_H_Intel
Moderator
496 Views

I don't have an ETA, but will update you when it's available.

Reply