Verbosity Level Not Shown in the commandLine Property of the PerfView/CommandLineParameters
This seems like a bug where despite adding the /ClrEventLevel:Verbose to collect a trace with all CLR Verbose events via perfview using a command such as:
PerfView start /AcceptEULA /NoGUI /Merge:true /zip:false /sessionName:e9a042b3-a75e-47f6-813f-afc5cf323f52 /GCCollectOnly /ClrEventLevel:Verbose /LogFile:C:\\V8\\heapcount_1\verbose.txt /DataFile:C:\\V8\\heapcount_1\verbose.etl
the PerfView/CommandLineParameters event doesn't mention this additional detail:
| Event Name | Time MSec | Process Name | commandLine | Rest |
| PerfView/CommandLineParameters | 1,735.222 | PerfView (27240) | "/DataFile:C:\V8\heapcount_1\verbose.etl" /BufferSizeMB:256 /StackCompression /KernelEvents:Process /ClrEvents:GC /NoGui /SessionName:fd0f4705-d616-4faa-bcdb-c0c196777e5f /LogFile:"C:\V8\heapcount_1\verbose.txt" /NoRundown /NoNGenRundown /Merge:True /GCCollectOnly | |
| PerfView/CommandLineParameters | 208,645.495 | PerfView (20216) | "/DataFile:C:\V8\heapcount_1\verbose.etl" /BufferSizeMB:256 /StackCompression /KernelEvents:Process /ClrEvents:GC /NoGui /SessionName:fd0f4705-d616-4faa-bcdb-c0c196777e5f /LogFile:"C:\V8\heapcount_1\verbose.txt" /NoRundown /NoNGenRundown /Merge:True /GCCollectOnly | |
| PerfView/CommandLineParameters | 214,751.470 | PerfView (20216) | "/DataFile:C:\V8\heapcount_1\verbose.etl" /BufferSizeMB:256 /StackCompression /KernelEvents:Process /ClrEvents:GC /NoGui /SessionName:fd0f4705-d616-4faa-bcdb-c0c196777e5f /LogFile:"C:\V8\heapcount_1\verbose.txt" /NoRundown /NoNGenRundown /Merge:True /GCCollectOnly |
The expected behavior is to be able to observe what verbosity level is being passed in for ClrEvents as the issue here is that the non-verbose commandline parameters are the same and thereby could be a point of confusion to those who rely on the event to decide what type of trace is captured.
Verbose CLR events not specified:
| Event Name | Time MSec | Process Name | commandLine | Rest |
| PerfView/CommandLineParameters | 531.885 | PerfView (19496) | "/DataFile:C:\\V8\\heapcount_1\gc.etl" /BufferSizeMB:256 /StackCompression /KernelEvents:Process /ClrEventLevel:Informational /ClrEvents:GC /NoGui /SessionName:161f9269-73bf-49b0-8f48-cb53204a15d2 /LogFile:"C:\\V8\\heapcount_1\gc.txt" /NoRundown /NoNGenRundown /Merge:True /Zip:False /GCCollectOnly | |
| PerfView/CommandLineParameters | 205,659.995 | PerfView (7856) | "/DataFile:C:\\V8\\heapcount_1\gc.etl" /BufferSizeMB:256 /StackCompression /KernelEvents:Process /ClrEventLevel:Informational /ClrEvents:GC /NoGui /SessionName:161f9269-73bf-49b0-8f48-cb53204a15d2 /LogFile:"C:\\V8\\heapcount_1\gc.txt" /NoRundown /NoNGenRundown /Merge:True /Zip:False /GCCollectOnly | |
| PerfView/CommandLineParameters | 210,603.619 | PerfView (7856) | "/DataFile:C:\\V8\\heapcount_1\gc.etl" /BufferSizeMB:256 /StackCompression /KernelEvents:Process /ClrEventLevel:Informational /ClrEvents:GC /NoGui /SessionName:161f9269-73bf-49b0-8f48-cb53204a15d2 /LogFile:"C:\\V8\\heapcount_1\gc.txt" /NoRundown /NoNGenRundown /Merge:True /Zip:False /GCCollectOnly |
CC: @Maoni0
@mrsharm, apologies for the delay on this. The reason that this happens is because Verbose is considered to be the default value for /ClrEventLevel. The expectation is that if the value is the default value, then it won't get shown, though I'm sure there are cases where that doesn't happen. The code responsible for this is at https://github.com/microsoft/perfview/blob/main/src/PerfView/CommandProcessor.cs#L2930.