public inbox for glibc-cvs@sourceware.org
help / color / mirror / Atom feed
* [glibc] x86_64/clone.S: Upate comments
@ 2021-02-22 12:37 H.J. Lu
  0 siblings, 0 replies; only message in thread
From: H.J. Lu @ 2021-02-22 12:37 UTC (permalink / raw)
  To: glibc-cvs

https://sourceware.org/git/gitweb.cgi?p=glibc.git;h=ebbb8c9f64c3486603ef4ccee4dd2a5574e41039

commit ebbb8c9f64c3486603ef4ccee4dd2a5574e41039
Author: H.J. Lu <hjl.tools@gmail.com>
Date:   Sat Feb 13 11:46:38 2021 -0800

    x86_64/clone.S: Upate comments

Diff:
---
 sysdeps/unix/sysv/linux/x86_64/clone.S | 14 ++++++++------
 1 file changed, 8 insertions(+), 6 deletions(-)

diff --git a/sysdeps/unix/sysv/linux/x86_64/clone.S b/sysdeps/unix/sysv/linux/x86_64/clone.S
index 51638d897b..31ac12da0c 100644
--- a/sysdeps/unix/sysv/linux/x86_64/clone.S
+++ b/sysdeps/unix/sysv/linux/x86_64/clone.S
@@ -24,18 +24,20 @@
 #include <asm-syntax.h>
 
 /* The userland implementation is:
-   int clone (int (*fn)(void *arg), void *child_stack, int flags, void *arg),
+   int clone (int (*fn)(void *arg), void *child_stack, int flags,
+	      void *arg, pid_t *parent_tid, void *tls, pid_t *child_tid);
    the kernel entry is:
-   int clone (long flags, void *child_stack).
+   int clone (long flags, void *child_stack, pid_t *parent_tid,
+	      pid_t *child_tid, void *tls);
 
    The parameters are passed in register and on the stack from userland:
    rdi: fn
    rsi: child_stack
    rdx:	flags
    rcx: arg
-   r8d:	TID field in parent
-   r9d: thread pointer
-%esp+8:	TID field in child
+    r8:	TID field in parent
+    r9: thread pointer
+%rsp+8:	TID field in child
 
    The kernel expects:
    rax: system call number
@@ -60,7 +62,7 @@ ENTRY (__clone)
 	movq	%rcx,8(%rsi)
 
 	/* Save the function pointer.  It will be popped off in the
-	   child in the ebx frobbing below.  */
+	   child.  */
 	movq	%rdi,0(%rsi)
 
 	/* Do the system call.  */


^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-02-22 12:37 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-02-22 12:37 [glibc] x86_64/clone.S: Upate comments H.J. Lu

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).