This is the mail archive of the
glibc-cvs@sourceware.org
mailing list for the glibc project.
GNU C Library master sources branch, master, updated. glibc-2.14-583-g4104316
- From: drepper at sourceware dot org
- To: glibc-cvs at sourceware dot org
- Date: 22 Dec 2011 16:38:52 -0000
- Subject: GNU C Library master sources branch, master, updated. glibc-2.14-583-g4104316
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "GNU C Library master sources".
The branch, master has been updated
via 41043168619f1bcb12a718792b052703b9d69e91 (commit)
from b7763303bfe01853eb4b5d034414e445e8c6a7b5 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
http://sources.redhat.com/git/gitweb.cgi?p=glibc.git;a=commitdiff;h=41043168619f1bcb12a718792b052703b9d69e91
commit 41043168619f1bcb12a718792b052703b9d69e91
Author: Ulrich Drepper <drepper@gmail.com>
Date: Thu Dec 22 11:38:32 2011 -0500
Optimize tr_freehook
diff --git a/ChangeLog b/ChangeLog
index b8ea695..0544a05 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,9 @@
2011-12-22 Ulrich Drepper <drepper@gmail.com>
+ [BZ #13328]
+ * malloc/mtrace.c (tr_freehook): Avoid unnecessary unlock/lock.
+ Proposed by Mariusz_Cukr <marcukr@op.pl>.
+
* sysdeps/x86_64/fpu/bits/fenv.h: Use __REDIRECT_NTH for
__feraiseexcept_renamed.
diff --git a/NEWS b/NEWS
index bdf996e..a10415d 100644
--- a/NEWS
+++ b/NEWS
@@ -12,9 +12,9 @@ Version 2.15
6779, 6783, 9696, 10103, 10709, 11589, 12403, 12847, 12868, 12852, 12874,
12885, 12892, 12907, 12922, 12935, 13007, 13021, 13067, 13068, 13090,
13092, 13114, 13118, 13123, 13134, 13138, 13147, 13150, 13179, 13192,
- 13268, 13276, 13291, 13305, 13335, 13337, 13344, 13358, 13367, 13413,
- 13416, 13423, 13439, 13446, 13472, 13484, 13506, 13515, 13523, 13524,
- 13538
+ 13268, 13276, 13291, 13305, 13328, 13335, 13337, 13344, 13358, 13367,
+ 13413, 13416, 13423, 13439, 13446, 13472, 13484, 13506, 13515, 13523,
+ 13524, 13538
* New program pldd to list loaded object of a process
Implemented by Ulrich Drepper.
diff --git a/malloc/mtrace.c b/malloc/mtrace.c
index b55449f..0d0cb35 100644
--- a/malloc/mtrace.c
+++ b/malloc/mtrace.c
@@ -146,10 +146,12 @@ tr_freehook (ptr, caller)
tr_where (caller, info);
/* Be sure to print it first. */
fprintf (mallstream, "- %p\n", ptr);
- __libc_lock_unlock (lock);
if (ptr == mallwatch)
- tr_break ();
- __libc_lock_lock (lock);
+ {
+ __libc_lock_unlock (lock);
+ tr_break ();
+ __libc_lock_lock (lock);
+ }
__free_hook = tr_old_free_hook;
if (tr_old_free_hook != NULL)
(*tr_old_free_hook) (ptr, caller);
-----------------------------------------------------------------------
Summary of changes:
ChangeLog | 4 ++++
NEWS | 6 +++---
malloc/mtrace.c | 8 +++++---
3 files changed, 12 insertions(+), 6 deletions(-)
hooks/post-receive
--
GNU C Library master sources