Skip to content

simplify executable_opts with new variable user_executable_opts - #249

Merged
casparvl merged 9 commits into
EESSI:mainfrom
smoors:user_executable_opts
Mar 13, 2025
Merged

casparvl merged 9 commits into
EESSI:mainfrom
smoors:user_executable_opts

Conversation

@smoors

@smoors smoors commented Mar 3, 2025

Copy link
Copy Markdown
Collaborator

this PR adds a new variable user_executable_opts to the EESSI_Mixin class, which users can specify on the cmd line. advantages:

  • gives users full control of the executable options: it will completely override the ones set in the test
  • simplifies the tests: no more annoying check_custom_executable_opts(self, num_default=num_default) and has_custom_executable_opts
  • consistency: some tests were using check_custom_executable_opts and has_custom_executable_opts, others were not.

Comment thread eessi/testsuite/eessi_mixin.py Resolved

@casparvl casparvl left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I love the idea of this one. It does indeed simplify the hooks.check_custom_executable_opts etc.

I think we should also remove that hook, as it shouldn't be used again. I think it's the only hook related to this specific change, right? (if there are more, all should probably be removed).

FYI: haven't tested yet... I'll do that once the changes are final

@smoors
smoors requested a review from casparvl March 4, 2025 22:55

@casparvl casparvl left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Looks good to me. I tested this with:

reframe -c eessi/testsuite/tests/apps/tensorflow/tensorflow.py  -t CI -t 1_8_node --run --system=snellius:rome --setvar=user_executable_opts='--device gpu --intra-op-parallelism 16 --inter-op-parallelism 1'

Which (as intended) fails with an error because these nodes don't contain a GPU device. So: it respected the user_executable_opts I set.

I will double check with a regular run (setting no user_executable_opts) that the modified tests still run correctly before I merge, but all looks fine to me.

@casparvl

casparvl commented Mar 5, 2025

Copy link
Copy Markdown
Collaborator

Hm, also here a conflict. It's ready to be merged once the conflict is resolved :)

@smoors
smoors requested a review from casparvl March 5, 2025 20:34

@casparvl casparvl left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

After resolving the conflict with main, this still works as intended. LGTM!

@casparvl

Copy link
Copy Markdown
Collaborator

Oh dear, another conflict :D too many PRs in flight that touch the same things...
Sorry @smoors , I don't have time to look into it myself right now... Any chance you could check out this conflict again and resolve...? :)

@smoors

smoors commented Mar 13, 2025

Copy link
Copy Markdown
Collaborator Author

Oh dear, another conflict :D too many PRs in flight that touch the same things... Sorry @smoors , I don't have time to look into it myself right now... Any chance you could check out this conflict again and resolve...? :)

yep, done. and don't worry, i expected this to happen, still better than lumping everything together in a big PR :)

@casparvl

Copy link
Copy Markdown
Collaborator

Ok, works for me, merging...

@casparvl
casparvl merged commit 5bdd979 into EESSI:main Mar 13, 2025
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