Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

dft: implementing interface to support different test modes #6533

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

fgaray
Copy link
Contributor

@fgaray fgaray commented Jan 15, 2025

This is a refactoring change + public API change where we start supporting different tests modes. The test mode currently does nothing except for independendly architect and stitch each test mode.

In the future, different tests modes may have different types of scan (ex: internal scan, scan compression, boundary scan, etc) and may support to include/exclude cells in certain modes.

This is a refactoring change + public API change where we start
supporting different tests modes. The test mode currently does nothing
except for independendly architect and stitch each test mode.

In the future, different tests modes may have different types of scan
(ex: internal scan, scan compression, boundary scan, etc) and may
support to include/exclude cells in certain modes.

Signed-off-by: Felipe Garay <[email protected]>
Copy link
Contributor

@github-actions github-actions bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

clang-tidy made some suggestions

src/dft/src/config/DftConfig.cpp Outdated Show resolved Hide resolved
Signed-off-by: Felipe Garay <[email protected]>
Copy link
Contributor

clang-tidy review says "All clean, LGTM! 👍"

1 similar comment
Copy link
Contributor

clang-tidy review says "All clean, LGTM! 👍"

@@ -124,3 +133,19 @@ proc report_dft_config { args } {
sta::parse_key_args "report_dft_config" args keys {} flags {}
dft::report_dft_config
}


sta::define_cmd_args "create_dft_test_mode" { [-test_mode test_mode] }
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is -test_mode really optional? If not provided the command is a silent no-op which seems unexpected.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, yeah, I will fix this, good point. I will revisit this PR on Friday

@@ -9,6 +9,8 @@ link_design sub_modules

create_clock -name main_clock -period 2.0000 -waveform {0.0000 1.0000} [get_ports {clock}]

set_dft_config -max_chains 1
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This has no effect on the ok file and doesn't relate to test modes - what is the purpose?

Comment on lines +48 to +49
ScanArchitectConfig* getMutableScanArchitectConfig();
const ScanArchitectConfig& getScanArchitectConfig() const;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason one is by pointer and the other by reference?

Comment on lines +44 to +46
// Not copyable or movable.
TestModeConfig(const TestModeConfig&) = delete;
TestModeConfig& operator=(const TestModeConfig&) = delete;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You have no prevented moving, only copying.

@@ -48,6 +48,8 @@ class ScanArchitectConfig
ClockMix // We architect the flops of different clock and edge together
};

ScanArchitectConfig() : clock_mixing_(ClockMixing::NoMix) {}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

You can just do

ClockMixing clock_mixing_{NoMix};

and skip the ctor. Does this relate to test mode?

if (name == kDefaultTestModeName) {
return createTestMode(name);
}
return nullptr;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

getOrDefaultMutableTestModeConfig sounds like it should return default if not found.

@maliberty
Copy link
Member

It would be nice to add a test with multiple test modes even if it doesn't do much yet.

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