[llvm-commits] my 2nd attempt at now-infamous PR889

pawel kunio pawel.kunio at gmail.com
Sun Feb 20 21:43:43 PST 2011


Hello Chris, all,
If its still relevant, here comes my partial patch for 889 broken down
(roughly)
by modules. I've decided not to change whole iplist for value, but rather
leave
default one operating on Values using llvm::deleteValue, with
specializations
for AliasSet, NamedMDNode and IVStride using plain delete.

Please note this shouldnt be released as its incomplete i.e.
specializations
for iplist traits are missing. Plus I would suggest to hide destructors on
Value-derived
classes in protected parts of relevant interfaces to prohibit direct
delete/destructor calls.

Hope this one is more suitable for review.

Best regards,

On Fri, Feb 18, 2011 at 1:15 AM, Chris Lattner <clattner at apple.com> wrote:

>
> On Feb 16, 2011, at 9:13 PM, pawel kunio wrote:
>
> > Hello,
> > In a meantime of preparing 2 tests for PR9067, I came with my 2nd and
> hopefully now more
> > successful attempt at now-infamous PR889 devirtualize Value destructor.
> >
> > Please find patches for llvm and clang attached to this mail. As I can
> see from mingw build
> > environment, it will need moving PseudoSourceValue.cpp from lib/CodeGen
> to lib/VMCore
> > after applying patch (seems not to be required on vc build env, as order
> of libraries given
> > to linker is not meaningful there).
> >
> > Please note that destructors have been moved into protected part of
> interface as well as
> > empty destructors were implemented for all Value-derived classes to help
> in catching all
> > destructions.
>
> Hi Pawel,
>
> Thank you for working on this!  Unfortunately, this patch is way too
> monolithic to review like this though, could you split it out into a series
> of obvious changes?  Doug recently "devirtualized" the clang decl hierarchy
> by devirtualizing one method at a time, which worked really well.
>
> -Chris
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20110221/d6174223/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: llvm_Value_destr_devirtualize_rest.patch
Type: application/octet-stream
Size: 12859 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20110221/d6174223/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: llvm_Value_destr_devirtualize_ValueCPP.patch
Type: application/octet-stream
Size: 10148 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20110221/d6174223/attachment-0001.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: llvm_Value_destr_devirtualize_VMCore.patch
Type: application/octet-stream
Size: 3187 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20110221/d6174223/attachment-0002.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: llvm_Value_destr_devirtualize_includes.patch
Type: application/octet-stream
Size: 21935 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20110221/d6174223/attachment-0003.obj>


More information about the llvm-commits mailing list