[PATCH] D28606: Mention devirtualization in release notes

Piotr Padlewski via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Jan 12 05:02:32 PST 2017


Prazek created this revision.
Prazek added a reviewer: hans.
Prazek added a subscriber: cfe-commits.

https://reviews.llvm.org/D28606

Files:
  docs/ReleaseNotes.rst


Index: docs/ReleaseNotes.rst
===================================================================
--- docs/ReleaseNotes.rst
+++ docs/ReleaseNotes.rst
@@ -51,6 +51,24 @@
   clang to emit a warning or error if a function call meets one or more
   user-specified conditions.
 
+- Enhanced devirtualization with `-fstrict-vtable-pointers`. Clang devirtualizes
+  across different basic blocks, like loops:
+
+  .. code-block:: c++
+       struct A {
+           virtual void foo();
+       };
+       void indirect(A &a, int n) {
+           for (int i = 0 ; i < n; i++)
+               a.foo();
+
+       }
+       void test(int n) {
+           A a;
+           indirect(a, n);
+       }
+
+
 -  ...
 
 Improvements to Clang's diagnostics


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D28606.84109.patch
Type: text/x-patch
Size: 736 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20170112/eeb2420f/attachment.bin>


More information about the cfe-commits mailing list