Skip to content

Commit

Permalink
fix ic10
Browse files Browse the repository at this point in the history
  • Loading branch information
zhanglei1949 committed Sep 1, 2023
1 parent 5522737 commit f22a8c1
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 17 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/hqps-db-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@ jobs:
cd ${GITHUB_WORKSPACE}/flex/bin
# for i in 1 2 3 5 6 7 8 9 10 11 12;
for i in 10;
for i in 13;
do
cmd="./load_plan_and_gen.sh -e=hqps -i=../resources/queries/ic/adhoc/ic${i}_adhoc.cypher -w=/tmp/codgen/"
cmd=${cmd}" -o=/tmp/plugin --ir_conf=/tmp/ir.compiler.properties "
Expand Down
2 changes: 1 addition & 1 deletion flex/engines/hqps_db/core/operator/group_by.h
Original file line number Diff line number Diff line change
Expand Up @@ -480,7 +480,7 @@ class GroupByOp {
size_t ind = 0;
if (key_tuple_set.find(key_tuple) != key_tuple_set.end()) {
// already exist
auto ind = key_tuple_set[key_tuple];
ind = key_tuple_set[key_tuple];
} else {
// not exist
ind = cur_ind++;
Expand Down
24 changes: 9 additions & 15 deletions flex/tests/hqps/ic10_adhoc.h
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ struct IC10Adhocleft_left_left_expr3 {
IC10Adhocleft_left_left_expr3() {}

inline auto operator()(int64_t var0, int64_t var1, int64_t var2) const {
return var0 - var1 - var2;
return var0 - (var1 - var2);
}

private:
Expand Down Expand Up @@ -167,15 +167,6 @@ class IC10Adhoc : public HqpsAppBase<gs::MutableCSRInterface> {
graph, std::move(left_left_left_ctx2),
std::move(left_left_left_edge_expand_opt4));

{
size_t cnt = 0;
for (auto iter : left_left_left_ctx3) {
VLOG(10) << "before antijoin: " << gs::to_string(iter.GetAllElement());
cnt += 1;
}
VLOG(10) << "before antijoin: " << cnt;
}

// scan from start person
auto left_left_right_expr0 = gs::make_filter(
IC10Adhocleft_left_right_expr0(), gs::PropertySelector<int64_t>("id"));
Expand Down Expand Up @@ -207,10 +198,11 @@ class IC10Adhoc : public HqpsAppBase<gs::MutableCSRInterface> {
{
size_t cnt = 0;
for (auto iter : left_left_left_ctx4) {
VLOG(10) << "After antijoin: " << gs::to_string(iter.GetAllElement());
VLOG(10) << "After remove 1-hop friends: "
<< gs::to_string(iter.GetAllElement());
cnt += 1;
}
VLOG(10) << "After antijoin: " << cnt;
VLOG(10) << "After remove 1-hop friends: " << cnt;
}

auto left_left_left_expr3 =
Expand All @@ -229,7 +221,7 @@ class IC10Adhoc : public HqpsAppBase<gs::MutableCSRInterface> {
<< gs::to_string(iter.GetAllElement());
cnt += 1;
}
VLOG(10) << "After select: " << cnt;
VLOG(10) << "After filter the start person: " << cnt;
}

auto left_left_left_ctx6 = Engine::Project<PROJ_TO_NEW>(
Expand All @@ -251,6 +243,7 @@ class IC10Adhoc : public HqpsAppBase<gs::MutableCSRInterface> {
}
VLOG(10) << "before select: " << cnt;
}

auto left_left_left_expr4 = gs::make_filter(
IC10Adhocleft_left_left_expr2(), gs::PropertySelector<Date>("None"),
gs::PropertySelector<Date>("None"), gs::PropertySelector<Date>("None"),
Expand Down Expand Up @@ -294,8 +287,9 @@ class IC10Adhoc : public HqpsAppBase<gs::MutableCSRInterface> {
auto left_right_ctx0 = Engine::template ScanVertex<gs::AppendOpt::Persist>(
graph, 3, Filter<TruePredicate>());

auto left_right_edge_expand_opt0 = gs::make_edge_expandv_opt(
gs::Direction::Out, (label_id_t) 0, (label_id_t) 1);
auto left_right_edge_expand_opt0 =
gs::make_edge_expandv_opt(gs::Direction::Out, (label_id_t) 0,
(label_id_t) 1); // hasCreator->person
auto left_right_ctx1 =
Engine::template EdgeExpandV<gs::AppendOpt::Temp, INPUT_COL_ID(0)>(
graph, std::move(left_right_ctx0),
Expand Down

0 comments on commit f22a8c1

Please sign in to comment.