summaryrefslogtreecommitdiff
path: root/libcxxabi/include
diff options
context:
space:
mode:
authorSaleem Abdulrasool <compnerd@compnerd.org>2015-02-12 04:25:03 +0000
committerSaleem Abdulrasool <compnerd@compnerd.org>2015-02-12 04:25:03 +0000
commita6b32ccec40567846ac6a30e20058bb76bab55d9 (patch)
tree31d7b3968ea7cd36bf4bdfb70d4066d02e13e258 /libcxxabi/include
parentd0c6468a2b2b5dc980cf36d0c210c0e7a16a3a71 (diff)
downloadllvm-a6b32ccec40567846ac6a30e20058bb76bab55d9.tar.gz
unwind: move exported APIs out of header
Ideally, we would do something like inline __declspec(dllexport) to ensure that the symbol was inlined within libunwind as well as emitted into the final DSO. This simply moves the definition out of the header to ensure that the *public* interfaces are defined and exported into the final DSO. This change also has "gratuitous" code movement so that the EHABI and generic implementations are co-located making it easier to find them. The movement from the header has one minor change introduced into the code: additional tracing to mirror the behaviour of the non-EHABI interfaces. llvm-svn: 228903
Diffstat (limited to 'libcxxabi/include')
-rw-r--r--libcxxabi/include/unwind.h26
1 files changed, 1 insertions, 25 deletions
diff --git a/libcxxabi/include/unwind.h b/libcxxabi/include/unwind.h
index 3d889cf40ac4..86001bbb5633 100644
--- a/libcxxabi/include/unwind.h
+++ b/libcxxabi/include/unwind.h
@@ -202,37 +202,13 @@ extern _Unwind_VRS_Result
_Unwind_VRS_Pop(_Unwind_Context *context, _Unwind_VRS_RegClass regclass,
uint32_t discriminator,
_Unwind_VRS_DataRepresentation representation);
+#endif
-static inline uintptr_t _Unwind_GetGR(struct _Unwind_Context* context,
- int index) {
- uintptr_t value = 0;
- _Unwind_VRS_Get(context, _UVRSC_CORE, (uint32_t)index, _UVRSD_UINT32, &value);
- return value;
-}
-
-static inline void _Unwind_SetGR(struct _Unwind_Context* context, int index,
- uintptr_t new_value) {
- _Unwind_VRS_Set(context, _UVRSC_CORE, (uint32_t)index,
- _UVRSD_UINT32, &new_value);
-}
-
-static inline uintptr_t _Unwind_GetIP(struct _Unwind_Context* context) {
- // remove the thumb-bit before returning
- return (_Unwind_GetGR(context, 15) & (~(uintptr_t)0x1));
-}
-
-static inline void _Unwind_SetIP(struct _Unwind_Context* context,
- uintptr_t new_value) {
- uintptr_t thumb_bit = _Unwind_GetGR(context, 15) & ((uintptr_t)0x1);
- _Unwind_SetGR(context, 15, new_value | thumb_bit);
-}
-#else
extern uintptr_t _Unwind_GetGR(struct _Unwind_Context *context, int index);
extern void _Unwind_SetGR(struct _Unwind_Context *context, int index,
uintptr_t new_value);
extern uintptr_t _Unwind_GetIP(struct _Unwind_Context *context);
extern void _Unwind_SetIP(struct _Unwind_Context *, uintptr_t new_value);
-#endif
extern uintptr_t _Unwind_GetRegionStart(struct _Unwind_Context *context);
extern uintptr_t