new: argument 1 value '18446744073709551599' exceeds maximum
Posted: Thu Sep 29, 2022 2:41 pm
When I compile user programs in my OS using gcc and libc++ and optimizations turned on, I get the following warning when I call 'new':
It hasn't yet caused any noticble bugs, and I the warning doesn't appear when optimizations are disabled.
I'm curious why I'm getting this warning through.
18446744073709551599 = 0xFFFFFFFFFFFFFFEF Is something trying to allocate -16 bytes?
Code: Select all
../Libraries/libcxx/public/new:248:24: warning: argument 1 value '18446744073709551599' exceeds maximum object size 9223372036854775807 [-Walloc-size-larger-than=]
248 | return ::operator new(__args...);
I'm curious why I'm getting this warning through.
18446744073709551599 = 0xFFFFFFFFFFFFFFEF Is something trying to allocate -16 bytes?