Skip to content
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

[oneDPL][ranges] + zip_view implementation for C++20 #1877

Open
wants to merge 128 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
128 commits
Select commit Hold shift + click to select a range
f636681
[oneDPL][ranges][zip_view] + initial implementation of standard compl…
MikeDvorskiy Sep 17, 2024
5f4a5bb
[oneDPL][ranges][zip_view] + missing arithmetic operations for zip_vi…
MikeDvorskiy Sep 18, 2024
b612d1f
[oneDPL][ranges][zip_view] + return type fix for operator*()
MikeDvorskiy Sep 20, 2024
ae8e379
[oneDPL][ranges][tuple] + const assignment operator overload
MikeDvorskiy Sep 24, 2024
c3de847
[oneDPL][ranges][zip_view] + test
MikeDvorskiy Sep 24, 2024
90a9b3e
[oneDPL][ranges][zip_view] + apply_to_tuple instead of std::apply; st…
MikeDvorskiy Sep 24, 2024
4f106ca
[oneDPL][ranges][zip_view] + changes in the test
MikeDvorskiy Sep 25, 2024
1f3e853
[oneDPL][ranges][zip_view] -> oneapi::dpl::ranges
MikeDvorskiy Sep 25, 2024
6d94997
[oneDPL][ranges][zip_view][test] -> oneapi::dpl::ranges
MikeDvorskiy Sep 25, 2024
01d573e
[oneDPL][ranges][zip_view] + file header and guards
MikeDvorskiy Sep 25, 2024
b45cdce
[oneDPL][ranges][zip_view] + apply_to_tuple instead of std::apply; st…
MikeDvorskiy Sep 25, 2024
27989b1
[oneDPL][ranges][zip_view] + begin_imp, end_impl to reduce code dupli…
MikeDvorskiy Sep 26, 2024
20a0ca3
Revert "[oneDPL][ranges][zip_view] + begin_imp, end_impl to reduce co…
MikeDvorskiy Sep 26, 2024
e9f7cb9
[oneDPL][ranges][zip_view][test] + minor changes
MikeDvorskiy Sep 27, 2024
9908a34
[oneDPL][ranges][zip_view] + minor changes
MikeDvorskiy Oct 7, 2024
a4ecfb6
[oneDPL][ranges][zip_view] + #include "tuple_impl.h"
MikeDvorskiy Oct 9, 2024
e439cb7
[oneDPL][ranges][zip_view][test] + test_zip_view_base_op()
MikeDvorskiy Oct 22, 2024
991cc74
[oneDPL][ranges][zip_view] + implementation fix for 'operator-' betwe…
MikeDvorskiy Oct 18, 2024
51f7a69
Update include/oneapi/dpl/pstl/zip_view_impl.h
MikeDvorskiy Oct 21, 2024
71170b0
Update include/oneapi/dpl/pstl/zip_view_impl.h
MikeDvorskiy Oct 21, 2024
fd6d400
Update include/oneapi/dpl/pstl/zip_view_impl.h
MikeDvorskiy Oct 21, 2024
f183330
Update include/oneapi/dpl/pstl/zip_view_impl.h
MikeDvorskiy Oct 21, 2024
efeee7f
Update include/oneapi/dpl/pstl/zip_view_impl.h
MikeDvorskiy Oct 21, 2024
6cb6c28
Update include/oneapi/dpl/pstl/zip_view_impl.h
MikeDvorskiy Oct 21, 2024
795e5d4
Update include/oneapi/dpl/pstl/zip_view_impl.h
MikeDvorskiy Oct 21, 2024
c8d7094
Update include/oneapi/dpl/pstl/zip_view_impl.h
MikeDvorskiy Oct 21, 2024
35b08c8
Update include/oneapi/dpl/pstl/zip_view_impl.h
MikeDvorskiy Oct 21, 2024
7a24436
[oneDPL][ranges][zip_view] + std::get usage
MikeDvorskiy Oct 21, 2024
fcb73df
[oneDPL][ranges][zip_view] + 'std::forward<decltype(__args)>(__args)'…
MikeDvorskiy Oct 21, 2024
c7a0203
[oneDPL][ranges][zip_view] + 'minor change' for const/non const type …
MikeDvorskiy Oct 21, 2024
3d57fcd
[oneDPL][ranges][zip_view] + fix operator<=> implementation
MikeDvorskiy Oct 22, 2024
ea4909f
[oneDPL][ranges][zip_view][test] removed cbegin(), cend() test cases …
MikeDvorskiy Oct 25, 2024
b08db96
[oneDPL][ranges][zip_view][test] + front(), back() methods check
MikeDvorskiy Oct 25, 2024
21ce3a6
[oneDPL][ranges][zip_view][test] + empty constructor call check
MikeDvorskiy Oct 29, 2024
b09e4b3
[oneDPL][ranges][zip_view][test] + ;
MikeDvorskiy Oct 30, 2024
d6a0951
[oneDPL][ranges][zip_view][test] const for compare_with_sentinels
MikeDvorskiy Nov 4, 2024
ea99d8b
[oneDPL][ranges][zip_view][test] a fix for zip_view::iterator::operator-
MikeDvorskiy Nov 6, 2024
025ea48
[oneDPL][rfc][zip_view] + std::ranges::range_reference_t usage; it f…
MikeDvorskiy Nov 8, 2024
b828942
[oneDPL][ranges][zip_view][test] + minor changes
MikeDvorskiy Nov 8, 2024
6d43e60
[oneDPL][zip_view] + minor improvements
MikeDvorskiy Nov 15, 2024
eeef87d
[oneDPL][ranges][zip_view][test] + EXPECT_TRUE usage
MikeDvorskiy Nov 19, 2024
4ffc7a7
[oneDPL][ranges][zip_view] + operator oneapi::dpl::zip_iterator<Itera…
MikeDvorskiy Dec 2, 2024
ae62a35
[oneDPL][ranges][zip_view][test] + check conversion to oneapi::dpl::z…
MikeDvorskiy Dec 2, 2024
5a1f826
[oneDPL][ranges][zip_view][test] + EXPECT_TRUE usage
MikeDvorskiy Dec 5, 2024
d38430d
[oneDPL][ranges][zip_view] + clang format
MikeDvorskiy Jan 16, 2025
2db10cc
[oneDPL][ranges][zip_view][test] + result checks
MikeDvorskiy Jan 16, 2025
1990a1f
[oneDPL][ranges][zip_view] + LLVM tests for ranges::zip_view (from C+…
MikeDvorskiy Feb 5, 2025
a401202
[oneDPL][ranges][zip_view] + __simple_view_concep. a fix for operator==
MikeDvorskiy Feb 7, 2025
186e707
[oneDPL][ranges][zip_view][test] LLVM test begin.pass adaptation for …
MikeDvorskiy Feb 7, 2025
4470026
[oneDPL][ranges][zip_view] + fix for end() and compare_equal
MikeDvorskiy Feb 7, 2025
ac26134
[oneDPL][ranges][zip_view][test] LLVM test end.pass adaptation for on…
MikeDvorskiy Feb 7, 2025
2b5e4ab
[oneDPL][ranges][zip_view] + fix an error in zip_fn
MikeDvorskiy Feb 7, 2025
7b266d6
[oneDPL][ranges][zip_view][test] LLVM test cpo.pass adaptation for on…
MikeDvorskiy Feb 7, 2025
01d45c5
[oneDPL][ranges][zip_view] + implementation fixes
MikeDvorskiy Feb 10, 2025
2399109
[oneDPL][ranges][zip_view][test] LLVM test borrowing.compile.pass ada…
MikeDvorskiy Feb 10, 2025
ce45417
[oneDPL][ranges][zip_view] + explicit for constructor
MikeDvorskiy Feb 10, 2025
1604451
[oneDPL][ranges][zip_view][test] LLVM test сtad.compile.pass adaptati…
MikeDvorskiy Feb 10, 2025
e76af7d
[oneDPL][ranges][zip_view][test] LLVM test сtor.default.pass adaptati…
MikeDvorskiy Feb 10, 2025
c6eeab0
[oneDPL][ranges][zip_view][test] LLVM test general.pass and ctor.view…
MikeDvorskiy Feb 10, 2025
2e9c20d
[oneDPL][ranges][zip_view] + correct implementation of method 'size()…
MikeDvorskiy Feb 10, 2025
19ee369
[oneDPL][ranges][zip_view][test] another couple of LLVM tests adapta…
MikeDvorskiy Feb 10, 2025
bf250d8
[oneDPL][ranges][zip_view] + arithmetic operation fixes
MikeDvorskiy Feb 12, 2025
34487d3
[oneDPL][ranges][zip_view][test] LLVM test arithmetict.pass adaptatio…
MikeDvorskiy Feb 12, 2025
01f1b29
[oneDPL][ranges][zip_view] + fixes in private zip_view::iterator cons…
MikeDvorskiy Feb 12, 2025
dfe2eac
[oneDPL][ranges][zip_view][test] compare.pass test adaptation for oneDPL
MikeDvorskiy Feb 12, 2025
0a3a371
[oneDPL][ranges][zip_view] + fixes in apply_to_tuple using
MikeDvorskiy Feb 12, 2025
753ed8e
[oneDPL][ranges][zip_view][test] another LLVM test portion were adopt…
MikeDvorskiy Feb 12, 2025
ac20fab
[oneDPL][ranges][zip_view] + iter_move friend method
MikeDvorskiy Feb 13, 2025
9970135
[oneDPL][ranges][zip_view][test] another couple of LLVM tests adapta…
MikeDvorskiy Feb 13, 2025
44f1600
[oneDPL][ranges][zip_view] + iter_swap friend method
MikeDvorskiy Feb 13, 2025
e2235a8
[oneDPL][ranges][zip_view][test] LLVM test iter_swap.pass adaptation …
MikeDvorskiy Feb 13, 2025
8914c39
[oneDPL][ranges][zip_view] + fix: public inheritance for class iterat…
MikeDvorskiy Feb 13, 2025
211ec04
[oneDPL][ranges][zip_view][test] another LLVM test adaptation for on…
MikeDvorskiy Feb 13, 2025
93414b4
[oneDPL][ranges][zip_view][test] another couple of LLVM tests adapta…
MikeDvorskiy Feb 13, 2025
6a264aa
[oneDPL][ranges][zip_view][test] + test cases disabling #if __GNUC__ …
MikeDvorskiy Feb 13, 2025
005065d
[oneDPL][ranges][tuple] + a fix for default. According to std::tuple:…
MikeDvorskiy Feb 17, 2025
961e55c
[oneDPL][ranges][zip_view] + a fix: __maybe_const usage.
MikeDvorskiy Feb 17, 2025
d8bdf63
[oneDPL][ranges][zip_view][test] another LLVM tests adaptation for o…
MikeDvorskiy Feb 17, 2025
99e1ab6
[oneDPL][ranges][zip_view][test] minor changes for begin.pass test
MikeDvorskiy Feb 17, 2025
42fe69f
[oneDPL][ranges][zip_view][test] the tests renamed: + prefix "zip_view."
MikeDvorskiy Feb 17, 2025
7890cf1
[oneDPL] a fixe for __pattern_walk2 implementation in case of forward…
MikeDvorskiy Feb 17, 2025
98bda33
[oneDPL][ranges][zip_view] removed spaces
MikeDvorskiy Feb 17, 2025
a2c4c4d
Revert "[oneDPL] a fixe for __pattern_walk2 implementation in case of…
MikeDvorskiy Feb 18, 2025
b34ebd4
[oneDPL][ranges][zip_view][test] additional LLVM tests adaptation for…
MikeDvorskiy Feb 19, 2025
fc3921e
[oneDPL][ranges][tuple] + a fix for Value-initializes all elements of…
MikeDvorskiy Feb 18, 2025
212531e
[oneDPL][ranges][zip_view][test] + #include "support/test_config.h"
MikeDvorskiy Feb 18, 2025
be0901c
[oneDPL][ranges][tuple] + a fix for the internal tuple default constr…
MikeDvorskiy Feb 19, 2025
9ae1f14
[oneDPL][ranges][zip_view] + namespace views = ranges::views;
MikeDvorskiy Feb 19, 2025
a5bec75
[oneDPL][ranges][zip_view][test] removed unused code
MikeDvorskiy Feb 24, 2025
56c2d33
[oneDPL][ranges][zip_view] + fix: std::ranges::enable_borrowed_range …
MikeDvorskiy Feb 24, 2025
abbc9b7
[oneDPL][ranges][zip_view][test] + include
MikeDvorskiy Feb 24, 2025
6d52459
[oneDPL][ranges][zip_view] + fix: using ranges::views::zip; in dpl::v…
MikeDvorskiy Feb 24, 2025
bb41196
[oneDPL][ranges][zip_view] + fixes
MikeDvorskiy Feb 24, 2025
5792b0a
[oneDPL][ranges][zip_view] + fixes
MikeDvorskiy Feb 24, 2025
c7f490e
[oneDPL][ranges][zip_view] + a fix for iterator private constructor
MikeDvorskiy Feb 25, 2025
45dbd3e
[oneDPL][ranges][zip_view][test] + name space fix
MikeDvorskiy Feb 25, 2025
f2bd43d
[oneDPL][tuple] + a comment default constructor
MikeDvorskiy Feb 25, 2025
d3e241d
[oneDPL][ranges][zip_view][test] removed // UNSUPPORTED: c++03, c++11…
MikeDvorskiy Feb 25, 2025
47ce943
Apply suggestions from code review
MikeDvorskiy Feb 25, 2025
2596876
[oneDPL][ranges][zip_view][test] header changed
MikeDvorskiy Feb 25, 2025
dabe108
[oneDPL][ranges][zip_view] removed the commented code
MikeDvorskiy Feb 25, 2025
32fed08
Apply suggestions from code review
MikeDvorskiy Feb 26, 2025
cd3c7c6
Apply suggestions from code review
MikeDvorskiy Feb 26, 2025
4ee2c96
[oneDPL][ranges][zip_view] + difference_type alias usage
MikeDvorskiy Feb 26, 2025
64a1721
Revert "[oneDPL][ranges][zip_view] + difference_type alias usage"
MikeDvorskiy Feb 26, 2025
04e383d
[oneDPL][ranges][zip_view] + difference_type alias usage for iterator
MikeDvorskiy Feb 26, 2025
15f714f
[oneDPL][ranges][zip_view] + difference_type alias usage for sentinel
MikeDvorskiy Feb 26, 2025
b7291f0
[oneDPL][ranges][zip_view] operator- code re-factored.
MikeDvorskiy Feb 28, 2025
fbe4de1
[oneDPL][ranges][zip_view] uglification, part1
MikeDvorskiy Feb 28, 2025
3a40f01
[oneDPL][ranges][zip_view] __apply_to_tuple stuff refactoring
MikeDvorskiy Feb 28, 2025
202f271
[oneDPL][ranges][zip_view] uglification, part2
MikeDvorskiy Feb 28, 2025
d4c1038
[oneDPL][ranges][zip_view] moved the internal utility to namespace __…
MikeDvorskiy Feb 28, 2025
3dc9bd9
[oneDPL][ranges][zip_view] + clang format
MikeDvorskiy Feb 28, 2025
85effed
Revert "[oneDPL][ranges][zip_view] + clang format"
MikeDvorskiy Feb 28, 2025
3b949af
[oneDPL][ranges][zip_view][tests] + removed unused code.
MikeDvorskiy Feb 28, 2025
f7c23c7
Update c++ standard in clang-format
dmitriy-sobolev Mar 3, 2025
fc4c595
[oneDPL][ranges][zip_view][tests] + test cases with zip_view (and dpc…
MikeDvorskiy Mar 3, 2025
6adb830
[oneDPL][ranges][zip_view] iterator_type -> iterators_type
MikeDvorskiy Mar 3, 2025
84cefc3
[oneDPL][tuple] + clang format
MikeDvorskiy Mar 3, 2025
3bf7265
[oneDPL][ranges][zip_view] + clang format
MikeDvorskiy Mar 3, 2025
6580821
[oneDPL][ranges][zip_view][test] + a test case for a device policy
MikeDvorskiy Mar 11, 2025
4ec04af
[oneDPL][ranges][zip_view][test] + sharing alias typel_type for sever…
MikeDvorskiy Mar 10, 2025
d5c02b0
Revert "[oneDPL][ranges][zip_view][test] + sharing alias typel_type f…
MikeDvorskiy Mar 10, 2025
3e39e5a
[oneDPL][ranges][zip_view] + fix "return" for __apply_to_tuples
MikeDvorskiy Mar 10, 2025
3e2cdd5
Update include/oneapi/dpl/pstl/zip_view_impl.h
MikeDvorskiy Mar 10, 2025
084b3a8
Update include/oneapi/dpl/pstl/zip_view_impl.h
MikeDvorskiy Mar 10, 2025
cf07622
[oneDPL][ranges][zip_view] + alias __iterators_type unification
MikeDvorskiy Mar 10, 2025
63939cb
Revert "[oneDPL][ranges][zip_view] + alias __iterators_type unification"
MikeDvorskiy Mar 10, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .clang-format
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
BasedOnStyle: LLVM

Standard: c++17
Standard: c++20

IndentWidth: 4
ColumnLimit: 120
Expand Down
3 changes: 3 additions & 0 deletions include/oneapi/dpl/pstl/ranges_defs.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,9 @@
#include <ranges>
#endif

//oneapi::dpl::ranges::zip_view support for C++20
#include "zip_view_impl.h"

#include "utils_ranges.h"
#if _ONEDPL_BACKEND_SYCL
# include "hetero/dpcpp/utils_ranges_sycl.h"
Expand Down
16 changes: 15 additions & 1 deletion include/oneapi/dpl/pstl/tuple_impl.h
Original file line number Diff line number Diff line change
Expand Up @@ -418,7 +418,12 @@ struct tuple<T1, T...>
return get_impl<I>()(::std::move(*this));
}

tuple() = default;
template <typename _Tp = T1,
std::enable_if_t<
std::conjunction_v<std::is_default_constructible<_Tp>, std::is_default_constructible<T>...>, int> = 0>
tuple() : holder{}, next{}
{
} //The std::tuple makes value-initialization all elements, so we also follow this.
tuple(const tuple& other) = default;
tuple(tuple&& other) = default;
template <typename _U1, typename... _U, typename = ::std::enable_if_t<(sizeof...(_U) == sizeof...(T))>>
Expand Down Expand Up @@ -501,6 +506,15 @@ struct tuple<T1, T...>
return *this;
}

template <typename U1, typename... U>
tuple&
operator=(const tuple<U1, U...>& other) const
{
holder.value = other.holder.value;
next = other.next;
return *this;
}

// if T1 is deduced with reference, compiler generates deleted operator= and,
// since "template operator=" is not considered as operator= overload
// the deleted operator= has a preference during lookup
Expand Down
Loading