Re: [Evolution-hackers] Performance with Exchange 2003



On Fri, 2005-04-29 at 12:56 -0400, Lee Revell wrote:
> Now do you believe me that it's a folder
> search bug?
> 

I have attached a debugging patch that times the search phase of the
message list generation.  These results clearly demonstrate the problem:

Test procedure: After applying debug patch, launch Evo, then repeatedly
switch back and forth between "Inbox" and "Unread Mail".

Unpatched:

regen_list_regen: search took 0.778 seconds
regen_list_regen: search took 0.073 seconds
regen_list_regen: search took 0.008 seconds
regen_list_regen: search took 6.248 seconds
regen_list_regen: search took 0.091 seconds
regen_list_regen: search took 0.064 seconds
regen_list_regen: search took 7.886 seconds
regen_list_regen: search took 0.060 seconds
regen_list_regen: search took 16.395 seconds
regen_list_regen: search took 6.674 seconds
regen_list_regen: search took 5.605 seconds
regen_list_regen: search took 12.937 seconds
regen_list_regen: search took 20.375 seconds
regen_list_regen: search took 0.170 seconds
regen_list_regen: search took 20.913 seconds
regen_list_regen: search took 54.960 seconds
regen_list_regen: search took 17.991 seconds
regen_list_regen: search took 31.834 seconds
regen_list_regen: search took 0.165 seconds

evo-search-bar-fix.patch:

regen_list_regen: search took 0.001 seconds
regen_list_regen: search took 0.002 seconds
regen_list_regen: search took 0.030 seconds
regen_list_regen: search took 1.425 seconds
regen_list_regen: search took 1.885 seconds
regen_list_regen: search took 3.389 seconds
regen_list_regen: search took 0.024 seconds
regen_list_regen: search took 11.302 seconds
regen_list_regen: search took 3.078 seconds
regen_list_regen: search took 0.024 seconds
regen_list_regen: search took 8.270 seconds
regen_list_regen: search took 3.487 seconds
regen_list_regen: search took 0.057 seconds
regen_list_regen: search took 3.649 seconds
regen_list_regen: search took 0.024 seconds
regen_list_regen: search took 8.832 seconds
regen_list_regen: search took 0.024 seconds
regen_list_regen: search took 9.913 seconds

evo-search-bar-fix.patch + hack to disable "hidejunk":

regen_list_regen: search took 0.000 seconds
regen_list_regen: search took 0.000 seconds
regen_list_regen: search took 0.000 seconds
regen_list_regen: search took 0.000 seconds
regen_list_regen: search took 0.000 seconds
regen_list_regen: search took 0.005 seconds
regen_list_regen: search took 0.004 seconds
regen_list_regen: search took 0.000 seconds
regen_list_regen: search took 0.000 seconds
regen_list_regen: search took 0.000 seconds
regen_list_regen: search took 0.006 seconds
regen_list_regen: search took 0.001 seconds
regen_list_regen: search took 0.005 seconds
regen_list_regen: search took 0.000 seconds
regen_list_regen: search took 0.004 seconds
regen_list_regen: search took 0.000 seconds
regen_list_regen: search took 0.000 seconds
regen_list_regen: search took 0.000 seconds
regen_list_regen: search took 0.005 seconds

I was wrong about the impact of the search bar bug relative to the
hidejunk issue, but it's impossible to deny that the above numbers
represent a problem.

Lee
Index: evolution/mail/message-list.c
===================================================================
RCS file: /cvs/gnome/evolution/mail/message-list.c,v
retrieving revision 1.414
diff -u -r1.414 message-list.c
--- evolution/mail/message-list.c	1 Apr 2005 00:17:24 -0000	1.414
+++ evolution/mail/message-list.c	29 Apr 2005 19:15:19 -0000
@@ -74,7 +74,7 @@
 
 #include "art/empty.xpm"
 
-/*#define TIMEIT */
+#define TIMEIT
 
 #ifdef TIMEIT
 #include <sys/time.h>
@@ -3117,6 +3117,7 @@
 	if (search != NULL && ml->search != NULL && strcmp (search, ml->search) == 0)
 		return;
 
+	printf ("message_list_set_search %s\n", search);
 	if (ml->thread_tree) {
 		camel_folder_thread_messages_unref(ml->thread_tree);
 		ml->thread_tree = NULL;
@@ -3397,6 +3398,14 @@
 	if (m->folder != m->ml->folder)
 		return;
 
+#ifdef TIMEIT
+	struct timeval start, end;
+	unsigned long diff;
+
+	printf("regen_list_regen: search\n");
+	gettimeofday(&start, NULL);
+#endif
+	
 	/* if we have hidedeleted on, use a search to find it out, merge with existing search if set */
 	if (!camel_folder_has_search_capability(m->folder)) {
 		/* if we have no search capability, dont let search or hide deleted work */
@@ -3435,6 +3444,13 @@
 				uids = camel_folder_get_uids (m->folder);
 		}
 	}
+
+#ifdef TIMEIT
+	gettimeofday(&end, NULL);
+	diff = end.tv_sec * 1000 + end.tv_usec/1000;
+	diff -= start.tv_sec * 1000 + start.tv_usec/1000;
+	printf("regen_list_regen: search took %ld.%03ld seconds\n", diff / 1000, diff % 1000);
+#endif
 	
 	if (camel_exception_is_set (&mm->ex))
 		return;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]