-
Notifications
You must be signed in to change notification settings - Fork 94
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
libstdc++ assertion failures in debug mode #1143
Comments
I'll investigate the runtime issues. The build issues we can't do much about, since GTest insists on using -Werror in its flags - something something live at head. Does the gtest package have a workaround in place for this? |
Looking at its PKGBUILD, I don't think there is any specific workaround. But it's building 1.12.1 instead of 1.11.0 that ginkgo pulls. |
it seems to me like somehow you got diff --git a/core/test/utils/matrix_generator.hpp b/core/test/utils/matrix_generator.hpp
index f4e6e4e26d..93b5166331 100644
--- a/core/test/utils/matrix_generator.hpp
+++ b/core/test/utils/matrix_generator.hpp
@@ -91,7 +91,7 @@ matrix_data<ValueType, IndexType> generate_random_matrix_data(
size_type(0),
std::min(static_cast<size_type>(nonzero_dist(engine)), num_cols));
std::uniform_int_distribution<IndexType> col_dist{
- 0, static_cast<IndexType>(num_cols) - 1};
+ 0, std::max(static_cast<IndexType>(num_cols) - 1, IndexType{})};
if (nnz_in_row > num_cols / 2) {
present_cols.assign(num_cols, true);
// remove num_cols - nnz_in_row entries from present_cols
@@ -228,7 +228,7 @@ matrix_data<ValueType, IndexType> generate_random_triangular_matrix_data(
// randomly generate number of nonzeros in this row
const auto min_col = lower_triangular ? 0 : row;
const auto max_col =
- lower_triangular ? row : static_cast<IndexType>(size) - 1;
+ lower_triangular ? row : std::max(static_cast<IndexType>(size) - 1, IndexType{});
const auto max_row_nnz = max_col - min_col + 1;
const auto nnz_in_row = std::max(
size_type(0), std::min(static_cast<size_type>(nonzero_dist(engine)), |
The RCM issue: @lksriemer how does this diff look? diff --git a/omp/reorder/rcm_kernels.cpp b/omp/reorder/rcm_kernels.cpp
index 920b23d627..38d855fccc 100644
--- a/omp/reorder/rcm_kernels.cpp
+++ b/omp/reorder/rcm_kernels.cpp
@@ -715,7 +715,7 @@ void write_permutation(std::shared_ptr<const OmpExecutor> exec,
// Sort neighbours. Can not be more than there are nodes.
const IndexType size = valid_neighbours.size();
- sort_small(&valid_neighbours[0], size,
+ sort_small(valid_neighbours.data(), size,
[&](IndexType l, IndexType r) {
return degrees[l] < degrees[r];
}); |
@upsj That diff looks good, |
@upsj Oh, Arch defines |
An update on this: We will not be able to support |
FWIW, building Ginkgo with |
While working on an AUR package, I've got this error:
This is with external gtest downloaded by ginkgo. When I use the system gtest-1.12.1-1 on Arch Linux, the error is gone, but some of the tests fail at runtime due to weird assertion errors in the stdlib:
The text was updated successfully, but these errors were encountered: