The Project > Add Object > DeviceTrace... command is available if a controller node is selected in the Devices tree. It allows you to add a device trace node below the selected controller node.
While opening the editor in online mode, right-clicking the root node Application.Trace opens the contextual menu that contains the commands Online list... and Upload Trace to update the traces running on the controller. This is also possible while just being connected to the controller (no login necessary). It is not a prerequisite that the associated application is compilable for the controller.
For further information, refer to the description of the trace editor in the EcoStruxure Machine Expert Programming Guide.