[wp-trac] [WordPress Trac] #58376: Improve performance of the `_wp_array_get` function

WordPress Trac noreply at wordpress.org
Tue May 23 22:51:30 UTC 2023


#58376: Improve performance of the `_wp_array_get` function
-------------------------+-----------------------------
 Reporter:  aristath     |       Owner:  SergeyBiryukov
     Type:  enhancement  |      Status:  closed
 Priority:  high         |   Milestone:  6.3
Component:  General      |     Version:
 Severity:  normal       |  Resolution:  fixed
 Keywords:  has-patch    |     Focuses:  performance
-------------------------+-----------------------------

Comment (by costdev):

 Here are some results from a quick check loading the frontend while logged
 in as an admin (TT3 active, no plugins active).

 Total calls to `_wp_array_get()`: 23873

 Top 5:
 - 9849 calls - `WP_Theme_JSON::merge()`
 - 3559 calls - `WP_Theme_JSON::get_property_value()`
 - 3283 calls - `WP_Theme_JSON::get_default_slugs()`
 - 1340 calls - `WP_Theme_JSON::get_metadata_boolean()`
 - 1129 calls - `block_has_support()`
 - These top 5 account for 19160 calls, or ~80%.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/58376#comment:11>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list