Hi!

On Sat, Aug 27, 2022 at 05:20:00PM +0100, Stuart Henderson wrote:
> df is used on the ramdisk, so this would need testing there (at least on
> the tighter media on some archs).
> 
> at least one other ramdisk binary does pull in libm so the overall size
> increase might not be terrible, but definitely would need checking.

I lack the knowledge and capability to do testing beyond "I just built
the patched version on CI and it rounded correctly", sorry.

But if linking to libm is an issue, we could substitute the ceil(3)s
with something trivial like
-- >8 --
int iceil(double d) {
  int ret = d;
  if(ret < d)
    ++ret;
  return ret;
}
-- >8 --
since all the formatting specifiers use %.0f anyway and the [0, 200)
domain is small enough that precision loss/overflow is not a factor.

Best,
наб

Attachment: signature.asc
Description: PGP signature

Reply via email to