Repository navigation
fs: dispatch ASCII and Latin1 via simdutf in ReadFileUtf8 - #63370
Closed
mertcanaltin wants to merge 1 commit into
Closed
mertcanaltin wants to merge 1 commit into
mertcanaltin wants to merge 1 commit into
Conversation
Collaborator
|
Review requested:
|
Codecov Report❌ Patch coverage is |
In fs.readFileSync(path, 'utf8'), I dispatch the V8 string creation through simdutf. ASCII and Latin1-fits utf-8 use one-byte V8 strings, multibyte goes through simdutf to UTF-16, invalid utf-8 falls back to V8.
@nodejs/fs, @anonrig @addaleax, @lemire @mcollina
Bench results (gist): https://gist.github.com/mertcanaltin/a0096c3fad387d0bace821938754af44