https://gcc.gnu.org/bugzilla/show_bug.cgi?id=69165

            Bug ID: 69165
           Summary: [6 Regression] ICE in create_tmp_var, at
                    gimple-expr.c:468
           Product: gcc
           Version: 6.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P3
         Component: tree-optimization
          Assignee: unassigned at gcc dot gnu.org
          Reporter: doko at gcc dot gnu.org
  Target Milestone: ---

trunk r232077, i686-linux-gnu, works with -O0

reduced test case:

class A {
public:
  class B {
    friend A;
    B() {}
    bool : 1;
  };
  B m_fn1() { return B(); }
};

class C {
  void m_fn2(int *&);
  class D {
  public:
    C *Label_masm;
    D() : m_label(Label_masm->m_assembler.m_fn1()) {}
    A::B m_label;
  };
  A m_assembler;
};

void C::m_fn2(int *&) { D(); }

$ g++ -march=i686 -c -std=c++11 -g -O2 -c JITArithmetic.ii                      
JITArithmetic.ii: In constructor 'C::D::D()':
JITArithmetic.ii:22:30: internal compiler error: in analyze_access_subtree, at
tree-sra.c:2340
 void C::m_fn2(int *&) { D(); }
                              ^

0x876134e analyze_access_subtree
        ../../src/gcc/tree-sra.c:2339
0x87610c7 analyze_access_subtree
        ../../src/gcc/tree-sra.c:2312
0x87669dd analyze_access_trees
        ../../src/gcc/tree-sra.c:2402
0x87669dd analyze_all_variable_accesses
        ../../src/gcc/tree-sra.c:2655
0x8766dad perform_intra_sra
        ../../src/gcc/tree-sra.c:3631
Please submit a full bug report,
with preprocessed source if appropriate.
Please include the complete backtrace with any bug report.

Reply via email to