From f0e8138accb980bfffa7479d3140f1202b3a6bb6 Mon Sep 17 00:00:00 2001 From: David Calvert Date: Mon, 25 Sep 2023 06:53:23 +0200 Subject: [PATCH] fix: orc unwinder link in stack-traces.md Signed-off-by: David Calvert --- stack-traces.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/stack-traces.md b/stack-traces.md index 7fa0963..44e24dc 100644 --- a/stack-traces.md +++ b/stack-traces.md @@ -170,7 +170,7 @@ Last but not least, it's worth noting that Go ships with two `.gopclntab` implem > The whole (and *only*) point of unwinders is to make debugging easy when a bug occurs [...]. An unwinder that is several hundred lines long is simply not even *remotely* interesting to me. > – [Linus Torvalds](https://lkml.org/lkml/2012/2/10/356) -This lead to the [creation](https://lwn.net/Articles/728339/) of the [ORC unwinder](https://www.kernel.org/doc/html/latest/x86/orc-unwinder.html) which is now available in the kernel as yet another unwinding mechanism. However, ORCs play no role for Go stack traces, we only have to fight with ELFs and DWARFs here. +This lead to the [creation](https://lwn.net/Articles/728339/) of the [ORC unwinder](https://www.kernel.org/doc/html/latest/arch/x86/orc-unwinder.html) which is now available in the kernel as yet another unwinding mechanism. However, ORCs play no role for Go stack traces, we only have to fight with ELFs and DWARFs here. The Go compiler always emits DWARF (v4) information for the binaries it produces. The format is standardized, so unlike `gopclntab`, external tools can rely on it. However, the DWARF data is also largely redundant with `gopclntab` and negatively impacts build times and binary sizes. Because of this Rob Pike is proposing to [disable it by default](https://github.com/golang/go/issues/26074), but it's still under discussion.