From 7d0bfedbfe5f39c087b2d28a3885c0283a99b942 Mon Sep 17 00:00:00 2001 From: Yee <2520865+yixinglu@users.noreply.github.com> Date: Fri, 3 Dec 2021 11:29:53 +0800 Subject: [PATCH 1/2] Increase the number of jobs at compile time (#3401) --- .github/workflows/nightly.yml | 4 +--- .github/workflows/pull_request.yml | 6 +----- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/.github/workflows/nightly.yml b/.github/workflows/nightly.yml index f5e7f5f3f19..19004ffab4c 100644 --- a/.github/workflows/nightly.yml +++ b/.github/workflows/nightly.yml @@ -126,12 +126,10 @@ jobs: -DENABLE_COVERAGE=on \ -B build echo "::set-output name=j::8" - echo "::set-output name=t::6" - name: Make run: | ccache -z - cmake --build build/ -j ${{ steps.cmake.outputs.j }} --target nebula-metad nebula-storaged nebula-graphd - cmake --build build/ -j ${{ steps.cmake.outputs.t }} + cmake --build build/ -j $(nproc) ccache -s - name: CTest env: diff --git a/.github/workflows/pull_request.yml b/.github/workflows/pull_request.yml index 7757ba606d2..08bfd000fbc 100644 --- a/.github/workflows/pull_request.yml +++ b/.github/workflows/pull_request.yml @@ -97,7 +97,6 @@ jobs: -DENABLE_TESTING=on \ -B build echo "::set-output name=j::10" - echo "::set-output name=t::$(nproc)" ;; ubuntu2004) # build with Debug type @@ -109,7 +108,6 @@ jobs: -DENABLE_COVERAGE=on \ -B build echo "::set-output name=j::10" - echo "::set-output name=t::6" ;; esac ;; @@ -123,14 +121,12 @@ jobs: -DENABLE_TESTING=on \ -B build echo "::set-output name=j::6" - echo "::set-output name=t::10" ;; esac - name: Make run: | ccache -z - cmake --build build/ -j $(nproc) --target nebula-metad nebula-storaged nebula-graphd - cmake --build build/ -j ${{ steps.cmake.outputs.t }} + cmake --build build/ -j $(nproc) ccache -s - name: CTest env: From 69bd48f392578f7f9c222af6a960c92623d9e342 Mon Sep 17 00:00:00 2001 From: "kyle.cao" Date: Fri, 3 Dec 2021 15:16:51 +0800 Subject: [PATCH 2/2] fix evaluableExprVisitor (#3389) --- src/graph/visitor/EvaluableExprVisitor.h | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/graph/visitor/EvaluableExprVisitor.h b/src/graph/visitor/EvaluableExprVisitor.h index 6e8aec319f3..9c1beb7c7d8 100644 --- a/src/graph/visitor/EvaluableExprVisitor.h +++ b/src/graph/visitor/EvaluableExprVisitor.h @@ -56,6 +56,14 @@ class EvaluableExprVisitor : public ExprVisitorImpl { void visit(SubscriptRangeExpression *) override { isEvaluable_ = false; } + void visitBinaryExpr(BinaryExpression *expr) override { + expr->left()->accept(this); + // Evaluable sub-expression should be obscured by the non-evaluable sub-expression. + if (isEvaluable_) { + expr->right()->accept(this); + } + } + bool isEvaluable_{true}; };