aboutsummaryrefslogtreecommitdiff
path: root/src/runtime/export_windows_test.go
diff options
context:
space:
mode:
authorqmuntal <quimmuntal@gmail.com>2023-03-09 14:55:31 +0100
committerQuim Muntal <quimmuntal@gmail.com>2023-04-10 18:52:58 +0000
commit65ea4c5021d44395db8728eea16eb8f7fc7420eb (patch)
treeaf729f4aed221fc5d7515141fd1c8cab28056654 /src/runtime/export_windows_test.go
parent5e93a2c2042484ee7a941e967294a5248ab6a593 (diff)
downloadgo-65ea4c5021d44395db8728eea16eb8f7fc7420eb.tar.xz
runtime: support GOTRACEBACK=wer on Windows
GOTRACEBACK=wer is a new traceback level that acts as "crash" and also enables WER. The same effect can be achieved using debug.SetTraceback("wer"). The Go runtime currently crashes using exit(2), which bypasses WER even if it is enabled. To best way to trigger WER is calling RaiseFailFastException [1] instead, which internally launches the WER machinery. This CL also changes how GOTRACEBACK=crash crashes, so both "wer" and "crash" crash using RaiseFailFastException, which simplifies the implementation and resolves a longstanding TODO. Fixes #57441 Fixes #20498 [1] https://learn.microsoft.com/en-us/windows/win32/api/errhandlingapi/nf-errhandlingapi-raisefailfastexception Change-Id: I45669d619fbbd2f6413ce5e5f08425ed1d9aeb64 Reviewed-on: https://go-review.googlesource.com/c/go/+/474915 Reviewed-by: Davis Goodin <dagood@microsoft.com> TryBot-Result: Gopher Robot <gobot@golang.org> Reviewed-by: David Chase <drchase@google.com> Reviewed-by: Than McIntosh <thanm@google.com> Reviewed-by: Alex Brainman <alex.brainman@gmail.com> Run-TryBot: Quim Muntal <quimmuntal@gmail.com>
Diffstat (limited to 'src/runtime/export_windows_test.go')
-rw-r--r--src/runtime/export_windows_test.go1
1 files changed, 0 insertions, 1 deletions
diff --git a/src/runtime/export_windows_test.go b/src/runtime/export_windows_test.go
index d4b1e1fad3..332136b586 100644
--- a/src/runtime/export_windows_test.go
+++ b/src/runtime/export_windows_test.go
@@ -11,7 +11,6 @@ import "unsafe"
const MaxArgs = maxArgs
var (
- TestingWER = &testingWER
OsYield = osyield
TimeBeginPeriodRetValue = &timeBeginPeriodRetValue
)