xref: /freebsd/contrib/llvm-project/clang/lib/Headers/unwind.h (revision 0eae32dcef82f6f06de6419a0d623d7def0cc8f6)
10b57cec5SDimitry Andric /*===---- unwind.h - Stack unwinding ----------------------------------------===
20b57cec5SDimitry Andric  *
30b57cec5SDimitry Andric  * Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
40b57cec5SDimitry Andric  * See https://llvm.org/LICENSE.txt for license information.
50b57cec5SDimitry Andric  * SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
60b57cec5SDimitry Andric  *
70b57cec5SDimitry Andric  *===-----------------------------------------------------------------------===
80b57cec5SDimitry Andric  */
90b57cec5SDimitry Andric 
100b57cec5SDimitry Andric /* See "Data Definitions for libgcc_s" in the Linux Standard Base.*/
110b57cec5SDimitry Andric 
120b57cec5SDimitry Andric #ifndef __CLANG_UNWIND_H
130b57cec5SDimitry Andric #define __CLANG_UNWIND_H
140b57cec5SDimitry Andric 
150b57cec5SDimitry Andric #if defined(__APPLE__) && __has_include_next(<unwind.h>)
160b57cec5SDimitry Andric /* Darwin (from 11.x on) provide an unwind.h. If that's available,
170b57cec5SDimitry Andric  * use it. libunwind wraps some of its definitions in #ifdef _GNU_SOURCE,
180b57cec5SDimitry Andric  * so define that around the include.*/
190b57cec5SDimitry Andric # ifndef _GNU_SOURCE
200b57cec5SDimitry Andric #  define _SHOULD_UNDEFINE_GNU_SOURCE
210b57cec5SDimitry Andric #  define _GNU_SOURCE
220b57cec5SDimitry Andric # endif
230b57cec5SDimitry Andric // libunwind's unwind.h reflects the current visibility.  However, Mozilla
240b57cec5SDimitry Andric // builds with -fvisibility=hidden and relies on gcc's unwind.h to reset the
250b57cec5SDimitry Andric // visibility to default and export its contents.  gcc also allows users to
260b57cec5SDimitry Andric // override its override by #defining HIDE_EXPORTS (but note, this only obeys
270b57cec5SDimitry Andric // the user's -fvisibility setting; it doesn't hide any exports on its own).  We
280b57cec5SDimitry Andric // imitate gcc's header here:
290b57cec5SDimitry Andric # ifdef HIDE_EXPORTS
300b57cec5SDimitry Andric #  include_next <unwind.h>
310b57cec5SDimitry Andric # else
320b57cec5SDimitry Andric #  pragma GCC visibility push(default)
330b57cec5SDimitry Andric #  include_next <unwind.h>
340b57cec5SDimitry Andric #  pragma GCC visibility pop
350b57cec5SDimitry Andric # endif
360b57cec5SDimitry Andric # ifdef _SHOULD_UNDEFINE_GNU_SOURCE
370b57cec5SDimitry Andric #  undef _GNU_SOURCE
380b57cec5SDimitry Andric #  undef _SHOULD_UNDEFINE_GNU_SOURCE
390b57cec5SDimitry Andric # endif
400b57cec5SDimitry Andric #else
410b57cec5SDimitry Andric 
420b57cec5SDimitry Andric #include <stdint.h>
430b57cec5SDimitry Andric 
440b57cec5SDimitry Andric #ifdef __cplusplus
450b57cec5SDimitry Andric extern "C" {
460b57cec5SDimitry Andric #endif
470b57cec5SDimitry Andric 
480b57cec5SDimitry Andric /* It is a bit strange for a header to play with the visibility of the
490b57cec5SDimitry Andric    symbols it declares, but this matches gcc's behavior and some programs
500b57cec5SDimitry Andric    depend on it */
510b57cec5SDimitry Andric #ifndef HIDE_EXPORTS
520b57cec5SDimitry Andric #pragma GCC visibility push(default)
530b57cec5SDimitry Andric #endif
540b57cec5SDimitry Andric 
550b57cec5SDimitry Andric typedef uintptr_t _Unwind_Word __attribute__((__mode__(__unwind_word__)));
560b57cec5SDimitry Andric typedef intptr_t _Unwind_Sword __attribute__((__mode__(__unwind_word__)));
570b57cec5SDimitry Andric typedef uintptr_t _Unwind_Ptr;
580b57cec5SDimitry Andric typedef uintptr_t _Unwind_Internal_Ptr;
590b57cec5SDimitry Andric typedef uint64_t _Unwind_Exception_Class;
600b57cec5SDimitry Andric 
610b57cec5SDimitry Andric typedef intptr_t _sleb128_t;
620b57cec5SDimitry Andric typedef uintptr_t _uleb128_t;
630b57cec5SDimitry Andric 
640b57cec5SDimitry Andric struct _Unwind_Context;
650b57cec5SDimitry Andric #if defined(__arm__) && !(defined(__USING_SJLJ_EXCEPTIONS__) || defined(__ARM_DWARF_EH__))
660b57cec5SDimitry Andric struct _Unwind_Control_Block;
670b57cec5SDimitry Andric typedef struct _Unwind_Control_Block _Unwind_Exception; /* Alias */
680b57cec5SDimitry Andric #else
690b57cec5SDimitry Andric struct _Unwind_Exception;
700b57cec5SDimitry Andric typedef struct _Unwind_Exception _Unwind_Exception;
710b57cec5SDimitry Andric #endif
720b57cec5SDimitry Andric typedef enum {
730b57cec5SDimitry Andric   _URC_NO_REASON = 0,
740b57cec5SDimitry Andric #if defined(__arm__) && !defined(__USING_SJLJ_EXCEPTIONS__) && \
750b57cec5SDimitry Andric     !defined(__ARM_DWARF_EH__)
760b57cec5SDimitry Andric   _URC_OK = 0, /* used by ARM EHABI */
770b57cec5SDimitry Andric #endif
780b57cec5SDimitry Andric   _URC_FOREIGN_EXCEPTION_CAUGHT = 1,
790b57cec5SDimitry Andric 
800b57cec5SDimitry Andric   _URC_FATAL_PHASE2_ERROR = 2,
810b57cec5SDimitry Andric   _URC_FATAL_PHASE1_ERROR = 3,
820b57cec5SDimitry Andric   _URC_NORMAL_STOP = 4,
830b57cec5SDimitry Andric 
840b57cec5SDimitry Andric   _URC_END_OF_STACK = 5,
850b57cec5SDimitry Andric   _URC_HANDLER_FOUND = 6,
860b57cec5SDimitry Andric   _URC_INSTALL_CONTEXT = 7,
870b57cec5SDimitry Andric   _URC_CONTINUE_UNWIND = 8,
880b57cec5SDimitry Andric #if defined(__arm__) && !defined(__USING_SJLJ_EXCEPTIONS__) && \
890b57cec5SDimitry Andric     !defined(__ARM_DWARF_EH__)
900b57cec5SDimitry Andric   _URC_FAILURE = 9 /* used by ARM EHABI */
910b57cec5SDimitry Andric #endif
920b57cec5SDimitry Andric } _Unwind_Reason_Code;
930b57cec5SDimitry Andric 
940b57cec5SDimitry Andric typedef enum {
950b57cec5SDimitry Andric   _UA_SEARCH_PHASE = 1,
960b57cec5SDimitry Andric   _UA_CLEANUP_PHASE = 2,
970b57cec5SDimitry Andric 
980b57cec5SDimitry Andric   _UA_HANDLER_FRAME = 4,
990b57cec5SDimitry Andric   _UA_FORCE_UNWIND = 8,
1000b57cec5SDimitry Andric   _UA_END_OF_STACK = 16 /* gcc extension to C++ ABI */
1010b57cec5SDimitry Andric } _Unwind_Action;
1020b57cec5SDimitry Andric 
1030b57cec5SDimitry Andric typedef void (*_Unwind_Exception_Cleanup_Fn)(_Unwind_Reason_Code,
1040b57cec5SDimitry Andric                                              _Unwind_Exception *);
1050b57cec5SDimitry Andric 
1060b57cec5SDimitry Andric #if defined(__arm__) && !(defined(__USING_SJLJ_EXCEPTIONS__) || defined(__ARM_DWARF_EH__))
1070b57cec5SDimitry Andric typedef struct _Unwind_Control_Block _Unwind_Control_Block;
1080b57cec5SDimitry Andric typedef uint32_t _Unwind_EHT_Header;
1090b57cec5SDimitry Andric 
1100b57cec5SDimitry Andric struct _Unwind_Control_Block {
1110b57cec5SDimitry Andric   uint64_t exception_class;
1120b57cec5SDimitry Andric   void (*exception_cleanup)(_Unwind_Reason_Code, _Unwind_Control_Block *);
1130b57cec5SDimitry Andric   /* unwinder cache (private fields for the unwinder's use) */
1140b57cec5SDimitry Andric   struct {
1150b57cec5SDimitry Andric     uint32_t reserved1; /* forced unwind stop function, 0 if not forced */
1160b57cec5SDimitry Andric     uint32_t reserved2; /* personality routine */
1170b57cec5SDimitry Andric     uint32_t reserved3; /* callsite */
1180b57cec5SDimitry Andric     uint32_t reserved4; /* forced unwind stop argument */
1190b57cec5SDimitry Andric     uint32_t reserved5;
1200b57cec5SDimitry Andric   } unwinder_cache;
1210b57cec5SDimitry Andric   /* propagation barrier cache (valid after phase 1) */
1220b57cec5SDimitry Andric   struct {
1230b57cec5SDimitry Andric     uint32_t sp;
1240b57cec5SDimitry Andric     uint32_t bitpattern[5];
1250b57cec5SDimitry Andric   } barrier_cache;
1260b57cec5SDimitry Andric   /* cleanup cache (preserved over cleanup) */
1270b57cec5SDimitry Andric   struct {
1280b57cec5SDimitry Andric     uint32_t bitpattern[4];
1290b57cec5SDimitry Andric   } cleanup_cache;
1300b57cec5SDimitry Andric   /* personality cache (for personality's benefit) */
1310b57cec5SDimitry Andric   struct {
1320b57cec5SDimitry Andric     uint32_t fnstart;         /* function start address */
1330b57cec5SDimitry Andric     _Unwind_EHT_Header *ehtp; /* pointer to EHT entry header word */
1340b57cec5SDimitry Andric     uint32_t additional;      /* additional data */
1350b57cec5SDimitry Andric     uint32_t reserved1;
1360b57cec5SDimitry Andric   } pr_cache;
1370b57cec5SDimitry Andric   long long int : 0; /* force alignment of next item to 8-byte boundary */
1380b57cec5SDimitry Andric } __attribute__((__aligned__(8)));
1390b57cec5SDimitry Andric #else
1400b57cec5SDimitry Andric struct _Unwind_Exception {
1410b57cec5SDimitry Andric   _Unwind_Exception_Class exception_class;
1420b57cec5SDimitry Andric   _Unwind_Exception_Cleanup_Fn exception_cleanup;
1430b57cec5SDimitry Andric #if !defined (__USING_SJLJ_EXCEPTIONS__) && defined (__SEH__)
1440b57cec5SDimitry Andric   _Unwind_Word private_[6];
1450b57cec5SDimitry Andric #else
1460b57cec5SDimitry Andric   _Unwind_Word private_1;
1470b57cec5SDimitry Andric   _Unwind_Word private_2;
1480b57cec5SDimitry Andric #endif
1490b57cec5SDimitry Andric   /* The Itanium ABI requires that _Unwind_Exception objects are "double-word
1500b57cec5SDimitry Andric    * aligned".  GCC has interpreted this to mean "use the maximum useful
1510b57cec5SDimitry Andric    * alignment for the target"; so do we. */
1520b57cec5SDimitry Andric } __attribute__((__aligned__));
1530b57cec5SDimitry Andric #endif
1540b57cec5SDimitry Andric 
1550b57cec5SDimitry Andric typedef _Unwind_Reason_Code (*_Unwind_Stop_Fn)(int, _Unwind_Action,
1560b57cec5SDimitry Andric                                                _Unwind_Exception_Class,
1570b57cec5SDimitry Andric                                                _Unwind_Exception *,
1580b57cec5SDimitry Andric                                                struct _Unwind_Context *,
1590b57cec5SDimitry Andric                                                void *);
1600b57cec5SDimitry Andric 
1610b57cec5SDimitry Andric typedef _Unwind_Reason_Code (*_Unwind_Personality_Fn)(int, _Unwind_Action,
1620b57cec5SDimitry Andric                                                       _Unwind_Exception_Class,
1630b57cec5SDimitry Andric                                                       _Unwind_Exception *,
1640b57cec5SDimitry Andric                                                       struct _Unwind_Context *);
1650b57cec5SDimitry Andric typedef _Unwind_Personality_Fn __personality_routine;
1660b57cec5SDimitry Andric 
1670b57cec5SDimitry Andric typedef _Unwind_Reason_Code (*_Unwind_Trace_Fn)(struct _Unwind_Context *,
1680b57cec5SDimitry Andric                                                 void *);
1690b57cec5SDimitry Andric 
1700b57cec5SDimitry Andric #if defined(__arm__) && !(defined(__USING_SJLJ_EXCEPTIONS__) || defined(__ARM_DWARF_EH__))
1710b57cec5SDimitry Andric typedef enum {
1720b57cec5SDimitry Andric   _UVRSC_CORE = 0,        /* integer register */
1730b57cec5SDimitry Andric   _UVRSC_VFP = 1,         /* vfp */
1740b57cec5SDimitry Andric   _UVRSC_WMMXD = 3,       /* Intel WMMX data register */
175*0eae32dcSDimitry Andric   _UVRSC_WMMXC = 4,       /* Intel WMMX control register */
176*0eae32dcSDimitry Andric   _UVRSC_PSEUDO = 5       /* Special purpose pseudo register */
1770b57cec5SDimitry Andric } _Unwind_VRS_RegClass;
1780b57cec5SDimitry Andric 
1790b57cec5SDimitry Andric typedef enum {
1800b57cec5SDimitry Andric   _UVRSD_UINT32 = 0,
1810b57cec5SDimitry Andric   _UVRSD_VFPX = 1,
1820b57cec5SDimitry Andric   _UVRSD_UINT64 = 3,
1830b57cec5SDimitry Andric   _UVRSD_FLOAT = 4,
1840b57cec5SDimitry Andric   _UVRSD_DOUBLE = 5
1850b57cec5SDimitry Andric } _Unwind_VRS_DataRepresentation;
1860b57cec5SDimitry Andric 
1870b57cec5SDimitry Andric typedef enum {
1880b57cec5SDimitry Andric   _UVRSR_OK = 0,
1890b57cec5SDimitry Andric   _UVRSR_NOT_IMPLEMENTED = 1,
1900b57cec5SDimitry Andric   _UVRSR_FAILED = 2
1910b57cec5SDimitry Andric } _Unwind_VRS_Result;
1920b57cec5SDimitry Andric 
1930b57cec5SDimitry Andric typedef uint32_t _Unwind_State;
1940b57cec5SDimitry Andric #define _US_VIRTUAL_UNWIND_FRAME  ((_Unwind_State)0)
1950b57cec5SDimitry Andric #define _US_UNWIND_FRAME_STARTING ((_Unwind_State)1)
1960b57cec5SDimitry Andric #define _US_UNWIND_FRAME_RESUME   ((_Unwind_State)2)
1970b57cec5SDimitry Andric #define _US_ACTION_MASK           ((_Unwind_State)3)
1980b57cec5SDimitry Andric #define _US_FORCE_UNWIND          ((_Unwind_State)8)
1990b57cec5SDimitry Andric 
2000b57cec5SDimitry Andric _Unwind_VRS_Result _Unwind_VRS_Get(struct _Unwind_Context *__context,
2010b57cec5SDimitry Andric   _Unwind_VRS_RegClass __regclass,
2020b57cec5SDimitry Andric   uint32_t __regno,
2030b57cec5SDimitry Andric   _Unwind_VRS_DataRepresentation __representation,
2040b57cec5SDimitry Andric   void *__valuep);
2050b57cec5SDimitry Andric 
2060b57cec5SDimitry Andric _Unwind_VRS_Result _Unwind_VRS_Set(struct _Unwind_Context *__context,
2070b57cec5SDimitry Andric   _Unwind_VRS_RegClass __regclass,
2080b57cec5SDimitry Andric   uint32_t __regno,
2090b57cec5SDimitry Andric   _Unwind_VRS_DataRepresentation __representation,
2100b57cec5SDimitry Andric   void *__valuep);
2110b57cec5SDimitry Andric 
2120b57cec5SDimitry Andric static __inline__
2130b57cec5SDimitry Andric _Unwind_Word _Unwind_GetGR(struct _Unwind_Context *__context, int __index) {
2140b57cec5SDimitry Andric   _Unwind_Word __value;
2150b57cec5SDimitry Andric   _Unwind_VRS_Get(__context, _UVRSC_CORE, __index, _UVRSD_UINT32, &__value);
2160b57cec5SDimitry Andric   return __value;
2170b57cec5SDimitry Andric }
2180b57cec5SDimitry Andric 
2190b57cec5SDimitry Andric static __inline__
2200b57cec5SDimitry Andric void _Unwind_SetGR(struct _Unwind_Context *__context, int __index,
2210b57cec5SDimitry Andric                    _Unwind_Word __value) {
2220b57cec5SDimitry Andric   _Unwind_VRS_Set(__context, _UVRSC_CORE, __index, _UVRSD_UINT32, &__value);
2230b57cec5SDimitry Andric }
2240b57cec5SDimitry Andric 
2250b57cec5SDimitry Andric static __inline__
2260b57cec5SDimitry Andric _Unwind_Word _Unwind_GetIP(struct _Unwind_Context *__context) {
2270b57cec5SDimitry Andric   _Unwind_Word __ip = _Unwind_GetGR(__context, 15);
2280b57cec5SDimitry Andric   return __ip & ~(_Unwind_Word)(0x1); /* Remove thumb mode bit. */
2290b57cec5SDimitry Andric }
2300b57cec5SDimitry Andric 
2310b57cec5SDimitry Andric static __inline__
2320b57cec5SDimitry Andric void _Unwind_SetIP(struct _Unwind_Context *__context, _Unwind_Word __value) {
2330b57cec5SDimitry Andric   _Unwind_Word __thumb_mode_bit = _Unwind_GetGR(__context, 15) & 0x1;
2340b57cec5SDimitry Andric   _Unwind_SetGR(__context, 15, __value | __thumb_mode_bit);
2350b57cec5SDimitry Andric }
2360b57cec5SDimitry Andric #else
2370b57cec5SDimitry Andric _Unwind_Word _Unwind_GetGR(struct _Unwind_Context *, int);
2380b57cec5SDimitry Andric void _Unwind_SetGR(struct _Unwind_Context *, int, _Unwind_Word);
2390b57cec5SDimitry Andric 
2400b57cec5SDimitry Andric _Unwind_Word _Unwind_GetIP(struct _Unwind_Context *);
2410b57cec5SDimitry Andric void _Unwind_SetIP(struct _Unwind_Context *, _Unwind_Word);
2420b57cec5SDimitry Andric #endif
2430b57cec5SDimitry Andric 
2440b57cec5SDimitry Andric 
2450b57cec5SDimitry Andric _Unwind_Word _Unwind_GetIPInfo(struct _Unwind_Context *, int *);
2460b57cec5SDimitry Andric 
2470b57cec5SDimitry Andric _Unwind_Word _Unwind_GetCFA(struct _Unwind_Context *);
2480b57cec5SDimitry Andric 
2490b57cec5SDimitry Andric _Unwind_Word _Unwind_GetBSP(struct _Unwind_Context *);
2500b57cec5SDimitry Andric 
2510b57cec5SDimitry Andric void *_Unwind_GetLanguageSpecificData(struct _Unwind_Context *);
2520b57cec5SDimitry Andric 
2530b57cec5SDimitry Andric _Unwind_Ptr _Unwind_GetRegionStart(struct _Unwind_Context *);
2540b57cec5SDimitry Andric 
2550b57cec5SDimitry Andric /* DWARF EH functions; currently not available on Darwin/ARM */
2560b57cec5SDimitry Andric #if !defined(__APPLE__) || !defined(__arm__)
2570b57cec5SDimitry Andric _Unwind_Reason_Code _Unwind_RaiseException(_Unwind_Exception *);
2580b57cec5SDimitry Andric _Unwind_Reason_Code _Unwind_ForcedUnwind(_Unwind_Exception *, _Unwind_Stop_Fn,
2590b57cec5SDimitry Andric                                          void *);
2600b57cec5SDimitry Andric void _Unwind_DeleteException(_Unwind_Exception *);
2610b57cec5SDimitry Andric void _Unwind_Resume(_Unwind_Exception *);
2620b57cec5SDimitry Andric _Unwind_Reason_Code _Unwind_Resume_or_Rethrow(_Unwind_Exception *);
2630b57cec5SDimitry Andric 
2640b57cec5SDimitry Andric #endif
2650b57cec5SDimitry Andric 
2660b57cec5SDimitry Andric _Unwind_Reason_Code _Unwind_Backtrace(_Unwind_Trace_Fn, void *);
2670b57cec5SDimitry Andric 
2680b57cec5SDimitry Andric /* setjmp(3)/longjmp(3) stuff */
2690b57cec5SDimitry Andric typedef struct SjLj_Function_Context *_Unwind_FunctionContext_t;
2700b57cec5SDimitry Andric 
2710b57cec5SDimitry Andric void _Unwind_SjLj_Register(_Unwind_FunctionContext_t);
2720b57cec5SDimitry Andric void _Unwind_SjLj_Unregister(_Unwind_FunctionContext_t);
2730b57cec5SDimitry Andric _Unwind_Reason_Code _Unwind_SjLj_RaiseException(_Unwind_Exception *);
2740b57cec5SDimitry Andric _Unwind_Reason_Code _Unwind_SjLj_ForcedUnwind(_Unwind_Exception *,
2750b57cec5SDimitry Andric                                               _Unwind_Stop_Fn, void *);
2760b57cec5SDimitry Andric void _Unwind_SjLj_Resume(_Unwind_Exception *);
2770b57cec5SDimitry Andric _Unwind_Reason_Code _Unwind_SjLj_Resume_or_Rethrow(_Unwind_Exception *);
2780b57cec5SDimitry Andric 
2790b57cec5SDimitry Andric void *_Unwind_FindEnclosingFunction(void *);
2800b57cec5SDimitry Andric 
2810b57cec5SDimitry Andric #ifdef __APPLE__
2820b57cec5SDimitry Andric 
2830b57cec5SDimitry Andric _Unwind_Ptr _Unwind_GetDataRelBase(struct _Unwind_Context *)
2840b57cec5SDimitry Andric     __attribute__((__unavailable__));
2850b57cec5SDimitry Andric _Unwind_Ptr _Unwind_GetTextRelBase(struct _Unwind_Context *)
2860b57cec5SDimitry Andric     __attribute__((__unavailable__));
2870b57cec5SDimitry Andric 
2880b57cec5SDimitry Andric /* Darwin-specific functions */
2890b57cec5SDimitry Andric void __register_frame(const void *);
2900b57cec5SDimitry Andric void __deregister_frame(const void *);
2910b57cec5SDimitry Andric 
2920b57cec5SDimitry Andric struct dwarf_eh_bases {
2930b57cec5SDimitry Andric   uintptr_t tbase;
2940b57cec5SDimitry Andric   uintptr_t dbase;
2950b57cec5SDimitry Andric   uintptr_t func;
2960b57cec5SDimitry Andric };
2970b57cec5SDimitry Andric void *_Unwind_Find_FDE(const void *, struct dwarf_eh_bases *);
2980b57cec5SDimitry Andric 
2990b57cec5SDimitry Andric void __register_frame_info_bases(const void *, void *, void *, void *)
3000b57cec5SDimitry Andric   __attribute__((__unavailable__));
3010b57cec5SDimitry Andric void __register_frame_info(const void *, void *) __attribute__((__unavailable__));
3020b57cec5SDimitry Andric void __register_frame_info_table_bases(const void *, void*, void *, void *)
3030b57cec5SDimitry Andric   __attribute__((__unavailable__));
3040b57cec5SDimitry Andric void __register_frame_info_table(const void *, void *)
3050b57cec5SDimitry Andric   __attribute__((__unavailable__));
3060b57cec5SDimitry Andric void __register_frame_table(const void *) __attribute__((__unavailable__));
3070b57cec5SDimitry Andric void __deregister_frame_info(const void *) __attribute__((__unavailable__));
3080b57cec5SDimitry Andric void __deregister_frame_info_bases(const void *)__attribute__((__unavailable__));
3090b57cec5SDimitry Andric 
3100b57cec5SDimitry Andric #else
3110b57cec5SDimitry Andric 
3120b57cec5SDimitry Andric _Unwind_Ptr _Unwind_GetDataRelBase(struct _Unwind_Context *);
3130b57cec5SDimitry Andric _Unwind_Ptr _Unwind_GetTextRelBase(struct _Unwind_Context *);
3140b57cec5SDimitry Andric 
3150b57cec5SDimitry Andric #endif
3160b57cec5SDimitry Andric 
3170b57cec5SDimitry Andric 
3180b57cec5SDimitry Andric #ifndef HIDE_EXPORTS
3190b57cec5SDimitry Andric #pragma GCC visibility pop
3200b57cec5SDimitry Andric #endif
3210b57cec5SDimitry Andric 
3220b57cec5SDimitry Andric #ifdef __cplusplus
3230b57cec5SDimitry Andric }
3240b57cec5SDimitry Andric #endif
3250b57cec5SDimitry Andric 
3260b57cec5SDimitry Andric #endif
3270b57cec5SDimitry Andric 
3280b57cec5SDimitry Andric #endif /* __CLANG_UNWIND_H */
329