[TYPO3-core] RFC #11808 : [Feature]: Increase performance using mbstring in t3lib_cs->crop

Rupert Germann rupi at gmx.li
Sat Aug 29 17:10:32 CEST 2009


hi Timo,

great performance improvement!

here some numbers:

trunk:   252ms (100%)
patched: 106ms ( 42%)

what did I test:
I used the array from your testcase and called function 
t3lib_div::fixed_lgd_cs() for each entry. this was done in another loop 
with 1000 iterations.


now the same with real-world data:
I measured the time that function getTable() in class.db_list_extra.inc 
needs to go through the foreach($accRows as $row) loop when displaying 
an extended view with 100 records.

trunk:   145ms (100%)
patched: 135ms ( 93%)

(crop() is called 240 times during this loop)

having in mind that I measure the execution time of a lot of other code, 
then 7% faster is still great :-)

+1 by reading, testing and benchmarking

I also tried Masi's suggestion (inlining instead of new method).
result: no measurable difference.



will take care of the commit


greets
rupert


More information about the TYPO3-team-core mailing list