Add VisualVM simulation profiling instructions#3128
Add VisualVM simulation profiling instructions#3128jasondaming wants to merge 1 commit intowpilibsuite:mainfrom
Conversation
Clarifies that simulation profiling doesn't require Gradle configuration changes, unlike roboRIO profiling. Adds step-by-step instructions for profiling simulation and mentions the VSCode extension option. Fixes wpilibsuite#2861
|
|
||
| 1. Launch VisualVM (see :ref:`Running VisualVM <docs/software/advanced-gradlerio/profiling-with-visualvm:Running VisualVM>` below for instructions) | ||
| 2. Start your robot simulation from VS Code | ||
| 3. In VisualVM, the simulation process will automatically appear in the left sidebar under "Local" as a Java process |
There was a problem hiding this comment.
Having not done this, is it obvious what is the correct process to connect to? I could see it being likely that there's several java processes that show up between VS Code Java stuff, the robot code, gradle daemons, and wpilib tools.
|
|
||
| To profile simulation: | ||
|
|
||
| 1. Launch VisualVM (see :ref:`Running VisualVM <docs/software/advanced-gradlerio/profiling-with-visualvm:Running VisualVM>` below for instructions) |
There was a problem hiding this comment.
I don't think it flows well to reference things down below that the user hasn't read yet. If simulation is the most common use case then build it into the instructions below, and then add the gradle instructions after that. Or alternately, move this section down below.
I can see arguments for either simulation or robot being the primary use case so I don't really care which one is moved down, but it seems convoluted the way it is now.

Summary
Adds instructions for using VisualVM to profile robot code in simulation, clarifying that no Gradle configuration changes are needed for simulation profiling (unlike roboRIO profiling).
Changes
Fixes #2861