reframe-hpc / reframe

A powerful Python framework for writing and running portable regression tests and benchmarks for HPC systems.
https://reframe-hpc.readthedocs.org
BSD 3-Clause "New" or "Revised" License
214 stars 101 forks source link

[feat] Add CPU vendor and model name to topology files #3107

Closed jack-morrison closed 6 months ago

jack-morrison commented 7 months ago

By having the CPU vendor identifier available, test authors can use "GeniuneIntel", "AuthenticAMD", etc. as a logic condition where high-level characterization is acceptable. There are cases where this may actually be more useful than the particular CPU model name.

Fixes #https://github.com/reframe-hpc/reframe/issues/2995

jenkins-cscs commented 7 months ago

Can I test this patch?

jack-morrison commented 7 months ago

Got some tests to fix up here, it seems.

teojgo commented 7 months ago

@jack-morrison since you are mentioning the model name of the CPU, do you think it could be added too?

jack-morrison commented 7 months ago

@jack-morrison since you are mentioning the model name of the CPU, do you think it could be added too?

I think that's already available in the topology files as arch (relevant archspec docs), on the line immediately above this change.

Edit: I guess it's the microarchitecture name that's already presented as arch. This what I was intending to refer to. I'm happy to add any (or all) other attributes from archspec.cpu though if that's desirable.

vkarak commented 7 months ago

@jack-morrison The CI fails because you need to update the configuration schema as well:

https://github.com/reframe-hpc/reframe/blob/f2a23261e7ae2927bc145cdc8f3d6a30f566f8b6/reframe/schemas/config.json#L219-L226

teojgo commented 7 months ago

@jack-morrison since you are mentioning the model name of the CPU, do you think it could be added too?

I think that's already available in the topology files as arch (relevant archspec docs), on the line immediately above this change.

Edit: I guess it's the microarchitecture name that's already presented as arch. This what I was intending to refer to. I'm happy to add any (or all) other attributes from archspec.cpu though if that's desirable.

Yeah, it's indeed the microarchitecture, the model name I can retrieve using: archspec.cpu.detect.raw_info_dictionary()['model name'].

codecov[bot] commented 6 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (ead9f84) 86.64% compared to head (9d122a0) 86.64%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## develop #3107 +/- ## ======================================== Coverage 86.64% 86.64% ======================================== Files 61 61 Lines 12051 12051 ======================================== Hits 10442 10442 Misses 1609 1609 ```

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

pep8speaks commented 6 months ago

Hello @jack-morrison, Thank you for updating!

Cheers! There are no PEP8 issues in this Pull Request!Do see the ReFrame Coding Style Guide

Comment last updated at 2024-02-13 22:05:27 UTC