Re: [VOTE] 64 bit platform improvements for string length and integer

From: Date: Fri, 31 Jan 2014 11:54:06 +0000
Subject: Re: [VOTE] 64 bit platform improvements for string length and integer
References: 1 2 3 4 5 6 7 8 9  Groups: php.internals 
Request: Send a blank email to internals+get-71859@lists.php.net to get a copy of this message
Hi, On Fri, Jan 31, 2014 at 11:34 AM, Derick Rethans <derick@php.net> wrote: > On Thu, 30 Jan 2014, Christopher Jones wrote: > > > This is because the implementation touches nearly every source file > > and alters the string length of the most fundamental data object in > > PHP's implementation (the zval). > > I know in the past we have been really reluctant to increase the zval > change. F.e. with the GC change we added bitfields. I think it might be > less of an issue now to increase the size, as Dmitry has I think > improved the allocator quite a bit, but it is by no means something that > should be glossed over lightly. > > cheers, > Derick > What do you mean by increasing the zval size? GCC aligns the memory to 64bits on 64bit which means following for the string in zvalue_value: - 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? Cheers Jakub

« previous php.internals (#71859) next »