From 249a3d0c4ffb36f4aacdbae357b371d53325f674 Mon Sep 17 00:00:00 2001 From: Ulrich Drepper Date: Thu, 8 Jan 2004 18:23:53 +0000 Subject: Update. 2004-01-08 Jakub Jelinek * sysdeps/unix/sysv/linux/x86_64/clone.S (__clone): Add cfi_endproc right before syscall and cfi_startproc before PSEUDO_END. Clear %rbp in thread_start. --- sysdeps/unix/sysv/linux/x86_64/clone.S | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'sysdeps/unix/sysv/linux/x86_64') diff --git a/sysdeps/unix/sysv/linux/x86_64/clone.S b/sysdeps/unix/sysv/linux/x86_64/clone.S index c8d7becc75..d182fe2f9e 100644 --- a/sysdeps/unix/sysv/linux/x86_64/clone.S +++ b/sysdeps/unix/sysv/linux/x86_64/clone.S @@ -1,4 +1,4 @@ -/* Copyright (C) 2001, 2002, 2003 Free Software Foundation, Inc. +/* Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. This file is part of the GNU C Library. The GNU C Library is free software; you can redistribute it and/or @@ -72,6 +72,10 @@ ENTRY (BP_SYM (__clone)) movq %r9, %r8 movq 8(%rsp), %r10 movq $SYS_ify(clone),%rax + + /* End FDE now, because in the child the unwind info will be + wrong. */ + cfi_endproc; syscall testq %rax,%rax @@ -82,6 +86,10 @@ L(pseudo_end): ret thread_start: + /* Clear the frame pointer. The ABI suggests this be done, to mark + the outermost frame obviously. */ + xorq %rbp, %rbp + /* Set up arguments for the function call. */ popq %rax /* Function to call. */ popq %rdi /* Argument. */ @@ -90,6 +98,7 @@ thread_start: movq %rax, %rdi call HIDDEN_JUMPTARGET (_exit) + cfi_startproc; PSEUDO_END (BP_SYM (__clone)) weak_alias (BP_SYM (__clone), BP_SYM (clone)) -- cgit 1.4.1