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

Erik Andersen andersen at uclibc.org
Sun Sep 7 04:08:27 UTC 2003


Update of /var/cvs/uClibc/libc/sysdeps/linux/sh/bits
In directory winder:/tmp/cvs-serv3162/libc/sysdeps/linux/sh/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/sh/bits/profil-counter.h,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -d -r1.2 -r1.3
--- profil-counter.h	7 Mar 2003 12:05:48 -0000	1.2
+++ profil-counter.h	7 Sep 2003 04:08:23 -0000	1.3
@@ -1,5 +1,5 @@
 /* Low-level statistical profiling support function.  Linux/SH version.
-   Copyright (C) 1996, 1997, 1998, 2000 Free Software Foundation, Inc.
+   Copyright (C) 1996, 1997, 1998, 2000, 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
@@ -23,11 +23,11 @@
 profil_counter (int signo, int _a2, int _a3, int _a4, struct sigcontext sc)
 {
   void *pc;
-  (void) signo;
-  (void)_a2;
-  (void)_a3;
-  (void)_a4;
-  
   pc = (void *) sc.sc_pc;
   profil_count (pc);
+
+  /* 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