Skip to content

Add circt_debug_* intrinsics for Chisel type metadata#1

Open
fkhaidari wants to merge 3 commits intomainfrom
fk-sc/debug-info
Open

Add circt_debug_* intrinsics for Chisel type metadata#1
fkhaidari wants to merge 3 commits intomainfrom
fk-sc/debug-info

Conversation

@fkhaidari
Copy link
Owner

  • Add compiler plugin hooks to record Chisel type/source metadata per HasId
  • Introduce DebugTypeEmitter to emit circt_debug_typetag / circt_debug_moduleinfo intrinsics
  • Wire up --emit-debug-type-info / EmitDebugTypeInfoAnnotation CLI flag
  • Add unit, lit, and firtool round-trip tests for debug intrinsics

Contributor Checklist

  • Did you add Scaladoc to every public function/method?
  • Did you add at least one test demonstrating the PR?
  • Did you delete any extraneous printlns/debugging code?
  • Did you specify the type of improvement?
  • Did you add appropriate documentation in docs/src?
  • Did you request a desired merge strategy?
  • Did you add text to be included in the Release Notes for this change?

Type of Improvement

  • Feature (or new API)
  • API modification
  • API deprecation
  • Backend code generation
  • Performance improvement
  • Bugfix
  • Documentation or website-related
  • Dependency update
  • Internal or build-related (includes code refactoring/cleanup)

Desired Merge Strategy

  • Squash: The PR will be squashed and merged (choose this if you have no preference).
  • Rebase: You will rebase the PR onto master and it will be merged with a merge commit.

Release Notes

Reviewer Checklist (only modified by reviewer)

  • Did you add the appropriate labels? (Select the most appropriate one based on the "Type of Improvement")
  • Did you mark the proper milestone (Bug fix: 3.6.x, 5.x, or 6.x depending on impact, API modification or big change: 7.0)?
  • Did you review?
  • Did you check whether all relevant Contributor checkboxes have been checked?
  • Did you do one of the following when ready to merge:
    • Squash: You/ the contributor Enable auto-merge (squash) and clean up the commit message.
    • Merge: Ensure that contributor has cleaned up their commit history, then merge with Create a merge commit.

@fkhaidari fkhaidari force-pushed the fk-sc/debug-info branch 2 times, most recently from e655450 to 1720c93 Compare February 28, 2026 12:05
@fkhaidari fkhaidari force-pushed the fk-sc/debug-info branch 3 times, most recently from 7f83f73 to f1043f1 Compare March 6, 2026 18:00
Introduce debug metadata infrastructure for Chisel → CIRCT pipeline:
- 4 new FIRRTL intrinsics: typetag, moduleinfo, enumdef, meminfo
- Scala 2 compiler plugin for constructor argument capture
- JSON schema v1.0 with semantic versioning policy
- Comprehensive test suite
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant