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

Add "number of instances" dimension to module-level variables to support multi-instance usage #561

Open
peverwhee opened this issue Apr 29, 2024 · 1 comment

Comments

@peverwhee
Copy link
Collaborator

Description

In order to enable multiple instances, we'll need a new dimension on all module-level (host caps and suite caps) variables. This includes: _dynamic_constituents (host cap), _constituents_obj? (host cap)

Solution

Add/update the following:

  • New ccpp variables (standard names not set in stone): "number_of_ccpp_instances" (integer) and "ccpp_instance" (integer, index)
  • Add an extra dimension to module variable declarations
  • Update allocate statements (in the init phase) to allocate the new dimension to the # of instances

User Interface Changes

Optional - host can now supply instance number to the cap routines (if not supplied, defaults to 1)

@gold2718
Copy link
Collaborator

Note, there was some discussion of this in the PR to prebuild a while ago. See the comment about the proposed capgen implementation for a suggestion about CCPP standard names that could be used for this method.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants