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

Fixes build and tests on Windows #1519

Merged
merged 20 commits into from
Mar 20, 2025
Merged

Conversation

kennyweiss
Copy link
Member

@kennyweiss kennyweiss commented Mar 12, 2025

Summary

  • This PR is a bugfix for the build on Windows
  • It fixes:
    • the MIR build, which required some exports for static members
    • MIR tests that depend on the compile time path to the data directory
    • A bug with the quicksort algorithm for some data orderings and adds a unit test
    • Some quest tests when mfem does not have MPI
    • Some quest lambdas that take a constexpr -- MSVC appears to require static constexpr w/ c++14. This might be relaxed in c++17
  • I also cleaned up/updated some sidre::Group implementations to use the iterator interface while working on sidre test bugfixes
  • Update: Passes all builds and tests in our Windows TPL CI -- https://github.com/LLNL/axom/actions/runs/13846008225

Status:

@kennyweiss kennyweiss added bug Something isn't working Build system Issues related to Axom's build system maintenance Issues related to code maintenance Windows Related to Windows development labels Mar 12, 2025
@kennyweiss kennyweiss self-assigned this Mar 12, 2025
@kennyweiss kennyweiss added this to the April 2025 Release milestone Mar 12, 2025
@kennyweiss
Copy link
Member Author

/style

@bgunnar5 bgunnar5 requested a review from HaluskaR March 13, 2025 16:14
@kennyweiss
Copy link
Member Author

/style

@white238 -- I am not sure that this worked. It seemed to trigger an action, but for some reason, the action was cancelled.
See: https://github.com/LLNL/axom/actions/runs/13825505635

Copy link
Member

@BradWhitlock BradWhitlock left a comment

Choose a reason for hiding this comment

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

Looks good to me.

@@ -88,87 +90,87 @@ namespace visit {
#define NOCOLOR 122

// Tables
extern VISIT_VTK_LIGHT_API int numClipCasesHex;
Copy link
Member

Choose a reason for hiding this comment

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

Thanks for fixing the export macro. I don't know how I overlooked that.

Copy link
Member Author

Choose a reason for hiding this comment

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

(there were a lot of files :) )

#ifndef UMPIRE_event_HPP
#define UMPIRE_event_HPP

+#include <chrono>
Copy link
Member Author

Choose a reason for hiding this comment

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

@davidbeckingsale -- My local machine did not need this on Windows, but our CI needed this for [email protected].
I saw that it was recently added to umpire@develop -- LLNL/Umpire#934

Comment on lines +68 to +72
: value(extractIDFromObject(parentObject, localName_, globalName_))
{
std::swap(localName, localName_);
std::swap(globalName, globalName_);
}
Copy link
Member Author

Choose a reason for hiding this comment

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

@doutriaux1 @bgunnar5 @gwaegner -- this was tricky to track down.

Presumably msvc has a different order of processing the arguments than clang and other compilers, or it wiped out the strings after moving them, rather than leaving them unchanged.

The call to extractIDFromObject was happening after localName_ and globalName_ were already moved.

Comment on lines +1000 to +1007
if(!group_name.empty())
{
grp->loadExternalData(path);
}
else
{
m_bp_grp->loadExternalData(path);
}
Copy link
Member Author

Choose a reason for hiding this comment

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

@white238 and @nselliott -- This was necessary to get loadExternalData() working in our Windows configuration, which has MPI for axom and a serial mfem.

I am not sure if we have test coverage for the if part (where the users provide a group_name)

The former is not available in msvc compiler
Fixes some MIR tests that check for the existence of data paths.
Chooses a better partition for the quick sort so it doesn't run
out of stack space.
kennyweiss and others added 13 commits March 19, 2025 09:25
Limit the scope of the saved and loaded variables
and use EXPECT_EQ instead of EXPECT_TRUE.
There's no guaranteed on the order of operations that constructor
parameters are accessed. This was using references to strings
before/after they were moved of the IDType constructor.
... when MFEM is built without MPI support.
Instead of loading from the hierarchy root when the user doesn't specify a group,
load from the blueprint group.
@kennyweiss kennyweiss force-pushed the bugfix/kweiss/windows-build branch from 99d4ebf to b116749 Compare March 19, 2025 16:37
This will be changed through uberenv in a separate PR.
@kennyweiss kennyweiss merged commit d4dc2d1 into develop Mar 20, 2025
13 checks passed
@kennyweiss kennyweiss deleted the bugfix/kweiss/windows-build branch March 20, 2025 04:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working Build system Issues related to Axom's build system maintenance Issues related to code maintenance Windows Related to Windows development
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants