In D61448 the cmake option LLVM_ENABLE_UNWIND_TABLES was added. Despite the name suggesting that the option enables unwind tables, that patch only uses it to disable them. That makes a difference for architectures where unwind tables aren't enabled by default (assuming we compile with -fno-exceptions, which we typically do due to LLVM_ENABLE_EH defaulting to OFF). The lack of unwind tables impacts backtraces (for some architectures/configurations) and the current handling of the option doesn't allow enabling them.
This patch makes an ON value of LLVM_ENABLE_UNWIND_TABLES actually enable unwind tables.
With this change, perhaps we should also now make LLVM_ENABLE_UNWIND_TABLES be OFF by default. That preserves compatibility in some cases but introduces configuration changes in other cases. The only way to ensure full compatibility would be if we made this a ternary option (force on; default; force off).
(For context, this is part of a series of patches that I'm working on to fix/test backtraces)