summaryrefslogtreecommitdiff
path: root/lib/msgc/src
diff options
context:
space:
mode:
authorwtc%netscape.com <devnull@localhost>1998-09-25 20:34:39 +0000
committerwtc%netscape.com <devnull@localhost>1998-09-25 20:34:39 +0000
commita5cf3a954c0d28455f78eaffcd2067e961972933 (patch)
treecf0a94361c04135067133f9c138577166fbbb0be /lib/msgc/src
parent299a8c91a9d819a6d8e38032447c052271fc41e8 (diff)
downloadnspr-hg-a5cf3a954c0d28455f78eaffcd2067e961972933.tar.gz
NSPR20 v3.0 beta landing from NSPRPUB_RELEASE_3_0_LANDING_BRANCH.
Diffstat (limited to 'lib/msgc/src')
-rw-r--r--lib/msgc/src/Makefile2
-rw-r--r--lib/msgc/src/prmsgc.c19
-rw-r--r--lib/msgc/src/unixgc.c2
3 files changed, 17 insertions, 6 deletions
diff --git a/lib/msgc/src/Makefile b/lib/msgc/src/Makefile
index 05413af9..6164d38d 100644
--- a/lib/msgc/src/Makefile
+++ b/lib/msgc/src/Makefile
@@ -105,7 +105,9 @@ include $(MOD_DEPTH)/config/rules.mk
export:: $(TARGETS)
$(INSTALL) -m 444 $(TARGETS) $(DIST)/lib
+ifdef SHARED_LIBRARY
$(INSTALL) -m 444 $(SHARED_LIBRARY) $(DIST)/bin
+endif
ifeq ($(MOZ_BITS),16)
$(INSTALL) -m 444 $(TARGETS) $(MOZ_DIST)/lib
$(INSTALL) -m 444 $(TARGETS) $(MOZ_DIST)/bin
diff --git a/lib/msgc/src/prmsgc.c b/lib/msgc/src/prmsgc.c
index 76a9860e..a707092d 100644
--- a/lib/msgc/src/prmsgc.c
+++ b/lib/msgc/src/prmsgc.c
@@ -733,7 +733,10 @@ void ScanScanQ(GCScanQ *iscan)
next = &nextQ;
while (scan->queued) {
_GCTRACE(GC_MARK, ("continue scanQ @ 0x%x (%d)", scan, scan->queued));
- /* Set pointer to current scanQ so that pr_liveObject can find it */
+ /*
+ * Set pointer to current scanQ so that _pr_gcData.livePointer
+ * can find it.
+ */
pScanQ = next;
next->queued = 0;
@@ -1890,7 +1893,7 @@ pr_ConservativeWalkPointer(void* ptr, PRWalkFun walkRootPointer, void* data)
return walkRootPointer(p, data);
}
-static int32 PR_CALLBACK
+static PRInt32 PR_CALLBACK
pr_ConservativeWalkBlock(void **base, PRInt32 count,
PRWalkFun walkRootPointer, void* data)
{
@@ -2083,7 +2086,7 @@ PR_DumpMemory(PRBool detailed)
/******************************************************************************/
-static int32 PR_CALLBACK
+static PRInt32 PR_CALLBACK
pr_DumpRootPointer(PRWord* p, void* data)
{
#ifdef XP_MAC
@@ -2247,7 +2250,7 @@ PRWord* pr_traceObj; /* set this in the debugger, then execute PR_TraceRoot() */
static PRInt32 PR_CALLBACK
pr_TraceRootObject(void* obj, void* data);
-static int32 PR_CALLBACK
+static PRInt32 PR_CALLBACK
pr_TraceRootPointer(PRWord *p, void* data)
{
PRInt32 printTrace = 0;
@@ -3094,6 +3097,12 @@ PR_AllocSimpleMemory(PRWord requestedBytes, PRInt32 tix)
PR_ASSERT( bytes < MAX_ALLOC_SIZE );
#endif
/* Java can ask for objects bigger than 4M, but it won't get them */
+ /*
+ * This check was added because there is a fundamental limit of
+ * the size field maintained by the gc code. Going over the 4M
+ * limit caused some bits to roll over into another bit field,
+ * violating the max segment size and causing a bug.
+ */
if (bytes >= MAX_ALLOC_SIZE) {
return NULL;
}
@@ -3183,7 +3192,7 @@ PR_AllocSimpleMemory(PRWord requestedBytes, PRInt32 tix)
{
PRInt64 now = PR_Now();
double delta;
- int32 bin;
+ PRInt32 bin;
GCBlockEnd* end = (GCBlockEnd*)((char*)p + OBJ_BYTES(p[0]) - sizeof(GCBlockEnd));
end->allocTime = allocTime;
diff --git a/lib/msgc/src/unixgc.c b/lib/msgc/src/unixgc.c
index 0f8def44..1c36f65b 100644
--- a/lib/msgc/src/unixgc.c
+++ b/lib/msgc/src/unixgc.c
@@ -31,7 +31,7 @@
#if defined(SOLARIS)
#define _MD_MMAP_FLAGS MAP_SHARED
-#elif defined(OSF1) || defined(RELIANTUNIX)
+#elif defined(RELIANTUNIX)
#define _MD_MMAP_FLAGS MAP_PRIVATE|MAP_FIXED
#else
#define _MD_MMAP_FLAGS MAP_PRIVATE