[PATCH] malloc: Improve checked_request2size
Paul Eggert
eggert@cs.ucla.edu
Fri Jun 6 19:49:33 GMT 2025
On 6/6/25 12:44, Cristian Rodríguez wrote:
> PTRDIFF_MAX + 1 is a nice way to say "it cannot be handled"
OK, but SIZE_MAX also says it nicely, and on x86-64 at least SIZE_MAX is
a bit more efficient because the instruction represents -1 more
compactly than 2**63.
> maybe adding a constant explaining that fact is better.
Yes, that'd be good regardless of the constant's value.
More information about the Libc-alpha
mailing list