re_intuit_start(): merge two similar code branches
authorDavid Mitchell <davem@iabyn.com>
Thu, 26 Dec 2013 22:00:24 +0000 (22:00 +0000)
committerDavid Mitchell <davem@iabyn.com>
Fri, 7 Feb 2014 22:39:35 +0000 (22:39 +0000)
commitd307bf5770f4eac074e80949ff625172ad46de1b
tree4678b2d4594acf82f891ed901c99147d41a3e071
parentc0e0ec46b63bba8f76af7b2b923a04d38bb671f3
re_intuit_start(): merge two similar code branches

When the check string is anchored at a fixed offset from the start
of the string (e.g. /^..abc/), there are two similar code branches
that do a quick memNE() reject - the difference being whether SvTAIL() is
true, i.e. whether the pattern ends with $ and may match a \n.

Merge the common bits of the two branches. Technically this makes the
non-SvTAIL() branch slightly less efficient, since it will always retrieve
SvCUR(check) even when its not needed, but in practice it will already be
in the cache since we have to access SvPVX(check), and the I-cache misses
will have been reduced by reducing the code size.

It also removes one label.
regexec.c