Obviously, that fixes the immediate problem, but is there any clue as to the reason for the extraordinary difference in performance? Where's it happening?
I can see it taking longer for the parser to look up the characters, but shouldn't the original translation have reduced that to a common form (essential what's been done here), before the execution? If this question reveals a total ignorance of the internal processes, please forgive it, and keep the reply simple and brief.