diff options
author | Peter Smith <peter.smith@linaro.org> | 2017-10-26 12:02:03 +0000 |
---|---|---|
committer | Peter Smith <peter.smith@linaro.org> | 2017-10-26 12:02:03 +0000 |
commit | 1f034adc84a9957ca3ed7a816ff23ad4584ad645 (patch) | |
tree | a6ffe618a5f21d54f21534f8eb9e4d3d694cf745 | |
parent | f44b1d24311cd272caedc1742636e6c535f73ecd (diff) |
[libunwind] Always use unwind tables in tests
For many targets setting -fno-exceptions will prevent unwinding tables from
being generated for the test programs. As libunwind depends on the tables to
unwind the stack several tests will fail.
This change always adds -funwind-tables so that even when -fno-exceptions
is set unwind tables are generated.
fixes PR33858
Differential Revision: https://reviews.llvm.org/D37484
git-svn-id: https://llvm.org/svn/llvm-project/libunwind/trunk@316657 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r-- | test/libunwind/test/config.py | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/test/libunwind/test/config.py b/test/libunwind/test/config.py index f5a1e88..2a0c828 100644 --- a/test/libunwind/test/config.py +++ b/test/libunwind/test/config.py @@ -43,10 +43,11 @@ class Configuration(LibcxxConfiguration): def configure_compile_flags(self): self.cxx.compile_flags += ['-DLIBUNWIND_NO_TIMER'] - if self.get_lit_bool('enable_exceptions', True): - self.cxx.compile_flags += ['-funwind-tables'] - else: + if not self.get_lit_bool('enable_exceptions', True): self.cxx.compile_flags += ['-fno-exceptions', '-DLIBUNWIND_HAS_NO_EXCEPTIONS'] + # Stack unwinding tests need unwinding tables and these are not + # generated by default on all Targets. + self.cxx.compile_flags += ['-funwind-tables'] if not self.get_lit_bool('enable_threads', True): self.cxx.compile_flags += ['-D_LIBUNWIND_HAS_NO_THREADS'] self.config.available_features.add('libunwind-no-threads') |