Skip to content

Insert mode, scatter mode and diag as keywords - #316

Merged
filoferra merged 1 commit into
JuliaParallel:mainfrom
filoferra:mode-keywords
Oct 21, 2026
Merged

filoferra merged 1 commit into
JuliaParallel:mainfrom
filoferra:mode-keywords

Conversation

@filoferra

Copy link
Copy Markdown
Collaborator

The insert mode, scatter mode and diagonal value of set_values!, ghost_update!, the DM transfers (local_to_global!, global_to_local!, local_to_local!), project_function!, project_field! and zero_rows! are now keywords: set_values!(A, rows, cols, vals; mode = ADD_VALUES), ghost_update!(v; mode, scatter), zero_rows!(A, rows; diag = 2).

The positional forms still work and warn once until v0.6. Keyword calls cost the same as the old positional ones (40 ns, no allocations, for a DMStag stencil block).

The insert mode, scatter mode and diagonal value of set_values!, ghost_update!, the DM transfers (local_to_global!, global_to_local!, local_to_local!), project_function!, project_field! and zero_rows! are now keywords: set_values!(A, rows, cols, vals; mode = ADD_VALUES), ghost_update!(v; mode, scatter), zero_rows!(A, rows; diag = 2).

The positional forms still work and warn once until v0.6. Keyword calls cost the same as the old positional ones (40 ns, no allocations, for a DMStag stencil block).
@filoferra
filoferra merged commit b2bed1d into JuliaParallel:main Oct 21, 2026
5 checks passed
@filoferra
filoferra deleted the mode-keywords branch October 21, 2026 15:13
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.

1 participant