> On 8. May 2018, at 13:32, Christian Hubert <[email protected]> 
> wrote:
> 
> *     Compared performance of std::map vs. .Net dictionaries : .Net is
> about 100x faster than std (the test populates the structure of 1000000
> integers ; 50ms for .Net vs. 5s for std, both in debug mode)

The numbers you get from a debug build or from running in a debugger are 
meaningless. For example, Microsoft’s CRT runtime injects lots of bounds and 
heap checking any time you run code in the Visual Studio debugger, which can be 
a dramatic slowdown even for the most optimised Release builds. Compilers and 
debuggers can have all kinds of performance-killing behaviour when debugging.

Also, synthetic tests aren’t giving too much information. Your benchmark tested 
insertion time, where one typically uses a std::map when one cares about fast 
lookups.

-Stefan

_______________________________________________
Bf-committers mailing list
[email protected]
https://lists.blender.org/mailman/listinfo/bf-committers

Reply via email to