Boost C++ Libraries: Ticket #6527: Segmentation fault from program_options with intel compiler and openmp https://svn.boost.org/trac10/ticket/6527 <p> When using program_options to parse the command line, a segmentation fault results from the store() function after a call to parse_command_line(). This seems to only happens when using the -openmp flag with the intel c++ (icpc) compiler (version 11) and -openmp compiler directive. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/6527 Trac 1.4.3 Ryan Scott Davis <rsdavis@…> Mon, 06 Feb 2012 05:17:11 GMT attachment set https://svn.boost.org/trac10/ticket/6527 https://svn.boost.org/trac10/ticket/6527 <ul> <li><strong>attachment</strong> → <span class="trac-field-new">bug</span> </li> </ul> <p> minimal, complete example </p> Ticket Ryan Scott Davis <rsdavis@…> Tue, 07 Feb 2012 03:15:46 GMT <link>https://svn.boost.org/trac10/ticket/6527#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/6527#comment:1</guid> <description> <p> Sorry, apparently this is some weird linking error. For others, I was compiling with </p> <p> icpc -L /path/to/boost/lib -I /path/to/boost/include test.cpp -static -lboost_program_options -openmp </p> <p> which compiled fine but result in seg fault. I guess older libraries on the cluster were somehow being linked. Instead, I now link to the library file directly, and it works, magic. </p> <p> icpc -I /path/to/boost/include test.cpp /path/to/boost/lib/libboost_program_options.a -openmp </p> </description> <category>Ticket</category> </item> <item> <dc:creator>anonymous</dc:creator> <pubDate>Tue, 22 May 2012 23:04:29 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/6527#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/6527#comment:2</guid> <description> <p> I see something similar with gcc4.7 and boost 1.49. </p> <pre class="wiki">Program received signal SIGSEGV, Segmentation fault. 0x00007ffff772b427 in ?? () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6 (gdb) bt #0 0x00007ffff772b427 in ?? () from /usr/lib/x86_64-linux-gnu/libstdc++.so.6 #1 0x0000000000b04229 in std::_Rb_tree_iterator&lt;std::string&gt;::operator-- (this=0x7fffffffd7a0) at /usr/include/c++/4.7/bits/stl_tree.h:203 #2 0x0000000000aedba8 in std::_Rb_tree&lt;std::string, std::string, std::_Identity&lt;std::string&gt;, std::less&lt;std::string&gt;, std::allocator&lt;std::string&gt; &gt;::_M_insert_unique&lt;std::string const&amp;&gt; (this=0x10aab10, __v=...) at /usr/include/c++/4.7/bits/stl_tree.h:1295 #3 0x0000000000ad6d3f in std::set&lt;std::string, std::less&lt;std::string&gt;, std::allocator&lt;std::string&gt; &gt;::insert ( this=0x10aab10, __x=...) at /usr/include/c++/4.7/bits/stl_set.h:415 #4 0x0000000000cf00dd in boost::program_options::store (options=..., xm=..., utf8=false) at libs/program_options/src/variables_map.cpp:98 #5 ... </pre><p> I need to do some more investigation but this code has worked fine in gcc 4.6 and with boost 1.47. </p> <p> Jamie </p> </description> <category>Ticket</category> </item> <item> <author>ja11sop@…</author> <pubDate>Fri, 25 May 2012 18:14:39 GMT</pubDate> <title>keywords, version, severity changed https://svn.boost.org/trac10/ticket/6527#comment:3 https://svn.boost.org/trac10/ticket/6527#comment:3 <ul> <li><strong>keywords</strong> gcc4.7 added </li> <li><strong>version</strong> <span class="trac-field-old">Boost 1.48.0</span> → <span class="trac-field-new">Boost 1.49.0</span> </li> <li><strong>severity</strong> <span class="trac-field-old">Problem</span> → <span class="trac-field-new">Showstopper</span> </li> </ul> <p> See also <a class="ext-link" href="http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53490"><span class="icon">​</span>http://gcc.gnu.org/bugzilla/show_bug.cgi?id=53490</a> </p> Ticket Vladimir Prus Mon, 28 May 2012 05:44:16 GMT severity changed https://svn.boost.org/trac10/ticket/6527#comment:4 https://svn.boost.org/trac10/ticket/6527#comment:4 <ul> <li><strong>severity</strong> <span class="trac-field-old">Showstopper</span> → <span class="trac-field-new">Problem</span> </li> </ul> <p> Per discussion in gcc bugzilla, the gcc problem is due to mismatched compilation options, and is independent from original intel problem. </p> <p> I am changing back the severity. </p> Ticket