Author: dick
Date: 2007-02-16 15:26:02 -0500 (Fri, 16 Feb 2007)
New Revision: 73042
Modified:
trunk/mono/mono/metadata/ChangeLog
trunk/mono/mono/metadata/threadpool.c
Log:
2007-02-16 Dick Porter <[EMAIL PROTECTED]>
* threadpool.c (append_job): Fix fast-path array handling, so it's
less likely the array will grow exponentially when the load is
heavy.
Modified: trunk/mono/mono/metadata/ChangeLog
===================================================================
--- trunk/mono/mono/metadata/ChangeLog 2007-02-16 20:07:32 UTC (rev 73041)
+++ trunk/mono/mono/metadata/ChangeLog 2007-02-16 20:26:02 UTC (rev 73042)
@@ -1,4 +1,9 @@
+2007-02-16 Dick Porter <[EMAIL PROTECTED]>
+ * threadpool.c (append_job): Fix fast-path array handling, so it's
+ less likely the array will grow exponentially when the load is
+ heavy.
+
Fri Feb 16 19:17:30 CET 2007 Paolo Molaro <[EMAIL PROTECTED]>
* metadata-internals.h, loader.c: fix dllmap lookup order
Modified: trunk/mono/mono/metadata/threadpool.c
===================================================================
--- trunk/mono/mono/metadata/threadpool.c 2007-02-16 20:07:32 UTC (rev
73041)
+++ trunk/mono/mono/metadata/threadpool.c 2007-02-16 20:26:02 UTC (rev
73042)
@@ -1116,7 +1116,7 @@
append_job (CRITICAL_SECTION *cs, TPQueue *list, MonoObject *ar)
{
EnterCriticalSection (cs);
- if (list->array && mono_array_length (list->array) < list->next_elem) {
+ if (list->array && (list->next_elem < mono_array_length (list->array)))
{
mono_array_setref (list->array, list->next_elem, ar);
list->next_elem++;
LeaveCriticalSection (cs);
_______________________________________________
Mono-patches maillist - [email protected]
http://lists.ximian.com/mailman/listinfo/mono-patches