-
Notifications
You must be signed in to change notification settings - Fork 144
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
Reduce disk I/O operation in cmake #2808
Conversation
A cursory reading suggests this adds an unstated set of naming requirements to efficiently setup tests. This complicates the setting up of new tests, and I am also not sure what this optimization means for our more complex tests. Generally I am only in favor of improving the ease of setting up tests. 1/3 speedup is a nice improvement, but not revolutionary and the complexity is now higher. Is the tradeoff going to be worth it? |
Currently, when I see a an xml file, I really need to spend seconds to figure out if a file is a control file or wavefunction file. In addition, each testing folder has all the input files of 20 testing cases. This is the what I care most.
Most people cannot figure out easily which in.xml was used for running the test. After this PR.
I think we do have enough flexibility, qmc-ref softlink is always added. I would say it motivates mandating more strict naming rules for files. Most unexpected file names are from old tests. File names from converters are standardized. Now making a new test requires naming and placing files more carefully, I see it positive push to keep testing folder more organized. For example, The speed-up is more of a by-product. If I check timing on invoking on pre-existing build folders, the timing is 10 sec vs 16 second. Most time are spent in the python script adding test labels. |
I think it would be helpful to have a known current/accurate (but short!) write up of test requirements and how to add new tests in the developer section of the manual. Then we could all discuss from a point of common knowledge. I agree on the test labels, although they are definitely another topic. A different strategy for the test setup and python interpreter invocations and file checks could lead to large speedups. |
If there are filename requirements, they should be checked for where possible and error trapped. e.g. No XML file -> hard abort with error. |
Developers need to agree naming rules and then add checks against them by QMCPACK. |
@prckent I added "Integration Tests" in the manual with some high level summary and all the contents of https://github.com/QMCPACK/qmcpack/wiki/How-to-add-tests Let me know if more things are needed to complete this PR. |
Confirming that I can build the docs locally with my combination of sphinx tools. I get the usual errors about duplicate citations and a note about the bullet lists in methods.rst, also not new.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks Ye!
I expanded the documentation a little. Once this is in the wiki page can be deleted.
Proposed changes
When generating a test in build folder, all the files in a source test folder are symlinked to the destination.
This is largely unnecessary. Each test only needs a single input xml file. So this PR does selective copy/symlink.
It also keep the test folder much cleaner.
On my workstation with an SSD, cmake time from scratch reduces from 19 sec to 14 sec.
What type(s) of changes does this code introduce?
Does this introduce a breaking change?
What systems has this change been tested on?
Bora, Ryzen-box
Checklist