Today I found a file called `gcc/cp/cxxapi-data.csv` that contains
# unimplemented <mdspan>,extents,1,no
# unimplemented <mdspan>,dextents,1,no
# unimplemented <mdspan>,layout_left,1,no
# unimplemented <mdspan>,layout_right,1,no
# unimplemented <mdspan>,layout_stride,1,no
# unimplemented <mdspan>,default_accessor,1,no
# unimplemented <mdspan>,mdspan,1,cxx23
I have a feeling I should have been updating this file (and maybe
regenerate a file).
This might be a reason for a fixup for std::extents and a v6
for the layouts.
On 6/3/25 18:50, Luc Grosheintz wrote:
Thank you Tomasz for the round of review. IIUC we have several
cases of if there's a v6, please change this, and no mandatory
changes.
Would you like me to submit a v6?
On 5/30/25 18:42, Luc Grosheintz wrote:
The discussion for v4 is here:
https://gcc.gnu.org/pipermail/libstdc++/2025-May/061665.html
The non-trivial changes are:
* Fixed bug in __offset that called m(0...) even for empty extents; added a
test.
* Fixed buggy tests for class mandates.
* Fix layout_stride::is_{,always_}exhaustive.
* Fix missing private (2x).
* Use cmp_equal in layout_stride::operator==
* Use cmp_equal in tests for std::extents (added to first commit).
Additionally:
* added __empty,
* cleaned up parens near `requires`,
* changed __mapping_like to __mapping_alike,
* use extents_type instead of _Extents,
* don't comment on deviation.
Luc Grosheintz (8):
libstdc++: Improve naming, whitespace and silence warnings for
extents.
libstdc++: Implement layout_left from mdspan.
libstdc++: Add tests for layout_left.
libstdc++: Implement layout_right from mdspan.
libstdc++: Add tests for layout_right.
libstdc++: Implement layout_stride from mdspan.
libstdc++: Add tests for layout_stride.
libstdc++: Make layout_left(layout_stride) noexcept.
libstdc++-v3/include/std/mdspan | 725 +++++++++++++++++-
libstdc++-v3/src/c++23/std.cc.in | 5 +-
.../mdspan/extents/ctor_default.cc | 2 +-
.../mdspan/layouts/class_mandate_neg.cc | 42 +
.../23_containers/mdspan/layouts/ctors.cc | 438 +++++++++++
.../23_containers/mdspan/layouts/empty.cc | 69 ++
.../23_containers/mdspan/layouts/mapping.cc | 568 ++++++++++++++
.../23_containers/mdspan/layouts/stride.cc | 526 +++++++++++++
8 files changed, 2360 insertions(+), 15 deletions(-)
create mode 100644
libstdc++-v3/testsuite/23_containers/mdspan/layouts/class_mandate_neg.cc
create mode 100644
libstdc++-v3/testsuite/23_containers/mdspan/layouts/ctors.cc
create mode 100644
libstdc++-v3/testsuite/23_containers/mdspan/layouts/empty.cc
create mode 100644
libstdc++-v3/testsuite/23_containers/mdspan/layouts/mapping.cc
create mode 100644
libstdc++-v3/testsuite/23_containers/mdspan/layouts/stride.cc