rust/library/core
Jubilee c6cdd457eb
Rollup merge of #125606 - diondokter:opt-size-int-fmt, r=cuviper
Size optimize int formatting

Let's use the new feature flag!

This uses a simpler algorithm to format integers.
It is slower, but also smaller.
It also saves having to import the 200 byte rodata lookup table.

In a test of mine this saves ~300 bytes total of a cortex-m binary that does integer formatting.
For a 16KB device, that's almost 2%.

Note though that for opt-level 3 the text size actually grows by 116 bytes.
Still a win in total. I'm not sure why the generated code is bigger than the more fancy algo. Maybe the smaller algo lends itself more to inlining and duplicating?
2024-06-06 21:10:08 -07:00
..
benches Write char::DebugEscape sequences using write_str 2024-05-20 10:04:44 +02:00
src Rollup merge of #125606 - diondokter:opt-size-int-fmt, r=cuviper 2024-06-06 21:10:08 -07:00
tests Add function core::iter::chain 2024-06-04 10:51:05 +02:00
Cargo.toml Remove now outdated comment since we bumped stage0 2024-05-24 08:08:41 +02:00