[all-commits] [llvm/llvm-project] 01d8e0: [clang][CodeGen] Fix wrong memcpy size of no_uniqu...

Stephen via All-commits all-commits at lists.llvm.org
Mon Nov 25 18:15:51 PST 2019


  Branch: refs/heads/master
  Home:   https://github.com/llvm/llvm-project
  Commit: 01d8e09fdba0c9d3fe316a86e5ce4481e6ed71d1
      https://github.com/llvm/llvm-project/commit/01d8e09fdba0c9d3fe316a86e5ce4481e6ed71d1
  Author: Senran Zhang <zsrkmyn at gmail.com>
  Date:   2019-11-25 (Mon, 25 Nov 2019)

  Changed paths:
    M clang/lib/CodeGen/CGClass.cpp
    A clang/test/CodeGenCXX/no-unique-address-2.cpp

  Log Message:
  -----------
  [clang][CodeGen] Fix wrong memcpy size of no_unique_address in FieldMemcpyizer

When generating ctor, FieldMemcpyizer wrongly treated zero-sized class members
as what should be copied, and generated wrong memcpy size under some special
circumstances. This patch tries to fix it.

Reviewed By: MaskRay, rjmccall

Differential Revision: https://reviews.llvm.org/D70671




More information about the All-commits mailing list