mirror of
https://github.com/capstone-engine/llvm-capstone.git
synced 2024-12-19 22:11:08 +00:00
957334382c
libgcc and libunwind have different flavours of __register_frame. Both flavours are already correctly handled, except that the code to handle the libunwind flavour is guarded by __APPLE__. This change uses the presence of __unw_add_dynamic_fde in libunwind instead to detect whether libunwind is used, rather than hardcoding it as Apple vs. non-Apple. Fixes PR44074. Thanks to Albert Jin <albert.jin@gmail.com> and Chris Schafmeister <chris.schaf@verizon.net> for identifying the problem. Reviewed By: lhames Differential Revision: https://reviews.llvm.org/D106129
9 lines
469 B
C
9 lines
469 B
C
// NOLINT: llvm-header-guard
|
|
// __register_frame() is used with dynamically generated code to register the
|
|
// FDE for a generated (JIT) code. This header provides protypes, since the gcc
|
|
// version of unwind.h may not, so CMake can check if the corresponding symbols
|
|
// exist in the runtime.
|
|
extern void __register_frame(const void *fde); // NOLINT
|
|
extern void __deregister_frame(const void *fde); // NOLINT
|
|
extern void __unw_add_dynamic_fde(); // NOLINT
|