Although you found your problem already, using the perl-compatible (preg_match, etc) regular expressions are MUCH MUCH faster (I can't quite explain how much faster it is!) than the POSIX-extended (ereg, etc) ones..
They use almost the exact same syntax, and can be converted easily to use the perl compatible ones.
For example, your eregi could be converted as so:
eregi("([]){\=function_name🙁[]):function_name\=}([])", $this->html, $tmp3)
preg_match("~{\=function_name🙁[]):function_name\=}~i",$this->html,$tmp3)
And you should get the exact same result (Not tested since I don't have an example input or output).
Hope this helps,
-Josh B