1 // PR gcov-profile/55650 2 // { dg-do link } 3 // { dg-require-profiling "-fprofile-generate" } 4 // { dg-options "-O2 -fprofile-generate" } 5 // { dg-additional-sources "pr55650.cc" } 6 7 struct A 8 { 9 virtual void foo (); 10 }; 11 12 struct B : public A 13 { 14 B (); fooB15 void foo () {} 16 }; 17 18 inline A * bar()19bar () 20 { 21 return new B; 22 } 23