[all-commits] [llvm/llvm-project] c60dd3: Revert "[clang] NRVO: Improvements and handling of...

Hans via All-commits all-commits at lists.llvm.org
Mon Jun 14 07:47:32 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: c60dd3b2626a4d9eefd9f82f9a406b0d28d3fd72
      https://github.com/llvm/llvm-project/commit/c60dd3b2626a4d9eefd9f82f9a406b0d28d3fd72
  Author: Hans Wennborg <hans at chromium.org>
  Date:   2021-06-14 (Mon, 14 Jun 2021)

  Changed paths:
    M clang/include/clang/Sema/Sema.h
    M clang/lib/Sema/Sema.cpp
    M clang/lib/Sema/SemaCoroutine.cpp
    M clang/lib/Sema/SemaExprCXX.cpp
    M clang/lib/Sema/SemaStmt.cpp
    M clang/lib/Sema/SemaTemplateInstantiateDecl.cpp
    M clang/lib/Sema/SemaType.cpp
    M clang/test/CXX/class/class.init/class.copy.elision/p3.cpp
    M clang/test/CXX/dcl.dcl/dcl.spec/dcl.type/dcl.spec.auto/p7-cxx14.cpp
    M clang/test/CXX/drs/dr3xx.cpp
    M clang/test/CXX/expr/expr.prim/expr.prim.lambda/p4-cxx14.cpp
    M clang/test/CXX/temp/temp.decls/temp.mem/p5.cpp
    M clang/test/CodeGen/nrvo-tracking.cpp
    M clang/test/SemaCXX/constant-expression-cxx11.cpp
    M clang/test/SemaCXX/constant-expression-cxx14.cpp
    M clang/test/SemaCXX/coroutine-rvo.cpp
    M clang/test/SemaCXX/coroutines.cpp
    M clang/test/SemaCXX/deduced-return-type-cxx14.cpp
    M clang/test/SemaCXX/return-stack-addr.cpp
    M clang/test/SemaCXX/warn-return-std-move.cpp

  Log Message:
  -----------
  Revert "[clang] NRVO: Improvements and handling of more cases."

This change caused build errors related to move-only __block variables,
see discussion on https://reviews.llvm.org/D99696

> This expands NRVO propagation for more cases:
>
> Parse analysis improvement:
> * Lambdas and Blocks with dependent return type can have their variables
>   marked as NRVO Candidates.
>
> Variable instantiation improvements:
> * Fixes crash when instantiating NRVO variables in Blocks.
> * Functions, Lambdas, and Blocks which have auto return type have their
>   variables' NRVO status propagated. For Blocks with non-auto return type,
>   as a limitation, this propagation does not consider the actual return
>   type.
>
> This also implements exclusion of VarDecls which are references to
> dependent types.
>
> Signed-off-by: Matheus Izvekov <mizvekov at gmail.com>
>
> Reviewed By: Quuxplusone
>
> Differential Revision: https://reviews.llvm.org/D99696

This also reverts the follow-on change which was hard to tease apart
form the one above:

> "[clang] Implement P2266 Simpler implicit move"
>
> This Implements [[http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2021/p2266r1.html|P2266 Simpler implicit move]].
>
> Signed-off-by: Matheus Izvekov <mizvekov at gmail.com>
>
> Reviewed By: Quuxplusone
>
> Differential Revision: https://reviews.llvm.org/D99005

This reverts commits 1e50c3d785f4563873ab1ce86559f2a1285b5678 and
bf20631782183cd19e0bb7219e908c2bbb01a75f.




More information about the All-commits mailing list