Commit Graph

11 Commits

Author SHA1 Message Date
John Baldwin e3e433b038 [libunwind] Permit additional compiler and linker flags to be passed to tests.
Summary:
This is done via new LIBUNWIND_TEST_COMPILER_FLAGS and
LIBUNWIND_TEST_LINKER_FLAGS variables.

Reviewed By: sdardis

Differential Revision: https://reviews.llvm.org/D43585

llvm-svn: 326223
2018-02-27 18:40:04 +00:00
Petr Hosek 9d30c313f1 [libunwind] Pass LIBUNWIND_SYSROOT and LIBUNWIND_GCC_TOOLCHAIN to lit
These are expected to be set by the shared lit scripts used from
libc++.

Differential Revision: https://reviews.llvm.org/D40817

llvm-svn: 319823
2017-12-05 20:22:10 +00:00
Peter Smith 7f6e910745 [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

llvm-svn: 316657
2017-10-26 12:02:03 +00:00
Saleem Abdulrasool f8774f1d73 ARM: explicitly specify the 8-byte alignment
It seems that GCC interprets `__attribute__((__aligned__))` as 8-byte
alignment on ARM, but clang does not.  Explicitly specify the
double-word alignment value to ensure that the structure is properly
aligned.

llvm-svn: 311574
2017-08-23 16:50:27 +00:00
Jonathan Roelofs 2cfff07a42 Partial fix for PR33858
https://reviews.llvm.org/D35848

llvm-svn: 309147
2017-07-26 18:13:57 +00:00
Jonathan Roelofs 6e50d93afc Add a test harness
Mostly cargo-culted from libcxxabi, since the unwinder was forked from there in
the first place. There may still be cruft that's only applicable to libcxxabi,
but that can be addressed in-tree.

https://reviews.llvm.org/D35038

llvm-svn: 307266
2017-07-06 15:20:12 +00:00
Eric Fiselier 19f802ff68 [libunwind] Properly align _Unwind_Exception.
Summary: _Unwind_Exception is required to be double word aligned. Currently the struct is under aligned.

Reviewers: mclow.lists, compnerd, kledzik, emaste

Subscribers: emaste, cfe-commits

Differential Revision: https://reviews.llvm.org/D22543

llvm-svn: 276215
2016-07-20 23:56:42 +00:00
Logan Chien 549d405877 Fix unw_getcontext() return value on AArch64.
unw_getcontext() should return UNW_ESUCCESS on success.  Therefore, the
assembly for AArch64 is incorrect because "ldr x0, #0" is a PC-relative
load instead of an immediate value load.

llvm-svn: 240648
2015-06-25 15:12:46 +00:00
Logan Chien 7fab97f364 libunwind: Fix unw_step() for ARM EHABI.
This commit fixes the unw_step() for ARM EHABI.  However, this commit
also changes the implementation details for ARM EHABI.

The first change is that the personality function should call
__gnu_unwind_frame() for default (or de facto) frame unwinding based on
the ARM-defined unwind opcode.  The function __gnu_unwind_frame() will
in turn calls unw_step() which actually unwinds the frame.

The second change is that the implementation _Unwind_Backtrace() should
no longer calls unw_step() to unwind the frame; since according to ARM
EHABI, the personality function should unwind the frame for us.

Special thanks to Anton for helpful suggestion on the initial version of
this patch.

llvm-svn: 238560
2015-05-29 15:33:38 +00:00
Saleem Abdulrasool a211afa448 unwind: remove libc++abi tests
These are related to libc++abi's personality routine and not core unwinding.
These have been restored in libc++abi, and are no longer needed here.

llvm-svn: 235766
2015-04-24 20:21:43 +00:00
Saleem Abdulrasool b1b1911777 unwind: move src/Unwind, include/, and test/ unwind content
This moves the majority of the unwind sources into the new project layout for
libunwind.  This was previously discussed on llvmdev at [1].  This is a
purely movement related change, with the build infrastructure currently still
residing in the libc++abi repository.

[1] http://lists.cs.uiuc.edu/pipermail/llvmdev/2015-January/081507.html

llvm-svn: 235758
2015-04-24 19:39:17 +00:00