Boost logo

Boost Users :

Subject: Re: [Boost-users] Boost Python is slow?
From: Ravi (lists_ravi_at_[hidden])
Date: 2009-07-11 11:08:52


On Thursday 09 July 2009 05:00:47 Tyomich on the AIR wrote:
> And then when I use a simple function which just increments the x member of
> every object, this function takes about 4 seconds to process the whole list
> (1000000 items) of Boost-wrapped objects and less than a second to process
> objects of my own wrapping! How this can be possible? Is Boost.Python much
> more slower than Python itself?

Boost.Python is a little slower than wrapping directly using Python C-API,
especially in very simple cases like yours. (It is a variant of the
abstraction penalty.) However, it is hard to believe that it is 4x slower.
Would you mind posting complete compilable examples so that we can take a look
at it?

Regards,
Ravi


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