[PATCH] D47671: [analyzer] Implement copy elision.

2018-06-27 Thread Phabricator via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC335800: [analyzer] Add support for pre-C++17 copy elision. (authored by dergachev, committed by ). Repository: rC Clang https://reviews.llvm.org/D47671 Files: include/clang/StaticAnalyzer/Core/PathS

[PATCH] D47671: [analyzer] Implement copy elision.

2018-06-13 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. > P.S. It seems that one of my currently-on-review patches has introduced a > performance regression, i'm investigating it. Never mind, that was an old version of the patch, i.e. i accidentally fixed that regression before uploading the patch to phabricator. https://revie

[PATCH] D47671: [analyzer] Implement copy elision.

2018-06-13 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ updated this revision to Diff 151279. NoQ added a comment. I added an option to disable copy elision on CFG side in https://reviews.llvm.org/D47616. The analyzer makes use of it automagically: elided constructors are replaced with temporary constructors in the CFG and the old behavior is re

[PATCH] D47671: [analyzer] Implement copy elision.

2018-06-11 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In https://reviews.llvm.org/D47671#1127486, @xazax.hun wrote: > Just for the record, there is a common example where relying on copy elision > might bite and google do not recommend relying on it for correctness: > https://abseil.io/tips/120 > > The main purpose of sharing

[PATCH] D47671: [analyzer] Implement copy elision.

2018-06-10 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. Herald added a subscriber: mikhail.ramalho. Just for the record, there is a common example where relying on copy elision might bite and google do not recommend relying on it for correctness: https://abseil.io/tips/120 The main purpose of sharing is to add some more co

[PATCH] D47671: [analyzer] Implement copy elision.

2018-06-05 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added a comment. In https://reviews.llvm.org/D47671#1122994, @george.karpenkov wrote: > From my understanding, that's just how c++17 is defined, and that's unrelated > to what compiler implementation is used. Yeah, but this patch is specifically about supporting the pre-C++17 AST, where c

[PATCH] D47671: [analyzer] Implement copy elision.

2018-06-05 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. In https://reviews.llvm.org/D47671#1122994, @george.karpenkov wrote: > > So having an analyzer-config option would be useful for those codebases > > that are expected to be compiled with less advanced compilers that do not > > elide copies or not doing it aggressively

[PATCH] D47671: [analyzer] Implement copy elision.

2018-06-05 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. > So having an analyzer-config option would be useful for those codebases that > are expected to be compiled with less advanced compilers that do not elide > copies or not doing it aggressively enough. I'm not sure it makes sense. From my understanding, that's

[PATCH] D47671: [analyzer] Implement copy elision.

2018-06-04 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. So having an analyzer-config option would be useful for those codebases that are expected to be compiled with less advanced compilers that do not elide copies or not doing it aggressively enough. Maybe it is worth to ask on the mailing list of the community wants to h

[PATCH] D47671: [analyzer] Implement copy elision.

2018-06-01 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ created this revision. NoQ added reviewers: dcoughlin, xazax.hun, a.sidorin, george.karpenkov, szepet, rnkovacs. Herald added subscribers: cfe-commits, baloghadamsoftware. This patch builds on top of https://reviews.llvm.org/D47616 to elide pre-C++17 elidable constructors during analysis. Th