[Patch, Fortran, OOP] PR 50960: vtables not marked as constant
Janus Weil
janus@gcc.gnu.org
Wed Nov 9 14:48:00 GMT 2011
> Thanks for the patch, but could you also add a test case? With the
> patch, one gets the following optimized dump:
> base ();
> while without the patch (or in the original dump) one has:
> x._vptr->bar ();
> (That's for the test case to the PR, see PR 50959 comment 0.)
Here is what I am going to commit.
It's nice to see that this kind of "devirtualization" optimization
actually works now. In this way the patch could really have an impact
on OOP code performance.
Would be interesting to see if we get a measurable speed-up in
real-world code, like e.g. Salvatore's PSBLAS.
Cheers,
Janus
-------------- next part --------------
A non-text attachment was scrubbed...
Name: typebound_call_22.f03
Type: application/octet-stream
Size: 694 bytes
Desc: not available
URL: <http://gcc.gnu.org/pipermail/fortran/attachments/20111109/5a81621a/attachment.obj>
More information about the Fortran
mailing list