[uClibc-cvs] uClibc/libc/sysdeps/linux/i386/bits profil-counter.h, 1.1, 1.2

Erik Andersen andersen at uclibc.org
Sun Sep 7 04:13:15 UTC 2003


Update of /var/cvs/uClibc/libc/sysdeps/linux/i386/bits
In directory winder:/tmp/cvs-serv3293/libc/sysdeps/linux/i386/bits

Modified Files:
	profil-counter.h 
Log Message:
Some updates from glibc.  mjn3 reports this fixes profiling
on i386, at least, so seems like a good thing.


Index: profil-counter.h
===================================================================
RCS file: /var/cvs/uClibc/libc/sysdeps/linux/i386/bits/profil-counter.h,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- profil-counter.h	3 Mar 2003 20:58:18 -0000	1.1
+++ profil-counter.h	7 Sep 2003 04:13:12 -0000	1.2
@@ -1,5 +1,5 @@
 /* Low-level statistical profiling support function.  Linux/i386 version.
-   Copyright (C) 1996, 1997, 1998 Free Software Foundation, Inc.
+   Copyright (C) 1996, 1997, 1998, 2002 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
@@ -21,7 +21,12 @@
 #include <bits/sigcontextinfo.h>
 
 static void
-profil_counter (int signo, SIGCONTEXT scp)
+profil_counter (int signo, const SIGCONTEXT scp)
 {
   profil_count ((void *) GET_PC (scp));
+
+  /* This is a hack to prevent the compiler from implementing the
+     above function call as a sibcall.  The sibcall would overwrite
+     the signal context.  */
+  asm volatile ("");
 }




More information about the uClibc-cvs mailing list