summaryrefslogtreecommitdiffstats
path: root/libunwind
diff options
context:
space:
mode:
authorSaleem Abdulrasool <compnerd@compnerd.org>2016-04-22 17:11:05 +0000
committerSaleem Abdulrasool <compnerd@compnerd.org>2016-04-22 17:11:05 +0000
commit39d86f44cb8263ff1c34999a7489fd137dc26108 (patch)
tree3a725bd7850c632405011a40182bc9ba97a34ade /libunwind
parenta630380a0c08c6b33e08679994c9d94d699274c2 (diff)
downloadbcm5719-llvm-39d86f44cb8263ff1c34999a7489fd137dc26108.tar.gz
bcm5719-llvm-39d86f44cb8263ff1c34999a7489fd137dc26108.zip
unwind: unify some more macros
The macros were defined identically across both cases. Unify the definitions to have a single definition for _LIBUWNIND_{HIDDEN,EXPORT} and _LIBUNWIND_LOG. NFC. llvm-svn: 267169
Diffstat (limited to 'libunwind')
-rw-r--r--libunwind/src/config.h13
1 files changed, 6 insertions, 7 deletions
diff --git a/libunwind/src/config.h b/libunwind/src/config.h
index 127dcd6b0f7..6ecad701e86 100644
--- a/libunwind/src/config.h
+++ b/libunwind/src/config.h
@@ -40,9 +40,6 @@
#endif
#define _LIBUNWIND_BUILD_SJLJ_APIS defined(__arm__)
- #define _LIBUNWIND_EXPORT __attribute__((visibility("default")))
- #define _LIBUNWIND_HIDDEN __attribute__((visibility("hidden")))
- #define _LIBUNWIND_LOG(msg, ...) fprintf(stderr, "libuwind: " msg, __VA_ARGS__)
#define _LIBUNWIND_ABORT(msg) __assert_rtn(__func__, __FILE__, __LINE__, msg)
#if defined(FOR_DYLD)
@@ -54,7 +51,6 @@
#define _LIBUNWIND_SUPPORT_DWARF_UNWIND 1
#define _LIBUNWIND_SUPPORT_DWARF_INDEX 0
#endif
-
#else
#include <stdlib.h>
@@ -66,9 +62,6 @@
}
#define _LIBUNWIND_BUILD_SJLJ_APIS 0
- #define _LIBUNWIND_EXPORT __attribute__((visibility("default")))
- #define _LIBUNWIND_HIDDEN __attribute__((visibility("hidden")))
- #define _LIBUNWIND_LOG(msg, ...) fprintf(stderr, "libuwind: " msg, __VA_ARGS__)
#define _LIBUNWIND_ABORT(msg) assert_rtn(__func__, __FILE__, __LINE__, msg)
#if defined(__ARM_DWARF_EH__) || !defined(__arm__)
@@ -82,6 +75,10 @@
#endif
#endif
+// FIXME: these macros are not correct for COFF targets
+#define _LIBUNWIND_EXPORT __attribute__((visibility("default")))
+#define _LIBUNWIND_HIDDEN __attribute__((visibility("hidden")))
+
#if defined(__i386__) || defined(__x86_64__)
#define _LIBUNWIND_SUPPORT_FRAME_APIS 1
#else
@@ -97,6 +94,8 @@
#define _LIBUNWIND_BUILD_ZERO_COST_APIS 0
#endif
+#define _LIBUNWIND_LOG(msg, ...) fprintf(stderr, "libuwind: " msg, __VA_ARGS__)
+
// Macros that define away in non-Debug builds
#ifdef NDEBUG
#define _LIBUNWIND_DEBUG_LOG(msg, ...)
OpenPOWER on IntegriCloud