microsoft / microsoft/perfview

TraceParserGen fails due to missing types in FieldInfo

Open
#852 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C#
Stars
4.7k
Forks
775
Avg merge
5d 11h
Merged PRs (30d)
9

Description

TraceParserGen fails for ~50 standard providers, due to missing cases in the switch on FieldInfo ctor.
The two worst offenders are -
(1) win:SID (needed for 37 providers)
(2) win:SYSTEMTIME (needed for 14 providers),

but also:
(3) win:CountedMbcsString
(4) win:CountedUtf16String
(5) win:Struct

and some unnamed numbered types.

I can suggest a PR to handle at least SID and SYSTEMTIME, but there might be a more robust way - to unify the handling of types with the one in DynamicTraceEventParser.PayloadFetch (which handles all RegisteredTraceEventParser.TdhInputType).


Below is the complete dump (with some cleanup) of manifests unable to be processed into code:

LsaSrv.manifest.xml
Unknown type win:SYSTEMTIME
Unknown type win:SID

Microsoft-Windows-AppLocker.manifest.xml
Unknown type win:SID

Microsoft-Windows-AppModel-Exec.manifest.xml
Unknown type win:SID

Microsoft-Windows-AppModel-Runtime.manifest.xml
Unknown type win:SID

Microsoft-Windows-AppSruProv.manifest.xml
Unknown type win:SID

Microsoft-Windows-AppxPackagingOM.manifest.xml
Unknown type win:SID

Microsoft-Windows-Base-Filtering-Engine-Connections.manifest.xml
Unknown type win:SYSTEMTIME

Microsoft-Windows-BitLocker-API.manifest.xml
Unknown type win:SYSTEMTIME

Microsoft-Windows-Bits-Client.manifest.xml
Unknown type win:SID

Microsoft-Windows-BranchCache.manifest.xml
Unknown type win:SYSTEMTIME

Microsoft-Windows-BrokerInfrastructure.manifest.xml
Unknown type win:SID

Microsoft-Windows-BTH-BTHPORT.manifest.xml
Unknown type win:69

Microsoft-Windows-Diagnosis-DPS.manifest.xml
Unknown type win:SID

Microsoft-Windows-Dwm-Core.manifest.xml
Unknown type win:31
Unknown type win:SID

Microsoft-Windows-EDP-Audit-Regular.manifest.xml
Unknown type win:SID

Microsoft-Windows-EDP-Audit-TCB.manifest.xml
Unknown type win:SID

Microsoft-Windows-Energy-Estimation-Engine.manifest.xml
Unknown type win:SID

Microsoft-Windows-Eventlog.manifest.xml
Unknown type win:SID
Unknown type win:SYSTEMTIME

Microsoft-Windows-exFAT-SQM.manifest.xml
Unknown type win:SID

Microsoft-Windows-Fat-SQM.manifest.xml
Unknown type win:SID

Microsoft-Windows-HelloForBusiness.manifest.xml
Unknown type win:SID

Microsoft-Windows-Kernel-General.manifest.xml
Unknown type win:28
Unknown type win:30
Unknown type win:31
Unknown type win:33
Unknown type win:SID
Unknown type win:34
Unknown type win:38

Microsoft-Windows-Kernel-PnP.manifest.xml
Unknown type win:SID
Unknown type win:SYSTEMTIME

Microsoft-Windows-Kernel-Power.manifest.xml
Unknown type win:SID

Microsoft-Windows-Kernel-Processor-Power.manifest.xml
Unknown type win:SID

Microsoft-Windows-Kernel-WDI.manifest.xml
Unknown type win:SID

Microsoft-Windows-Kernel-WHEA.manifest.xml
Unknown type win:SID

Microsoft-Windows-LiveId.manifest.xml
Unknown type win:SYSTEMTIME

Microsoft-Windows-Ndu.manifest.xml
Unknown type win:SID

Microsoft-Windows-ParentalControls.manifest.xml
Unknown type win:SYSTEMTIME

Microsoft-Windows-RPC.manifest.xml
Unknown type win:SYSTEMTIME

Microsoft-Windows-SEC.manifest.xml
Unknown type win:SID

Microsoft-Windows-Security-Auditing.manifest.xml
Unknown type win:SID

Microsoft-Windows-Security-IdentityListener.manifest.xml
Unknown type win:SID

Microsoft-Windows-Sensors.manifest.xml
Unknown type win:SYSTEMTIME

Microsoft-Windows-SetupCl.manifest.xml
Unknown type win:SID

Microsoft-Windows-Shell-Core.manifest.xml
Unknown type win:SID

Microsoft-Windows-SrumTelemetry.manifest.xml
Unknown type win:SYSTEMTIME

Microsoft-Windows-StorSqm.manifest.xml
Unknown type win:SID

Microsoft-Windows-SystemEventsBroker.manifest.xml
Unknown type win:SID

Microsoft-Windows-UAC-FileVirtualization.manifest.xml
Unknown type win:SID

Microsoft-Windows-USB-UCX.manifest.xml
Unknown type win:CountedMbcsString
Unknown type win:Struct
Unknown type win:26
Unknown type win:26
Unknown type win:CountedUtf16String
Unknown type win:CountedMbcsString

Microsoft-Windows-USB-USBPORT.manifest.xml
Unknown type win:Struct
Unknown type win:27
Unknown type win:33
Unknown type win:SID
Unknown type win:50
Unknown type win:CountedMbcsString
Unknown type win:29
Unknown type win:CountedUtf16String
Unknown type win:25
Unknown type win:31
Unknown type win:28
Unknown type win:30
Unknown type win:31
Unknown type win:28
Unknown type win:46
Unknown type win:SYSTEMTIME
Unknown type win:26
Unknown type win:32
Unknown type win:47

Microsoft-Windows-UserModePowerService.manifest.xml
Unknown type win:SID

Microsoft-Windows-VolumeSnapshot-Driver.manifest.xml
Unknown type win:SYSTEMTIME

Microsoft-Windows-WebIO.manifest.xml
Unknown type win:SID

Microsoft-Windows-WFP.manifest.xml
Unknown type win:SID

Microsoft-Windows-Winlogon.manifest.xml
Unknown type win:SID

Microsoft-Windows-WLAN-AutoConfig.manifest.xml
Unknown type win:SYSTEMTIME

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at TraceParserGen's switch on the FieldInfo constructor and compare its handling with DynamicTraceEventParser.PayloadFetch, which handles the registered trace-event input types. Run TraceParserGen against the listed standard provider manifests and use the reported unknown types to guide coverage. Done means those manifests no longer fail on the listed SID, SYSTEMTIME, counted-string, Struct, and numbered types.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.