michael-kenzel wrote:
@arichardson as promised, I have rebased the changes. I'm not sure about the
test failures, it would seem to me that they are unlikely to be caused by
anything I did?
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commi
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From 70ef8570614f1fe8140f24bbe27f69f9c1deb994 Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] Remove unnecessary dependencies on stdio.h fo
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From 8c59516b8235049dc74e2496b9e1a1833d38f494 Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] Remove unnecessary dependencies on stdio.h fo
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
michael-kenzel wrote:
> @michael-kenzel Was there a reason why this never got merged?
I don't think there was, I guess this just fell through the cracks…
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.ll
@@ -381,24 +381,22 @@ typename A::pint_t
DwarfInstructions::evaluateExpression(pint_t expression, A &addressSpace,
const R ®isters,
pint_t initialStackValue) {
- const bool log = false;
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -223,6 +221,41 @@
} while (0)
#endif
+#define _LIBUNWIND_TRACING_COMPACT_UNWIND (0)
+#if !_LIBUNWIND_TRACING_COMPACT_UNWIND
+#define _LIBUNWIND_TRACE_COMPACT_UNWIND0(msg)
+#define _LIBUNWIND_TRACE_COMPACT_UNWIND(msg, ...)
+#else
+#define _LIBUNWIND_TRACE_COMPACT_UNWIND0
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -223,6 +221,41 @@
} while (0)
#endif
+#define _LIBUNWIND_TRACING_COMPACT_UNWIND (0)
+#if !_LIBUNWIND_TRACING_COMPACT_UNWIND
+#define _LIBUNWIND_TRACE_COMPACT_UNWIND0(msg)
+#define _LIBUNWIND_TRACE_COMPACT_UNWIND(msg, ...)
+#else
+#define _LIBUNWIND_TRACE_COMPACT_UNWIND0
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
michael-kenzel wrote:
> [AddressSpace.hpp](https://github.com/llvm/llvm-project/pull/72040/files#diff-dc10e493a84f7de241e331f66a5af195689f08d45a6fd0da90b275a662856327)
> was using `snprintf` to copy strings into a buffer. I replaced those uses
> with `strncpy` to remove the need for ``.
As dis
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From fcdccb35b8c641b99bfb72948520771d9969671a Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] Remove unnecessary dependencies on stdio.h fo
@@ -672,7 +671,7 @@ inline bool LocalAddressSpace::findFunctionName(pint_t
addr, char *buf,
Dl_info dyldInfo;
if (dladdr((void *)addr, &dyldInfo)) {
if (dyldInfo.dli_sname != NULL) {
- snprintf(buf, bufLen, "%s", dyldInfo.dli_sname);
+ strncpy(buf, dyldInfo.d
https://github.com/michael-kenzel ready_for_review
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
michael-kenzel wrote:
As discussed, I've removed unnecessary includes of `` as well as a
couple other unnecessary includes. I've put the include of `` in
`config.h` under an `#ifdef` so it only gets included when logging is
potentially active. I've also moved the include of `` from `config.h`
https://github.com/michael-kenzel reopened
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
michael-kenzel wrote:
As discussed, I've removed unnecessary includes of `` as well as a
couple other unnecessary includes. I've put the include of `` in
`config.h` under an `#ifdef` so it only gets included when logging is
potentially active. I've also moved the include of `` from `config.h`
https://github.com/michael-kenzel closed
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From f8b562dbd0c5927b92c5314ea70745b9b3ec1535 Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] Remove unnecessary dependencies on stdio.h fo
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From a72cef20e847e85a5fedb56d1b9d1414dbd7e516 Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] Introduce _LIBUNWIND_TRACE_DWARF_EVAL
---
l
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From 0bedd8b680bf8f2957a6056e92eb1cb92a8666e3 Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] Introduce _LIBUNWIND_TRACE_DWARF_EVAL
---
l
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From f98bbd27427a3cc03dbb933c2fccbab73b557cec Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] Introduce _LIBUNWIND_TRACE_DWARF_EVAL
---
l
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From c78b3f5267a5809f1d29a17dd392a8a2d0b4147c Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] Introduce _LIBUNWIND_TRACE_DWARF_EVAL
---
l
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From 42bfd80e85095d8a1c94926fb907874f1c73f5c3 Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] Introduce _LIBUNWIND_TRACE_DWARF_EVAL
---
l
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From ef0ec53cdcc3cd2b42bfaafe2504f4e90fbf0c2e Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] Introduce _LIBUNWIND_TRACE_DWARF_EVAL
---
l
@@ -381,24 +381,22 @@ typename A::pint_t
DwarfInstructions::evaluateExpression(pint_t expression, A &addressSpace,
const R ®isters,
pint_t initialStackValue) {
- const bool log = false;
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel converted_to_draft
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -381,24 +381,22 @@ typename A::pint_t
DwarfInstructions::evaluateExpression(pint_t expression, A &addressSpace,
const R ®isters,
pint_t initialStackValue) {
- const bool log = false;
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -381,24 +381,22 @@ typename A::pint_t
DwarfInstructions::evaluateExpression(pint_t expression, A &addressSpace,
const R ®isters,
pint_t initialStackValue) {
- const bool log = false;
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
michael-kenzel wrote:
I found another use of the same string copying in `tests/forceunwind.pass.cpp`
and updated that to match.
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72043
>From d5adc242a9c52c7de2a860489a4292b7461b6164 Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sun, 12 Nov 2023 02:46:15 +0100
Subject: [PATCH] [libunwind] Remove unnecessary strcpy dependency
---
li
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -143,7 +143,7 @@ _Unwind_Backtrace(_Unwind_Trace_Fn callback, void *ref) {
// Create a mock exception object for force unwinding.
_Unwind_Exception ex;
memset(&ex, '\0', sizeof(ex));
- strcpy((char *)&ex.exception_class, "CLNGUNW");
+ memcpy(&ex.exception_class, "CLN
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
michael-kenzel wrote:
> I would assume this is already transformed to memcpy but I guess it won't be
> for -O0
[I did some testing on this](https://godbolt.org/z/YMEjbxYd9): it seems that
gcc replaces the `strcpy` with a simple `mov` even under `-O0`, but not the
`memcpy`. clang does the reve
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From 7e285a5121be99e41097e4615cab7568e1f4b7d0 Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] Introduce _LIBUNWIND_TRACE_DWARF_EVAL
---
l
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72043
>From c423c5bd51bd7aa093025b2892706b1968eba09d Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sun, 12 Nov 2023 02:46:15 +0100
Subject: [PATCH] [libunwind] Remove unnecessary strcpy dependency
---
li
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72043
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From 00742101facde57594384727de3359d1d85554a4 Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] introduce _LIBUNWIND_TRACE_DWARF_EVAL
---
l
https://github.com/michael-kenzel created
https://github.com/llvm/llvm-project/pull/72043
libunwind uses a minimum set of necessary standard library functions, basically
just `memset` and `memcpy`. There is a single use of `strcpy` to copy the bytes
`"CLNGUNW"` into a `uint64_t` object. This i
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From cd42165f8b3c74f58632ee12d60aa5cfc6a14b4a Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] introduce _LIBUNWIND_TRACE_DWARF_EVAL
---
l
https://github.com/michael-kenzel updated
https://github.com/llvm/llvm-project/pull/72040
>From 85eb8a3f5accfdb8c90b8e45a7ff0f7480e648ce Mon Sep 17 00:00:00 2001
From: Michael Kenzel
Date: Sat, 11 Nov 2023 22:09:05 +0100
Subject: [PATCH] [libunwind] introduce _LIBUNWIND_TRACE_DWARF_EVAL
---
l
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -223,6 +223,21 @@
} while (0)
#endif
+#define _LIBUNWIND_TRACING_DWARF_EVAL (0)
michael-kenzel wrote:
In fact, since this is more some kind of internal feature, maybe it shouldn't
be in the config header at all but rather just defined and undef'ed aga
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
https://github.com/michael-kenzel edited
https://github.com/llvm/llvm-project/pull/72040
___
cfe-commits mailing list
cfe-commits@lists.llvm.org
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
@@ -223,6 +223,21 @@
} while (0)
#endif
+#define _LIBUNWIND_TRACING_DWARF_EVAL (0)
michael-kenzel wrote:
Yeah, I figured if anyone ever actually needed to turn this on for debug builds
in general, they'd have added that option. It seemed to me like this
https://github.com/michael-kenzel created
https://github.com/llvm/llvm-project/pull/72040
libunwind already puts logging facilities behind macros so that they can be
turned on and off. The one place where this isn't done yet is for debug output
tracing DWARF evaluation. The code there directly
85 matches
Mail list logo