|
Boost Users : |
Subject: [Boost-users] Boost interprocess containers - performance issue
From: Naveen Santhapuri (naveenu_at_[hidden])
Date: 2012-03-10 19:00:22
Hello all,
I am experimenting with Boost interprocess containers and like the
ease of using them. I want to use these in place of the "linux shared
memory+shared memory allocator + std containers". However, I am seeing some
performance hit when using boost. I measured the times for vector access
from shared memory. I define access as indexing into the vector (v[i]) (all
times in milli seconds):
Num elements Local heap | Boost ipc | Shmat()
100,000 0.23 0.39 0.27
1,000,000 2.3 3.85 2.7
I repeated these for different number of elements and the results scaled as
above. I used callgrid+kcachegrind to profile boost and shmat() access, and
I see there is a significant amount of time spent in boost offset pointer
calculation and mcount ( I don't know what that is).
Is there something I am missing or is this an expected performance hit, for
using boost with all off the additional functionality, compared to linux
shared memory?
Thank you,
Naveen
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