From ad634537ce1cf94e45ea13469dfb2032e1e219f8 Mon Sep 17 00:00:00 2001 From: Jacob Young Date: Fri, 16 Aug 2024 14:42:50 -0400 Subject: [PATCH] x86_64: move end of prologue to after function arguments are spilled This prevents the first step in to a function from displaying bogus argument values. --- src/arch/x86_64/Emit.zig | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/src/arch/x86_64/Emit.zig b/src/arch/x86_64/Emit.zig index 54993220b1..8a7b2a2b5c 100644 --- a/src/arch/x86_64/Emit.zig +++ b/src/arch/x86_64/Emit.zig @@ -222,13 +222,7 @@ pub fn emitMir(emit: *Emit) Error!void { else => unreachable, .pseudo_dbg_prologue_end_none => { switch (emit.debug_output) { - .dwarf => |dw| { - try dw.setPrologueEnd(); - log.debug("mirDbgPrologueEnd (line={d}, col={d})", .{ - emit.prev_di_line, emit.prev_di_column, - }); - try emit.dbgAdvancePCAndLine(emit.prev_di_line, emit.prev_di_column); - }, + .dwarf => |dw| try dw.setPrologueEnd(), .plan9 => {}, .none => {}, }