aboutsummaryrefslogtreecommitdiff
path: root/lib/std/debug/cpu_context.zig
diff options
context:
space:
mode:
authormlugg <mlugg@mlugg.co.uk>2025-09-18 15:52:02 +0100
committermlugg <mlugg@mlugg.co.uk>2025-09-30 13:44:55 +0100
commit084e92879a1732374fac5f1a05a27f42b9306d22 (patch)
tree59d416eec4b409c74aa2c0b95781e418d5cd2c7a /lib/std/debug/cpu_context.zig
parentdae703d3c028eab3bf98d89d2bca1abc75f864fa (diff)
downloadzig-084e92879a1732374fac5f1a05a27f42b9306d22.tar.gz
zig-084e92879a1732374fac5f1a05a27f42b9306d22.zip
std: don't get CPU context when using CBE targeting MSVC
Calling `current` here causes compilation failures as the C backend currently does not emit valid MSVC inline assembly. This change means that when building for MSVC with the self-hosted C backend, only FP unwinding can be used.
Diffstat (limited to 'lib/std/debug/cpu_context.zig')
-rw-r--r--lib/std/debug/cpu_context.zig4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/std/debug/cpu_context.zig b/lib/std/debug/cpu_context.zig
index b9dd49767f..fdf6ebd243 100644
--- a/lib/std/debug/cpu_context.zig
+++ b/lib/std/debug/cpu_context.zig
@@ -316,7 +316,7 @@ pub const X86_64 = struct {
\\movq %%r15, 0x78(%%rdi)
\\leaq (%%rip), %%rax
\\movq %%rax, 0x80(%%rdi)
- \\movq 0x00(%%rdi), %%rax // restore saved rax
+ \\movq 0x00(%%rdi), %%rax
:
: [gprs] "{rdi}" (&ctx.gprs.values),
: .{ .memory = true });
@@ -431,7 +431,7 @@ pub const Aarch64 = extern struct {
\\str x1, [x0, #0x0f8]
\\adr x1, .
\\str x1, [x0, #0x100]
- \\ldr x1, [x0, #0x008] // restore saved x1
+ \\ldr x1, [x0, #0x008]
:
: [gprs] "{x0}" (&ctx),
: .{ .memory = true });