[all-commits] [llvm/llvm-project] 5086e0: Repair tautological condition.

Richard Smith via All-commits all-commits at lists.llvm.org
Wed Jun 29 13:08:58 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 5086e05bb0cdeef68b110336dba2fe229be95110
      https://github.com/llvm/llvm-project/commit/5086e05bb0cdeef68b110336dba2fe229be95110
  Author: Richard Smith <richard at metafoo.co.uk>
  Date:   2022-06-29 (Wed, 29 Jun 2022)

  Changed paths:
    M clang/include/clang/APINotes/Types.h

  Log Message:
  -----------
  Repair tautological condition.

Fixes #49725.


  Commit: dcea10c3c6ac963387e53f918c3616b64cb82e8d
      https://github.com/llvm/llvm-project/commit/dcea10c3c6ac963387e53f918c3616b64cb82e8d
  Author: Richard Smith <richard at metafoo.co.uk>
  Date:   2022-06-29 (Wed, 29 Jun 2022)

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

  Log Message:
  -----------
  Fix miscompile with [[no_unique_address]] struct fields.

If a zero-sized field has a non-trivial initializer, it should prevent
the overall struct initialization from being folded to a constant during
IR generation. Don't just ignore zero-sized fields entirely in IR
constant emission.


Compare: https://github.com/llvm/llvm-project/compare/e341e9f09484...dcea10c3c6ac


More information about the All-commits mailing list