]> Lady’s Gitweb - Shushe/commitdiff
Just manually parse hexadecimal in Awk 0.5.2
authorLady <redacted>
Sat, 3 Feb 2024 23:25:56 +0000 (18:25 -0500)
committerLady <redacted>
Sun, 4 Feb 2024 00:49:30 +0000 (19:49 -0500)
The biggest performance bottleneck in this code was the fact that, for
compatibility reasons, Awk was piping hexadecimal numbers to the shell
in order to parse them. (Macintosh Awk can parse hexadecimal numbers in
`printf`, but G·N·U Awk cannot.)

Because the hexadecimal number is known to be two digits, it’s easy to
just parse it in Awk directly, avoiding the shell pipe and considerably
speeding up the program.


No differences found
This page took 0.021763 seconds and 4 git commands to generate.