[wp-trac] [WordPress Trac] #17110: apply_filters() performance

WordPress Trac wp-trac at lists.automattic.com
Mon Apr 11 23:18:05 UTC 2011

#17110: apply_filters() performance
 Reporter:  ryan          |       Owner:
     Type:  defect (bug)  |      Status:  new
 Priority:  normal        |   Milestone:  3.2
Component:  Performance   |     Version:  3.1
 Severity:  normal        |  Resolution:
 Keywords:  has-patch     |

Comment (by ryan):

 On my test setup, that patch eliminates 2886 calls to array_pop() as well
 as the corresponding assignments and reduces time spent in apply_filters()
 by almost 50%.  Most filters, like the often called gettext one, have
 nothing hooked to them so the pushing and popping is a waste of time.  For
 cases where there is hook on the filter, the patch adds one isset check.

Ticket URL: <http://core.trac.wordpress.org/ticket/17110#comment:1>
WordPress Trac <http://core.trac.wordpress.org/>
WordPress blogging software

More information about the wp-trac mailing list