- Resync with upstream sources.

Lots of local systemtap bits are now upstream and no longer needed as
local changes.
This commit is contained in:
Jeff Law 2012-05-30 00:22:40 -06:00
parent bb3a5a5ad9
commit e1b411d16d
6 changed files with 293 additions and 1752 deletions

3
.gitignore vendored
View File

@ -16,3 +16,6 @@ glibc-2.14-394-g8f3b1ff
/glibc-2.15.90-8b728fa3.tar.gz /glibc-2.15.90-8b728fa3.tar.gz
/glibc-ports-2.15.90-4645e97.tar.gz /glibc-ports-2.15.90-4645e97.tar.gz
/glibc-2.15.90-8b728fa3-fedora.tar.gz /glibc-2.15.90-8b728fa3-fedora.tar.gz
/glibc-2.15.90-4d17e683-fedora.tar.gz
/glibc-2.15.90-4d17e683.tar.gz
/glibc-ports-2.15.90-0387d093.tar.gz

File diff suppressed because it is too large Load Diff

View File

@ -1,8 +1,7 @@
Index: glibc-2.12-2-gc4ccff1/malloc/arena.c diff -Nrup a/malloc/arena.c b/malloc/arena.c
=================================================================== --- a/malloc/arena.c 2012-05-29 16:45:53.000000000 -0600
--- glibc-2.12-2-gc4ccff1.orig/malloc/arena.c +++ b/malloc/arena.c 2012-05-30 00:13:40.683514016 -0600
+++ glibc-2.12-2-gc4ccff1/malloc/arena.c @@ -673,7 +673,7 @@ heap_trim(heap_info *heap, size_t pad)
@@ -870,7 +870,7 @@ heap_trim(heap, pad) heap_info *heap; si
heap = prev_heap; heap = prev_heap;
if(!prev_inuse(p)) { /* consolidate backward */ if(!prev_inuse(p)) { /* consolidate backward */
p = prev_chunk(p); p = prev_chunk(p);
@ -11,11 +10,10 @@ Index: glibc-2.12-2-gc4ccff1/malloc/arena.c
} }
assert(((unsigned long)((char*)p + new_size) & (pagesz-1)) == 0); assert(((unsigned long)((char*)p + new_size) & (pagesz-1)) == 0);
assert( ((char*)p + new_size) == ((char*)heap + heap->size) ); assert( ((char*)p + new_size) == ((char*)heap + heap->size) );
Index: glibc-2.12-2-gc4ccff1/malloc/hooks.c diff -Nrup a/malloc/hooks.c b/malloc/hooks.c
=================================================================== --- a/malloc/hooks.c 2012-05-29 16:45:53.000000000 -0600
--- glibc-2.12-2-gc4ccff1.orig/malloc/hooks.c +++ b/malloc/hooks.c 2012-05-30 00:13:40.684514011 -0600
+++ glibc-2.12-2-gc4ccff1/malloc/hooks.c @@ -191,7 +191,9 @@ top_check(void)
@@ -219,7 +219,9 @@ top_check()
(char*)t + chunksize(t) == mp_.sbrk_base + main_arena.system_mem))) (char*)t + chunksize(t) == mp_.sbrk_base + main_arena.system_mem)))
return 0; return 0;
@ -25,11 +23,10 @@ Index: glibc-2.12-2-gc4ccff1/malloc/hooks.c
/* Try to set up a new top chunk. */ /* Try to set up a new top chunk. */
brk = MORECORE(0); brk = MORECORE(0);
Index: glibc-2.12-2-gc4ccff1/malloc/malloc.c diff -Nrup a/malloc/malloc.c b/malloc/malloc.c
=================================================================== --- a/malloc/malloc.c 2012-05-29 16:45:53.000000000 -0600
--- glibc-2.12-2-gc4ccff1.orig/malloc/malloc.c +++ b/malloc/malloc.c 2012-05-30 00:13:40.686514001 -0600
+++ glibc-2.12-2-gc4ccff1/malloc/malloc.c @@ -1424,12 +1424,14 @@ typedef struct malloc_chunk* mbinptr;
@@ -1541,12 +1541,14 @@
#define last(b) ((b)->bk) #define last(b) ((b)->bk)
/* Take a chunk off a bin list */ /* Take a chunk off a bin list */
@ -47,7 +44,7 @@ Index: glibc-2.12-2-gc4ccff1/malloc/malloc.c
FD->bk = BK; \ FD->bk = BK; \
BK->fd = FD; \ BK->fd = FD; \
if (!in_smallbin_range (P->size) \ if (!in_smallbin_range (P->size) \
@@ -2593,7 +2595,9 @@ @@ -2511,7 +2513,9 @@ static void* sysmalloc(INTERNAL_SIZE_T n
else if (contiguous(av) && old_size && brk < old_end) { else if (contiguous(av) && old_size && brk < old_end) {
/* Oops! Someone else killed our space.. Can't touch anything. */ /* Oops! Someone else killed our space.. Can't touch anything. */
@ -57,7 +54,7 @@ Index: glibc-2.12-2-gc4ccff1/malloc/malloc.c
} }
/* /*
@@ -3467,7 +3471,9 @@ @@ -3345,7 +3349,9 @@ _int_malloc(mstate av, size_t bytes)
{ {
errstr = "malloc(): memory corruption (fast)"; errstr = "malloc(): memory corruption (fast)";
errout: errout:
@ -67,7 +64,7 @@ Index: glibc-2.12-2-gc4ccff1/malloc/malloc.c
return NULL; return NULL;
} }
check_remalloced_chunk(av, victim, nb); check_remalloced_chunk(av, victim, nb);
@@ -3552,8 +3558,12 @@ @@ -3430,8 +3436,12 @@ _int_malloc(mstate av, size_t bytes)
bck = victim->bk; bck = victim->bk;
if (__builtin_expect (victim->size <= 2 * SIZE_SZ, 0) if (__builtin_expect (victim->size <= 2 * SIZE_SZ, 0)
|| __builtin_expect (victim->size > av->system_mem, 0)) || __builtin_expect (victim->size > av->system_mem, 0))
@ -82,7 +79,7 @@ Index: glibc-2.12-2-gc4ccff1/malloc/malloc.c
size = chunksize(victim); size = chunksize(victim);
/* /*
@@ -3694,7 +3704,7 @@ @@ -3572,7 +3582,7 @@ _int_malloc(mstate av, size_t bytes)
victim = victim->fd; victim = victim->fd;
remainder_size = size - nb; remainder_size = size - nb;
@ -91,7 +88,7 @@ Index: glibc-2.12-2-gc4ccff1/malloc/malloc.c
/* Exhaust */ /* Exhaust */
if (remainder_size < MINSIZE) { if (remainder_size < MINSIZE) {
@@ -3792,7 +3802,7 @@ @@ -3670,7 +3680,7 @@ _int_malloc(mstate av, size_t bytes)
remainder_size = size - nb; remainder_size = size - nb;
/* unlink */ /* unlink */
@ -100,7 +97,7 @@ Index: glibc-2.12-2-gc4ccff1/malloc/malloc.c
/* Exhaust */ /* Exhaust */
if (remainder_size < MINSIZE) { if (remainder_size < MINSIZE) {
@@ -3927,9 +3937,11 @@ @@ -3805,9 +3815,11 @@ _int_free(mstate av, mchunkptr p, int ha
{ {
errstr = "free(): invalid pointer"; errstr = "free(): invalid pointer";
errout: errout:
@ -112,8 +109,8 @@ Index: glibc-2.12-2-gc4ccff1/malloc/malloc.c
+ mutex_lock(&av->mutex); + mutex_lock(&av->mutex);
return; return;
} }
/* We know that each chunk is at least MINSIZE bytes in size. */ /* We know that each chunk is at least MINSIZE bytes in size or a
@@ -4073,7 +4085,7 @@ @@ -3952,7 +3964,7 @@ _int_free(mstate av, mchunkptr p, int ha
prevsize = p->prev_size; prevsize = p->prev_size;
size += prevsize; size += prevsize;
p = chunk_at_offset(p, -((long) prevsize)); p = chunk_at_offset(p, -((long) prevsize));
@ -122,7 +119,7 @@ Index: glibc-2.12-2-gc4ccff1/malloc/malloc.c
} }
if (nextchunk != av->top) { if (nextchunk != av->top) {
@@ -4082,7 +4094,7 @@ @@ -3961,7 +3973,7 @@ _int_free(mstate av, mchunkptr p, int ha
/* consolidate forward */ /* consolidate forward */
if (!nextinuse) { if (!nextinuse) {
@ -131,7 +128,7 @@ Index: glibc-2.12-2-gc4ccff1/malloc/malloc.c
size += nextsize; size += nextsize;
} else } else
clear_inuse_bit_at_offset(nextchunk, 0); clear_inuse_bit_at_offset(nextchunk, 0);
@@ -4243,7 +4255,7 @@ @@ -4122,7 +4134,7 @@ static void malloc_consolidate(mstate av
prevsize = p->prev_size; prevsize = p->prev_size;
size += prevsize; size += prevsize;
p = chunk_at_offset(p, -((long) prevsize)); p = chunk_at_offset(p, -((long) prevsize));
@ -140,7 +137,7 @@ Index: glibc-2.12-2-gc4ccff1/malloc/malloc.c
} }
if (nextchunk != av->top) { if (nextchunk != av->top) {
@@ -4251,7 +4263,7 @@ @@ -4130,7 +4142,7 @@ static void malloc_consolidate(mstate av
if (!nextinuse) { if (!nextinuse) {
size += nextsize; size += nextsize;
@ -149,7 +146,7 @@ Index: glibc-2.12-2-gc4ccff1/malloc/malloc.c
} else } else
clear_inuse_bit_at_offset(nextchunk, 0); clear_inuse_bit_at_offset(nextchunk, 0);
@@ -4320,7 +4332,9 @@ @@ -4199,7 +4211,9 @@ _int_realloc(mstate av, mchunkptr oldp,
{ {
errstr = "realloc(): invalid old size"; errstr = "realloc(): invalid old size";
errout: errout:
@ -159,7 +156,7 @@ Index: glibc-2.12-2-gc4ccff1/malloc/malloc.c
return NULL; return NULL;
} }
@@ -4362,7 +4376,7 @@ @@ -4241,7 +4255,7 @@ _int_realloc(mstate av, mchunkptr oldp,
(unsigned long)(newsize = oldsize + nextsize) >= (unsigned long)(newsize = oldsize + nextsize) >=
(unsigned long)(nb)) { (unsigned long)(nb)) {
newp = oldp; newp = oldp;

View File

@ -1,298 +1,3 @@
diff -Nrup c/config.h.in d/config.h.in
--- c/config.h.in 2012-05-20 19:47:38.000000000 -0600
+++ d/config.h.in 2012-05-20 23:51:59.511489307 -0600
@@ -208,6 +208,9 @@
#endif
+/* Define if Systemtap <sys/sdt.h> probes should be defined. */
+#undef USE_STAP_PROBE
+
/*
*/
diff -Nrup c/configure d/configure
--- c/configure 2012-05-20 23:51:08.075734606 -0600
+++ d/configure 2012-05-20 23:53:48.520969358 -0600
@@ -1441,6 +1441,7 @@ Optional Features:
--enable-nss-crypt enable libcrypt to use nss
--enable-obsolete-rpc build and install the obsolete RPC code for
link-time usage
+ --enable-systemtap enable systemtap static probe points [default=no]
Optional Packages:
--with-PACKAGE[=ARG] use PACKAGE [ARG=yes]
@@ -3767,6 +3768,51 @@ if test "$link_obsolete_rpc" = yes; then
fi
+# Check whether --enable-systemtap was given.
+if test "${enable_systemtap+set}" = set; then :
+ enableval=$enable_systemtap; systemtap=$enableval
+else
+ systemtap=no
+fi
+
+if test x$systemtap != xno; then
+ { $as_echo "$as_me:${as_lineno-$LINENO}: checking for systemtap static probe support" >&5
+$as_echo_n "checking for systemtap static probe support... " >&6; }
+if test "${libc_cv_sdt+set}" = set; then :
+ $as_echo_n "(cached) " >&6
+else
+ old_CFLAGS="$CFLAGS"
+ CFLAGS="-std=gnu99 $CFLAGS"
+ cat confdefs.h - <<_ACEOF >conftest.$ac_ext
+/* end confdefs.h. */
+#include <sys/sdt.h>
+void foo (int i, void *p)
+{
+ asm ("" STAP_PROBE_ASM (foo, bar, STAP_PROBE_ASM_TEMPLATE (2)) ""
+ :: STAP_PROBE_ASM_OPERANDS (2, i, p));
+}
+_ACEOF
+if ac_fn_c_try_compile "$LINENO"; then :
+ libc_cv_sdt=yes
+else
+ libc_cv_sdt=no
+fi
+rm -f core conftest.err conftest.$ac_objext conftest.$ac_ext
+ CFLAGS="$old_CFLAGS"
+fi
+{ $as_echo "$as_me:${as_lineno-$LINENO}: result: $libc_cv_sdt" >&5
+$as_echo "$libc_cv_sdt" >&6; }
+ if test $libc_cv_sdt = yes; then
+ $as_echo "#define USE_STAP_PROBE 1" >>confdefs.h
+
+ else
+ { { $as_echo "$as_me:${as_lineno-$LINENO}: error: in \`$ac_pwd':" >&5
+$as_echo "$as_me: error: in \`$ac_pwd':" >&2;}
+as_fn_error $? "systemtap support needs sys/sdt.h with asm support
+See \`config.log' for more details" "$LINENO" 5; }
+ fi
+fi
+
# The way shlib-versions is used to generate soversions.mk uses a
# fairly simplistic model for name recognition that can't distinguish
# i486-pc-linux-gnu fully from i486-pc-gnu. So we mutate a $host_os
diff -Nrup c/configure.in d/configure.in
--- c/configure.in 2012-05-20 19:47:38.000000000 -0600
+++ d/configure.in 2012-05-20 23:51:59.558489083 -0600
@@ -263,6 +263,29 @@ if test "$link_obsolete_rpc" = yes; then
AC_DEFINE(LINK_OBSOLETE_RPC)
fi
+AC_ARG_ENABLE([systemtap],
+ [AS_HELP_STRING([--enable-systemtap],
+ [enable systemtap static probe points @<:@default=no@:>@])],
+ [systemtap=$enableval],
+ [systemtap=no])
+if test x$systemtap != xno; then
+ AC_CACHE_CHECK([for systemtap static probe support], libc_cv_sdt, [dnl
+ old_CFLAGS="$CFLAGS"
+ CFLAGS="-std=gnu99 $CFLAGS"
+ AC_COMPILE_IFELSE([#include <sys/sdt.h>
+void foo (int i, void *p)
+{
+ asm ("" STAP_PROBE_ASM (foo, bar, STAP_PROBE_ASM_TEMPLATE (2)) ""
+ :: STAP_PROBE_ASM_OPERANDS (2, i, p));
+}], [libc_cv_sdt=yes], [libc_cv_sdt=no])
+ CFLAGS="$old_CFLAGS"])
+ if test $libc_cv_sdt = yes; then
+ AC_DEFINE([USE_STAP_PROBE])
+ else
+ AC_MSG_FAILURE([systemtap support needs sys/sdt.h with asm support])
+ fi
+fi
+
# The way shlib-versions is used to generate soversions.mk uses a
# fairly simplistic model for name recognition that can't distinguish
# i486-pc-linux-gnu fully from i486-pc-gnu. So we mutate a $host_os
diff -Nrup c/elf/Makefile d/elf/Makefile
--- c/elf/Makefile 2012-05-20 23:51:07.907735407 -0600
+++ d/elf/Makefile 2012-05-20 23:51:59.561489070 -0600
@@ -423,7 +423,8 @@ CFLAGS-dl-cache.c = $(SYSCONF-FLAGS)
CFLAGS-cache.c = $(SYSCONF-FLAGS)
CFLAGS-rtld.c = $(SYSCONF-FLAGS)
-CPPFLAGS-.os += $(if $(filter $(@F),$(patsubst %,%.os,$(all-rtld-routines))),-DNOT_IN_libc=1 -DIS_IN_rtld=1)
+CPPFLAGS-.os += $(if $(filter $(@F),$(patsubst %,%.os,$(all-rtld-routines))),\
+ -DNOT_IN_libc=1 -DIS_IN_rtld=1 -DIN_LIB=rtld)
test-modules = $(addprefix $(objpfx),$(addsuffix .so,$(strip $(modules-names))))
generated += $(addsuffix .so,$(strip $(modules-names)))
diff -Nrup c/elf/rtld-Rules d/elf/rtld-Rules
--- c/elf/rtld-Rules 2012-05-20 19:47:38.000000000 -0600
+++ d/elf/rtld-Rules 2012-05-20 23:51:59.561489070 -0600
@@ -1,7 +1,7 @@
# Subroutine makefile for compiling libc modules linked into dynamic linker.
# Copyright (C) 2002,2003,2005,2006,2008,2010,2011
-# Free Software Foundation, Inc.
+# 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
@@ -130,6 +130,6 @@ ifdef rtld-depfiles
endif
# This here is the whole point of all the shenanigans.
-rtld-CPPFLAGS := -DNOT_IN_libc=1 -DIS_IN_rtld=1
+rtld-CPPFLAGS := -DNOT_IN_libc=1 -DIS_IN_rtld=1 -DIN_LIB=rtld
endif
diff -Nrup c/extra-lib.mk d/extra-lib.mk
--- c/extra-lib.mk 2012-05-20 19:47:38.000000000 -0600
+++ d/extra-lib.mk 2012-05-20 23:51:59.559489078 -0600
@@ -101,4 +101,4 @@ ifneq (,$(cpp-srcs-left))
include $(patsubst %,$(..)cppflags-iterator.mk,$(cpp-srcs-left))
endif
-CPPFLAGS-$(lib) := -DNOT_IN_libc=1 -DIS_IN_$(lib)=1
+CPPFLAGS-$(lib) := -DNOT_IN_libc=1 -DIS_IN_$(lib)=1 -DIN_LIB=$(lib)
diff -Nrup c/include/stap-probe.h d/include/stap-probe.h
--- c/include/stap-probe.h 1969-12-31 17:00:00.000000000 -0700
+++ d/include/stap-probe.h 2012-05-20 23:51:59.510489312 -0600
@@ -0,0 +1,140 @@
+/* Macros for defining Systemtap <sys/sdt.h> static probe points.
+ Copyright (C) 2011 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
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or (at your option) any later version.
+
+ The GNU C Library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+ Lesser General Public License for more details.
+
+ You should have received a copy of the GNU Lesser General Public
+ License along with the GNU C Library; if not, write to the Free
+ Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
+ 02111-1307 USA. */
+
+#ifndef _STAP_PROBE_H
+#define _STAP_PROBE_H 1
+
+#ifdef USE_STAP_PROBE
+
+# include <sys/sdt.h>
+
+/* Our code uses one macro LIBC_PROBE (name, n, arg1, ..., argn).
+
+ Without USE_STAP_PROBE, that does nothing but evaluates all
+ its arguments (to prevent bit rot, unlike e.g. assert).
+
+ Systemtap's header defines the macros STAP_PROBE (provider, name) and
+ STAP_PROBEn (provider, name, arg1, ..., argn). For "provider" we paste
+ in the IN_LIB name (libc, libpthread, etc.) automagically. */
+
+# ifndef NOT_IN_libc
+# define IN_LIB libc
+# elif !defined IN_LIB
+/* This is intentionally defined with extra unquoted commas in it so
+ that macro substitution will bomb out when it is used. We don't
+ just use #error here, so that this header can be included by
+ other headers that use LIBC_PROBE inside their own macros. We
+ only want such headers to fail to compile if those macros are
+ actually used in a context where IN_LIB has not been defined. */
+# define IN_LIB ,,,missing -DIN_LIB=... -- not extra-lib.mk?,,,
+# endif
+
+# define LIBC_PROBE(name, n, ...) \
+ LIBC_PROBE_1 (IN_LIB, name, n, ## __VA_ARGS__)
+
+# define LIBC_PROBE_1(lib, name, n, ...) \
+ STAP_PROBE##n (lib, name, ## __VA_ARGS__)
+
+# define STAP_PROBE0 STAP_PROBE
+
+# define LIBC_PROBE_ASM(name, template) \
+ STAP_PROBE_ASM (IN_LIB, name, template)
+
+# define LIBC_PROBE_ASM_OPERANDS STAP_PROBE_ASM_OPERANDS
+
+#else /* Not USE_STAP_PROBE. */
+
+# ifndef __ASSEMBLER__
+# define LIBC_PROBE(name, n, ...) DUMMY_PROBE##n (__VA_ARGS__)
+# else
+# define LIBC_PROBE(name, n, ...) /* Nothing. */
+# endif
+
+# define LIBC_PROBE_ASM(name, template) /* Nothing. */
+# define LIBC_PROBE_ASM_OPERANDS(n, ...) /* Nothing. */
+
+/* This silliness lets us evaluate all the arguments for each arity
+ of probe. My kingdom for a real macro system. */
+
+# define DUMMY_PROBE0() do {} while (0)
+# define DUMMY_PROBE1(a1) do {} while ((void) (a1), 0)
+# define DUMMY_PROBE2(a1, a2) do {} while ((void) (a1), \
+ (void) (a2), 0)
+# define DUMMY_PROBE3(a1, a2, a3) do {} while ((void) (a1), \
+ (void) (a2), \
+ (void) (a3), 0)
+# define DUMMY_PROBE4(a1, a2, a3, a4) do {} while ((void) (a1), \
+ (void) (a2), \
+ (void) (a3), \
+ (void) (a4), 0)
+# define DUMMY_PROBE5(a1, a2, a3, a4, a5) \
+ do {} while ((void) (a1), \
+ (void) (a2), \
+ (void) (a3), \
+ (void) (a4), \
+ (void) (a5), 0)
+# define DUMMY_PROBE6(a1, a2, a3, a4, a5, a6) \
+ do {} while ((void) (a1), \
+ (void) (a2), \
+ (void) (a3), \
+ (void) (a4), \
+ (void) (a5), \
+ (void) (a6), 0)
+# define DUMMY_PROBE7(a1, a2, a3, a4, a5, a6, a7) \
+ do {} while ((void) (a1), \
+ (void) (a2), \
+ (void) (a3), \
+ (void) (a4), \
+ (void) (a5), \
+ (void) (a6), \
+ (void) (a7), 0)
+# define DUMMY_PROBE8(a1, a2, a3, a4, a5, a6, a7, a8) \
+ do {} while ((void) (a1), \
+ (void) (a2), \
+ (void) (a3), \
+ (void) (a4), \
+ (void) (a5), \
+ (void) (a6), \
+ (void) (a7), \
+ (void) (a8), 0)
+# define DUMMY_PROBE9(a1, a2, a3, a4, a5, a6, a7, a8, a9) \
+ do {} while ((void) (a1), \
+ (void) (a2), \
+ (void) (a3), \
+ (void) (a4), \
+ (void) (a5), \
+ (void) (a6), \
+ (void) (a7), \
+ (void) (a8), \
+ (void) (a9), 0)
+# define DUMMY_PROBE10(a1, a2, a3, a4, a5, a6, a7, a8, a9, a10) \
+ do {} while ((void) (a1), \
+ (void) (a2), \
+ (void) (a3), \
+ (void) (a4), \
+ (void) (a5), \
+ (void) (a6), \
+ (void) (a7), \
+ (void) (a8), \
+ (void) (a9), \
+ (void) (a10), 0)
+
+#endif /* USE_STAP_PROBE. */
+
+#endif /* stap-probe.h */
diff -Nrup c/scripts/check-local-headers.sh d/scripts/check-local-headers.sh diff -Nrup c/scripts/check-local-headers.sh d/scripts/check-local-headers.sh
--- c/scripts/check-local-headers.sh 2012-05-20 19:47:38.000000000 -0600 --- c/scripts/check-local-headers.sh 2012-05-20 19:47:38.000000000 -0600
+++ d/scripts/check-local-headers.sh 2012-05-20 23:54:51.258670072 -0600 +++ d/scripts/check-local-headers.sh 2012-05-20 23:54:51.258670072 -0600
@ -305,255 +10,3 @@ diff -Nrup c/scripts/check-local-headers.sh d/scripts/check-local-headers.sh
} }
/^[^ ]/ && $1 ~ /.*:/ { obj = $1 } /^[^ ]/ && $1 ~ /.*:/ { obj = $1 }
{ {
diff -Nrup c/sysdeps/i386/__longjmp.S d/sysdeps/i386/__longjmp.S
--- c/sysdeps/i386/__longjmp.S 2012-05-20 19:47:38.000000000 -0600
+++ d/sysdeps/i386/__longjmp.S 2012-05-20 23:51:59.478489471 -0600
@@ -1,5 +1,5 @@
/* longjmp for i386.
- Copyright (C) 1995-1998,2000,2002,2005,2006,2009
+ Copyright (C) 1995-1998,2000,2002,2005,2006,2009,2011
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -20,6 +20,7 @@
#include <sysdep.h>
#include <jmpbuf-offsets.h>
#include <asm-syntax.h>
+#include <stap-probe.h>
.text
ENTRY (__longjmp)
@@ -32,6 +33,7 @@ ENTRY (__longjmp)
movl (JB_SP*4)(%eax), %ecx
PTR_DEMANGLE (%edx)
PTR_DEMANGLE (%ecx)
+ LIBC_PROBE (longjmp, 3, 4@%eax, -4@8(%esp), 4@%edx)
cfi_def_cfa(%eax, 0)
cfi_register(%eip, %edx)
cfi_register(%esp, %ecx)
@@ -49,6 +51,7 @@ ENTRY (__longjmp)
cfi_restore(%edi)
cfi_restore(%ebp)
+ LIBC_PROBE (longjmp_target, 3, 4@%eax, -4@8(%esp), 4@%edx)
movl 8(%esp), %eax /* Second argument is return value. */
movl %ecx, %esp
#else
@@ -56,12 +59,14 @@ ENTRY (__longjmp)
movl 8(%esp), %eax /* Second argument is return value. */
/* Save the return address now. */
movl (JB_PC*4)(%ecx), %edx
+ LIBC_PROBE (longjmp, 3, 4@%ecx, -4@%eax, 4@%edx)
/* Restore registers. */
movl (JB_BX*4)(%ecx), %ebx
movl (JB_SI*4)(%ecx), %esi
movl (JB_DI*4)(%ecx), %edi
movl (JB_BP*4)(%ecx), %ebp
movl (JB_SP*4)(%ecx), %esp
+ LIBC_PROBE (longjmp_target, 3, 4@%ecx, -4@%ecx, 4@%edx)
#endif
/* Jump to saved PC. */
jmp *%edx
diff -Nrup c/sysdeps/i386/bsd-_setjmp.S d/sysdeps/i386/bsd-_setjmp.S
--- c/sysdeps/i386/bsd-_setjmp.S 2012-05-20 19:47:38.000000000 -0600
+++ d/sysdeps/i386/bsd-_setjmp.S 2012-05-20 23:51:59.479489464 -0600
@@ -1,5 +1,6 @@
/* BSD `_setjmp' entry point to `sigsetjmp (..., 0)'. i386 version.
- Copyright (C) 1994-1997,2000-2002,2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 1994-1997,2000-2002,2005,2006,2011
+ 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
@@ -24,6 +25,7 @@
#include <jmpbuf-offsets.h>
#include "bp-sym.h"
#include "bp-asm.h"
+#include <stap-probe.h>
#define PARMS LINKAGE /* no space for saved regs */
#define JMPBUF PARMS
@@ -46,6 +48,7 @@ ENTRY (BP_SYM (_setjmp))
#endif
movl %ecx, (JB_SP*4)(%edx)
movl PCOFF(%esp), %ecx /* Save PC we are returning to now. */
+ LIBC_PROBE (setjmp, 3, 4@%edx, -4@$0, 4@%ecx)
#ifdef PTR_MANGLE
PTR_MANGLE (%ecx)
#endif
diff -Nrup c/sysdeps/i386/bsd-setjmp.S d/sysdeps/i386/bsd-setjmp.S
--- c/sysdeps/i386/bsd-setjmp.S 2012-05-20 19:47:38.000000000 -0600
+++ d/sysdeps/i386/bsd-setjmp.S 2012-05-20 23:51:59.505489337 -0600
@@ -1,5 +1,6 @@
/* BSD `setjmp' entry point to `sigsetjmp (..., 1)'. i386 version.
- Copyright (C) 1994-1997,2000,2001,2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 1994-1997,2000,2001,2005,2006,2011
+ 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
@@ -24,6 +25,7 @@
#include <jmpbuf-offsets.h>
#include "bp-sym.h"
#include "bp-asm.h"
+#include <stap-probe.h>
#define PARMS LINKAGE /* no space for saved regs */
#define JMPBUF PARMS
@@ -48,6 +50,7 @@ ENTRY (BP_SYM (setjmp))
#endif
movl %ecx, (JB_SP*4)(%eax)
movl PCOFF(%esp), %ecx /* Save PC we are returning to now. */
+ LIBC_PROBE (setjmp, 3, 4@%eax, -4@$1, 4@%ecx)
#ifdef PTR_MANGLE
PTR_MANGLE (%ecx)
#endif
diff -Nrup c/sysdeps/i386/setjmp.S d/sysdeps/i386/setjmp.S
--- c/sysdeps/i386/setjmp.S 2012-05-20 19:47:38.000000000 -0600
+++ d/sysdeps/i386/setjmp.S 2012-05-20 23:51:59.507489327 -0600
@@ -1,5 +1,5 @@
/* setjmp for i386.
- Copyright (C) 1995,1996,1997,2000,2001,2005,2006
+ Copyright (C) 1995,1996,1997,2000,2001,2005,2006,2011
Free Software Foundation, Inc.
This file is part of the GNU C Library.
@@ -22,6 +22,7 @@
#include <asm-syntax.h>
#include "bp-sym.h"
#include "bp-asm.h"
+#include <stap-probe.h>
#define PARMS LINKAGE /* no space for saved regs */
#define JMPBUF PARMS
@@ -43,6 +44,7 @@ ENTRY (BP_SYM (__sigsetjmp))
#endif
movl %ecx, (JB_SP*4)(%eax)
movl PCOFF(%esp), %ecx /* Save PC we are returning to now. */
+ LIBC_PROBE (setjmp, 3, 4@%eax, -4@SIGMSK(%esp), 4@%ecx)
#ifdef PTR_MANGLE
PTR_MANGLE (%ecx)
#endif
diff -Nrup c/sysdeps/unix/sysv/linux/i386/____longjmp_chk.S d/sysdeps/unix/sysv/linux/i386/____longjmp_chk.S
--- c/sysdeps/unix/sysv/linux/i386/____longjmp_chk.S 2012-05-20 19:47:38.000000000 -0600
+++ d/sysdeps/unix/sysv/linux/i386/____longjmp_chk.S 2012-05-20 23:51:59.507489327 -0600
@@ -1,4 +1,5 @@
-/* Copyright (C) 2001,2004,2005,2006,2009 Free Software Foundation, Inc.
+/* Copyright (C) 2001,2004,2005,2006,2009,2011
+ 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
@@ -18,6 +19,7 @@
#include <sysdep.h>
#include <jmpbuf-offsets.h>
#include <asm-syntax.h>
+#include <stap-probe.h>
.section .rodata.str1.1,"aMS",@progbits,1
@@ -78,7 +80,9 @@ ENTRY (____longjmp_chk)
cfi_adjust_cfa_offset(-12)
movl 4(%esp), %ecx
-.Lok: /* We add unwind information for the target here. */
+.Lok:
+ LIBC_PROBE (longjmp, 3, 4@%ecx, -4@8(%esp), 4@%edx)
+ /* We add unwind information for the target here. */
cfi_def_cfa(%ecx, 0)
cfi_register(%eip, %edx)
cfi_register(%esp, %edi)
@@ -101,5 +105,6 @@ ENTRY (____longjmp_chk)
cfi_restore(%ebp)
/* Jump to saved PC. */
+ LIBC_PROBE (longjmp_target, 3, 4@%ecx, -4@%eax, 4@%edx)
jmp *%edx
END (____longjmp_chk)
diff -Nrup c/sysdeps/unix/sysv/linux/x86_64/____longjmp_chk.S d/sysdeps/unix/sysv/linux/x86_64/____longjmp_chk.S
--- c/sysdeps/unix/sysv/linux/x86_64/____longjmp_chk.S 2012-05-20 19:47:38.000000000 -0600
+++ d/sysdeps/unix/sysv/linux/x86_64/____longjmp_chk.S 2012-05-20 23:51:59.508489322 -0600
@@ -18,6 +18,7 @@
#include <sysdep.h>
#include <jmpbuf-offsets.h>
#include <asm-syntax.h>
+#include <stap-probe.h>
#include <sigaltstack-offsets.h>
@@ -95,7 +96,9 @@ ENTRY(____longjmp_chk)
movl %ebx, %esi
cfi_restore (%rsi)
-.Lok: /* We add unwind information for the target here. */
+.Lok:
+ LIBC_PROBE (longjmp, 3, 8@%rdi, -4@%esi, 8@%rdx)
+ /* We add unwind information for the target here. */
cfi_def_cfa(%rdi, 0)
cfi_register(%rsp,%r8)
cfi_register(%rbp,%r9)
@@ -114,5 +117,6 @@ ENTRY(____longjmp_chk)
movl %esi, %eax
mov %R8_LP, %RSP_LP
movq %r9,%rbp
+ LIBC_PROBE (longjmp_target, 3, 8@%rdi, -4@%eax, 8@%rdx)
jmpq *%rdx
END (____longjmp_chk)
diff -Nrup c/sysdeps/x86_64/__longjmp.S d/sysdeps/x86_64/__longjmp.S
--- c/sysdeps/x86_64/__longjmp.S 2012-05-20 19:47:38.000000000 -0600
+++ d/sysdeps/x86_64/__longjmp.S 2012-05-20 23:51:59.509489317 -0600
@@ -1,4 +1,4 @@
-/* Copyright (C) 2001,2004,2005,2006,2009 Free Software Foundation, Inc.
+/* Copyright (C) 2001,2004,2005,2006,2009,2011 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
@@ -18,6 +18,7 @@
#include <sysdep.h>
#include <jmpbuf-offsets.h>
#include <asm-syntax.h>
+#include <stap-probe.h>
/* Jump to the position specified by ENV, causing the
setjmp call there to return VAL, or 1 if VAL is 0.
@@ -33,6 +34,7 @@ ENTRY(__longjmp)
PTR_DEMANGLE (%r9)
PTR_DEMANGLE (%RDX_LP)
#endif
+ LIBC_PROBE (longjmp, 3, 8@%rdi, -4@%esi, 8@%rdx)
/* We add unwind information for the target here. */
cfi_def_cfa(%rdi, 0)
cfi_register(%rsp,%r8)
@@ -52,5 +54,6 @@ ENTRY(__longjmp)
mov %esi, %eax
mov %R8_LP,%RSP_LP
movq %r9,%rbp
+ LIBC_PROBE (longjmp_target, 3, 8@%rdi, -4@%eax, 8@%rdx)
jmpq *%rdx
END (__longjmp)
diff -Nrup c/sysdeps/x86_64/setjmp.S d/sysdeps/x86_64/setjmp.S
--- c/sysdeps/x86_64/setjmp.S 2012-05-20 19:47:38.000000000 -0600
+++ d/sysdeps/x86_64/setjmp.S 2012-05-20 23:52:44.907272800 -0600
@@ -1,5 +1,5 @@
/* setjmp for x86-64.
- Copyright (C) 2001, 2003, 2005, 2006 Free Software Foundation, Inc.
+ Copyright (C) 2001,2003,2005,2006,2011 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
@@ -19,6 +19,7 @@
#include <sysdep.h>
#include <jmpbuf-offsets.h>
#include <asm-syntax.h>
+#include <stap-probe.h>
ENTRY (__sigsetjmp)
/* Save registers. */
@@ -40,6 +41,7 @@ ENTRY (__sigsetjmp)
#endif
movq %rdx, (JB_RSP*8)(%rdi)
mov (%rsp), %RAX_LP /* Save PC we are returning to now. */
+ LIBC_PROBE (setjmp, 3, 8@%rdi, -4@%esi, 8@%rax)
#ifdef PTR_MANGLE
PTR_MANGLE (%RAX_LP)
#endif

View File

@ -1,6 +1,6 @@
%define glibcsrcdir glibc-2.15.90-8b728fa3 %define glibcsrcdir glibc-2.15.90-4d17e683
%define glibcversion 2.15.90 %define glibcversion 2.15.90
%define glibcportsdir glibc-ports-2.15.90-4645e97 %define glibcportsdir glibc-ports-2.15.90-0387d093
### glibc.spec.in follows: ### glibc.spec.in follows:
%define run_glibc_tests 1 %define run_glibc_tests 1
%define auxarches athlon alphaev6 %define auxarches athlon alphaev6
@ -28,7 +28,7 @@
Summary: The GNU libc libraries Summary: The GNU libc libraries
Name: glibc Name: glibc
Version: %{glibcversion} Version: %{glibcversion}
Release: 4%{?dist} Release: 5%{?dist}
# GPLv2+ is used in a bunch of programs, LGPLv2+ is used for libraries. # GPLv2+ is used in a bunch of programs, LGPLv2+ is used for libraries.
# Things that are linked directly into dynamically linked programs # Things that are linked directly into dynamically linked programs
# and shared libraries (e.g. crt files, lib*_nonshared.a) have an additional # and shared libraries (e.g. crt files, lib*_nonshared.a) have an additional
@ -63,14 +63,14 @@ Source2: %{glibcsrcdir}-fedora.tar.gz
# Still needs to be broken down into individual patches # Still needs to be broken down into individual patches
Patch0000: %{name}-fedora.patch Patch0000: %{name}-fedora.patch
# Systemtap and thus won't likely be accepted upstream # Is this still necessary, if so, it needs to go upstream
Patch0001: %{name}-stap.patch Patch0001: %{name}-stap.patch
# Reverting an upstream patch. I don't think this has been discussed # Reverting an upstream patch. I don't think this has been discussed
# upstream yet. # upstream yet.
Patch0005: %{name}-rh769421.patch Patch0005: %{name}-rh769421.patch
# Depends on systemtap infrastructure, so can't go upstream # stap, needs to be sent upstream
Patch0009: %{name}-rh179072.patch Patch0009: %{name}-rh179072.patch
# Needs to be sent upstream # Needs to be sent upstream
@ -91,7 +91,7 @@ Patch0018: %{name}-rh688948.patch
# Needs to be sent upstream # Needs to be sent upstream
Patch0021: %{name}-rh564528.patch Patch0021: %{name}-rh564528.patch
# stap and thus will never be accepted upstream # stap, needs to be sent upstream
Patch0029: %{name}-stap-libm.patch Patch0029: %{name}-stap-libm.patch
# Build info files in the source tree, then move to the build # Build info files in the source tree, then move to the build
@ -1295,6 +1295,9 @@ rm -f *.filelist*
%endif %endif
%changelog %changelog
* Wed May 30 2012 Jeff Law <law@redhat.com> - 2.15.90-5
- Resync with upstream sources.
* Tue May 29 2012 Jeff Law <law@redhat.com> - 2.15.90-4 * Tue May 29 2012 Jeff Law <law@redhat.com> - 2.15.90-4
- Build info files in the source dir, then move to objdir - Build info files in the source dir, then move to objdir
to avoid multilib conflicts (#825061) to avoid multilib conflicts (#825061)

View File

@ -1,3 +1,3 @@
a958330a0f9d3c388abef8cbc8b868e3 glibc-2.15.90-8b728fa3.tar.gz 14a90b1f2ad381de235eae6550413f9b glibc-2.15.90-4d17e683-fedora.tar.gz
6de42dba1548f09bc6adff993db2f9fe glibc-ports-2.15.90-4645e97.tar.gz 9ed9cd006644f0484e467523882ddafc glibc-2.15.90-4d17e683.tar.gz
abe0e2514f86286214b6af4c5cff0577 glibc-2.15.90-8b728fa3-fedora.tar.gz 22f9acb2a86fc4bce023458c5a16c9e0 glibc-ports-2.15.90-0387d093.tar.gz