diff --git a/cmake/CompilerHelper.cmake b/cmake/CompilerHelper.cmake index 74bc939c36..54adf1ce31 100644 --- a/cmake/CompilerHelper.cmake +++ b/cmake/CompilerHelper.cmake @@ -37,16 +37,13 @@ if(CMAKE_C_COMPILER_ID MATCHES "PGI" OR CMAKE_C_COMPILER_ID MATCHES "NVHPC") # "src/modlunit/units.cpp", warning #170-D: pointer points outside of underlying object # "src/nrnpython/grids.cpp", warning #174-D: expression has no effect # "src/nmodl/nocpout.cpp", warning #177-D: variable "j" was declared but never referenced - # "src/mesch/conjgrad.c", warning #180-D: argument is incompatible with formal parameter # "src/nrniv/partrans.cpp", warning #186-D: pointless comparison of unsigned integer with zero - # "src/mesch/machine.h", warning #301-D: typedef name has already been declared (with same type) # "src/nrnpython/rxdmath.cpp", warning #541-D: allowing all exceptions is incompatible with previous function # "src/nmodl/nocpout.cpp", warning #550-D: variable "sion" was set but never used # "src/gnu/neuron_gnu_builtin.h", warning #816-D: type qualifier on return type is meaningless" # "src/modlunit/consist.cpp", warning #2465-D: conversion from a string literal to "char *" is deprecated # ~~~ - list(APPEND NRN_COMPILE_FLAGS - --diag_suppress=1,47,111,128,170,174,177,180,186,301,541,550,816,2465) + list(APPEND NRN_COMPILE_FLAGS --diag_suppress=1,47,111,128,170,174,177,186,541,550,816,2465) endif() list(APPEND NRN_COMPILE_FLAGS -noswitcherror) list(APPEND NRN_LINK_FLAGS -noswitcherror) diff --git a/docs/hoc/programming/math/matrix.rst b/docs/hoc/programming/math/matrix.rst index 15a31632b2..617ad13fa4 100644 --- a/docs/hoc/programming/math/matrix.rst +++ b/docs/hoc/programming/math/matrix.rst @@ -53,20 +53,17 @@ Matrix By default, a new Matrix is of type MFULL (= 1) and allocates storage for all nrow*ncol elements. Scaffolding is in place for matrices of storage type MSPARSE (=2) and MBAND (=3) but not many methods have been interfaced - to the meschach library at this time. If a method is called on a matrix type + to the eigen library at this time. If a method is called on a matrix type whose method has not been implemented, an error message will be printed. It is intended that implemented methods will be transparent to the user, eg m*x=b (``x = m.solv(b)`` ) will solve the linear system regardless of the type of m and v1 = m*v2 (``v1 = m.mulv(v2)`` ) will perform the vector multiplication. - Matrix is implemented using the - `meschach c library by David E. Stewart `_ - (discovered at http://www.netlib.org/c/index.html\ ) which contains a large collection - of routines for sparse, banded, and full matrices. Many of the useful - routines have not - been interfaced with the hoc interpreter but can be easily added on request - or you can add it yourself + Matrix is implemented using the `eigen3 library `_ + which contains a large collection of routines for sparse, banded, and full matrices. + Many of the useful routines have not been interfaced with the hoc + interpreter but can be easily added on request or you can add it yourself by analogy with the code in ``nrn/src/ivoc/(matrix.c ocmatrix.[ch])`` At this time the MFULL matrix type is complete enough to do useful work and MSPARSE can be used to multiply a matrix by a vector and solve diff --git a/docs/python/programming/math/matrix.rst b/docs/python/programming/math/matrix.rst index 62e7f1b044..f494cb50b6 100755 --- a/docs/python/programming/math/matrix.rst +++ b/docs/python/programming/math/matrix.rst @@ -53,20 +53,17 @@ Matrix By default, a new Matrix is of type MFULL (= 1) and allocates storage for all nrow*ncol elements. Scaffolding is in place for matrices of storage type MSPARSE (=2) and MBAND (=3) but not many methods have been interfaced - to the meschach library at this time. If a method is called on a matrix type + to the eigen library at this time. If a method is called on a matrix type whose method has not been implemented, an error message will be printed. It is intended that implemented methods will be transparent to the user, eg m*x=b (``x = m.solv(b)`` ) will solve the linear system regardless of the type of m and v1 = m*v2 (``v1 = m.mulv(v2)`` ) will perform the vector multiplication. - Matrix is implemented using the - `meschach c library by David E. Stewart `_ - (discovered at http://www.netlib.org/c/index.html\ ) which contains a large collection - of routines for sparse, banded, and full matrices. Many of the useful - routines have not - been interfaced with the hoc interpreter but can be easily added on request - or you can add it yourself + Matrix is implemented using the `eigen3 library `_ + which contains a large collection of routines for sparse, banded, and full matrices. + Many of the useful routines have not been interfaced with the hoc + interpreter but can be easily added on request or you can add it yourself by analogy with the code in ``nrn/src/ivoc/(matrix.c ocmatrix.[ch])`` At this time the MFULL matrix type is complete enough to do useful work and MSPARSE can be used to multiply a matrix by a vector and solve diff --git a/src/ivoc/matrix.cpp b/src/ivoc/matrix.cpp index 67e2367578..3c66406403 100644 --- a/src/ivoc/matrix.cpp +++ b/src/ivoc/matrix.cpp @@ -358,10 +358,6 @@ static Object** m_muls(void* v) { if (ifarg(2)) { out = matrix_arg(2); } - // I believe meschach does this for us - // if (out != m) { - // out->resize(... - // } m->muls(*getarg(1), out); return temp_objvar(out); } diff --git a/src/nrniv/CMakeLists.txt b/src/nrniv/CMakeLists.txt index 2af3fc458d..babfe56cc4 100644 --- a/src/nrniv/CMakeLists.txt +++ b/src/nrniv/CMakeLists.txt @@ -214,7 +214,6 @@ set(NRN_INCLUDE_DIRS ${PROJECT_SOURCE_DIR}/external/Random123/include ${PROJECT_SOURCE_DIR}/src ${PROJECT_SOURCE_DIR}/src/gnu - ${PROJECT_SOURCE_DIR}/src/mesch ${PROJECT_SOURCE_DIR}/src/nrncvode ${PROJECT_SOURCE_DIR}/src/nrnmpi ${PROJECT_SOURCE_DIR}/src/nrnpython @@ -327,12 +326,6 @@ if(NRN_USE_BACKWARD) endif() if(NRN_HAVE_NVHPC_COMPILER) - # NVHPC/21.7 cannot compile znorm.c with -O2 or above. See also: - # https://forums.developer.nvidia.com/t/nvc-21-7-regression-internal-compiler-error-can-only-coerce-indirect-args/184847 - if(${CMAKE_CXX_COMPILER_VERSION} VERSION_EQUAL 21.7) - set_source_files_properties(${PROJECT_SOURCE_DIR}/src/mesch/znorm.c PROPERTIES COMPILE_OPTIONS - -Mnovect) - endif() # For NVHPC we will rely on FE exceptions as opposed to errno in order to make use of faster # builtins. One caveat is that if we use an optimization level greater than -O1, the FE exception # is not raised. See https://github.com/neuronsimulator/nrn/pull/1930 diff --git a/src/nrnpython/CMakeLists.txt b/src/nrnpython/CMakeLists.txt index 6f114673f6..79a24c67fb 100644 --- a/src/nrnpython/CMakeLists.txt +++ b/src/nrnpython/CMakeLists.txt @@ -25,7 +25,6 @@ if(NRN_ENABLE_PYTHON_DYNAMIC) ../ivoc ../nrniv ../gnu - ../mesch ../nrnmpi ${PROJECT_BINARY_DIR}/src/nrnpython ${PROJECT_BINARY_DIR}/src/ivos