Send Linux-ha-cvs mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
http://lists.community.tummy.com/mailman/listinfo/linux-ha-cvs
or, via email, send a message with subject or body 'help' to
[EMAIL PROTECTED]
You can reach the person managing the list at
[EMAIL PROTECTED]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of Linux-ha-cvs digest..."
Today's Topics:
1. Linux-HA CVS: membership by alan from
([email protected])
2. Linux-HA CVS: lib by alan from ([email protected])
3. Linux-HA CVS: lib by alan from ([email protected])
4. Linux-HA CVS: lib by alan from ([email protected])
5. Linux-HA CVS: include by andrew from
([email protected])
----------------------------------------------------------------------
Message: 1
Date: Wed, 1 Feb 2006 13:53:05 -0700 (MST)
From: [email protected]
Subject: [Linux-ha-cvs] Linux-HA CVS: membership by alan from
To: [EMAIL PROTECTED]
Message-ID: <[EMAIL PROTECTED]>
linux-ha CVS committal
Author : alan
Host :
Project : linux-ha
Module : membership
Dir : linux-ha/membership/ccm
Modified Files:
ccmmisc.c
Log Message:
Changed the CCM so it checks for memory leaks a lot less often...
===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/membership/ccm/ccmmisc.c,v
retrieving revision 1.27
retrieving revision 1.28
diff -u -3 -r1.27 -r1.28
--- ccmmisc.c 8 Nov 2005 21:29:59 -0000 1.27
+++ ccmmisc.c 1 Feb 2006 20:53:05 -0000 1.28
@@ -1,4 +1,4 @@
-/* $Id: ccmmisc.c,v 1.27 2005/11/08 21:29:59 gshi Exp $ */
+/* $Id: ccmmisc.c,v 1.28 2006/02/01 20:53:05 alan Exp $ */
/*
* ccmmisc.c: Miscellaneous Consensus Cluster Service functions
*
@@ -156,15 +156,22 @@
/* check for memory leaks */
struct mallinfo i;
static int arena=0;
- i = mallinfo();
- if(arena==0) {
- arena = i.arena;
- } else if(arena < i.arena) {
- cl_log(LOG_WARNING,
- "leaking memory? previous arena=%d "
- "present arena=%d",
- arena, i.arena);
- arena=i.arena;
+ static int count = 0;
+
+ ++count;
+ /* Mallinfo is surprisingly expensive */
+ if (count >= 60) {
+ count = 0;
+ i = mallinfo();
+ if(arena==0) {
+ arena = i.arena;
+ } else if(arena < i.arena) {
+ cl_log(LOG_WARNING,
+ "leaking memory? previous arena=%d "
+ "present arena=%d",
+ arena, i.arena);
+ arena=i.arena;
+ }
}
#endif
}
------------------------------
Message: 2
Date: Wed, 1 Feb 2006 21:55:51 -0700 (MST)
From: [email protected]
Subject: [Linux-ha-cvs] Linux-HA CVS: lib by alan from
To: [EMAIL PROTECTED]
Message-ID: <[EMAIL PROTECTED]>
linux-ha CVS committal
Author : alan
Host :
Project : linux-ha
Module : lib
Dir : linux-ha/lib/clplumbing
Modified Files:
cl_malloc.c
Log Message:
Put in code to round up the size of memory asked for from malloc when asking
for chunks bigger than
we manage ourselves. This rounding size is currently set to 4K.
Since we manage all things up to 4K, this is probably good...
Probably would be even better if we went ahead and managed everything
up to 64K ourselves.
But, this is a more moderate step with the intent of helping with
memory fragmentation.
===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/lib/clplumbing/cl_malloc.c,v
retrieving revision 1.20
retrieving revision 1.21
diff -u -3 -r1.20 -r1.21
--- cl_malloc.c 1 Feb 2006 18:55:17 -0000 1.20
+++ cl_malloc.c 2 Feb 2006 04:55:50 -0000 1.21
@@ -1,4 +1,4 @@
-/* $Id: cl_malloc.c,v 1.20 2006/02/01 18:55:17 alan Exp $ */
+/* $Id: cl_malloc.c,v 1.21 2006/02/02 04:55:50 alan Exp $ */
/*
* Copyright (C) 2000 Alan Robertson <[EMAIL PROTECTED]>
*
@@ -191,7 +191,7 @@
# define CHECK_GUARD_BYTES(cp, msg) /* */
#endif
-
+#define MALLOCROUND 4096 /* Round big mallocs up to a multiple
of this size */
/*
* cl_malloc: malloc clone
@@ -534,6 +534,9 @@
}
mallocsize = MALLOCSIZE(allocsize);
+ if (numbuck == NOBUCKET) {
+ mallocsize = (((mallocsize +
(MALLOCROUND-1))/MALLOCROUND)*MALLOCROUND);
+ }
if ((hdrret = malloc(mallocsize)) == NULL) {
return NULL;
------------------------------
Message: 3
Date: Wed, 1 Feb 2006 22:09:19 -0700 (MST)
From: [email protected]
Subject: [Linux-ha-cvs] Linux-HA CVS: lib by alan from
To: [EMAIL PROTECTED]
Message-ID: <[EMAIL PROTECTED]>
linux-ha CVS committal
Author : alan
Host :
Project : linux-ha
Module : lib
Dir : linux-ha/lib/clplumbing
Modified Files:
cl_malloc.c
Log Message:
Changed cl_malloc so it handles buffers up to 64K
------------------------------
Message: 4
Date: Wed, 1 Feb 2006 22:15:22 -0700 (MST)
From: [email protected]
Subject: [Linux-ha-cvs] Linux-HA CVS: lib by alan from
To: [EMAIL PROTECTED]
Message-ID: <[EMAIL PROTECTED]>
linux-ha CVS committal
Author : alan
Host :
Project : linux-ha
Module : lib
Dir : linux-ha/lib/clplumbing
Modified Files:
cl_malloc.c
Log Message:
Fixed the last fix. The constant 11 should have been 12.
This is about getting the powers of two correct in cl_malloc so that
we can manage chunks of memory up to 64k by ourselves (in cl_malloc).
===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/lib/clplumbing/cl_malloc.c,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -3 -r1.22 -r1.23
--- cl_malloc.c 2 Feb 2006 05:09:19 -0000 1.22
+++ cl_malloc.c 2 Feb 2006 05:15:22 -0000 1.23
@@ -1,4 +1,4 @@
-/* $Id: cl_malloc.c,v 1.22 2006/02/02 05:09:19 alan Exp $ */
+/* $Id: cl_malloc.c,v 1.23 2006/02/02 05:15:22 alan Exp $ */
/*
* Copyright (C) 2000 Alan Robertson <[EMAIL PROTECTED]>
*
@@ -131,7 +131,7 @@
};
-#define NUMBUCKS 11
+#define NUMBUCKS 12
#define NOBUCKET (NUMBUCKS)
static struct cl_bucket* cl_malloc_buckets[NUMBUCKS];
@@ -607,7 +607,7 @@
{
int j;
size_t cursize = 32;
- int llcount = 1;
+ int llcount = 1;
cl_malloc_inityet = 1;
------------------------------
Message: 5
Date: Thu, 2 Feb 2006 01:33:14 -0700 (MST)
From: [email protected]
Subject: [Linux-ha-cvs] Linux-HA CVS: include by andrew from
To: [EMAIL PROTECTED]
Message-ID: <[EMAIL PROTECTED]>
linux-ha CVS committal
Author : andrew
Host :
Project : linux-ha
Module : include
Dir : linux-ha/include/crm/common
Modified Files:
xml.h
Log Message:
Non "dev" builds don't need to call cl_is_allocated() and crm_validate_data().
They are very expensive and will have caught everything they're going to
catch in our testing.
===================================================================
RCS file: /home/cvs/linux-ha/linux-ha/include/crm/common/xml.h,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -3 -r1.38 -r1.39
--- xml.h 7 Jan 2006 21:23:11 -0000 1.38
+++ xml.h 2 Feb 2006 08:33:14 -0000 1.39
@@ -1,4 +1,4 @@
-/* $Id: xml.h,v 1.38 2006/01/07 21:23:11 andrew Exp $ */
+/* $Id: xml.h,v 1.39 2006/02/02 08:33:14 andrew Exp $ */
/*
* Copyright (C) 2004 Andrew Beekhof <[EMAIL PROTECTED]>
*
@@ -32,7 +32,9 @@
#include <clplumbing/cl_log.h>
/* #define USE_LIBXML 1 */
-#define XML_PARANOIA_CHECKS 1
+#if CRM_DEV_BUILD
+# define XML_PARANOIA_CHECKS 1
+#endif
#ifdef USE_LIBXML
# include <libxml/tree.h>
------------------------------
_______________________________________________
Linux-ha-cvs mailing list
[email protected]
http://lists.community.tummy.com/mailman/listinfo/linux-ha-cvs
End of Linux-ha-cvs Digest, Vol 27, Issue 3
*******************************************