Details
-
Task
-
Status: Closed (View Workflow)
-
Major
-
Resolution: Fixed
-
None
-
None
Description
Client-side prepared statements parse the SQL on every prepareStatement (text protocol) to locate
parameter markers, strings, comments and INSERT ... VALUES / ON DUPLICATE keywords, and
Connection.nativeSQL / escape processing lexes the text again to resolve
{fn ...}, {ts ...}
|
escapes.
Both lexers were byte-at-a-time state machines doing several comparisons per byte. They are rewritten
to skip ordinary bytes through a 256-entry lookup table and to consume strings, backtick identifiers
and comments in tight inner loops, with the same results as before (same unit test corpus).