Skip to content

Update 'DynamicLoading' docs with section on loading Chapel libraries#28973

Merged
dlongnecke-cray merged 2 commits into
chapel-lang:mainfrom
dlongnecke-cray:dynamic-loading-50
Jun 12, 2026
Merged

Update 'DynamicLoading' docs with section on loading Chapel libraries#28973
dlongnecke-cray merged 2 commits into
chapel-lang:mainfrom
dlongnecke-cray:dynamic-loading-50

Conversation

@dlongnecke-cray

@dlongnecke-cray dlongnecke-cray commented Jun 11, 2026

Copy link
Copy Markdown
Contributor

Add a new section to the DynamicLoading module docs that describes how to build and load a Chapel library.

Reviewed by @benharsh. Thanks!

Signed-off-by: David Longnecker <dlongnecke-cray@users.noreply.github.com>
@dlongnecke-cray dlongnecke-cray self-assigned this Jun 11, 2026
Comment thread modules/packages/DynamicLoading.chpl Outdated

Additionally, while it should be possible to execute parallel and
distributed code from a loaded Chapel library, it is possible that certain
(combinations of) features may be bugged and fail to work correctly.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

"may have bugs"?

Do note that only ``export`` procedures may be called from the library. This
restriction may be removed in the future.

.. note::

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Is there a way a user might run into this? Or is this something only a developer would encounter after modifying the runtime? If it's the latter, I'd recommend moving this into a comment.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Hi Ben, it's something a user could run into if they build from source.

Signed-off-by: David Longnecker <dlongnecke-cray@users.noreply.github.com>
@dlongnecke-cray dlongnecke-cray merged commit 624c3a1 into chapel-lang:main Jun 12, 2026
12 checks passed
This feature is highly unstable (even more than the rest of this module).
As of the 2.9 release, it is only supported when ``CHPL_COMM=gasnet`` and
``CHPL_LIB_PIC=pic``. Safety checks have not been added yet, so dynamically
loaded code may break in unexpected ways if these constraints are not met.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I thought it was also possible with CHPL_COMM=none?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Oh, shoot. Totally fixated on configurations with comm when I wrote that.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

I wouldn't break the freeze over this, but it should be fixed on main asap imo

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

Agreed: #28989

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.

3 participants