This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
[Bug tree-optimization/17635] [4.0 regression] ICE in verify_ssa: type mismatch
- From: "bangerth at dealii dot org" <gcc-bugzilla at gcc dot gnu dot org>
- To: gcc-bugs at gcc dot gnu dot org
- Date: 23 Sep 2004 15:36:18 -0000
- Subject: [Bug tree-optimization/17635] [4.0 regression] ICE in verify_ssa: type mismatch
- References: <20040923141106.17635.bangerth@dealii.org>
- Reply-to: gcc-bugzilla at gcc dot gnu dot org
------- Additional Comments From bangerth at dealii dot org 2004-09-23 15:36 -------
Here's the smallest I can get it within the constraints of my time:
----------------------------
#include <vector>
template<typename T>
T max_element(T __first, T __last) {
if (__first == __last)
return __first;
T __result = __first;
while (++__first != __last)
if (*__result < *__first)
__result = __first;
return __result;
}
struct S {
std::vector<bool> used;
};
struct A {
unsigned int foo ();
std::vector<S*> s;
};
struct Accessor {
A *a;
bool used () {
return this->a->s[0]->used[0];
}
void bar () {
this->a->s[0]->used.size();
}
};
struct D {
bool baz ();
Accessor accessor;
void bar () {
accessor.bar();
if (this->accessor.used())
return;
}
};
unsigned int A::foo () {
std::vector<int> v;
for (D d; d.baz(); d.bar()) +v[0];
return (*max_element (v.begin(), v.end()));
}
-------------------------------
g/x> /home/bangerth/bin/gcc-4.0-pre/bin/c++ -O3 -ftree-vectorize -c x.cc
x.cc: In member function `unsigned int A::foo()':
x.cc:47: error: Type mismatch between an SSA_NAME and its symbol.
x.cc:47: error: Missing definition
for SSA_NAME: D.14109_789in statement:
D.14109_788 = PHI <D.14109_149(29), D.14109_789(6)>;
x.cc:47: internal compiler error: verify_ssa failed.
Please submit a full bug report,
with preprocessed source if appropriate.
See <URL:http://gcc.gnu.org/bugs.html> for instructions.
W.
--
http://gcc.gnu.org/bugzilla/show_bug.cgi?id=17635