On 2015-03-13 08:27, Dominique Devienne wrote:
On Fri, Mar 13, 2015 at 9:22 AM, Ion GaztaƱaga
wrote: Might also be interesting to know if your perf numbers are based on a primitive key or a UDT, and whether the relative performance changes depending on key/value sizes. --DD
On 2015-03-13 09:11, Giacomo Drago wrote:> On 2015-03-13 08:27, Dominique Devienne wrote:
On Fri, Mar 13, 2015 at 9:22 AM, Ion GaztaƱaga
wrote: Just a question. Are your insertions one by one or by range?
Might also be interesting to know if your perf numbers are based on a primitive key or a UDT, and whether the relative performance changes depending on key/value sizes. --DD
This is what happens with a key made of four integers rather than just an integer. Size: 50000 std::map: Random insertion: 19.881 ms Random find: 19.87 ms Iteration: 6.241 ms Random erase: 42.872 ms experimental::flat_map: Random insertion: 509.001 ms Random find: 14.922 ms Iteration: 9.036 ms Random erase: 727.366 ms boost::container::flat_map: Random insertion: 1049.87 ms Random find: 7.778 ms Iteration: 0.082 ms Random erase: 885.753 ms Size: 200000 std::map: Random insertion: 124.174 ms Random find: 133.111 ms Iteration: 21.915 ms Random erase: 253.892 ms experimental::flat_map: Random insertion: 8181.72 ms Random find: 96.38 ms Iteration: 45.847 ms Random erase: 10951.3 ms boost::container::flat_map: Random insertion: 20271.5 ms Random find: 53.225 ms Iteration: 0.455 ms Random erase: 17338.5 ms Best Giacomo