Commits
Click on a commit to change the comparison rangeperf(codegen): reduce size of `LineOffsetTable` (#4643)
`LineOffsetTables` records mappings from byte offset to line and column numbers (with column number in UTF-16 characters).
Most lines do not contain any Unicode characters, and for these lines there is an exact correspondence between number of bytes from start of line and UTF-16 column number, so no column lookup table is required.
Reduce the data stored for each line from 32 bytes to 8 bytes by storing column offset lookup tables for the rare lines which do contain Unicode chars separately.
Additionally, store column lookup tables as a `Box<[u32]>` instead of `Vec<u32>` to reduce the size of `ColumnOffsets` by 8 bytes.1 year ago
by overlookmotel