Boost logo

Boost Users :

From: Andrew VanUitert (avanuitert_at_[hidden])
Date: 2007-05-29 19:54:10


 

I am using Boost Serialization as a basic RPC mechanism on an embedded
Linux system, however it seems that the serialization library uses a lot
of CPU cycles to process some rather simple messages. Each of the
messages I am using passes a pointer to an object that is a serializable
object representing the needed parameters for each type of message. As
each message/command is passed from one system to another, the pointer
is filled in with the de-marshaled parameters. So far this has worked
splendidly except for the CPU utilization. The embedded processor is an
Arm running at 300 MHz, and when I send it repeated messages the CPU
utilization pegs. Profiling has revealed that the embedded processor is
spending all its time in serialization library.

 

For the most part, the message being sent back and forth are arrays of
chars under 255 in size.

 

Are there some general guidelines when considering performance with this
library ?

 

For instance, I read that the performance of 1.34 increased
substantially with the use of a streambuf and a binary archive for
arrays of basic types. However, the constructor that takes a streambuf
is only available in the binary archive, and I am using a text archive
to avoid ending and alignment issues.

 

Is the use of a pointer for the parameters a place for optimization ?

 

Andy



Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net