Closed xq114 closed 3 weeks ago
To make it short: We don't really support 32bit builds, since pure 32 bit CPUs are rather uncommon nowadays
Same error exists on WebAssembly:
/home/runner/ginkgo/v1.7.0/source/core/reorder/amd.cpp:188:20: error: non-constant-expression cannot be narrowed from type 'value_type' (aka 'long long') to 'size_type' (aka 'unsigned long') in initializer list [-Wc++11-narrowing]
host_exec, col_idxs_plus_workspace_size + 6 * num_rows};
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/home/runner/ginkgo/v1.7.0/source/core/reorder/amd.cpp:220:37: note: in instantiation of member function 'gko::experimental::reorder::Amd<long long>::generate_impl' requested here
GKO_INSTANTIATE_FOR_EACH_INDEX_TYPE(GKO_DECLARE_AMD);
^
/home/runner/ginkgo/v1.7.0/source/core/reorder/amd.cpp:188:20: note: insert an explicit cast to silence this issue
host_exec, col_idxs_plus_workspace_size + 6 * num_rows};
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
static_cast<size_type>( )
1 error generated.
I think it will do no harm to support as more platform as possible. Anyway, the fix is straightforward as gcc supposes: add a static_cast<size_type>()
to amd.cpp. if there is a need, I can make a pr
When I try to build ginkgo release 1.7.0 on x86 windows, I got this error:
https://github.com/ginkgo-project/ginkgo/blob/v1.7.0/core/reorder/amd.cpp#L188
It seems there should be an explicit conversion.