Skip to content

feat(pack): refactor pack structure and support DUT abstraction generation#72

Merged
Makiras merged 4 commits intoXS-MLVP:masterfrom
SFangYy:feat_uvm
Jan 4, 2026
Merged

feat(pack): refactor pack structure and support DUT abstraction generation#72
Makiras merged 4 commits intoXS-MLVP:masterfrom
SFangYy:feat_uvm

Conversation

@SFangYy
Copy link
Contributor

@SFangYy SFangYy commented Dec 23, 2025

Description

This PR refactor pack structure and support DUT abstraction generation

  • Update pack function structure for better maintainability:

    • Refactored src/codegen/uvm.cpp by modularizing directory setup and template rendering logic.
  • Implement automated DUT abstraction generation:

    • Introduced -d flag to generate DUT abstraction classes.
    • Added support for parsing RTL module ports directly via --from-rtl.
  • Revamp UVM and Python template architecture:

    • Introduced dut.py, xagent.py and utils_pkg.sv to decouple logic.
    • Standardized template output structure for easier integration.
  • Reduced file duplication and cleaner project structure:

    • Removed legacy example files and unified generated output directories.

Type of change

Please delete options that are not relevant.

  • New feature (non-breaking change which adds functionality)

How Has This Been Tested?

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce.
Please also list any relevant details for your test configuration

bash example/Pack/release-pack.sh basic

Checklist:

  • My code follows the style guidelines of this project
  • I have added the appropriate labels
  • I have performed a self-review of my code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • Any dependent changes have been merged and published in downstream modules

…ation

- Update pack function structure for better maintainability:
	- Refactored `src/codegen/uvm.cpp` by modularizing directory setup and template rendering logic.

- Implement automated DUT abstraction generation:
    - Introduced `-d` flag to generate DUT abstraction classes.
	- Added support for parsing RTL module ports directly via `--from-rtl`.

- Revamp UVM and Python template architecture:
	- Introduced `dut.py`, `xagent.py` and `utils_pkg.sv` to decouple logic.
	- Standardized template output structure for easier integration.

- Reduced file duplication and cleaner project structure:
	- Removed legacy example files and unified generated output directories.
Adapt UVM templates (example.sv, dut.py, utils_pkg.sv, xagent.py) for ucagent compatibility and improved robustness.

- Refactor example.sv to follow UVM best practices
- Separate driver and monitor responsibilities
- Add auto-generated DUT interface and instantiation
- Improve virtual interface configuration
@Makiras Makiras merged commit 42844ae into XS-MLVP:master Jan 4, 2026
6 checks passed
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.

2 participants