PAM
PAM copied to clipboard
Compiler errors on GCC 10.1
Configuration: x86-64, CentOS 7
-- --------------- General configuration -------------
-- CMake Generator: Ninja
-- Compiler: GNU 10.1.0
-- Build type: Release
I'm seeing 3 error(s):
/home/praja002/OpenSource/PAM/examples/tpch/queries/Q10.h:25:43: **error:** ‘group_by_and_combine’ is not a member of ‘parlay::internal’
25 | sequence<kf_pair> r = parlay::internal::group_by_and_combine(elts, parlay::addm<float>());
| ^~~~~~~~~~~~~~~~~~~~
In file included from /home/praja002/OpenSource/PAM/examples/tpch/queries/queries.h:25,
from /home/praja002/OpenSource/PAM/examples/tpch/test.cpp:26:
/home/praja002/OpenSource/PAM/examples/tpch/queries/Q15.h: In function ‘Q15_rtype Q15(maps, const char*, const char*)’:
/home/praja002/OpenSource/PAM/examples/tpch/queries/Q15.h:30:21: **error:** no matching function for call to ‘collect_reduce(parlay::sequence<std::pair<unsigned int, float> >&, Q15(maps, const char*, const char*)::<lambda(const sr_type&)>&, Q15(maps, const char*, const char*)::<lambda(const sr_type&)>&, parlay::addm<double>, int&)’
30 | max_supp_id);
| ^
In file included from /usr/local/include/parlay/internal/group_by.h:17,
from /usr/local/include/parlay/primitives.h:897,
from /home/praja002/OpenSource/PAM/examples/tpch/lineitem.h:1,
from /home/praja002/OpenSource/PAM/examples/tpch/test.cpp:5:
/usr/local/include/parlay/internal/collect_reduce.h:162:6: note: candidate: ‘template<class Seq, class Helper> auto parlay::internal::collect_reduce(const Seq&, const Helper&, size_t)’
162 | auto collect_reduce(Seq const &A, Helper const &helper, size_t num_buckets) {
| ^~~~~~~~~~~~~~
/usr/local/include/parlay/internal/collect_reduce.h:162:6: note: template argument deduction/substitution failed:
In file included from /home/praja002/OpenSource/PAM/examples/tpch/queries/queries.h:25,
from /home/praja002/OpenSource/PAM/examples/tpch/test.cpp:26:
/home/praja002/OpenSource/PAM/examples/tpch/queries/Q15.h:30:21: note: candidate expects 3 arguments, 5 provided
30 | max_supp_id);
| ^
In file included from /home/praja002/OpenSource/PAM/examples/tpch/queries/queries.h:32,
from /home/praja002/OpenSource/PAM/examples/tpch/test.cpp:26:
/home/praja002/OpenSource/PAM/examples/tpch/queries/Q22.h: In function ‘Q22_rtype Q22(maps, bool, uchar*)’:
/home/praja002/OpenSource/PAM/examples/tpch/queries/Q22.h:58:7: **error:** no matching function for call to ‘collect_reduce(parlay::sequence<std::tuple<float, unsigned char, bool> >&, Q22(maps, bool, uchar*)::<lambda(a_type)>&, Q22(maps, bool, uchar*)::<lambda(a_type)>&, parlay::monoid<parlay::pair_monoid<parlay::addm<int>, parlay::addm<double> >::<lambda(P, P)>, std::pair<int, double> >, int)’
58 | 32);
| ^
In file included from /usr/local/include/parlay/internal/group_by.h:17,
from /usr/local/include/parlay/primitives.h:897,
from /home/praja002/OpenSource/PAM/examples/tpch/lineitem.h:1,
from /home/praja002/OpenSource/PAM/examples/tpch/test.cpp:5:
/usr/local/include/parlay/internal/collect_reduce.h:162:6: note: candidate: ‘template<class Seq, class Helper> auto parlay::internal::collect_reduce(const Seq&, const Helper&, size_t)’
162 | auto collect_reduce(Seq const &A, Helper const &helper, size_t num_buckets) {
| ^~~~~~~~~~~~~~
/usr/local/include/parlay/internal/collect_reduce.h:162:6: note: template argument deduction/substitution failed:
In file included from /home/praja002/OpenSource/PAM/examples/tpch/queries/queries.h:32,
from /home/praja002/OpenSource/PAM/examples/tpch/test.cpp:26:
/home/praja002/OpenSource/PAM/examples/tpch/queries/Q22.h:58:7: note: candidate expects 3 arguments, 5 provided
58 | 32);
Also, on compiling with clang on MacOS, I get the following warning (After commenting out the #include<parallel/algorithm>, since clang doesn't have support for it yet):
/Users/payasr/OpenSource/PAM/include/pam/utils.h:70:7: warning: 'memcpy' will always overflow; destination buffer has size 4, but size argument is 8 [-Wfortify-source]
memcpy(&r_nval, &newval, sizeof(ET));
Hi,
For the first problem, it looks like it's because parlaylib changed the interface of collect_reduce (the three queries all use collect_reduce). You could try this:
https://github.com/cmuparlay/PAM/releases/tag/V1
with using pbbslib, which is available here:
https://github.com/cmuparlay/pbbslib
I will also try to fix the new version.