On Fri, Jan 31, 2014 at 11:57 AM, Pierre Joye <pierre.php@gmail.com> wrote:
>
> On Jan 31, 2014 12:54 PM, "Jakub Zelenka" <bukka@php.net> wrote:
> >
> >
> > - before the patch: 8B (ptr) + 4B (int) + 4B (alignment) = 16B
> > - after the patch: 8B (ptr) + 8B (size_t) = 16B
> >
> > That seems like no increase to me. Is there anything else that I missed?
>
> size_t will be 8 bytes on most architecture. That's 4 bytes more than what
> we have now for buffer length (using int).
>
Yeah but the final size of zval is the same. With int the memory is aligned
and the extra 4 bytes are not used. It means that the size for zvalue_value
was 16B on 64bit anyway (see above). On 32bit the size of size_t and int is
4 bytes so there is no difference - 8 bytes for zvalue_value.
Regards
Jakub