[wp-trac] [WordPress Trac] #41501: Emoji: Short-circuit wp_staticize_emoji() when there are no emoji to staticise.

WordPress Trac noreply at wordpress.org
Tue Aug 1 17:08:55 UTC 2017


#41501: Emoji: Short-circuit wp_staticize_emoji() when there are no emoji to
staticise.
-------------------------------------+--------------------------
 Reporter:  pento                    |       Owner:  pento
     Type:  defect (bug)             |      Status:  assigned
 Priority:  high                     |   Milestone:  4.9
Component:  Emoji                    |     Version:  trunk
 Severity:  major                    |  Resolution:
 Keywords:  has-patch needs-testing  |     Focuses:  performance
-------------------------------------+--------------------------
Description changed by westonruter:

Old description:

> After [41043], there seem to be some circumstances where the new regex is
> noticeably slower, particularly with PHP < 7, and PCRE < 8.39.
>
> This isn't noticeable for most sites, but does become a problem for sites
> with a particularly high volume of HTML email. (Looking at you, WP.com.)
>
> To help mitigate that, we can short circuit the process with early checks
> for emoji - if there are none, we can return before running the regex.

New description:

 After [41043] (for #35293), there seem to be some circumstances where the
 new regex is noticeably slower, particularly with PHP < 7, and PCRE <
 8.39.

 This isn't noticeable for most sites, but does become a problem for sites
 with a particularly high volume of HTML email. (Looking at you, WP.com.)

 To help mitigate that, we can short circuit the process with early checks
 for emoji - if there are none, we can return before running the regex.

--

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


More information about the wp-trac mailing list