rust-lang / rust-lang/rust

Consider adding Windows Debug Interface Access (DIA) SDK wrappers for PDB analysis

Open
#143,737 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

A-run-make A-test-infra C-enhancement O-windows-msvc T-compiler
Dominant language
Rust
Stars
119k
Forks
16.1k
PR merge metrics
PR metrics pending

Description

My only concern with the pdb crate is it doesn't look like it's been updated in awhile. It's probably fine (it has few dependencies by the looks of it) but it makes me slightly wary.

[..] I think long term it would be good to use official debugging APIs on Windows hosts and only fallback to the pdb crate on other platforms (or maybe if they're unavailable for some reason).

-- https://github.com/rust-lang/rust/pull/143669#issuecomment-3057992603

Currently, some run-make tests use llvm-pdbutil to inspect PDB for symbols and other purposes, but operating on llvm-pdbutil's textual output seems rather fragile, as between llvm-pdbutil versions that's not guaranteed to stay the same (there's an pdb2yaml subcommand, but then we're still parsing yaml?).

Consider introducing Windows Debug Interface Access (DIA) API wrappers to perform PDB analysis programmatically via the Officially Recommended ™️ way instead.

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 by reviewing the run-make tests that use llvm-pdbutil and how they consume its textual output. Read the Windows DIA SDK documentation and compare it with the existing PDB analysis needs, including the possible pdb2yaml path. Done means the project has a decided, programmatic approach for PDB analysis rather than relying on fragile llvm-pdbutil output.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
compilers, operating-systems, testing-qa
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.