forked from OSchip/llvm-project
parent
68147ee320
commit
4d94e47368
|
|
@ -1963,3 +1963,23 @@ bb3: ; preds = %entry
|
||||||
ret i32 %b
|
ret i32 %b
|
||||||
}
|
}
|
||||||
//===---------------------------------------------------------------------===//
|
//===---------------------------------------------------------------------===//
|
||||||
|
|
||||||
|
clang -O3 fails to devirtualize this virtual inheritance case: (GCC PR45875)
|
||||||
|
|
||||||
|
struct c1 {};
|
||||||
|
struct c10 : c1{
|
||||||
|
virtual void foo ();
|
||||||
|
};
|
||||||
|
struct c11 : c10, c1{
|
||||||
|
virtual void f6 ();
|
||||||
|
};
|
||||||
|
struct c28 : virtual c11{
|
||||||
|
void f6 ();
|
||||||
|
};
|
||||||
|
void check_c28 () {
|
||||||
|
c28 obj;
|
||||||
|
c11 *ptr = &obj;
|
||||||
|
ptr->f6 ();
|
||||||
|
}
|
||||||
|
|
||||||
|
//===---------------------------------------------------------------------===//
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue