-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Open
Description
Issue Description
Providing /p:MultiProcessorCompilation=true doesn't seem to add /MP to the resulting cl command.
Steps to Reproduce
cmake_minimum_required(VERSION 3.10)
project(HelloInstall)
set(CMAKE_CXX_STANDARD 20)
add_executable(main main.cpp)// main.cpp
#include <iostream>
int main() {
std::cout << "Hello, World!" << std::endl;
return 0;
}mkdir build && cd build
cmake ..
msbuild main.vcxproj /p:Configuration=Release /p:Platform=x64 /v:n /p:MultiProcessorCompilation=trueExpected Behavior
Resulting cl command to have /MP.
Similar to how /p:WholeProgramOptimization=true adds /GL.
Actual Behavior
Resuling cl command is missing /MP:
L:\Software\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.44.35207\bin\HostX64\x64\CL.exe /c /nologo /W3 /WX- /diagnostics:column /O2 /Ob2 /D _MBCS /D
WIN32 /D _WINDOWS /D NDEBUG /D "CMAKE_INTDIR=\"Release\"" /EHsc /MD /GS /fp:precise /Zc:wchar_t /Zc:forScope /Zc:inline /GR /std:c++20 /Fo"main.dir\Release\\" /F
d"main.dir\Release\vc143.pdb" /external:W3 /Gd /TP /errorReport:queue "L:\ccache-test\main.cpp"
Analysis
No response
Versions & Configurations
MSBuild version 17.14.23+b0019275e for .NET Framework
Metadata
Metadata
Assignees
Labels
No labels