[all-commits] [llvm/llvm-project] 677a1d: [clang] Fix crash caused by PseudoObjectExprBitfie...

yronglin via All-commits all-commits at lists.llvm.org
Wed Jul 12 16:58:29 PDT 2023

  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 677a1da6fafddb13aebd4c170c8452029a05858d
  Author: yrong <yronglin777 at gmail.com>
  Date:   2023-07-13 (Thu, 13 Jul 2023)

  Changed paths:
    M clang/docs/ReleaseNotes.rst
    M clang/include/clang/AST/Stmt.h
    M clang/test/SemaCXX/builtin-dump-struct.cpp

  Log Message:
  [clang] Fix crash caused by PseudoObjectExprBitfields::NumSubExprs overflow

This patch makes the bit-fields wider, and also implement a small optimization for `PseudoObjectExprBitfields`, when there is no result in `PseudoObjectExpr`, we use 32 bits to store the number of subexpressions, otherwise, we use 16 bits to store the number of subexpressions, and use 16 bits to store the result indexes.

Fixes https://github.com/llvm/llvm-project/issues/63169

Reviewed By: aaron.ballman

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

More information about the All-commits mailing list