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

Support parallel runs (intra-solver parallelism) #3

Open
BenjaminRodenberg opened this issue Dec 6, 2019 · 3 comments
Open

Support parallel runs (intra-solver parallelism) #3

BenjaminRodenberg opened this issue Dec 6, 2019 · 3 comments
Labels
enhancement New feature or request

Comments

@BenjaminRodenberg
Copy link
Member

Currently, the bindings do not support parallel runs. We should add this feature.

@uekerman
Copy link
Member

uekerman commented Jan 7, 2020

What exactly do you mean by "parallel runs"? Shared memory parallelization of Matlab? Or does Matlab also offer distributed parallelization? If shared memory: do we want to treat the Matlab solver as a serial or as a parallel solver from preCICE perspective? If we treat it as a serial solver this should always be possible or am I overlooking sth?

@BenjaminRodenberg BenjaminRodenberg changed the title Support parallel runs Support parallel runs (intra-solver parallelism) Jan 8, 2020
@BenjaminRodenberg
Copy link
Member Author

What exactly do you mean by "parallel runs"? Shared memory parallelization of Matlab? Or does Matlab also offer distributed parallelization? If shared memory: do we want to treat the Matlab solver as a serial or as a parallel solver from preCICE perspective? If we treat it as a serial solver this should always be possible or am I overlooking sth?

To be more clear: I mean intra-solver parallelism. I.e. the MATLAB solver running on several processes. Currently, we require the user to provide solverProcessIndex = 0 and solverProcessSize = 1, otherwise an error is thrown:

function obj = SolverInterface(SolverName,configFileName,solverProcessIndex,solverProcessSize)
%SOLVERINTERFACE Construct an instance of this class
if (solverProcessIndex > 0 || solverProcessSize > 1)
error('Parallel runs are currently not supported with the MATLAB bindings.')
end

From preCICE perspective nothing speaks against supporting intra-solver parallelism, but since the feature is untested with the MATLAB bindings, we currently do not support it and rather throw an error on unexpected user input.

@uekerman
Copy link
Member

uekerman commented Jan 8, 2020

But which type of parallelization would you want to support? Shared memory parallelization? Using then more threads in preCICE has never been tested afaik. I am not sure if preCICE has enough thread-safety for this. Only letting one thread interact with preCICE might be just the right approach.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants