-
Notifications
You must be signed in to change notification settings - Fork 86
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
Dpcpp port ELL and the porting script #779
Conversation
format! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For now, I only look into the oneAPI porting script to get that out of the
way. My main concern is to create a proper documentation of this as well as a
few fixes. I do a few tentative comments already in line in the files. I think
in addition to that, having a main README.md
file which explains the
workflow and how the different parts are organized and interact with each
other would be useful.
local str="$1" | ||
# local GET_PARAM=" *([^ ]*) *$" | ||
# Need to remove the = .... | ||
# note. it only remove the simple one |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here you mean that it doesn't work with x = y = 3
sort of cases?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, but I think the template will not have this case?
# It should automatically be decided from argument | ||
# Also need to ignore = ... | ||
if [[ "${temp}" =~ "typename" ]]; then | ||
: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
continue
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
no, I need to reset the temp to empty
echo "$parameter" | ||
} | ||
|
||
check_closed() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since the function is also in the other file, you could share this.
echo "false" | ||
fi | ||
} | ||
CONFIG_SELECTION_SUFFIX="_CONFIG" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This can be shared as well
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
the situation is complex, and we do not add the config to cuda.
Thus, I will delete the adding Config part first.
dev_tools/oneapi/convert_source.sh
Outdated
|
||
check_closed() { | ||
local str="$1" | ||
str="${str//->}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Extra comment? # Replace everything except begin or end characters, resp. (<[ and )>]
dev_tools/oneapi/convert_source.sh
Outdated
local str="$1" | ||
str="${str//->}" | ||
str_start="${str//[^(<\[]}" | ||
str_end="${str//[^>)\]]}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Extra comment? # Check that there are as many begin as end characters
echo "false" | ||
fi | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Possible comment:
# Converts a CUDA kernel call to the DPC++ equivalent. Also takes care of the config selection calls and DPC++ queue manipulation if needed.
dev_tools/oneapi/convert_source.sh
Outdated
fi | ||
} | ||
|
||
convert_syntax() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tentative other name:
convert_cuda_kernel_call
} | ||
|
||
convert_syntax() { | ||
local syntax_regex="([^<>]*)(<[^<>]*>)?<<<(.*)>>>(.*)" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe a comment for the regex?
# [1]: kernel name
# [2]: template parameters if it exists
# [3]: CUDA parameters
# [4]: the rest of the function call (parameters, ...)
As a note, couldn't the template parameters call another templated struct? In
that case, maybe the check [^<>]*
isn't warranted for the template portion?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
you are right, it can not handle call<t<1>, ..><<<>>>()
should we consider it? it maybe is possible to handle up to one level but arbitrary template is hard or impossible?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Continued
dev_tools/oneapi/convert_source.sh
Outdated
local num=0 | ||
local var="" | ||
if [[ "${str}" =~ ${syntax_regex} ]]; then | ||
content="${BASH_REMATCH[3]}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
local content="${BASH_REMATCH[3]}"
dev_tools/oneapi/convert_source.sh
Outdated
fi | ||
temp="${temp}${variable}" | ||
# echo "// temp ${temp}" | ||
is_closed=$(check_closed "$temp") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think a comment is warranted here:
# Do not fall into the trap of counting parameters in a sub-expression, such as a function call inside the CUDA kernel parameters
dev_tools/oneapi/convert_source.sh
Outdated
fi | ||
temp="" | ||
fi | ||
done |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If I'm correct, all you do in the previous loop is to count the number of
variables in the list, and you reconstruct it all in $var
? In that case,
isn't it possible to use three regex on $content
to cleanup the annoying
parts before counting? Like:
temp=${content//\[*\]/}
temp=${temp//\(*\)/}
temp=${temp//<*>/}
num=$((${#temp//[^,]} + 1))
# You can also do checks for when num == 4
dev_tools/oneapi/convert_source.sh
Outdated
local suffix="" | ||
local function_name=$(echo "${BASH_REMATCH[1]}" | sed -E 's/(.*::)| //g') | ||
# echo "// functioname ${function_name}" | ||
MAP_FILE="map_list" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This seems to come from somewhere else, maybe put it as a global variable or
function variable?
dev_tools/oneapi/convert_source.sh
Outdated
# echo "// functioname ${function_name}" | ||
MAP_FILE="map_list" | ||
suffix=$(cat "${MAP_FILE}" | sed -nE "s/${function_name} -> ${function_name}(.*)/\1/p") | ||
suffix_matches=$(echo "${suffix}" | wc -l) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
local suffix_matches=$(echo "${suffix}" | wc -l)
dev_tools/oneapi/convert_source.sh
Outdated
|
||
# extract device_code | ||
if [ "${EXTRACT_KERNEL}" = "true" ]; then | ||
IFS=';' read -ra individual_deivce <<< "${DEVICE_FILE}" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
IFS=';' read -ra individual_device <<< "${DEVICE_FILE}"
dev_tools/oneapi/convert_source.sh
Outdated
# extract device_code | ||
if [ "${EXTRACT_KERNEL}" = "true" ]; then | ||
IFS=';' read -ra individual_deivce <<< "${DEVICE_FILE}" | ||
for variable in "${individual_deivce[@]}"; do |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
for variable in "${individual_device[@]}"; do
mkdir -p "${ROOT_DIR}/${dpct_dir}" | ||
cp "${dpct_device_file}" "${ROOT_DIR}/${dpct_device_path}" | ||
done | ||
fi |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I fail to see for now, what is this for?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it is optional and off.
it will move the common code to common/dpcpp_code if enabling it.
cp "${dpct_device_file}" "${ROOT_DIR}/${dpct_device_path}" | ||
done | ||
fi | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe a comment?
# Integrate the new DPC++ file into the correct place
dev_tools/oneapi/convert_source.sh
Outdated
done | ||
fi | ||
|
||
target_file=$(echo "${input}" | sed 's/cuda\//dpcpp\//g;s/\.cuh/\.dp\.hpp/g;s/\.cu/\.dp\.cpp/g') |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
target_file=$(echo "${input}" | sed 's:cuda/:dpcpp/:g;s:\.cuh:\.dp\.hpp:g;s:\.cu:\.dp\.cpp:g')
146b746
to
d5c5899
Compare
Codecov Report
@@ Coverage Diff @@
## develop #779 +/- ##
===========================================
+ Coverage 93.71% 94.25% +0.54%
===========================================
Files 408 408
Lines 32758 32756 -2
===========================================
+ Hits 30698 30874 +176
+ Misses 2060 1882 -178
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a bit out of my depth, but I just had a cursory look. :)
accessor/range.hpp
Outdated
@@ -69,7 +69,8 @@ class range { | |||
* | |||
* @param params parameters forwarded to Accessor constructor. | |||
*/ | |||
template <typename... AccessorParams> | |||
template <typename... AccessorParams, | |||
std::enable_if_t<(sizeof...(AccessorParams) > 1), bool> = true> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change would make the include/ginkgo/core/base/range.hpp
diverge ? Maybe we should either note this somewhere and in 2.0 fix it, or adapt the include/ginkgo/core/base/range.hpp
as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
what do you mean diverge here? the usage of constructor keeps the same due to the accessor always require more than 1 args
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I believe this is a duplication of the include/ginkgo/core/base/range.hpp
, as it was needed to be separate for the Accessor. I meant now the typically the same class (range) has two different versions and we should probably unify them. Also I think you are changing one of the copy constructors below ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, it uses enable_if_t to avoid compiler use this constructor as copy constuctor. By doing so, compiler can auto generate the copy/move constructor, so we do not need to manually point copy constructor to default behavior.
I can also change the part in include/ginkgo/core/base/range.hpp
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, I guess we need to be sure that it does not break interface, I would also maybe ping @thoasm for his comments here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you give a bit of background why we need a copy constructor and a mutable lvalue ref constructor?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
disabling Outer(const Outer&)
error: no matching constructor for initialization of 'Outer'
run([&]() { [=]() { func(a); }; });
^
candidate constructor not viable: 1st argument ('const Outer') would lose const qualifier
disabling Outer(Outer&)
note: in instantiation of function template specialization 'Outer::Outer<Outer &>' requested here
run([&]() { [=]() { func(a); }; });
this is simple version for emulating the dpcpp submit the job.
As far as I remember, two default impl out of class is okay in C++ code, but dpcpp can not allow it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you post a longer snippet that contains the entire context? Why do you need to modify the element you are copying in a copy constructor?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right, we talked about something like that previously.
If I remember correctly, the problem is that you need both const range &
and range &
for them to be used, otherwise, for a range &
, the forwarding constructor is taken. Additionally, for some reason, the visual studio compiler does not accept both copy constructors range(const range &) = default
and range(range &) = default
(apparently, implementing them instead of =default
does not help as well).
Was that about right, @yhmtsai?
I would prefer to find an alternative solution and will try something tomorrow, otherwise, we can add the SFINAE work-around to only exclude single range
parameter for this constructor.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is the small example
#include <CL/sycl.hpp>
#include <utility>
class Inner {
public:
explicit Inner(int, int) {}
};
class Outer {
public:
template <typename... T>
constexpr explicit Outer(T &&... inner) : inner_{std::forward<T>(inner)...}
{}
Outer(Outer &&) = default;
// putting default inside class works
// Outer(Outer &) = default;
// Outer(Outer const&) = default;
Outer(Outer &);
Outer(Outer const &);
private:
Inner inner_;
};
// putting outside fails
Outer::Outer(Outer &) = default;
Outer::Outer(Outer const &) = default;
void func(Outer a) {}
template <typename Lambda>
void run(Lambda f)
{
f();
}
int main()
{
auto a = Outer(3, 4);
// simulate the submit
run([&]() { [=]() { func(a); }; });
sycl::queue q_ct1{sycl::property::queue::in_order{}};
// real submit
q_ct1.submit([&](sycl::handler &cgh) {
cgh.parallel_for(sycl::range<1>{1},
[=](sycl::id<1> idx_id) { func(a); });
});
q_ct1.wait_and_throw();
return 0;
}
the error in MSVC is shown in https://github.com/ginkgo-project/ginkgo/runs/3008759379?check_suite_focus=true
error C2580 ... multiple versions of a defaulted special member functions are not allowed
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Some more minor comments
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The ELL kernels look good to me. On the rest I think others are better qualified to review
dpcpp/base/config.hpp
Outdated
@@ -49,6 +49,12 @@ struct config { | |||
*/ | |||
using lane_mask_type = uint64; | |||
|
|||
|
|||
/** | |||
* The number of threads within a CUDA warp. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* The number of threads within a CUDA warp. | |
* The number of threads within a DPCPP warp. |
dpcpp/base/config.hpp
Outdated
@@ -59,6 +65,11 @@ struct config { | |||
* to maximize GPU occupancy. | |||
*/ | |||
static constexpr uint32 min_warps_per_block = 4; | |||
|
|||
/** | |||
* The maximal number of threads allowed in a CUDA warp. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* The maximal number of threads allowed in a CUDA warp. | |
* The maximal number of threads allowed in a DPCPP warp. |
dec40a8
to
317ddd7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would prefer to move the check_if_valid
helper structure.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Does it make sense to keep the conversion scripts in-tree in the long run? We're not maintaining them, and they will not be used after we finished porting.
dpcpp/matrix/ell_kernels.dp.cpp
Outdated
// Because the atomic operation changes the values of c during computation, | ||
// it can not do the right alpha * a * b + beta * c operation. | ||
// Thus, the dpcpp kernel only computes alpha * a * b when it uses atomic | ||
// operation. | ||
if (atomic) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe instead note that c
needs to be scaled beforehand, otherwise this might lead to confusion. Also:
// Because the atomic operation changes the values of c during computation, | |
// it can not do the right alpha * a * b + beta * c operation. | |
// Thus, the dpcpp kernel only computes alpha * a * b when it uses atomic | |
// operation. | |
if (atomic) { | |
// Because the atomic operation changes the values of c during computation, | |
// it can not do the right alpha * a * b + beta * c operation. | |
// Thus, the dpcpp kernel only adds alpha * a * b when it uses atomic | |
// operation. | |
if (atomic) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will move this part into the atomic scope and the following is what I use (including c be scaled)
// Because the atomic operation changes the values of c during
// computation, it can not directly do alpha * a * b + beta * c
// operation. The beta * c needs to be done before calling this kernel.
// Then, this kernel only adds alpha * a * b when it uses atomic
// operation.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Thanks for adding the documentation.
Co-authored-by: Terry Cojean <terry.cojean@kit.edu>
such that compiler use auto generated one.
Co-authored-by: Fritz Goebel <goebel.fritz@googlemail.com> Co-authored-by: Pratik Nayak <pratikvn@protonmail.com> Co-authored-by: Tobias Ribizel <ribizel@kit.edu>
Co-authored-by: Thomas Grützmacher <thomas.gruetzmacher@kit.edu>
Kudos, SonarCloud Quality Gate passed! |
@upsj I think we put it here like cuda2hip. it will be hard to use on adaptive changes. |
Ginkgo release 1.4.0 The Ginkgo team is proud to announce the new Ginkgo minor release 1.4.0. This release brings most of the Ginkgo functionality to the Intel DPC++ ecosystem which enables Intel-GPU and CPU execution. The only Ginkgo features which have not been ported yet are some preconditioners. Ginkgo's mixed-precision support is greatly enhanced thanks to: 1. The new Accessor concept, which allows writing kernels featuring on-the-fly memory compression, among other features. The accessor can be used as header-only, see the [accessor BLAS benchmarks repository](https://github.com/ginkgo-project/accessor-BLAS/tree/develop) as a usage example. 2. All LinOps now transparently support mixed-precision execution. By default, this is done through a temporary copy which may have a performance impact but already allows mixed-precision research. Native mixed-precision ELL kernels are implemented which do not see this cost. The accessor is also leveraged in a new CB-GMRES solver which allows for performance improvements by compressing the Krylov basis vectors. Many other features have been added to Ginkgo, such as reordering support, a new IDR solver, Incomplete Cholesky preconditioner, matrix assembly support (only CPU for now), machine topology information, and more! Supported systems and requirements: + For all platforms, cmake 3.13+ + C++14 compliant compiler + Linux and MacOS + gcc: 5.3+, 6.3+, 7.3+, all versions after 8.1+ + clang: 3.9+ + Intel compiler: 2018+ + Apple LLVM: 8.0+ + CUDA module: CUDA 9.0+ + HIP module: ROCm 3.5+ + DPC++ module: Intel OneAPI 2021.3. Set the CXX compiler to `dpcpp`. + Windows + MinGW and Cygwin: gcc 5.3+, 6.3+, 7.3+, all versions after 8.1+ + Microsoft Visual Studio: VS 2019 + CUDA module: CUDA 9.0+, Microsoft Visual Studio + OpenMP module: MinGW or Cygwin. Algorithm and important feature additions: + Add a new DPC++ Executor for SYCL execution and other base utilities [#648](#648), [#661](#661), [#757](#757), [#832](#832) + Port matrix formats, solvers and related kernels to DPC++. For some kernels, also make use of a shared kernel implementation for all executors (except Reference). [#710](#710), [#799](#799), [#779](#779), [#733](#733), [#844](#844), [#843](#843), [#789](#789), [#845](#845), [#849](#849), [#855](#855), [#856](#856) + Add accessors which allow multi-precision kernels, among other things. [#643](#643), [#708](#708) + Add support for mixed precision operations through apply in all LinOps. [#677](#677) + Add incomplete Cholesky factorizations and preconditioners as well as some improvements to ILU. [#672](#672), [#837](#837), [#846](#846) + Add an AMGX implementation and kernels on all devices but DPC++. [#528](#528), [#695](#695), [#860](#860) + Add a new mixed-precision capability solver, Compressed Basis GMRES (CB-GMRES). [#693](#693), [#763](#763) + Add the IDR(s) solver. [#620](#620) + Add a new fixed-size block CSR matrix format (for the Reference executor). [#671](#671), [#730](#730) + Add native mixed-precision support to the ELL format. [#717](#717), [#780](#780) + Add Reverse Cuthill-McKee reordering [#500](#500), [#649](#649) + Add matrix assembly support on CPUs. [#644](#644) + Extends ISAI from triangular to general and spd matrices. [#690](#690) Other additions: + Add the possibility to apply real matrices to complex vectors. [#655](#655), [#658](#658) + Add functions to compute the absolute of a matrix format. [#636](#636) + Add symmetric permutation and improve existing permutations. [#684](#684), [#657](#657), [#663](#663) + Add a MachineTopology class with HWLOC support [#554](#554), [#697](#697) + Add an implicit residual norm criterion. [#702](#702), [#818](#818), [#850](#850) + Row-major accessor is generalized to more than 2 dimensions and a new "block column-major" accessor has been added. [#707](#707) + Add an heat equation example. [#698](#698), [#706](#706) + Add ccache support in CMake and CI. [#725](#725), [#739](#739) + Allow tuning and benchmarking variables non intrusively. [#692](#692) + Add triangular solver benchmark [#664](#664) + Add benchmarks for BLAS operations [#772](#772), [#829](#829) + Add support for different precisions and consistent index types in benchmarks. [#675](#675), [#828](#828) + Add a Github bot system to facilitate development and PR management. [#667](#667), [#674](#674), [#689](#689), [#853](#853) + Add Intel (DPC++) CI support and enable CI on HPC systems. [#736](#736), [#751](#751), [#781](#781) + Add ssh debugging for Github Actions CI. [#749](#749) + Add pipeline segmentation for better CI speed. [#737](#737) Changes: + Add a Scalar Jacobi specialization and kernels. [#808](#808), [#834](#834), [#854](#854) + Add implicit residual log for solvers and benchmarks. [#714](#714) + Change handling of the conjugate in the dense dot product. [#755](#755) + Improved Dense stride handling. [#774](#774) + Multiple improvements to the OpenMP kernels performance, including COO, an exclusive prefix sum, and more. [#703](#703), [#765](#765), [#740](#740) + Allow specialization of submatrix and other dense creation functions in solvers. [#718](#718) + Improved Identity constructor and treatment of rectangular matrices. [#646](#646) + Allow CUDA/HIP executors to select allocation mode. [#758](#758) + Check if executors share the same memory. [#670](#670) + Improve test install and smoke testing support. [#721](#721) + Update the JOSS paper citation and add publications in the documentation. [#629](#629), [#724](#724) + Improve the version output. [#806](#806) + Add some utilities for dim and span. [#821](#821) + Improved solver and preconditioner benchmarks. [#660](#660) + Improve benchmark timing and output. [#669](#669), [#791](#791), [#801](#801), [#812](#812) Fixes: + Sorting fix for the Jacobi preconditioner. [#659](#659) + Also log the first residual norm in CGS [#735](#735) + Fix BiCG and HIP CSR to work with complex matrices. [#651](#651) + Fix Coo SpMV on strided vectors. [#807](#807) + Fix segfault of extract_diagonal, add short-and-fat test. [#769](#769) + Fix device_reset issue by moving counter/mutex to device. [#810](#810) + Fix `EnableLogging` superclass. [#841](#841) + Support ROCm 4.1.x and breaking HIP_PLATFORM changes. [#726](#726) + Decreased test size for a few device tests. [#742](#742) + Fix multiple issues with our CMake HIP and RPATH setup. [#712](#712), [#745](#745), [#709](#709) + Cleanup our CMake installation step. [#713](#713) + Various simplification and fixes to the Windows CMake setup. [#720](#720), [#785](#785) + Simplify third-party integration. [#786](#786) + Improve Ginkgo device arch flags management. [#696](#696) + Other fixes and improvements to the CMake setup. [#685](#685), [#792](#792), [#705](#705), [#836](#836) + Clarification of dense norm documentation [#784](#784) + Various development tools fixes and improvements [#738](#738), [#830](#830), [#840](#840) + Make multiple operators/constructors explicit. [#650](#650), [#761](#761) + Fix some issues, memory leaks and warnings found by MSVC. [#666](#666), [#731](#731) + Improved solver memory estimates and consistent iteration counts [#691](#691) + Various logger improvements and fixes [#728](#728), [#743](#743), [#754](#754) + Fix for ForwardIterator requirements in iterator_factory. [#665](#665) + Various benchmark fixes. [#647](#647), [#673](#673), [#722](#722) + Various CI fixes and improvements. [#642](#642), [#641](#641), [#795](#795), [#783](#783), [#793](#793), [#852](#852) Related PR: #857
Release 1.4.0 to master The Ginkgo team is proud to announce the new Ginkgo minor release 1.4.0. This release brings most of the Ginkgo functionality to the Intel DPC++ ecosystem which enables Intel-GPU and CPU execution. The only Ginkgo features which have not been ported yet are some preconditioners. Ginkgo's mixed-precision support is greatly enhanced thanks to: 1. The new Accessor concept, which allows writing kernels featuring on-the-fly memory compression, among other features. The accessor can be used as header-only, see the [accessor BLAS benchmarks repository](https://github.com/ginkgo-project/accessor-BLAS/tree/develop) as a usage example. 2. All LinOps now transparently support mixed-precision execution. By default, this is done through a temporary copy which may have a performance impact but already allows mixed-precision research. Native mixed-precision ELL kernels are implemented which do not see this cost. The accessor is also leveraged in a new CB-GMRES solver which allows for performance improvements by compressing the Krylov basis vectors. Many other features have been added to Ginkgo, such as reordering support, a new IDR solver, Incomplete Cholesky preconditioner, matrix assembly support (only CPU for now), machine topology information, and more! Supported systems and requirements: + For all platforms, cmake 3.13+ + C++14 compliant compiler + Linux and MacOS + gcc: 5.3+, 6.3+, 7.3+, all versions after 8.1+ + clang: 3.9+ + Intel compiler: 2018+ + Apple LLVM: 8.0+ + CUDA module: CUDA 9.0+ + HIP module: ROCm 3.5+ + DPC++ module: Intel OneAPI 2021.3. Set the CXX compiler to `dpcpp`. + Windows + MinGW and Cygwin: gcc 5.3+, 6.3+, 7.3+, all versions after 8.1+ + Microsoft Visual Studio: VS 2019 + CUDA module: CUDA 9.0+, Microsoft Visual Studio + OpenMP module: MinGW or Cygwin. Algorithm and important feature additions: + Add a new DPC++ Executor for SYCL execution and other base utilities [#648](#648), [#661](#661), [#757](#757), [#832](#832) + Port matrix formats, solvers and related kernels to DPC++. For some kernels, also make use of a shared kernel implementation for all executors (except Reference). [#710](#710), [#799](#799), [#779](#779), [#733](#733), [#844](#844), [#843](#843), [#789](#789), [#845](#845), [#849](#849), [#855](#855), [#856](#856) + Add accessors which allow multi-precision kernels, among other things. [#643](#643), [#708](#708) + Add support for mixed precision operations through apply in all LinOps. [#677](#677) + Add incomplete Cholesky factorizations and preconditioners as well as some improvements to ILU. [#672](#672), [#837](#837), [#846](#846) + Add an AMGX implementation and kernels on all devices but DPC++. [#528](#528), [#695](#695), [#860](#860) + Add a new mixed-precision capability solver, Compressed Basis GMRES (CB-GMRES). [#693](#693), [#763](#763) + Add the IDR(s) solver. [#620](#620) + Add a new fixed-size block CSR matrix format (for the Reference executor). [#671](#671), [#730](#730) + Add native mixed-precision support to the ELL format. [#717](#717), [#780](#780) + Add Reverse Cuthill-McKee reordering [#500](#500), [#649](#649) + Add matrix assembly support on CPUs. [#644](#644) + Extends ISAI from triangular to general and spd matrices. [#690](#690) Other additions: + Add the possibility to apply real matrices to complex vectors. [#655](#655), [#658](#658) + Add functions to compute the absolute of a matrix format. [#636](#636) + Add symmetric permutation and improve existing permutations. [#684](#684), [#657](#657), [#663](#663) + Add a MachineTopology class with HWLOC support [#554](#554), [#697](#697) + Add an implicit residual norm criterion. [#702](#702), [#818](#818), [#850](#850) + Row-major accessor is generalized to more than 2 dimensions and a new "block column-major" accessor has been added. [#707](#707) + Add an heat equation example. [#698](#698), [#706](#706) + Add ccache support in CMake and CI. [#725](#725), [#739](#739) + Allow tuning and benchmarking variables non intrusively. [#692](#692) + Add triangular solver benchmark [#664](#664) + Add benchmarks for BLAS operations [#772](#772), [#829](#829) + Add support for different precisions and consistent index types in benchmarks. [#675](#675), [#828](#828) + Add a Github bot system to facilitate development and PR management. [#667](#667), [#674](#674), [#689](#689), [#853](#853) + Add Intel (DPC++) CI support and enable CI on HPC systems. [#736](#736), [#751](#751), [#781](#781) + Add ssh debugging for Github Actions CI. [#749](#749) + Add pipeline segmentation for better CI speed. [#737](#737) Changes: + Add a Scalar Jacobi specialization and kernels. [#808](#808), [#834](#834), [#854](#854) + Add implicit residual log for solvers and benchmarks. [#714](#714) + Change handling of the conjugate in the dense dot product. [#755](#755) + Improved Dense stride handling. [#774](#774) + Multiple improvements to the OpenMP kernels performance, including COO, an exclusive prefix sum, and more. [#703](#703), [#765](#765), [#740](#740) + Allow specialization of submatrix and other dense creation functions in solvers. [#718](#718) + Improved Identity constructor and treatment of rectangular matrices. [#646](#646) + Allow CUDA/HIP executors to select allocation mode. [#758](#758) + Check if executors share the same memory. [#670](#670) + Improve test install and smoke testing support. [#721](#721) + Update the JOSS paper citation and add publications in the documentation. [#629](#629), [#724](#724) + Improve the version output. [#806](#806) + Add some utilities for dim and span. [#821](#821) + Improved solver and preconditioner benchmarks. [#660](#660) + Improve benchmark timing and output. [#669](#669), [#791](#791), [#801](#801), [#812](#812) Fixes: + Sorting fix for the Jacobi preconditioner. [#659](#659) + Also log the first residual norm in CGS [#735](#735) + Fix BiCG and HIP CSR to work with complex matrices. [#651](#651) + Fix Coo SpMV on strided vectors. [#807](#807) + Fix segfault of extract_diagonal, add short-and-fat test. [#769](#769) + Fix device_reset issue by moving counter/mutex to device. [#810](#810) + Fix `EnableLogging` superclass. [#841](#841) + Support ROCm 4.1.x and breaking HIP_PLATFORM changes. [#726](#726) + Decreased test size for a few device tests. [#742](#742) + Fix multiple issues with our CMake HIP and RPATH setup. [#712](#712), [#745](#745), [#709](#709) + Cleanup our CMake installation step. [#713](#713) + Various simplification and fixes to the Windows CMake setup. [#720](#720), [#785](#785) + Simplify third-party integration. [#786](#786) + Improve Ginkgo device arch flags management. [#696](#696) + Other fixes and improvements to the CMake setup. [#685](#685), [#792](#792), [#705](#705), [#836](#836) + Clarification of dense norm documentation [#784](#784) + Various development tools fixes and improvements [#738](#738), [#830](#830), [#840](#840) + Make multiple operators/constructors explicit. [#650](#650), [#761](#761) + Fix some issues, memory leaks and warnings found by MSVC. [#666](#666), [#731](#731) + Improved solver memory estimates and consistent iteration counts [#691](#691) + Various logger improvements and fixes [#728](#728), [#743](#743), [#754](#754) + Fix for ForwardIterator requirements in iterator_factory. [#665](#665) + Various benchmark fixes. [#647](#647), [#673](#673), [#722](#722) + Various CI fixes and improvements. [#642](#642), [#641](#641), [#795](#795), [#783](#783), [#793](#793), [#852](#852) Related PR: #866
This PR adds the dpcpp ported ELL and the porting script
For review before merging dense, the https://github.com/ginkgo-project/ginkgo/pull/779/files/7ac6d0909f006b52c5516e63b50cf0dff6b18012..3fc8bea0d5d6f81ef4be661aade1254ad1d54355 changes only contains the ell part
TODO: