[libcxx-commits] [PATCH] D111667: [libc++abi] Change LIBCXXABI_NO_TIMER to LIBCXXABI_USE_TIMER
Louis Dionne via Phabricator via libcxx-commits
libcxx-commits at lists.llvm.org
Tue Oct 12 11:57:34 PDT 2021
ldionne created this revision.
Herald added a project: libunwind.
Herald added a subscriber: libcxx-commits.
Herald added a reviewer: libunwind.
ldionne requested review of this revision.
Herald added a project: libc++abi.
Herald added a reviewer: libc++abi.
Instead of always defining LIBCXXABI_NO_TIMER to run the tests, only
define LIBCXXABI_USE_TIMER when we want to enable the timer. This makes
the libc++abi testing configuration simpler.
As a fly-by fix, remove the unused LIBUNWIND_NO_TIMER macro from libunwind.
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D111667
Files:
libcxxabi/test/libcxxabi/test/config.py
libcxxabi/test/support/timer.h
libunwind/test/libunwind/test/config.py
Index: libunwind/test/libunwind/test/config.py
===================================================================
--- libunwind/test/libunwind/test/config.py
+++ libunwind/test/libunwind/test/config.py
@@ -39,7 +39,6 @@
self.config.available_features.add('libunwind-arm-ehabi')
def configure_compile_flags(self):
- self.cxx.compile_flags += ['-DLIBUNWIND_NO_TIMER']
# Stack unwinding tests need unwinding tables and these are not
# generated by default on all Targets.
self.cxx.compile_flags += ['-funwind-tables']
Index: libcxxabi/test/support/timer.h
===================================================================
--- libcxxabi/test/support/timer.h
+++ libcxxabi/test/support/timer.h
@@ -9,8 +9,8 @@
#ifndef TIMER_H
#define TIMER_H
-// Define LIBCXXABI_NO_TIMER to disable testing with a timer.
-#ifndef LIBCXXABI_NO_TIMER
+// Define LIBCXXABI_USE_TIMER to enable testing with a timer.
+#ifndef LIBCXXABI_USE_TIMER
#include <chrono>
#include <cstdio>
@@ -38,7 +38,7 @@
TimePoint m_start;
};
-#else /* LIBCXXABI_NO_TIMER */
+#else /* LIBCXXABI_USE_TIMER */
class timer
{
@@ -49,6 +49,6 @@
~timer() {}
};
-#endif /* LIBCXXABI_NO_TIMER */
+#endif /* LIBCXXABI_USE_TIMER */
#endif /* TIMER_H */
Index: libcxxabi/test/libcxxabi/test/config.py
===================================================================
--- libcxxabi/test/libcxxabi/test/config.py
+++ libcxxabi/test/libcxxabi/test/config.py
@@ -44,7 +44,6 @@
def configure_compile_flags(self):
self.cxx.compile_flags += [
- '-DLIBCXXABI_NO_TIMER',
'-D_LIBCPP_ENABLE_CXX17_REMOVED_UNEXPECTED_FUNCTIONS',
]
if self.get_lit_bool('enable_exceptions', True):
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D111667.379130.patch
Type: text/x-patch
Size: 1758 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/libcxx-commits/attachments/20211012/2bb89365/attachment.bin>
More information about the libcxx-commits
mailing list