Re: [opendemo-devel] Perfomance.
Status: Beta
Brought to you by:
girlich
From: Dr. U. G. <Uwe...@ph...> - 2002-01-03 17:40:39
|
Hello! mbSize() and mbGetBuffer() are now macros. > from the source: > c = fbReadChar(doc.fb, 0); > this line is totally useless wrong! The next line was the problem: the macro IS_NAMESTARTCHAR used its argument several time, so we had many calls of fbReadChar(). Now the code reads: > c = fbReadChar(doc.fb, 0); > if (!IS_NAMESTARTCHAR(c)) { > doc.errNo = XML_ERR_NAME_REQUIRED; > doc.errString = "Name does not start with valid character"; > return NULL; > } > I think we should collect the characters in a local variable and simply copy > them over after odMalloc(). fbRead() calls fbGrow() and 2 times mbSize(), > no wonder that it takes so much time. This is not done yet. Please perform another profiler run first. > ... Maybe a simple > reordering of the strcmp()s by the number of their appearance would help > a lot. Also not done yet. I wait for the profiler results (or profile myself, which takes a bit more time). Bye, Uwe |