I have a rather complicated C ++ code that is used in a real-time system and, therefore, is absolutely speed sensitive. It was developed on Linux and, to speed up its execution, many functions were marked with the keyword βinlineβ and moved to the header files to allow embedding.
Now I have ported this code to Windows (msvc 10.0, Windows 7) and it works 30% slower. After some profiling, I found out that the problem mainly lies in the fact that many functions are not built-in. When I use "__forceinline", I can easily see acceleration of about 10-20%.
Does anyone have an explanation? Does msvc algorithm work much more conservatively? Or was I just doing something wrong, for example, was there a missing configuration option?
user1720409
source share