[M3devel] [Fwd: Re: <*LAZYALIGN*>]

Darko darko at darko.org
Sat Feb 23 02:01:55 CET 2008


Then I assume RTTipe needs to be fixed, and pickles and the alignment  
are ok.

On 23/02/2008, at 9:01 AM, Rodney M. Bates wrote:

> But pickles are working below the type safety of the language, copying
> bits around.  True, pickles will only build an object in the reading
> program with the same type it had in the writing program.  But the
> layout of fields can be different, even with the same type, for  
> example,
> due to integer size, or as you say, endianness.  Pickles has to be  
> able
> to reconstruct the bit layout of a type both as it was on the writing
> machine and as it is on the reading machine.
>
> If anything LAZYALIGN is written to a pickle, then it's already  
> broken,
> because pickles will have the wrong idea about where the bits of the
> fields are located and will garble bits.  Pickles always recomputes
> bit layouts as the compiler would for STRICTALIGN.
>
> Which means, if you never pickle anything that is LAZYALIGN, you won't
> invoke this brokenness.  And it sounds like nobody is doing that, so
> it's not broken for current uses.
>
> Darko wrote:
>> I don't think breaking pickles is at issue at all since the  
>> alignment  issues don't change the meaning of a type, only its  
>> layout in memory  on a particular platform, akin to endian issues.
>> -- 
> -------------------------------------------------------------
> Rodney M. Bates, retired assistant professor
> Dept. of Computer Science, Wichita State University
> Wichita, KS 67260-0083
> 316-978-3922
> rodney.bates at wichita.edu




More information about the M3devel mailing list