Skip to content

Commit

Permalink
Merge pull request #9937 from masterleinad/remove_even_more_deprecation
Browse files Browse the repository at this point in the history
Remove PETScWrappers deprecations
  • Loading branch information
drwells committed Jul 27, 2022
2 parents d1475a1 + 3320bb5 commit 664a66f
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 38 deletions.
5 changes: 5 additions & 0 deletions doc/news/changes/incompatibilities/20200421DanielArndt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Removed: Deprecated constructors for PETScWrappers::MPI::SparseMatrix,
a deprecated overload for PETScWrappers::MatrixBase::add and a deprecated
constructor for PETScWrappers::MPI::Vector have been removed.
<br>
(Daniel Arndt, 2020/04/21)
18 changes: 0 additions & 18 deletions include/deal.II/lac/petsc_vector.h
Original file line number Diff line number Diff line change
Expand Up @@ -203,24 +203,6 @@ namespace PETScWrappers
const dealii::Vector<Number> &v,
const size_type locally_owned_size);


/**
* Copy-constructor the values from a PETSc wrapper vector class.
*
* @arg local_size denotes the size of the chunk that shall be stored on
* the present process.
*
* @arg communicator denotes the MPI communicator over which the
* different parts of the vector shall communicate
*
* @deprecated The use of objects that are explicitly of type VectorBase
* is deprecated: use PETScWrappers::MPI::Vector instead.
*/
DEAL_II_DEPRECATED
explicit Vector(const MPI_Comm & communicator,
const VectorBase &v,
const size_type local_size);

/**
* Construct a new parallel ghosted PETSc vector from IndexSets.
*
Expand Down
1 change: 1 addition & 0 deletions source/lac/petsc_matrix_base.cc
Original file line number Diff line number Diff line change
Expand Up @@ -428,6 +428,7 @@ namespace PETScWrappers
}



MatrixBase &
MatrixBase::add(const PetscScalar factor, const MatrixBase &other)
{
Expand Down
2 changes: 2 additions & 0 deletions source/lac/petsc_parallel_sparse_matrix.cc
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,8 @@ namespace PETScWrappers
preset_nonzero_locations);
}



template <typename SparsityPatternType>
void
SparseMatrix::reinit(const IndexSet & local_rows,
Expand Down
20 changes: 0 additions & 20 deletions source/lac/petsc_parallel_vector.cc
Original file line number Diff line number Diff line change
Expand Up @@ -49,26 +49,6 @@ namespace PETScWrappers



Vector::Vector(const MPI_Comm & communicator,
const VectorBase &v,
const size_type locally_owned_size)
: VectorBase(v)
, communicator(communicator)
{
// In the past (before it was deprecated) this constructor did a
// byte-for-byte copy of v. This choice resulted in two problems:
// 1. The created vector will have the same size as v, not local size.
// 2. Since both the created vector and v maintain ownership of the same
// PETSc Vec, both will try to destroy it: this does not make sense.
//
// For the sake of backwards compatibility, preserve the behavior of the
// copy, but correct the ownership bug. Note that in both this (and the
// original) implementation locally_owned_size is ultimately unused.
(void)locally_owned_size;
}



Vector::Vector(const IndexSet &local,
const IndexSet &ghost,
const MPI_Comm &communicator)
Expand Down

0 comments on commit 664a66f

Please sign in to comment.