This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug tree-optimization/47316] devirtualize calls to virtual methods that are never further overriden


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=47316

--- Comment #1 from Zdenek Sojka <zsojka at seznam dot cz> 2011-01-17 06:48:50 UTC ---
Actually better solution would be function and type attributes, hinting the
function is never overriden.

The automatic analysis wouldn't work in cases like:

std::vector<A *> vec;

if there are any library calls inside std::vector.

Attributes would also work in non-whole-program mode.

I am sorry for not thinking it through - or rather forgetting the issues it had
and opening this PR so enthusiastically.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]