Skip to content

Commit

Permalink
Merge pull request #10 from fverdugo/quickfix
Browse files Browse the repository at this point in the history
Bugfix in MatCreateMPIAIJWithSplitArrays
  • Loading branch information
fverdugo authored May 18, 2024
2 parents 265b2dd + 62a6563 commit 56539b5
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 2 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,12 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [0.1.2] - 2024-05-18

### Fixed

- Bug in `MatCreateMPIAIJWithSplitArrays_args`.

## [0.1.1] - 2024-02-28

### Fixed
Expand Down
2 changes: 1 addition & 1 deletion Project.toml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
name = "PetscCall"
uuid = "1194c000-87c4-4102-b4a0-a6217ec4849e"
authors = ["Francesc Verdugo <[email protected]> and contributors"]
version = "0.1.1"
version = "0.1.2"

[deps]
Libdl = "8f399da3-3557-5675-b5ff-fb832c97cbdb"
Expand Down
7 changes: 6 additions & 1 deletion src/ksp.jl
Original file line number Diff line number Diff line change
Expand Up @@ -274,7 +274,12 @@ function MatCreateMPIAIJWithSplitArrays_args(a::PSparseMatrix,petsc_comm,cols=re
end
end
if ! issorted
sort!(view(oj,pini:pend))
# TODO a more efficient way of doing this, or avoiding the need to sort
viewj = view(oj,pini:pend)
viewv = view(ov,pini:pend)
perm = sortperm(viewj) # Allocation here
viewj .= viewj[perm]
viewv .= viewv[perm]
end
end
(petsc_comm,m,n,M,N,i,j,v,oi,oj,ov)
Expand Down

2 comments on commit 56539b5

@fverdugo
Copy link
Owner Author

Choose a reason for hiding this comment

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

@JuliaRegistrator register()

@JuliaRegistrator
Copy link

Choose a reason for hiding this comment

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

Registration pull request created: JuliaRegistries/General/107123

Tip: Release Notes

Did you know you can add release notes too? Just add markdown formatted text underneath the comment after the text
"Release notes:" and it will be added to the registry PR, and if TagBot is installed it will also be added to the
release that TagBot creates. i.e.

@JuliaRegistrator register

Release notes:

## Breaking changes

- blah

To add them here just re-invoke and the PR will be updated.

Tagging

After the above pull request is merged, it is recommended that a tag is created on this repository for the registered package version.

This will be done automatically if the Julia TagBot GitHub Action is installed, or can be done manually through the github interface, or via:

git tag -a v0.1.2 -m "<description of version>" 56539b5c5df27dda6818ecb586d6fe9aa4e33d55
git push origin v0.1.2

Please sign in to comment.