Skip to content

Commit 925fee8

Browse files
author
Colin Robertson
authored
More VS2022 non-bulk fixes. (#3867)
1 parent b6dc238 commit 925fee8

6 files changed

Lines changed: 46 additions & 34 deletions

File tree

docs/build-insights/reference/vcperf-commands.md

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,16 +8,17 @@ helpviewer_keywords: ["C++ Build Insights", "throughput analysis", "build time a
88

99
::: moniker range="<=msvc-150"
1010

11-
The C++ Build Insights tools are available in Visual Studio 2019. To see the documentation for that version, set the Visual Studio **Version** selector control for this article to Visual Studio 2019. It's found at the top of the table of contents on this page.
11+
The C++ Build Insights tools are available starting in Visual Studio 2019 and later. To see the documentation for that version, set the Visual Studio **Version** selector control for this article to Visual Studio 2019 or later. It's found at the top of the table of contents on this page.
1212

1313
::: moniker-end
14-
::: moniker range="msvc-160"
14+
::: moniker range=">=msvc-160"
1515

16-
This article lists and describes the commands available in *vcperf.exe*, and how to use them.
16+
This article lists and describes the commands available in *`vcperf.exe`*, and how to use them.
1717

1818
## Commands to start and stop traces
1919

20-
*IMPORTANT: the following commands all require administrative privileges.*
20+
> [!IMPORTANT]
21+
> The following commands all require administrative privileges.
2122
2223
| Option | Arguments and description |
2324
|------------------|---------------------------|

docs/build-insights/tutorials/vcperf-and-wpa.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -8,18 +8,18 @@ helpviewer_keywords: ["C++ Build Insights", "throughput analysis", "build time a
88

99
::: moniker range="<=msvc-150"
1010

11-
The C++ Build Insights tools are available in Visual Studio 2019. To see the documentation for this version, set the Visual Studio **Version** selector control for this article to Visual Studio 2019. It's found at the top of the table of contents on this page.
11+
The C++ Build Insights tools are available in Visual Studio 2019 and later. To see the documentation for this version, set the Visual Studio **Version** selector control for this article to Visual Studio 2019 or later. It's found at the top of the table of contents on this page.
1212

1313
::: moniker-end
14-
::: moniker range="msvc-160"
14+
::: moniker range=">=msvc-160"
1515

16-
In this tutorial, you'll learn how to use *vcperf.exe* to collect a trace of your C++ build. You'll also learn how to view this trace in Windows Performance Analyzer.
16+
In this tutorial, you'll learn how to use *`vcperf.exe`* to collect a trace of your C++ build. You'll also learn how to view this trace in Windows Performance Analyzer.
1717

1818
## Step 1: Install and configure Windows Performance Analyzer
1919

2020
WPA is a trace viewer available in the Windows Assessment and Deployment Kit (ADK). It's a separate utility that's not part of the components you can install with the Visual Studio installer.
2121

22-
A version of WPA that supports C++ Build Insights is currently only available in the most recent versions of the Windows ADK, 10.1.19041.0 or later.
22+
A version of WPA that supports C++ Build Insights is only available in versions of the Windows ADK numbered 10.1.19041.0 or later.
2323

2424
### To download and install WPA
2525

@@ -42,10 +42,11 @@ Viewing C++ Build Insights traces in WPA requires a special add-in. Follow these
4242
1. [C++ Build Insights NuGet package](https://www.nuget.org/packages/Microsoft.Cpp.BuildInsights/).
4343

4444
1. Copy the `perf_msvcbuildinsights.dll` file into your WPA installation directory.
45-
1. In Visual Studio 2019 version 16.6 and above, this file is located here: `C:\Program Files (x86)\Microsoft Visual Studio\2019\{Edition}\VC\Tools\MSVC\{Version}\bin\Host{Architecture}\{Architecture}`.
45+
1. In Visual Studio 2019 version 16.6 and above, this file is located here: `C:\Program Files (x86)\Microsoft Visual Studio\{Year}\{Edition}\VC\Tools\MSVC\{Version}\bin\Host{Architecture}\{Architecture}`.
4646
1. In the C++ Build Insights NuGet package, this file is located here: `wpa\{Architecture}`.
4747
1. In the paths above, replace the variables surrounded by curly brackets as follows:
48-
1. `{Edition}` is your Visual Studio 2019 edition such as Community, Professional, or Enterprise.
48+
1. `{Year}` is your Visual Studio product year, such as 2019 or 2022.
49+
1. `{Edition}` is your Visual Studio edition such as Community, Professional, or Enterprise.
4950
1. `{Version}` is your MSVC version. Choose the highest one available.
5051
1. `{Architecture}`: choose `x64` if you have a 64-bit version of Windows. Otherwise, choose `x86`.
5152
1. The WPA installation directory is typically: `C:\Program Files (x86)\Windows Kits\10\Windows Performance Toolkit`.

docs/build/clang-support-cmake.md

Lines changed: 18 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -9,23 +9,33 @@ helpviewer_keywords: ["Clang support for C++ CMake projects"]
99

1010
::: moniker range="<=msvc-150"
1111

12-
Clang support is available in Visual Studio 2019.
12+
Clang support is available starting in Visual Studio 2019.
1313

1414
::: moniker-end
15-
16-
::: moniker range="msvc-160"
15+
::: moniker range=">=msvc-160"
1716

1817
You can use Visual Studio with Clang to edit and debug C++ CMake projects that target Windows or Linux.
1918

20-
**Windows**: Visual Studio 2019 version 16.1 includes support for editing, building, and debugging with Clang/LLVM in CMake projects targeting Windows.
19+
**Windows**: Starting in Visual Studio 2019 version 16.1, Visual Studio includes support for editing, building, and debugging with Clang/LLVM in CMake projects targeting Windows.
2120

2221
**Linux**: For Linux CMake projects, no special Visual Studio support is required. You can install Clang using your distro's package manager, and add the appropriate commands in the CMakeLists.txt file.
2322

2423
## Install
2524

26-
For best IDE support in Visual Studio, we recommend using the latest Clang compiler tools for Windows. If you don't already have those, you can install them by opening the Visual Studio Installer and choosing **C++ Clang compiler for Windows** under **Desktop development with C++** optional components. When using a custom Clang installation, check the **C++ Clang-cl for v142 build tools** component.
25+
::: moniker-end
26+
::: moniker range="msvc-160"
27+
28+
For the best IDE support in Visual Studio, we recommend using the latest Clang compiler tools for Windows. If you don't already have those, you can install them by opening the Visual Studio Installer and choosing **C++ Clang compiler for Windows** under **Desktop development with C++** optional components. When using a custom Clang installation, check the **C++ Clang-cl for v142 build tools** component.
29+
30+
::: moniker-end
31+
::: moniker range="msvc-170"
32+
33+
For the best IDE support in Visual Studio, we recommend using the latest Clang compiler tools for Windows. If you don't already have those, you can install them by opening the Visual Studio Installer and choosing **C++ Clang compiler for Windows** under **Desktop development with C++** optional components. When using a custom Clang installation, check the **C++ Clang-cl for v143 build tools** component.
34+
35+
::: moniker-end
36+
::: moniker range=">=msvc-160"
2737

28-
![Clang component installation.](media/clang-install-vs2019.png)
38+
![Screenshot of the Visual Studio Installer Individual Components page that shows Clang components available for installation.](media/clang-install-vs2019.png)
2939

3040
## Create a new configuration
3141

@@ -35,11 +45,11 @@ To add a new Clang configuration to a CMake project:
3545

3646
1. Under **Configurations**, press the **Add Configuration** button:
3747

38-
![Add configuration.](media/cmake-add-config-icon.png)
48+
![Screenshot of the controls at the top of the C Make Settings dialog, with the Add Configuration control highlighted.](media/cmake-add-config-icon.png)
3949

4050
1. Choose the desired Clang configuration (note that separate Clang configurations are provided for Windows and Linux), then press **Select**:
4151

42-
![CMake Clang configuration.](media/cmake-clang-configuration.png)
52+
![Screenshot of the Add Configuration to C Make Settings dialog for Clang configuration.](media/cmake-clang-configuration.png)
4353

4454
1. To make modifications to this configuration, use the **CMake Settings Editor**. For more information, see [Customize CMake build settings in Visual Studio](customize-cmake-settings.md).
4555

docs/linux/create-a-new-linux-project.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ To create a new Linux project in Visual Studio 2017, follow these steps:
3636

3737
::: moniker-end
3838

39-
::: moniker range="msvc-160"
39+
::: moniker range=">=msvc-160"
4040

4141
First, make sure you have the **Linux Development Workload** for Visual Studio installed. For more information, see [Download, install, and set up the Linux workload](download-install-and-setup-the-linux-development-workload.md).
4242

@@ -46,7 +46,7 @@ If you have an existing Windows Visual Studio solution that you would like to ex
4646

4747
## Create a new Linux project
4848

49-
To create a new Linux project in Visual Studio 2019, follow these steps:
49+
To create a new Linux project in Visual Studio, follow these steps:
5050

5151
1. Select **File > New Project** in Visual Studio, or press **Ctrl + Shift + N**. The Create a new project dialog appears.
5252
1. In the **Search for templates** textbox, enter **Linux** to list the available templates for Linux projects.

docs/linux/deploy-run-and-debug-your-linux-project.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,9 @@ Linux support is available in Visual Studio 2017 and later. To see the documenta
1313

1414
Once you've created a MSBuild-based Linux C++ project in Visual Studio and you've connected to the project using the [Linux Connection Manager](connect-to-your-remote-linux-computer.md), you can run and debug the project. You compile, execute, and debug the code on the remote target.
1515

16-
::: moniker range="msvc-160"
16+
::: moniker range=">=msvc-160"
1717

18-
**Visual Studio 2019 version 16.1** You can target different Linux systems for debugging and building. For example, you can cross-compile on x64 and deploy to an ARM device when targeting IoT scenarios. For more information, see [Specify different machines for building and debugging](#separate_build_debug) later in this article.
18+
**Visual Studio 2019 version 16.1** and later: You can target different Linux systems for debugging and building. For example, you can cross-compile on x64 and deploy to an ARM device when targeting IoT scenarios. For more information, see [Specify different machines for building and debugging](#separate_build_debug) later in this article.
1919

2020
::: moniker-end
2121

@@ -29,19 +29,19 @@ There are several ways to interact with and debug your Linux project.
2929

3030
1. Select debugging mode in the **Debugging** property page.
3131

32-
::: moniker range="msvc-160"
32+
::: moniker range=">=msvc-160"
3333

3434
GDB is used to debug applications running on Linux. When debugging on a remote system (not WSL) GDB can run in two different modes, which can be selected from the **Debugging Mode** option in the project's **Debugging** property page:
3535

36-
![Screenshot of the Visual Studio 2019 Linux Console App Property Pages dialog box with Configuration Properties > Debugging selected and Debugging Mode highlighted with G B D selected and highlighted from the dropdown list.](media/vs2019-debugger-settings.png)
36+
![Screenshot of the Visual Studio Linux Console App Property Pages dialog box with Configuration Properties > Debugging selected and Debugging Mode highlighted with G D B selected and highlighted from the dropdown list.](media/vs2019-debugger-settings.png)
3737

3838
::: moniker-end
3939

4040
::: moniker range="msvc-150"
4141

4242
GDB is used to debug applications running on Linux. GDB can run in two different modes, which can be selected from the **Debugging Mode** option in the project's **Debugging** property page:
4343

44-
![Screenshot of the Visual Studio 2017 Linux Console App Property Pages dialog box with Configuration Properties > Debugging selected and Debugging Mode highlighted with G B D selected and highlighted from the dropdown list.](media/vs2017-debugger-settings.png)
44+
![Screenshot of the Visual Studio 2017 Linux Console App Property Pages dialog box with Configuration Properties > Debugging selected and Debugging Mode highlighted with G D B selected and highlighted from the dropdown list.](media/vs2017-debugger-settings.png)
4545

4646
::: moniker-end
4747

@@ -118,11 +118,11 @@ ExePath="C:\temp\ConsoleApplication17\ConsoleApplication17\bin\x64\Debug\Console
118118

119119
The **AttachOptionsForConnection** has most of the attributes you might need. The example above shows how to specify a location to search for additional .so libraries. The child element **ServerOptions** enables attaching to the remote process with gdbserver instead. To do that, you need to specify a local gdb client (the one shipped in Visual Studio 2017 is shown above) and a local copy of the binary with symbols. The **SetupCommands** element enables you to pass commands directly to gdb. You can find all the options available in the [LaunchOptions.xsd schema](https://github.com/Microsoft/MIEngine/blob/master/src/MICore/LaunchOptions.xsd) on GitHub.
120120

121-
::: moniker range="msvc-160"
121+
::: moniker range=">=msvc-160"
122122

123123
## <a name="separate_build_debug"></a> Specify different machines for building and debugging in MSBuild-based Linux projects
124124

125-
In Visual Studio 2019 version 16.1, you can separate your remote build machine from your remote debug machine for both MSBuild-based Linux projects and CMake projects that target a remote Linux machine. For example, you can now cross-compile on x64 and deploy to an ARM device when targeting IoT scenarios.
125+
You can separate your remote build machine from your remote debug machine for both MSBuild-based Linux projects and CMake projects that target a remote Linux machine. For example, you can now cross-compile on x64 and deploy to an ARM device when targeting IoT scenarios.
126126

127127
By default, the remote debug machine is the same as the remote build machine (**Configuration Properties** > **General** > **Remote Build Machine**). To specify a new remote debug machine, right-click on the project in **Solution Explorer** and go to **Configuration Properties** > **Debugging** > **Remote Debug Machine**.
128128

docs/overview/overview-of-cpp-development.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -20,15 +20,15 @@ Visual Studio provides support for any project system or custom build tools that
2020

2121
- **MSBuild** is the native project system for Visual Studio. When you select **File** > **New** > **Project** from the main menu, you see many kinds of MSBuild *project templates* that get you started quickly developing different kinds of C++ applications.
2222

23-
::: moniker range="msvc-160"
23+
::: moniker range=">=msvc-160"
2424

25-
![Screenshot of the Create a new Project dialog showing new project templates.](../build/media/mathclient-project-name-2019.png "Visual Studio 2019 New Project Dialog")
25+
![Screenshot of the Create a new Project dialog showing new project templates.](../build/media/mathclient-project-name-2019.png)
2626

2727
::: moniker-end
2828

2929
::: moniker range="<=msvc-150"
3030

31-
![Screenshot of the New Project dialog showing project templates.](media/vs2017-new-project.png "Visual Studio 2017 New Project Dialog")
31+
![Screenshot of the New Project dialog showing project templates.](media/vs2017-new-project.png)
3232

3333
::: moniker-end
3434

@@ -42,23 +42,23 @@ Visual Studio provides support for any project system or custom build tools that
4242

4343
Source control enables you to coordinate work among multiple developers, isolate in-progress work from production code, and backup your source code. Visual Studio supports Git and [Team Foundation Version Control \(TFVC\)](/azure/devops/repos/tfvc/) through its **Team Explorer** window.
4444

45-
::: moniker range="msvc-160"
45+
::: moniker range=">=msvc-160"
4646

47-
![Screenshot of the Team Explorer window in Visual Studio 2019.](media/vs2019-team-explorer.png "Visual Studio 2017 Team Explorer")
47+
![Screenshot of the Team Explorer window in Visual Studio 2019.](media/vs2019-team-explorer.png )
4848

4949
::: moniker-end
5050

5151
::: moniker range="<=msvc-150"
5252

53-
![Screenshot of the Team Explorer window in Visual Studio 2017.](media/vs2017-team-explorer.png "Visual Studio 2017 Team Explorer")
53+
![Screenshot of the Team Explorer window in Visual Studio 2017.](media/vs2017-team-explorer.png )
5454

5555
::: moniker-end
5656

5757
For more information about Git integration with repos in Azure, see [Share your code with Visual Studio 2017 and Azure Repos Git](/azure/devops/repos/git/share-your-code-in-git-vs-2017). For information about Git integration with GitHub, see [GitHub Extension for Visual Studio](https://visualstudio.github.com/).
5858

5959
## Obtain libraries
6060

61-
Use the [vcpkg](https://vcpkg.io/) package manager to obtain and install third-party libraries. Over 900 open-source libraries are currently available in the catalog.
61+
Use the [vcpkg](https://vcpkg.io/) package manager to obtain and install third-party libraries. Over 1700 open-source library packages are currently available in the catalog.
6262

6363
## Create user interfaces with designers
6464

0 commit comments

Comments
 (0)