<html>
    <head>
      <base href="http://bugzilla.gdcproject.org/" />
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_NEW "
   title="NEW - using -O{1,2,3} together with -g causes ICE (seg fault)"
   href="http://bugzilla.gdcproject.org/show_bug.cgi?id=157">157</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>using -O{1,2,3} together with -g causes ICE (seg fault)
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>GDC
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>4.9.x
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>NEW
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>Normal
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>gdc
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>ibuclaw@gdcproject.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>maor@weka.io
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Working on Linux (Ubuntu 4.10) and gdc 4.10.0 20140629 I get an ICE with the
following backtrace when compiling with both -g and -O1 (either one works fine
but not both).

code:

import std.process;
import std.string;

string runSomething() {
    return execute("some executable").output.chomp;
}

void main() {}


cmdline: gdc -g -O1 ./test.d -o/tmp/test

backtrace:

./test.d:1: internal compiler error: Segmentation fault
0xae393f crash_signal
    ../../gcc-4.10-20140629/gcc/toplev.c:337
0x10fe570 htab_hash_string
    ../../gcc-4.10-20140629/libiberty/hashtab.c:839
0x802827 external_ref_hasher::hash(external_ref const*)
    ../../gcc-4.10-20140629/gcc/dwarf2out.c:7619
0x802827 hash_table<external_ref_hasher, xcallocator,
false>::find_slot(external_ref const*, insert_option)
    ../../gcc-4.10-20140629/gcc/hash-table.h:532
0x802827 lookup_external_ref
    ../../gcc-4.10-20140629/gcc/dwarf2out.c:7647
0x8028cc optimize_external_refs_1
    ../../gcc-4.10-20140629/gcc/dwarf2out.c:7685
0x8028f8 optimize_external_refs_1
    ../../gcc-4.10-20140629/gcc/dwarf2out.c:7689
0x802d2e optimize_external_refs
    ../../gcc-4.10-20140629/gcc/dwarf2out.c:7738
0x8030ec output_comp_unit
    ../../gcc-4.10-20140629/gcc/dwarf2out.c:8970
0x825ea9 dwarf2out_finish
    ../../gcc-4.10-20140629/gcc/dwarf2out.c:24439
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.
See <<a href="http://bugzilla.gdcproject.org">http://bugzilla.gdcproject.org</a>> for instructions.</pre>
        </div>
      </p>
      <hr>
      <span>You are receiving this mail because:</span>
      
      <ul>
          <li>You are watching all bug changes.</li>
      </ul>
    </body>
</html>