From 1e2433acc2fa1d62a470581aa0da2d7f914bbfe5 Mon Sep 17 00:00:00 2001 From: Nick Date: Thu, 9 Jul 2020 12:53:14 -0400 Subject: [PATCH 1/3] Append mode has been completed. --- bindings/CXX11/adios2/cxx11/IO.h | 4 ++-- source/adios2/engine/bp3/BP3Writer.cpp | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/bindings/CXX11/adios2/cxx11/IO.h b/bindings/CXX11/adios2/cxx11/IO.h index cce90e6d01..f620e1be08 100644 --- a/bindings/CXX11/adios2/cxx11/IO.h +++ b/bindings/CXX11/adios2/cxx11/IO.h @@ -252,7 +252,7 @@ class IO * Open an Engine to start heavy-weight input/output operations. * @param name unique engine identifier * @param mode adios2::Mode::Write, adios2::Mode::Read, or - * adios2::Mode::Append (not yet support) + * adios2::Mode::Append * @return engine object */ Engine Open(const std::string &name, const Mode mode); @@ -265,7 +265,7 @@ class IO * MPI Collective function as it calls MPI_Comm_dup * @param name unique engine identifier within IO * @param mode adios2::Mode::Write, adios2::Mode::Read, or - * adios2::Mode::Append (not yet support) + * adios2::Mode::Append * @param comm new communicator other than ADIOS object's communicator * @return engine object */ diff --git a/source/adios2/engine/bp3/BP3Writer.cpp b/source/adios2/engine/bp3/BP3Writer.cpp index 47b0554b50..a20115cc6f 100644 --- a/source/adios2/engine/bp3/BP3Writer.cpp +++ b/source/adios2/engine/bp3/BP3Writer.cpp @@ -205,7 +205,7 @@ void BP3Writer::InitBPBuffer() if (m_OpenMode == Mode::Append) { throw std::invalid_argument( - "ADIOS2: OpenMode Append hasn't been implemented, yet"); + "ADIOS2: Mode::Append is only available BP4; it is not implemented for BP3 files."); // TODO: Get last pg timestep and update timestep counter in } else From e165808d8fd52d167eaaac602fa9d6c850dd6d18 Mon Sep 17 00:00:00 2001 From: Nick Date: Thu, 9 Jul 2020 15:31:51 -0400 Subject: [PATCH 2/3] Apply clang-format. --- source/adios2/engine/bp3/BP3Writer.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/source/adios2/engine/bp3/BP3Writer.cpp b/source/adios2/engine/bp3/BP3Writer.cpp index a20115cc6f..d6cb142984 100644 --- a/source/adios2/engine/bp3/BP3Writer.cpp +++ b/source/adios2/engine/bp3/BP3Writer.cpp @@ -205,7 +205,8 @@ void BP3Writer::InitBPBuffer() if (m_OpenMode == Mode::Append) { throw std::invalid_argument( - "ADIOS2: Mode::Append is only available BP4; it is not implemented for BP3 files."); + "ADIOS2: Mode::Append is only available BP4; it is not implemented " + "for BP3 files."); // TODO: Get last pg timestep and update timestep counter in } else From 6751221f8ac21c79cda960f814a33701c3f279af Mon Sep 17 00:00:00 2001 From: Nick Date: Fri, 10 Jul 2020 10:57:53 -0400 Subject: [PATCH 3/3] Document that adios2::Mode::Append is only available for bp4. --- bindings/CXX11/adios2/cxx11/IO.h | 4 ++-- source/adios2/engine/bp3/BP3Writer.cpp | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/bindings/CXX11/adios2/cxx11/IO.h b/bindings/CXX11/adios2/cxx11/IO.h index f620e1be08..717b6be72b 100644 --- a/bindings/CXX11/adios2/cxx11/IO.h +++ b/bindings/CXX11/adios2/cxx11/IO.h @@ -252,7 +252,7 @@ class IO * Open an Engine to start heavy-weight input/output operations. * @param name unique engine identifier * @param mode adios2::Mode::Write, adios2::Mode::Read, or - * adios2::Mode::Append + * adios2::Mode::Append (BP4 only) * @return engine object */ Engine Open(const std::string &name, const Mode mode); @@ -265,7 +265,7 @@ class IO * MPI Collective function as it calls MPI_Comm_dup * @param name unique engine identifier within IO * @param mode adios2::Mode::Write, adios2::Mode::Read, or - * adios2::Mode::Append + * adios2::Mode::Append (BP4 only) * @param comm new communicator other than ADIOS object's communicator * @return engine object */ diff --git a/source/adios2/engine/bp3/BP3Writer.cpp b/source/adios2/engine/bp3/BP3Writer.cpp index d6cb142984..9e869c4b64 100644 --- a/source/adios2/engine/bp3/BP3Writer.cpp +++ b/source/adios2/engine/bp3/BP3Writer.cpp @@ -204,9 +204,9 @@ void BP3Writer::InitBPBuffer() { if (m_OpenMode == Mode::Append) { - throw std::invalid_argument( - "ADIOS2: Mode::Append is only available BP4; it is not implemented " - "for BP3 files."); + throw std::invalid_argument("ADIOS2: Mode::Append is only available in " + "BP4; it is not implemented " + "for BP3 files."); // TODO: Get last pg timestep and update timestep counter in } else