[all-commits] [llvm/llvm-project] 674ec1: [libcxxabi] Insert padding in __cxa_exception stru...

Steven Wu via All-commits all-commits at lists.llvm.org
Mon Feb 3 05:17:36 PST 2020


  Branch: refs/heads/release/10.x
  Home:   https://github.com/llvm/llvm-project
  Commit: 674ec1eb16678b8addc02a4b0534ab383d22fa77
      https://github.com/llvm/llvm-project/commit/674ec1eb16678b8addc02a4b0534ab383d22fa77
  Author: Steven Wu <stevenwu at apple.com>
  Date:   2020-02-03 (Mon, 03 Feb 2020)

  Changed paths:
    M libcxxabi/src/cxa_exception.h

  Log Message:
  -----------
  [libcxxabi] Insert padding in __cxa_exception struct for compatibility

Summary:
Preserve the old ABI for __cxa_exception and __cxa_dependent_exception
on 64 bit platforms or ARM_EHABI platforms.

After r276215, libunwind in llvm-project labels _Unwind_Exception to be
double word aligned. That change implictly adds a padding before
unwindHeader field in __cxa_exception and __cxa_dependent_exception.
Preserve the same negative offsets in those struct by moving the padding
to the beginning of the field.

The assumption here is that if the ABI is not aware of the padding before
unwindHeader and put the referenceCount/primaryException in there, no padding
should exist before unwindHeader.

Reviewers: EricWF, mclow.lists, ldionne, jroelofs, dexonsmith, rjmccall, compnerd, phosek, ahatanak

Reviewed By: rjmccall

Subscribers: hans, smeenai, kristof.beyls, christof, jkorous, ributzka, libcxx-commits

Tags: #libc

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

(cherry picked from commit f2a436058fcbc11291e73badb44e243f61046183)




More information about the All-commits mailing list