An experimental profile mode has been added. This is an implementation of many C++ standard library constructs with an additional analysis layer that gives performance improvement advice based on recognition of suboptimal usage patterns. For example,
#include <vector>
int main()
{
std::vector<int> v;
for (int k = 0; k < 1024; ++k)
v.insert(v.begin(), k);
}
When instrumented via the profile mode, can return suggestions about the initial size and choice of the container used as follows:
vector-to-list: improvement = 5: call stack = 0x804842c ...
: advice = change std::vector to std::list
vector-size: improvement = 3: call stack = 0x804842c ...
: advice = change initial container size from 0 to 1024
These constructs can be substituted for the normal libstdc++
constructs on a piecemeal basis, or all existing components can be
transformed via the -D_GLIBCXX_PROFILE
macro.
git clone git://gitorious.org/boost/cmake.git src
cd src
git checkout <TAG> //TAG==1.41.0.cmake0
mkdir bld
cd bld/
cmake ../
濡傛灉闇瑕佹寜闇緙栬瘧鏌愪簺搴擄紝鍙渶鐢╩ake edit_cache淇敼cache鍗沖彲銆?br>