Skip to content

perf: Replace decodeOctal's call to parseInt on the tarInput hotpath#9

Merged
kitten merged 2 commits intomainfrom
@kitten/perf/replace-octal-parsing
Nov 25, 2025
Merged

perf: Replace decodeOctal's call to parseInt on the tarInput hotpath#9
kitten merged 2 commits intomainfrom
@kitten/perf/replace-octal-parsing

Conversation

@kitten
Copy link
Copy Markdown
Owner

@kitten kitten commented Nov 24, 2025

Every decoding of a Tar header requires us to read several octals. This hotpath contains an optional call to parseInt(x, 16) which is slower than the alternative number format paths. For parity, this should avoid the call to parseInt, since the input is quite limited in its character set (only digits 0-7 are allowed).

@kitten kitten merged commit 21ab14f into main Nov 25, 2025
2 checks passed
@github-actions github-actions bot mentioned this pull request Nov 25, 2025
@kitten kitten deleted the @kitten/perf/replace-octal-parsing branch February 16, 2026 03:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant