[PATCH] D39251: [libunwind] Fix building for ARM with dwarf exception handling

Martin Storsjö via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Oct 24 11:56:49 PDT 2017


mstorsjo created this revision.
Herald added subscribers: kristof.beyls, aprantl, aemerson.

The previous definition of _LIBUNWIND_HIGHEST_DWARF_REGISTER seems to be a copy of the ARM64 value (introduced in SVN r276128); since the code actually hasn't compiled properly for arm in dwarf mode before, this hasn't actually been used. Set it to the correct value based on the UNW_ARM_* enum values.

Use the same size for data types unw_word_t as for _LIBUNWIND_ARM_EHABI, to have the struct sizes match.

This requires adding casts in a log line, where the data types (unw_word_t) implicitly were assumed be uint64_t. Normally mismatched
printf formats aren't fatal (and might go unnoticed), unless a later parameter is interpreted as a string, when it becomes fatal.


https://reviews.llvm.org/D39251

Files:
  include/__libunwind_config.h
  include/libunwind.h
  src/Registers.hpp
  src/UnwindCursor.hpp
  src/UnwindLevel1.c
  src/libunwind.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D39251.120110.patch
Type: text/x-patch
Size: 3445 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20171024/51b35201/attachment.bin>


More information about the cfe-commits mailing list