[cfe-commits] [PATCH][Review Please] Devirtualize record type member object

Richard Smith richard at metafoo.co.uk
Wed Aug 15 16:01:50 PDT 2012


Hi,

I added a comment explaining why this optimization is permitted, and
simplified your testcase and folded it into an existing test file.
Committed as r161998.

Thanks!

On Mon, Aug 13, 2012 at 4:48 PM, Yin Ma <yinma at codeaurora.org> wrote:

> Hi Richard,****
>
> ** **
>
>      Could you review all my changes again. I have added test case you
> requested.****
>
> I hope this one can be merged soon.****
>
> ** **
>
> Thanks,****
>
> ** **
>
>                 Yin ****
>
> ** **
>
> ** **
>
> *From:* cfe-commits-bounces at cs.uiuc.edu [mailto:
> cfe-commits-bounces at cs.uiuc.edu] *On Behalf Of *Yin Ma
> *Sent:* Tuesday, July 31, 2012 11:26 AM
> *To:* 'Richard Smith'
>
> *Cc:* cfe-commits at cs.uiuc.edu
> *Subject:* Re: [cfe-commits] [PATCH][Review Please] Devirtualize record
> type member object****
>
> ** **
>
> Hi Richard,****
>
> ** **
>
> Here is the test file. It is good to be put into ****
>
> Clang/test/CodeGenCXX directory****
>
> ** **
>
> Thanks,****
>
> ** **
>
>                    Yin ****
>
> ** **
>
> *From:* metafoo at gmail.com [mailto:metafoo at gmail.com] *On Behalf Of *Richard
> Smith
> *Sent:* Monday, July 30, 2012 2:38 PM
> *To:* Yin Ma
> *Cc:* cfe-commits at cs.uiuc.edu
> *Subject:* Re: [cfe-commits] [PATCH][Review Please] Devirtualize record
> type member object****
>
> ** **
>
> On Mon, Jul 30, 2012 at 2:33 PM, Yin Ma <yinma at codeaurora.org> wrote:****
>
> Hi Richard,****
>
>  ****
>
>      What test cases you need? Do you mean that a test sits in clang test
> folder****
>
> With a code that can be devirtualized?****
>
> ** **
>
> Yes, add some cases
> to test/CodeGenCXX/devirtualize-virtual-function-calls.cpp which check that
> the right IR is produced for this case.****
>
>  ****
>
>  ****
>
> Thanks,****
>
>  ****
>
>                           Yin ****
>
>  ****
>
> *From:* metafoo at gmail.com [mailto:metafoo at gmail.com] *On Behalf Of *Richard
> Smith
> *Sent:* Monday, July 30, 2012 1:13 PM
> *To:* Yin Ma
> *Cc:* cfe-commits at cs.uiuc.edu
> *Subject:* Re: [cfe-commits] [PATCH][Review Please] Devirtualize record
> type member object****
>
>  ****
>
> On Mon, Jul 30, 2012 at 10:54 AM, Yin Ma <yinma at codeaurora.org> wrote:****
>
> Hi,****
>
> Currently, the LLVM devirtualization forgets to handle a simple code
> pattern where can be devirutalized. The code pattern is when a call is from
> the record type member object. Currently, LLVM only supports devirtualizing
> a call from the record type object defined in the same function. If object
> is defined as member, it should be supported. The patch is to enable
> devirtualization for this case.****
>
> In the attachment.
> devir.diff is the code change
> the rest of files are the results from validation tests****
>
> Please give a review.****
>
> The patch looks correct, but needs some test cases added before it can be
> checked in.****
>
> ** **
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20120815/62b5b134/attachment.html>


More information about the cfe-commits mailing list