On 2007-06-08T11:06:02, Dejan Muhamedagic <[EMAIL PROTECTED]> wrote: > > Right. That's why the compression needs to be done in the *_add call > > directly, so that the lower levels need not know about message > > compression. > > > > Hinting is broken by design, and I don't want to see that introduced. > Can you elaborate.
Predicting a possible compressed size is notoriously hard and inexact. Having the compression happen immediately, so that all layers which care about the actual wire-size of the encoded message, is the best way. Only the outer layers - ie, the users of the cl_msg stuff - care about the uncompressed size to allocate their buffers when retrieving it. Internally, _nobody_ ever needs to touch the uncompressed data. So, right now message compression simply happens at the entirely wrong level, which causes needless complexity and obscurity. Does that clear my point of view up? ;-) Regards, Lars -- Teamlead Kernel, SuSE Labs, Research and Development SUSE LINUX Products GmbH, GF: Markus Rex, HRB 16746 (AG Nürnberg) "Experience is the name everyone gives to their mistakes." -- Oscar Wilde _______________________________________________________ Linux-HA-Dev: Linux-HA-Dev@lists.linux-ha.org http://lists.linux-ha.org/mailman/listinfo/linux-ha-dev Home Page: http://linux-ha.org/