[flang-commits] [flang] [flang]Add new intrinsic function backtrace and complete the TODO of abort (PR #117603)

Krzysztof Parzyszek via flang-commits flang-commits at lists.llvm.org
Tue Nov 26 07:52:55 PST 2024


================
@@ -15,6 +15,7 @@
 #include <cfenv>
 #include <cstdio>
 #include <cstdlib>
+#include <execinfo.h>
----------------
kparzysz wrote:

We have a config file with the results of the checks made by cmake: `<build-dir>/include/llvm/Config/config.h`.  One of these checks is for the `backtrace` function, and the header that declares it.
Please add
```
#include "llvm/Config/config.h"
```
then replace the `#ifdef __linux__` part with
```
#ifdef HAVE_BACKTRACE
#include BACKTRACE_HEADER
#endif
```

https://github.com/llvm/llvm-project/pull/117603


More information about the flang-commits mailing list