remove unnecessary ud2 instructions

This commit is contained in:
2025-12-17 11:15:51 +01:00
parent 403fd6031b
commit eea0e6204d
3 changed files with 1 additions and 9 deletions

View File

@@ -74,12 +74,10 @@ export fn syscall_handler(ctx: *SavedContext) callconv(.c) void {
asm volatile (
\\ mov %[rsp], %%rsp
\\ syscall
\\ ud2
:
: [rsp] "r" (rsp_orig),
[number] "{rax}" (ctx.rax),
: .{ .memory = true }
);
: .{ .memory = true });
unreachable;
},
.execve, .execveat => |s| {

View File

@@ -30,9 +30,6 @@ pub fn main() !void {
\\ mov $60, %%rax # SYS_exit
\\ syscall
\\
\\ # Should not be reached
\\ ud2
\\
\\ 1:
\\ # Parent Path continues
: [ret] "={rax}" (-> usize),

View File

@@ -34,9 +34,6 @@ pub fn main() !void {
\\ mov $60, %%rax # SYS_exit
\\ syscall
\\
\\ # Should not be reached
\\ ud2
\\
\\ 1:
\\ # Parent Path continues
: [ret] "={rax}" (-> usize),