KhronosGroup / KhronosGroup/SPIRV-Tools

Extend disassembly comments to add block information

Open
#3,854 0 comments 0 reactions 0 assignees View on GitHub
component:as/dis
Dominant language
C++
Stars
1.4k
Forks
709
Avg merge
1d 22h
Merged PRs (30d)
28

Description

Should be possible to annotate labels with the predecessor block information if comments are enabled for the disassembly format.

```
: ; preds = %, %, etc.

```

Note from @dneto0 `Predecessor blocks might come from the future (happens for the backedge of a loop), so you'd need to do a prepass and carry state around. So you could copy the Namer pattern to collect that info before hand.`

Contributor guide

Open the contributing guide

Research direction

Start by locating the disassembly formatter and the Namer pattern referenced in the issue. Trace how comments and labels are emitted, then determine how a prepass can collect predecessor blocks, including backedges from the future. Done means enabled disassembly comments annotate each label with its predecessor blocks without changing output when comments are disabled.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
compilers
Issue type
Feature
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.