Visual Studio 2015でビルドされた実行可能ファイルでは、ランタイムライブラリvcruntime140.dll
の下記関数を呼び出すコードが勝手に埋め込まれる。
__telemetry_main_invoke_trigger
__telemetry_main_return_trigger
関数名に telemetry/遠隔測定 といういくぶん不穏な単語が含まれているが、ETW(Event Tracing for Windows)によるロギング処理用途とのこと。ただし、同関数を機能させるためADVAPI32.dll
への依存が生まれてしまう。
従来通り同機能を無効化するには notelemetry.obj
をリンクする。
- https://www.reddit.com/r/cpp/comments/4hoyzr/msvc_mutex_is_slower_than_you_might_expect/d2thalz
- https://np.reddit.com/r/cpp/comments/4ibauu/visual_studio_adding_telemetry_function_calls_to/d2x6dau
- https://connect.microsoft.com/VisualStudio/feedback/details/1852848/unexpected-dependency-of-advapi32-dll-when-statically-linking-the-runtime-library