[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Emacs-diffs] trunk r117189: Add diagnostics for using private heap on M
From: |
Eli Zaretskii |
Subject: |
[Emacs-diffs] trunk r117189: Add diagnostics for using private heap on MS-Windows during dumping. |
Date: |
Thu, 29 May 2014 15:21:55 +0000 |
User-agent: |
Bazaar (2.6b2) |
------------------------------------------------------------
revno: 117189
revision-id: address@hidden
parent: address@hidden
committer: Eli Zaretskii <address@hidden>
branch nick: trunk
timestamp: Thu 2014-05-29 18:21:08 +0300
message:
Add diagnostics for using private heap on MS-Windows during dumping.
src/w32heap.c (report_temacs_memory_usage): New function.
src/unexw32.c (unexec) [ENABLE_CHECKING]: Call report_temacs_memory_usage.
src/w32heap.h (report_temacs_memory_usage): Add prototype.
modified:
src/ChangeLog changelog-20091113204419-o5vbwnq5f7feedwu-1438
src/unexw32.c unexw32.c-20091113204419-o5vbwnq5f7feedwu-887
src/w32heap.c w32heap.c-20091113204419-o5vbwnq5f7feedwu-810
src/w32heap.h w32heap.h-20091113204419-o5vbwnq5f7feedwu-811
=== modified file 'src/ChangeLog'
--- a/src/ChangeLog 2014-05-29 15:05:06 +0000
+++ b/src/ChangeLog 2014-05-29 15:21:08 +0000
@@ -1,3 +1,12 @@
+2014-05-29 Eli Zaretskii <address@hidden>
+
+ * w32heap.c (report_temacs_memory_usage): New function.
+
+ * unexw32.c (unexec) [ENABLE_CHECKING]: Call
+ report_temacs_memory_usage.
+
+ * w32heap.h (report_temacs_memory_usage): Add prototype.
+
2014-05-29 Paul Eggert <address@hidden>
Don't substitute sigprocmask for pthread_sigmask (Bug#17561).
=== modified file 'src/unexw32.c'
--- a/src/unexw32.c 2014-05-27 17:31:17 +0000
+++ b/src/unexw32.c 2014-05-29 15:21:08 +0000
@@ -728,6 +728,10 @@
abort ();
strcpy (p, q);
+#ifdef ENABLE_CHECKING
+ report_temacs_memory_usage ();
+#endif
+
/* Make sure that the output filename has the ".exe" extension...patch
it up if not. */
p = out_filename + strlen (out_filename) - 4;
=== modified file 'src/w32heap.c'
--- a/src/w32heap.c 2014-05-27 17:31:17 +0000
+++ b/src/w32heap.c 2014-05-29 15:21:08 +0000
@@ -448,6 +448,19 @@
}
}
+#ifdef ENABLE_CHECKING
+void
+report_temacs_memory_usage (void)
+{
+ /* Emulate 'message', which writes to stderr in non-interactive
+ sessions. */
+ fprintf (stderr,
+ "Dump memory usage: Heap: %" PRIu64 " Large blocks(%lu): %" PRIu64
"\n",
+ (unsigned long long)committed, blocks_number,
+ (unsigned long long)(dumped_data + DUMPED_HEAP_SIZE - bc_limit));
+}
+#endif
+
/* Emulate getpagesize. */
int
getpagesize (void)
=== modified file 'src/w32heap.h'
--- a/src/w32heap.h 2014-05-27 17:31:17 +0000
+++ b/src/w32heap.h 2014-05-29 15:21:08 +0000
@@ -41,6 +41,7 @@
extern void mmap_free (void **);
extern void *mmap_alloc (void **, size_t);
+extern void report_temacs_memory_usage (void);
/* Emulation of Unix sbrk(). */
extern void *sbrk (ptrdiff_t size);
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Emacs-diffs] trunk r117189: Add diagnostics for using private heap on MS-Windows during dumping.,
Eli Zaretskii <=