[PATCH] CodeGen: Devirtualize member calls on classes that are provably final.
Benjamin Kramer
benny.kra at gmail.com
Tue Aug 27 10:52:04 PDT 2013
On 27.08.2013, at 18:58, John McCall <rjmccall at gmail.com> wrote:
> On Aug 25, 2013, at 10:38 AM, Benjamin Kramer <benny.kra at gmail.com> wrote:
>> Hi rjmccall, rsmith,
>>
>> The idea is as follows:
>> 1. After CodeGenModule::Release is called we know that the AST is complete and we
>> can compute which classes with internal linkage have no children.
>> 2. Do a recursive AST visitation to find those classes. We do this lazily on the
>> first attempt to emit a virtual call.
>
> On the entire translation unit? That’ll fully deserialize pre-compiled headers, won’t it?
The current implementation would. I guess it could be limited to only look at classes in the current file without missing anything, hmm.
- Ben
More information about the cfe-commits
mailing list