mirror of git://gcc.gnu.org/git/gcc.git
Add a test for PR ipa/63814
PR ipa/63814 * g++.dg/ipa/pr63814.C: New test. From-SVN: r218268
This commit is contained in:
parent
ffc510234e
commit
88936a2bfd
|
|
@ -1,3 +1,8 @@
|
||||||
|
2014-12-02 H.J. Lu <hongjiu.lu@intel.com>
|
||||||
|
|
||||||
|
PR ipa/63814
|
||||||
|
* g++.dg/ipa/pr63814.C: New test.
|
||||||
|
|
||||||
2014-12-02 Wilco Dijkstra <wilco.dijkstra@arm.com>
|
2014-12-02 Wilco Dijkstra <wilco.dijkstra@arm.com>
|
||||||
|
|
||||||
* gcc.target/aarch64/remat1.c: New testcase.
|
* gcc.target/aarch64/remat1.c: New testcase.
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,29 @@
|
||||||
|
// { dg-do run { target fpic } }
|
||||||
|
// { dg-options "-O3 -fpic" }
|
||||||
|
|
||||||
|
struct CBase {
|
||||||
|
virtual void BaseFunc () {}
|
||||||
|
};
|
||||||
|
|
||||||
|
struct MMixin {
|
||||||
|
virtual void * MixinFunc (int, int) = 0;
|
||||||
|
};
|
||||||
|
|
||||||
|
struct CExample: CBase, public MMixin
|
||||||
|
{
|
||||||
|
void *MixinFunc (int arg, int arg2)
|
||||||
|
{
|
||||||
|
return this;
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
void *test (MMixin & anExample)
|
||||||
|
{
|
||||||
|
return anExample.MixinFunc (0, 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
int main ()
|
||||||
|
{
|
||||||
|
CExample c;
|
||||||
|
return (test (c) != &c);
|
||||||
|
}
|
||||||
Loading…
Reference in New Issue