Tobias Schlüter
cd2ba9d03e
Add construct_at, destroy_at wrappers. Use throughout.
2022-03-08 20:43:22 +00:00
AlexanderMueller
dfa5176780
make SparseSolverBase and IterativeSolverBase move constructable
2022-03-08 20:03:53 +01:00
Erik Schultheis
d271a7d545
reduce float warnings (comparisons and implicit conversions)
2022-01-26 18:16:19 +00:00
Kolja Brix
8d81a2339c
Reduce usage of reserved names
2022-01-10 20:53:29 +00:00
Erik Schultheis
e939c06b0e
Small speed-up in row-major sparse dense product
2021-12-15 18:46:25 +00:00
Erik Schultheis
c20e908ebc
turn some macros intro constexpr functions
2021-12-10 19:27:01 +00:00
Erik Schultheis
ec2fd0f7ed
Require recent GCC and MSCV and removed EIGEN_HAS_CXX14
and some other feature test macros
2021-12-01 00:48:34 +00:00
Erik Schultheis
7e586635ba
don't use deprecated MappedSparseMatrix
2021-11-19 15:58:04 +00:00
Erik Schultheis
b0fb5417d3
Fixed Sparse-Sparse Product in case of mixed StorageIndex types
2021-11-18 18:33:31 +00:00
Erik Schultheis
ca9c848679
use consistent StorageIndex
types in SparseMatrix::Map
...
and `SparseMatrix::TransposedSparseMatrix`
2021-11-15 22:18:26 +00:00
Erik Schultheis
13954c4440
moved pruning code to SparseVector.h
2021-11-15 22:16:01 +00:00
sciencewhiz
4b6036e276
fix various typos
2021-09-22 16:15:06 +00:00
Rasmus Munk Larsen
6cadab6896
Clean up EIGEN_STATIC_ASSERT to only use standard c++11 static_assert.
2021-09-16 20:43:54 +00:00
Rasmus Munk Larsen
d7d0bf832d
Issue an error in case of direct inclusion of internal headers.
2021-09-10 19:12:26 +00:00
Antonio Sanchez
3b48a3b964
Remove stray DynamicSparseMatrix references.
...
DynamicSparseMatrix has been removed. These shouldn't be here anymore.
2021-09-02 19:47:26 +00:00
Alexander Karatarakis
4ba872bd75
Avoid leading underscore followed by cap in template identifiers
2021-08-04 22:41:52 +00:00
Antonio Sanchez
1e6c6c1576
Replace memset with fill to work for non-trivial scalars.
...
For custom scalars, zero is not necessarily represented by
a zeroed-out memory block (e.g. gnu MPFR). We therefore
cannot rely on `memset` if we want to fill a matrix or tensor
with zeroes. Instead, we should rely on `fill`, which for trivial
types does end up getting converted to a `memset` under-the-hood
(at least with gcc/clang).
Requires adding a `fill(begin, end, v)` to `TensorDevice`.
Replaced all potentially bad instances of memset with fill.
Fixes #2245 .
2021-07-08 18:34:41 +00:00
Rasmus Munk Larsen
13fb5ab92c
Fix more enum arithmetic.
2021-06-15 09:09:31 -07:00
Rasmus Munk Larsen
f64b2954c7
Fix c++20 warnings about using enums in arithmetic expressions.
2021-06-10 17:17:39 -07:00
Christoph Hertzberg
ca528593f4
Fixed/masked more implicit copy constructor warnings
...
(cherry picked from commit 2883e91ce5a99c391fbf28e20160176b70854992)
2021-02-27 18:44:26 +01:00
Adam Shapiro
2ac0b78739
Fixed sparse conservativeResize() when both num cols and rows decreased.
...
The previous implementation caused a buffer overflow trying to calculate non-
zero counts for columns that no longer exist.
2021-02-23 21:32:39 +00:00
David Tellenbach
2e8f850c78
Fix a typo in SparseMatrix documentation.
...
This fixes issue #2091 .
2020-12-09 14:48:24 +01:00
Antonio Sanchez
a8fdcae55d
Fix sparse_extra_3, disable counting temporaries for testing DynamicSparseMatrix.
...
Multiplication of column-major `DynamicSparseMatrix`es involves three
temporaries:
- two for transposing twice to sort the coefficients
(`ConservativeSparseSparseProduct.h`, L160-161)
- one for a final copy assignment (`SparseAssign.h`, L108)
The latter is avoided in an optimization for `SparseMatrix`.
Since `DynamicSparseMatrix` is deprecated in favor of `SparseMatrix`, it's not
worth the effort to optimize further, so I simply disabled counting
temporaries via a macro.
Note that due to the inclusion of `sparse_product.cpp`, the `sparse_extra`
tests actually re-run all the original `sparse_product` tests as well.
We may want to simply drop the `DynamicSparseMatrix` tests altogether, which
would eliminate the test duplication.
Related to #2048
2020-11-18 23:15:33 +00:00
Gael Guennebaud
27e6648074
fix #1901 : warning in Mode==(Upper|Lower)
2020-09-02 15:43:58 +02:00
Gael Guennebaud
25424d91f6
Fix #1974 : assertion when reserving an empty sparse matrix
2020-08-26 12:32:20 +02:00
Rasmus Munk Larsen
acab22c205
Avoid division by zero in nonZerosEstimate() for empty blocks.
2020-07-22 01:38:30 +00:00
Gael Guennebaud
ab615e4114
Save one extra temporary when assigning a sparse product to a row-major sparse matrix
2020-05-30 23:15:12 +02:00
Christoph Hertzberg
72166d0e6e
Fix some maybe-unitialized warnings
2019-12-18 18:26:20 +01:00
Gael Guennebaud
15b3bcfca0
Bug 1786: fix compilation with MSVC
2019-12-11 16:16:38 +01:00
Eugene Zhulenev
82a47338df
Fix shadow warnings in AlignedBox and SparseBlock
2019-11-27 16:22:27 -08:00
Joel Holdsworth
86eb41f1cb
SparseRef: Fixed alignment warning on ARM GCC
2019-11-07 14:34:06 +00:00
Rasmus Munk Larsen
ee404667e2
Rollback or PR-746 and partial rollback of 668ab3fc47
...
.
std::array is still not supported in CUDA device code on Windows.
2019-11-05 17:17:58 -08:00
Eugene Zhulenev
e7ed4bd388
Remove internal::smart_copy and replace with std::copy
2019-10-29 11:25:24 -07:00
Gael Guennebaud
196de2efe3
Explicitly bypass resize and memmoves when there is already the exact right number of elements available.
2019-10-08 21:44:33 +02:00
Gael Guennebaud
afa8d13532
Fix some implicit literal to Scalar conversions in SparseCore
2019-09-11 00:03:07 +02:00
Eugene Zhulenev
f59bed7a13
Change typedefs from private to protected to fix MSVC compilation
2019-09-03 19:11:36 -07:00
Gael Guennebaud
a2a07e62b9
Fix compilation with c++03 (local class cannot be template arguments), and make SparseMatrix::assignDiagonal truly protected.
2019-01-29 10:10:07 +01:00
Gael Guennebaud
f489f44519
bug #1574 : implement "sparse_matrix =,+=,-= diagonal_matrix" with smart insertion strategies of missing diagonal coeffs.
2019-01-28 17:29:50 +01:00
Gael Guennebaud
803fa79767
Move evaluator<SparseCompressedBase>::find(i,j) to a more general and reusable SparseCompressedBase::lower_bound(i,j) functiion
2019-01-28 17:24:44 +01:00
Christoph Hertzberg
24dc076519
Explicitly convert 0 to Scalar for custom types
2018-10-12 10:22:19 +02:00
Gael Guennebaud
eec0dfd688
bug #632 : add specializations for res ?= dense +/- sparse and res ?= sparse +/- dense.
...
They are rewritten as two compound assignment to by-pass hybrid dense-sparse iterator.
2018-10-10 22:50:15 +02:00
Gael Guennebaud
0c56d22e2e
Fix shadowing
2018-09-20 22:56:21 +02:00
Gael Guennebaud
d6813fb1c5
bug #1531 : expose NumDimensions for solve and sparse expressions.
2018-06-08 16:55:10 +02:00
Gael Guennebaud
8810baaed4
Add multi-threading for sparse-row-major * dense-row-major
2018-04-25 10:14:48 +02:00
Gael Guennebaud
a57e6e5f0f
workaround MSVC 2013 compilation issue (ambiguous call)
2018-04-23 15:31:51 +02:00
Gael Guennebaud
368dd4cd9d
Make innerVector() and innerVectors() methods available to all expressions supported by Block.
...
Before, only SparseBase exposed such methods.
2018-04-04 15:09:21 +02:00
luz.paz
e3912f5e63
MIsc. source and comment typos
...
Found using `codespell` and `grep` from downstream FreeCAD
2018-03-11 10:01:44 -04:00
Gael Guennebaud
8579195169
bug #1468 (1/2) : add missing std:: to memcpy
2017-09-22 09:23:24 +02:00
Gael Guennebaud
80142362ac
Fix mixing types in sparse matrix products.
2017-09-02 22:50:20 +02:00
Gael Guennebaud
1f4b24d2df
Do not preallocate more space than the matrix size (when the sparse matrix boils down to a vector
2017-07-20 10:13:48 +02:00