@zufuliu it certainly occurs inside Scintilla, but I am not sure what it can do about it, it has to perform the wrapping operation if that setting is on.
I doubt the cache will help since the problem is the first time the file is opened, so nothing is in the cache.