Skip to content

Commit

Permalink
Update.
Browse files Browse the repository at this point in the history
2002-09-19  David Mosberger  <davidm@hpl.hp.com>

	* sysdeps/ia64/dl-fptr.c (make_fdesc): Load address of "local" via
	a 64-bit gp-relative address to enable binaries with large data
	sections.

2002-09-30  Ulrich Drepper  <drepper@redhat.com>

	* stdlib/cxa_finalize.c (__cxa_finalize): Call UNREGISTER_ATFORK
	if it is defined.
	* posix/Makefile (distribute): Add fork.h.
	* sysdeps/generic/fork.h: New file.
  • Loading branch information
Ulrich Drepper committed Oct 1, 2002
1 parent e3b0b8b commit d1f69fe
Show file tree
Hide file tree
Showing 5 changed files with 31 additions and 4 deletions.
13 changes: 13 additions & 0 deletions ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,16 @@
2002-09-19 David Mosberger <davidm@hpl.hp.com>

* sysdeps/ia64/dl-fptr.c (make_fdesc): Load address of "local" via
a 64-bit gp-relative address to enable binaries with large data
sections.

2002-09-30 Ulrich Drepper <drepper@redhat.com>

* stdlib/cxa_finalize.c (__cxa_finalize): Call UNREGISTER_ATFORK
if it is defined.
* posix/Makefile (distribute): Add fork.h.
* sysdeps/generic/fork.h: New file.

2002-09-29 Bruno Haible <bruno@clisp.org>

* sysdeps/generic/utmp_file.c (LOCKING_FAILED): New macro.
Expand Down
2 changes: 1 addition & 1 deletion posix/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ distribute := confstr.h TESTS TESTS2C.sed testcases.h \
PTESTS PTESTS2C.sed ptestcases.h \
globtest.c globtest.sh wordexp-tst.sh annexc.c fnmatch_loop.c \
spawn_int.h tst-getconf.sh regcomp.c regexec.c regex_internal.c \
regex_internal.h
regex_internal.h fork.h

routines := \
uname \
Expand Down
8 changes: 7 additions & 1 deletion stdlib/cxa_finalize.c
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/* Copyright (C) 1999, 2001 Free Software Foundation, Inc.
/* Copyright (C) 1999, 2001, 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
Expand All @@ -20,6 +20,7 @@
#include <stdlib.h>
#include <atomicity.h>
#include "exit.h"
#include <fork.h>

/* If D is non-NULL, call all functions registered with `__cxa_atexit'
with the same dso handle. Otherwise, if D is NULL, do nothing. */
Expand All @@ -41,4 +42,9 @@ __cxa_finalize (void *d)
&& compare_and_swap (&f->flavor, ef_cxa, ef_free))
(*f->func.cxa.fn) (f->func.cxa.arg, 0);
}

/* Remove the registered fork handlers. */
#ifdef UNREGISTER_ATFORK
UNREGISTER_ATFORK (d);
#endif
}
8 changes: 8 additions & 0 deletions sysdeps/generic/fork.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
/* Stub version of header for fork handling. Mainly to handle pthread_atfork
and friends. Outside dependencies:
UNREGISTER_ATFORK
If defined it must expand to a function call which takes one void*
parameter which is the DSO handle for the DSO which gets unloaded.
The function so called has to remove the atfork handlers registered
by this module. */
4 changes: 2 additions & 2 deletions sysdeps/ia64/dl-fptr.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* Manage function descriptors. IA-64 version.
Copyright (C) 1999, 2000, 2001 Free Software Foundation, Inc.
Copyright (C) 1999, 2000, 2001, 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
Expand Down Expand Up @@ -127,7 +127,7 @@ make_fdesc (Elf64_Addr ip, Elf64_Addr gp)
unsigned int old;
struct local *l;

asm ("addl %0 = @gprel (local), gp" : "=r" (l));
asm ("movl %0 = @gprel (local);; add %0 = %0, gp" : "=&r"(l));

t = l->root;
while (1)
Expand Down

0 comments on commit d1f69fe

Please sign in to comment.