From patchwork Tue Oct 20 13:40:58 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alex Vandiver X-Patchwork-Id: 11846975 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.6 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 21D1DC4363A for ; Tue, 20 Oct 2020 13:41:11 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id BB6F422250 for ; Tue, 20 Oct 2020 13:41:10 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="YuCQCO1g" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2407557AbgJTNlJ (ORCPT ); Tue, 20 Oct 2020 09:41:09 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60670 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2407508AbgJTNlJ (ORCPT ); Tue, 20 Oct 2020 09:41:09 -0400 Received: from mail-wr1-x441.google.com (mail-wr1-x441.google.com [IPv6:2a00:1450:4864:20::441]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A77C3C061755 for ; Tue, 20 Oct 2020 06:41:08 -0700 (PDT) Received: by mail-wr1-x441.google.com with SMTP id n6so2179782wrm.13 for ; Tue, 20 Oct 2020 06:41:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:in-reply-to:references:from:date:subject:fcc :content-transfer-encoding:mime-version:to:cc; bh=0cKnq3ai3qJJvReanp+IwPBsXPj7SOWushngrvWxycE=; b=YuCQCO1gX3ngO3LQD2boPSNkp6FOGW4TVqmC+AISi/l8F+9WcrbstnqztEsV/lHxEU LaURfbt1aokvdJDJVip9JbrDHDTGCZFrJu5geGN9DicIfhFpPROhk+xzWKEs/oDzDlI3 2qsvBoyVgQ5ITuL90jlDO4UZY77u1CY7W4Mk65AEC8YmyTSf76YW4X8hXrl+3554Ouji wDd/qMh6rbNBZCFBW0xHnL0WnySmsrSkSw9cIkfxYKkLmT7V1vElisz/oyZk/0iXds5u isF/+3Jy9iiDrjTBTUl9HR+DHIX1GbG7dQuUtuXG76qnfcK6fUC6dyInmLylFmoHgha8 8i8Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:in-reply-to:references:from:date :subject:fcc:content-transfer-encoding:mime-version:to:cc; bh=0cKnq3ai3qJJvReanp+IwPBsXPj7SOWushngrvWxycE=; b=j5hmH5f4WfAdekvjGie0VIvdAYcp2OXamDP6VG7Kx6TmA6ERaIVSYrWLByNxxWz41V Xn/mEid1TlMOUutOFmYZv22G0j5+aAYyE8SFKkuKkeiq5yKWrZIicydZvp18x0QZ8DrG Hl2z9Uon7rky+4pTDj9MKSK07tv7FKQUgb6gkcYlXq3BNfE5YKxCeNdSjSLoBfkQZjOt NW5mFA5yvB2M9H+e9FjUh8ydYqYcm+z7HPERBzDaKVV/xt983bMeyYX8KeG8k8qJqVC6 kzAXHncvp9RRNWXWPAzbIuguC1ilMs/LQjR4WyBcrk6KRXcvdEHkUtl57pvuNhkInuZM WGnQ== X-Gm-Message-State: AOAM533xPOjKgKcIqbPDSb352yLBl0GioT2WUK+4vNHj9UPDiFtNx14R Hx2wkWDRO60Ri9prvMubODz/OWPC+zc= X-Google-Smtp-Source: ABdhPJyAdybaULnBV489nPAL82quggQ+8Erv0hyjDV/9khz07bmZnqxPqwOR+Y7suA6ESSdcGJjawQ== X-Received: by 2002:adf:f88a:: with SMTP id u10mr3608762wrp.1.1603201267101; Tue, 20 Oct 2020 06:41:07 -0700 (PDT) Received: from [127.0.0.1] ([13.74.141.28]) by smtp.gmail.com with ESMTPSA id g144sm3051985wmg.30.2020.10.20.06.41.06 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 06:41:06 -0700 (PDT) Message-Id: In-Reply-To: References: Date: Tue, 20 Oct 2020 13:40:58 +0000 Subject: [PATCH v4 1/7] fsmonitor: use fsmonitor data in `git diff` Fcc: Sent MIME-Version: 1.0 To: git@vger.kernel.org Cc: Derrick Stolee , Utsav Shah , Nipunn Koorapati , Nipunn Koorapati , Taylor Blau , Nipunn Koorapati , Alex Vandiver Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org From: Alex Vandiver From: Alex Vandiver With fsmonitor enabled, the first call to match_stat_with_submodule calls refresh_fsmonitor, incurring the overhead of reading the list of updated files -- but run_diff_files does not respect the CE_FSMONITOR_VALID flag. Make use of the fsmonitor extension to skip lstat() calls on files that fsmonitor judged as unmodified. Notably, this change improves performance of the git shell prompt when GIT_PS1_SHOWDIRTYSTATE is set. Signed-off-by: Alex Vandiver Signed-off-by: Nipunn Koorapati --- diff-lib.c | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/diff-lib.c b/diff-lib.c index f95c6de75f..d2d31b9f82 100644 --- a/diff-lib.c +++ b/diff-lib.c @@ -97,6 +97,8 @@ int run_diff_files(struct rev_info *revs, unsigned int option) diff_set_mnemonic_prefix(&revs->diffopt, "i/", "w/"); + refresh_fsmonitor(istate); + if (diff_unmerged_stage < 0) diff_unmerged_stage = 2; entries = istate->cache_nr; @@ -197,8 +199,17 @@ int run_diff_files(struct rev_info *revs, unsigned int option) if (ce_uptodate(ce) || ce_skip_worktree(ce)) continue; - /* If CE_VALID is set, don't look at workdir for file removal */ - if (ce->ce_flags & CE_VALID) { + /* + * When CE_VALID is set (via "update-index --assume-unchanged" + * or via adding paths while core.ignorestat is set to true), + * the user has promised that the working tree file for that + * path will not be modified. When CE_FSMONITOR_VALID is true, + * the fsmonitor knows that the path hasn't been modified since + * we refreshed the cached stat information. In either case, + * we do not have to stat to see if the path has been removed + * or modified. + */ + if (ce->ce_flags & (CE_VALID | CE_FSMONITOR_VALID)) { changed = 0; newmode = ce->ce_mode; } else { From patchwork Tue Oct 20 13:41:00 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nipunn Koorapati X-Patchwork-Id: 11846979 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.6 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id C49F0C4363A for ; Tue, 20 Oct 2020 13:41:20 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 7468321D7B for ; Tue, 20 Oct 2020 13:41:20 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="dYj2FBhZ" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2407569AbgJTNlT (ORCPT ); Tue, 20 Oct 2020 09:41:19 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60682 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2407562AbgJTNlN (ORCPT ); Tue, 20 Oct 2020 09:41:13 -0400 Received: from mail-wm1-x344.google.com (mail-wm1-x344.google.com [IPv6:2a00:1450:4864:20::344]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 526AAC0613CE for ; Tue, 20 Oct 2020 06:41:10 -0700 (PDT) Received: by mail-wm1-x344.google.com with SMTP id k18so1929860wmj.5 for ; Tue, 20 Oct 2020 06:41:10 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:in-reply-to:references:from:date:subject:fcc :content-transfer-encoding:mime-version:to:cc; bh=Djf3TWO3UFcf03qpN2acJDVn06wf04grB536pabMBck=; b=dYj2FBhZdpaG67OBBRXvoFm29ZcBgDHN5ih9bBERrrFeXbFxAf2gvOkF23qDsMchAj vgKbjOYOLnUuqCHRceZQCG9kxhMuaqCRnCgldhFUb0gTxsxFljyuKkgYNWi7uUXyDDPR 8vUX6B8q6GQ284At8MfXLlfV9SwjZT+lIUk6DUYXv6tAMRDhtwfyVCJHxpdFKvfTgC04 g9YsdQNC29KUWrvIarphWMLsk/NjMVOW5LobnRBzhmFeuWDt8lbXC9vdRTCC76T61Y0W nxa2MbQhHJD6l4e2GWeQ1Igj1YqH3F/WTcdV7bodUqaAyo42xKzWzfumAsPwHB7bX9Qn ZpIA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:in-reply-to:references:from:date :subject:fcc:content-transfer-encoding:mime-version:to:cc; bh=Djf3TWO3UFcf03qpN2acJDVn06wf04grB536pabMBck=; b=lTCnW0byGJPxqHZ1v4vZ87Zabjx0VgVXkJ83rYtxAgZY1G9sPYNHNO8J6VuHTVNjAz zYXLuyu8X4QlkVCmEkUGbBS0LXuBgCo7gg3U6lkduGpDha8LBshwF+m7t6Rt+VwkAa2o v5o3/uOp2Y2iSZHCYuG4omhMAWthOUG3Od1t2LLP4+Fjf/kpz2zfPRIHuOfq1kK6prPD +zQDpe+N3m2ccZvU7+3TtPcy9tsiOYoktmdtaoT5y0Y8m7GXFaN+YQXw3Zc65xSvrQsY KvTR3LBmWFFfHMnAhdB93v4/HTq/hrCy3mYhun6152xmbjJUwLHGp9W8u7Ae4cq/nipp mDGA== X-Gm-Message-State: AOAM533CVf8/iS4VQW1bnpvr3YBWiSlYzsWcOAeS0HapnKctD70IgYHt SZbw+qLAyS7M5HBa3GB7R7JuY6/WGU0= X-Google-Smtp-Source: ABdhPJwyNbllWuCfHqlNntqkCSZNz2qoQSLTr+UXUqu3JJZcbRIuUXqNm1B0RitvhYEeSvYh0mfwHw== X-Received: by 2002:a05:600c:255:: with SMTP id 21mr3060417wmj.69.1603201268844; Tue, 20 Oct 2020 06:41:08 -0700 (PDT) Received: from [127.0.0.1] ([13.74.141.28]) by smtp.gmail.com with ESMTPSA id b5sm3084777wrs.97.2020.10.20.06.41.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 06:41:08 -0700 (PDT) Message-Id: <401f696c8156acafd1bf91511fde7ae099ff9052.1603201264.git.gitgitgadget@gmail.com> In-Reply-To: References: Date: Tue, 20 Oct 2020 13:41:00 +0000 Subject: [PATCH v4 3/7] t/perf/p7519-fsmonitor.sh: warm cache on first git status Fcc: Sent MIME-Version: 1.0 To: git@vger.kernel.org Cc: Derrick Stolee , Utsav Shah , Nipunn Koorapati , Nipunn Koorapati , Taylor Blau , Nipunn Koorapati , Nipunn Koorapati Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org From: Nipunn Koorapati From: Nipunn Koorapati The first git status would be inflated due to warming of filesystem cache. This makes the results comparable. Before Test this tree -------------------------------------------------------------------------------- 7519.2: status (fsmonitor=.git/hooks/fsmonitor-watchman) 2.52(1.59+1.56) 7519.3: status -uno (fsmonitor=.git/hooks/fsmonitor-watchman) 0.18(0.12+0.06) 7519.4: status -uall (fsmonitor=.git/hooks/fsmonitor-watchman) 1.36(0.73+0.62) 7519.7: status (fsmonitor=) 0.69(0.52+0.90) 7519.8: status -uno (fsmonitor=) 0.37(0.28+0.81) 7519.9: status -uall (fsmonitor=) 1.53(0.93+1.32) After Test this tree -------------------------------------------------------------------------------- 7519.2: status (fsmonitor=.git/hooks/fsmonitor-watchman) 0.39(0.33+0.06) 7519.3: status -uno (fsmonitor=.git/hooks/fsmonitor-watchman) 0.17(0.13+0.05) 7519.4: status -uall (fsmonitor=.git/hooks/fsmonitor-watchman) 1.34(0.77+0.56) 7519.7: status (fsmonitor=) 0.70(0.53+0.90) 7519.8: status -uno (fsmonitor=) 0.37(0.32+0.78) 7519.9: status -uall (fsmonitor=) 1.55(1.01+1.25) Signed-off-by: Nipunn Koorapati --- t/perf/p7519-fsmonitor.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/t/perf/p7519-fsmonitor.sh b/t/perf/p7519-fsmonitor.sh index def7ecdbc7..9313d4a51d 100755 --- a/t/perf/p7519-fsmonitor.sh +++ b/t/perf/p7519-fsmonitor.sh @@ -114,7 +114,8 @@ test_expect_success "setup for fsmonitor" ' fi && git config core.fsmonitor "$INTEGRATION_SCRIPT" && - git update-index --fsmonitor + git update-index --fsmonitor && + git status # Warm caches ' if test -n "$GIT_PERF_7519_DROP_CACHE"; then From patchwork Tue Oct 20 13:41:01 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nipunn Koorapati X-Patchwork-Id: 11846977 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.6 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id A0699C4363A for ; Tue, 20 Oct 2020 13:41:29 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 4A40E21D7B for ; Tue, 20 Oct 2020 13:41:29 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="qVEppYyO" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2407521AbgJTNlY (ORCPT ); Tue, 20 Oct 2020 09:41:24 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60684 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2407559AbgJTNlM (ORCPT ); Tue, 20 Oct 2020 09:41:12 -0400 Received: from mail-wr1-x441.google.com (mail-wr1-x441.google.com [IPv6:2a00:1450:4864:20::441]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A1B8BC061755 for ; Tue, 20 Oct 2020 06:41:11 -0700 (PDT) Received: by mail-wr1-x441.google.com with SMTP id n6so2179998wrm.13 for ; Tue, 20 Oct 2020 06:41:11 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:in-reply-to:references:from:date:subject:fcc :content-transfer-encoding:mime-version:to:cc; bh=Ty+osmufCYHp5UuwM+HiHearrRr3lEPv9V0tXUxBAZ8=; b=qVEppYyOvBYbuWyvWVY92tJ0OnhCnTwKAceYiYRfvS4Z3uJYTKvpGpxNPXhP1uFJNQ oi93RcnFkgeGuLMW/QMeojWCd//RUR51GZzt3Lqh5ptod0VxJXzTKpwE8L9yP1vTcqub JwE9uyOWPlKrV9YoqohCRx1Ds7obUCP8T7nDoVpAfaA2wFVTr0NT3RtF7sOnCkIwXtb7 JtzbqnJLB8acSxhc66j8jpNk4E+xIQjzv4PlizJeXGmACU4qy8Ek62wTv/BeXL4FOFCR 1ZOVNBeJsAJNCc4+2IAIrN494+0df9RAjzzL6nef6yaNCFyYww5WTGeQSQioyMQA4xnl MR/g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:in-reply-to:references:from:date :subject:fcc:content-transfer-encoding:mime-version:to:cc; bh=Ty+osmufCYHp5UuwM+HiHearrRr3lEPv9V0tXUxBAZ8=; b=GMPfG55yGcDy8zsI+OSAJBFBtXt7S7fYND6nOJVjlWzowF57lDfttY5DEWMFYBskNx V1HhrDtSvocDcvlAkBh7aUGaH9c8bNLrEnQaEOOp6lqyzN7oXl9NbFZJxs5qly+FYOKK cWvC/+h32XF6GRhceX8ksRB3SGcvKGLnGE0ED1rj1n8kMAp1djmB6TVxFpyi0To7MEAm BygmB8QSQNzF/rkv58YbXh7zR8lmCepMsN84ban7Mp2LqQdiIKEdiDokQl64yaWxoFWU eVJv+VwWmoebqEKhuMVW4bXkW1JvgjX2rvdvMXqafJ/iOy5USwv7TVUwWTROgi8nFfQD mwDw== X-Gm-Message-State: AOAM532jDr6224XLTrPt2ieQbA+8/Rt/TrXyXahzb32zqmKQNVloCwE/ StEQFouuj2ITn1dmFOIaAqyF+raOPoY= X-Google-Smtp-Source: ABdhPJy1/Ku37mQ+sVmgEDX2TRJFfdxlj9laenijxAirWQXd6r8qWRL5WpDXTYA6YgIL34Bi1Zr+hQ== X-Received: by 2002:adf:e549:: with SMTP id z9mr3856800wrm.12.1603201270081; Tue, 20 Oct 2020 06:41:10 -0700 (PDT) Received: from [127.0.0.1] ([13.74.141.28]) by smtp.gmail.com with ESMTPSA id a15sm3217266wro.3.2020.10.20.06.41.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 06:41:09 -0700 (PDT) Message-Id: In-Reply-To: References: Date: Tue, 20 Oct 2020 13:41:01 +0000 Subject: [PATCH v4 4/7] t/perf: add fsmonitor perf test for git diff Fcc: Sent MIME-Version: 1.0 To: git@vger.kernel.org Cc: Derrick Stolee , Utsav Shah , Nipunn Koorapati , Nipunn Koorapati , Taylor Blau , Nipunn Koorapati , Nipunn Koorapati Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org From: Nipunn Koorapati From: Nipunn Koorapati Results for the git-diff fsmonitor optimization in patch in the parent-rev (using a 400k file repo to test) As you can see here - git diff with fsmonitor running is significantly better with this patch series (80% faster on my workload)! GIT_PERF_LARGE_REPO=~/src/server ./run v2.29.0-rc1 . -- p7519-fsmonitor.sh Test v2.29.0-rc1 this tree ----------------------------------------------------------------------------------------------------------------- 7519.2: status (fsmonitor=.git/hooks/fsmonitor-watchman) 1.46(0.82+0.64) 1.47(0.83+0.62) +0.7% 7519.3: status -uno (fsmonitor=.git/hooks/fsmonitor-watchman) 0.16(0.12+0.04) 0.17(0.12+0.05) +6.3% 7519.4: status -uall (fsmonitor=.git/hooks/fsmonitor-watchman) 1.36(0.73+0.62) 1.37(0.76+0.60) +0.7% 7519.5: diff (fsmonitor=.git/hooks/fsmonitor-watchman) 0.85(0.22+0.63) 0.14(0.10+0.05) -83.5% 7519.6: diff -- 0_files (fsmonitor=.git/hooks/fsmonitor-watchman) 0.12(0.08+0.05) 0.13(0.11+0.02) +8.3% 7519.7: diff -- 10_files (fsmonitor=.git/hooks/fsmonitor-watchman) 0.12(0.08+0.04) 0.13(0.09+0.04) +8.3% 7519.8: diff -- 100_files (fsmonitor=.git/hooks/fsmonitor-watchman) 0.12(0.07+0.05) 0.13(0.07+0.06) +8.3% 7519.9: diff -- 1000_files (fsmonitor=.git/hooks/fsmonitor-watchman) 0.12(0.09+0.04) 0.13(0.08+0.05) +8.3% 7519.10: diff -- 10000_files (fsmonitor=.git/hooks/fsmonitor-watchman) 0.14(0.09+0.05) 0.13(0.10+0.03) -7.1% 7519.12: status (fsmonitor=) 1.67(0.93+1.49) 1.67(0.99+1.42) +0.0% 7519.13: status -uno (fsmonitor=) 0.37(0.30+0.82) 0.37(0.33+0.79) +0.0% 7519.14: status -uall (fsmonitor=) 1.58(0.97+1.35) 1.57(0.86+1.45) -0.6% 7519.15: diff (fsmonitor=) 0.34(0.28+0.83) 0.34(0.27+0.83) +0.0% 7519.16: diff -- 0_files (fsmonitor=) 0.09(0.06+0.04) 0.09(0.08+0.02) +0.0% 7519.17: diff -- 10_files (fsmonitor=) 0.09(0.07+0.03) 0.09(0.06+0.05) +0.0% 7519.18: diff -- 100_files (fsmonitor=) 0.09(0.06+0.04) 0.09(0.06+0.04) +0.0% 7519.19: diff -- 1000_files (fsmonitor=) 0.09(0.06+0.04) 0.09(0.05+0.05) +0.0% 7519.20: diff -- 10000_files (fsmonitor=) 0.10(0.08+0.04) 0.10(0.06+0.05) +0.0% I also added a benchmark for a tiny git diff workload w/ a pathspec. I see an approximately .02 second overhead added w/ and w/o fsmonitor From looking at these results, I suspected that refresh_fsmonitor is already happening during git diff - independent of this patch series' optimization. Confirmed that suspicion by breaking on refresh_fsmonitor. (gdb) bt [simplified] 0 refresh_fsmonitor at fsmonitor.c:176 1 ie_match_stat at read-cache.c:375 2 match_stat_with_submodule at diff-lib.c:237 4 builtin_diff_files at builtin/diff.c:260 5 cmd_diff at builtin/diff.c:541 6 run_builtin at git.c:450 7 handle_builtin at git.c:700 8 run_argv at git.c:767 9 cmd_main at git.c:898 10 main at common-main.c:52 Signed-off-by: Nipunn Koorapati --- t/perf/p7519-fsmonitor.sh | 71 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 71 insertions(+) diff --git a/t/perf/p7519-fsmonitor.sh b/t/perf/p7519-fsmonitor.sh index 9313d4a51d..ef4c3c8c5c 100755 --- a/t/perf/p7519-fsmonitor.sh +++ b/t/perf/p7519-fsmonitor.sh @@ -115,6 +115,13 @@ test_expect_success "setup for fsmonitor" ' git config core.fsmonitor "$INTEGRATION_SCRIPT" && git update-index --fsmonitor && + mkdir 1_file 10_files 100_files 1000_files 10000_files && + for i in $(test_seq 1 10); do touch 10_files/$i; done && + for i in $(test_seq 1 100); do touch 100_files/$i; done && + for i in $(test_seq 1 1000); do touch 1000_files/$i; done && + for i in $(test_seq 1 10000); do touch 10000_files/$i; done && + git add 1_file 10_files 100_files 1000_files 10000_files && + git commit -m "Add files" && git status # Warm caches ' @@ -142,6 +149,38 @@ test_perf "status -uall (fsmonitor=$INTEGRATION_SCRIPT)" ' git status -uall ' +if test -n "$GIT_PERF_7519_DROP_CACHE"; then + test-tool drop-caches +fi + +test_perf "diff (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff +' + +if test -n "$GIT_PERF_7519_DROP_CACHE"; then + test-tool drop-caches +fi + +test_perf "diff -- 0_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 1_file +' + +test_perf "diff -- 10_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 10_files +' + +test_perf "diff -- 100_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 100_files +' + +test_perf "diff -- 1000_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 1000_files +' + +test_perf "diff -- 10000_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 10000_files +' + test_expect_success "setup without fsmonitor" ' unset INTEGRATION_SCRIPT && git config --unset core.fsmonitor && @@ -172,6 +211,38 @@ test_perf "status -uall (fsmonitor=$INTEGRATION_SCRIPT)" ' git status -uall ' +if test -n "$GIT_PERF_7519_DROP_CACHE"; then + test-tool drop-caches +fi + +test_perf "diff (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff +' + +if test -n "$GIT_PERF_7519_DROP_CACHE"; then + test-tool drop-caches +fi + +test_perf "diff -- 0_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 1_file +' + +test_perf "diff -- 10_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 10_files +' + +test_perf "diff -- 100_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 100_files +' + +test_perf "diff -- 1000_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 1000_files +' + +test_perf "diff -- 10000_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 10000_files +' + if test_have_prereq WATCHMAN then watchman watch-del "$GIT_WORK_TREE" >/dev/null 2>&1 && From patchwork Tue Oct 20 13:41:03 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nipunn Koorapati X-Patchwork-Id: 11846981 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.6 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 11BB1C4363D for ; Tue, 20 Oct 2020 13:41:19 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id BCE0721741 for ; Tue, 20 Oct 2020 13:41:18 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="rQORHOq0" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2407567AbgJTNlR (ORCPT ); Tue, 20 Oct 2020 09:41:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60694 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2407566AbgJTNlP (ORCPT ); Tue, 20 Oct 2020 09:41:15 -0400 Received: from mail-wr1-x443.google.com (mail-wr1-x443.google.com [IPv6:2a00:1450:4864:20::443]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7B144C0613D3 for ; Tue, 20 Oct 2020 06:41:13 -0700 (PDT) Received: by mail-wr1-x443.google.com with SMTP id t9so2182341wrq.11 for ; Tue, 20 Oct 2020 06:41:13 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:in-reply-to:references:from:date:subject:fcc :content-transfer-encoding:mime-version:to:cc; bh=kRyxFYsdUp56FTApiMNfeHAgQPCyidPizX4u7iT/YYU=; b=rQORHOq0x5JswSSucwk3xFomxo0rzukeQ9BQ+ZQJg3abWmlTO/9zvoWwCKuJ1LCn8l Lhren33qh0jMFY+Dn2r3ga3Irk6xnnPPlvDBNodgZjBV45qOuS99bloXkR8V8u9K6awc zM66fEsmaZ2jT4zhtfGo+jOiTiPHA7bP9LuJC9SaeUL7o6E1NqqrpviQb04hEEvv84WD oLjs5N45XX2C8n9yH/jo80aik4HPqVi0XL6eMBWZcgzNo9vDhw3gtLnS0iRUl53Nqr/N pEUDvJL6xmOymM5yiqzeS/3G4AlgHJSNmrEtNlhBuGS0d0+KtXVxFGmgic/vQ0eIDJlP oBXg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:in-reply-to:references:from:date :subject:fcc:content-transfer-encoding:mime-version:to:cc; bh=kRyxFYsdUp56FTApiMNfeHAgQPCyidPizX4u7iT/YYU=; b=PaFWLy3vTL2V/6l50oGtXYYbhxGq4dICbK4jlxtbRs5zTRKj07jU8RM5JPxz+6011I UQixYCZMSEW1sVTn97wjsztbPxh6Ppx9K27EiF6skgEzeoHvKadYZ09ZZJqMBJk4Oxfr 7x66goCsXcklebtJwvP9ibq3d+YNvEZf1pvVfgMnKiJoLiMIoG3JEg1c9Ib7ONeXLn2a XmkWRlsTWvaR0lJjwwvVVPQr3L1Yy2seDb7DKw/F7tGBUhPzsvrt4ZiZfppVpL56dGgz lGWKJ6FNnrURBvM5CXV2QaLLxhnvaxFwiblfdlJz2x1eJA/9El8qUtzwniAaB/vO0Wly ujgA== X-Gm-Message-State: AOAM533UPHklFBMCKnWQB0EoP/KaK7QVKfgvl714lZGbv/LbwCSUIEuL O0USSb+lnYWqG1ACtulqL7/WcSnTpeI= X-Google-Smtp-Source: ABdhPJyX621cWNnuamr2DkoSXEao67woFGkr0lylnJh1xgLf+22AvqJw0N245JvILq5ywnlFOB7r6A== X-Received: by 2002:adf:fd07:: with SMTP id e7mr3444284wrr.377.1603201271907; Tue, 20 Oct 2020 06:41:11 -0700 (PDT) Received: from [127.0.0.1] ([13.74.141.28]) by smtp.gmail.com with ESMTPSA id g14sm2376057wrx.22.2020.10.20.06.41.11 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 06:41:11 -0700 (PDT) Message-Id: <3b20f4c76e31e101da99f8f3e2933ea49b95c6ab.1603201265.git.gitgitgadget@gmail.com> In-Reply-To: References: Date: Tue, 20 Oct 2020 13:41:03 +0000 Subject: [PATCH v4 6/7] p7519-fsmonitor: refactor to avoid code duplication Fcc: Sent MIME-Version: 1.0 To: git@vger.kernel.org Cc: Derrick Stolee , Utsav Shah , Nipunn Koorapati , Nipunn Koorapati , Taylor Blau , Nipunn Koorapati , Nipunn Koorapati Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org From: Nipunn Koorapati From: Nipunn Koorapati Much of the benchmark code is redundant. This is easier to understand and edit. Signed-off-by: Nipunn Koorapati --- t/perf/p7519-fsmonitor.sh | 136 +++++++++++--------------------------- 1 file changed, 37 insertions(+), 99 deletions(-) diff --git a/t/perf/p7519-fsmonitor.sh b/t/perf/p7519-fsmonitor.sh index ef4c3c8c5c..75a0cef01d 100755 --- a/t/perf/p7519-fsmonitor.sh +++ b/t/perf/p7519-fsmonitor.sh @@ -125,61 +125,53 @@ test_expect_success "setup for fsmonitor" ' git status # Warm caches ' -if test -n "$GIT_PERF_7519_DROP_CACHE"; then - test-tool drop-caches -fi +test_perf_w_drop_caches () { + if test -n "$GIT_PERF_7519_DROP_CACHE"; then + test-tool drop-caches + fi -test_perf "status (fsmonitor=$INTEGRATION_SCRIPT)" ' - git status -' + test_perf "$@" +} -if test -n "$GIT_PERF_7519_DROP_CACHE"; then - test-tool drop-caches -fi +test_fsmonitor_suite() { + test_perf_w_drop_caches "status (fsmonitor=$INTEGRATION_SCRIPT)" ' + git status + ' -test_perf "status -uno (fsmonitor=$INTEGRATION_SCRIPT)" ' - git status -uno -' + test_perf_w_drop_caches "status -uno (fsmonitor=$INTEGRATION_SCRIPT)" ' + git status -uno + ' -if test -n "$GIT_PERF_7519_DROP_CACHE"; then - test-tool drop-caches -fi + test_perf_w_drop_caches "status -uall (fsmonitor=$INTEGRATION_SCRIPT)" ' + git status -uall + ' -test_perf "status -uall (fsmonitor=$INTEGRATION_SCRIPT)" ' - git status -uall -' - -if test -n "$GIT_PERF_7519_DROP_CACHE"; then - test-tool drop-caches -fi - -test_perf "diff (fsmonitor=$INTEGRATION_SCRIPT)" ' - git diff -' + test_perf_w_drop_caches "diff (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff + ' -if test -n "$GIT_PERF_7519_DROP_CACHE"; then - test-tool drop-caches -fi + test_perf_w_drop_caches "diff -- 0_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 1_file + ' -test_perf "diff -- 0_files (fsmonitor=$INTEGRATION_SCRIPT)" ' - git diff -- 1_file -' + test_perf_w_drop_caches "diff -- 10_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 10_files + ' -test_perf "diff -- 10_files (fsmonitor=$INTEGRATION_SCRIPT)" ' - git diff -- 10_files -' + test_perf_w_drop_caches "diff -- 100_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 100_files + ' -test_perf "diff -- 100_files (fsmonitor=$INTEGRATION_SCRIPT)" ' - git diff -- 100_files -' + test_perf_w_drop_caches "diff -- 1000_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 1000_files + ' -test_perf "diff -- 1000_files (fsmonitor=$INTEGRATION_SCRIPT)" ' - git diff -- 1000_files -' + test_perf_w_drop_caches "diff -- 10000_files (fsmonitor=$INTEGRATION_SCRIPT)" ' + git diff -- 10000_files + ' +} -test_perf "diff -- 10000_files (fsmonitor=$INTEGRATION_SCRIPT)" ' - git diff -- 10000_files -' +test_fsmonitor_suite test_expect_success "setup without fsmonitor" ' unset INTEGRATION_SCRIPT && @@ -187,61 +179,7 @@ test_expect_success "setup without fsmonitor" ' git update-index --no-fsmonitor ' -if test -n "$GIT_PERF_7519_DROP_CACHE"; then - test-tool drop-caches -fi - -test_perf "status (fsmonitor=$INTEGRATION_SCRIPT)" ' - git status -' - -if test -n "$GIT_PERF_7519_DROP_CACHE"; then - test-tool drop-caches -fi - -test_perf "status -uno (fsmonitor=$INTEGRATION_SCRIPT)" ' - git status -uno -' - -if test -n "$GIT_PERF_7519_DROP_CACHE"; then - test-tool drop-caches -fi - -test_perf "status -uall (fsmonitor=$INTEGRATION_SCRIPT)" ' - git status -uall -' - -if test -n "$GIT_PERF_7519_DROP_CACHE"; then - test-tool drop-caches -fi - -test_perf "diff (fsmonitor=$INTEGRATION_SCRIPT)" ' - git diff -' - -if test -n "$GIT_PERF_7519_DROP_CACHE"; then - test-tool drop-caches -fi - -test_perf "diff -- 0_files (fsmonitor=$INTEGRATION_SCRIPT)" ' - git diff -- 1_file -' - -test_perf "diff -- 10_files (fsmonitor=$INTEGRATION_SCRIPT)" ' - git diff -- 10_files -' - -test_perf "diff -- 100_files (fsmonitor=$INTEGRATION_SCRIPT)" ' - git diff -- 100_files -' - -test_perf "diff -- 1000_files (fsmonitor=$INTEGRATION_SCRIPT)" ' - git diff -- 1000_files -' - -test_perf "diff -- 10000_files (fsmonitor=$INTEGRATION_SCRIPT)" ' - git diff -- 10000_files -' +test_fsmonitor_suite if test_have_prereq WATCHMAN then From patchwork Tue Oct 20 13:41:04 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nipunn Koorapati X-Patchwork-Id: 11846985 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.6 required=3.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FORGED_FROMDOMAIN,FREEMAIL_FROM, HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH,MAILING_LIST_MULTI,SIGNED_OFF_BY, SPF_HELO_NONE,SPF_PASS autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 9EC53C388F7 for ; Tue, 20 Oct 2020 13:41:30 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by mail.kernel.org (Postfix) with ESMTP id 52CC922247 for ; Tue, 20 Oct 2020 13:41:30 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="iBtRLEeK" Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2407575AbgJTNl3 (ORCPT ); Tue, 20 Oct 2020 09:41:29 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:60706 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2407570AbgJTNlT (ORCPT ); Tue, 20 Oct 2020 09:41:19 -0400 Received: from mail-wm1-x343.google.com (mail-wm1-x343.google.com [IPv6:2a00:1450:4864:20::343]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 67E17C061755 for ; Tue, 20 Oct 2020 06:41:17 -0700 (PDT) Received: by mail-wm1-x343.google.com with SMTP id f21so1827205wml.3 for ; Tue, 20 Oct 2020 06:41:17 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=message-id:in-reply-to:references:from:date:subject:fcc :content-transfer-encoding:mime-version:to:cc; bh=hXKOoN1rTfmjYc9bEHjZ5Kz6Fx+nBTv+DEl06unKn/Q=; b=iBtRLEeKfYvdc53CY9H4s5A1+bpt/WngINJsGX9nWu6hO7WqETkEUolnTztZeSEtwk uIL55JynrMw1bmXKsh+SEYiYe52CJvPzKj1Uiu3BUVmSsOK/51piwK2C9XTcshBlwiD3 I3N/Ycn1zY9mxnYCA9sZtogNadeWHOKG/U+Ej2wox3fdgRc5We+rnDoqHWwFkSIfYKEj vEoiP0bo+JKnXq+RrSmw+EEPudniESG2Ae0uRsHS2PWqMfytH/+1Qxv1ax4HuBP1DCyC pKQVVOxvJ8L+ExQKhuF5sHswDszx7xzY/vYr4qrMqk+6qorOVQfNmvemeYoXzjCvK4JB Zduw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:message-id:in-reply-to:references:from:date :subject:fcc:content-transfer-encoding:mime-version:to:cc; bh=hXKOoN1rTfmjYc9bEHjZ5Kz6Fx+nBTv+DEl06unKn/Q=; b=Idm8dHUlQXvEAsgqypig014a4JO8ae8SirjF3CXivSyelvJ+IvO6usdc7OHke1BYmr xCR9jQmBSwL1kBO4JFuWrJKdiB/ogTm16/oUlbF0wbS25Klpcoxte/oJHGVWrbpgggjO p7W4+ICjCzj8+ZeciC5MkxagIhNcVED46/4zqnlFscfpT3Tt5xj25Z13Za7nggz7IXyU pt7e9nQsyX7yXrW4HK/lkeXXFsAFstX6675FHMSq8u+uUpCCB6rN8fhw0MiQQMq78cxj M1TiISN2fbE70hYK5M2SPl72TRc465sVig65bZcPYJLWzgLn+EJyMRaHFzbWxLRIRfs9 zekg== X-Gm-Message-State: AOAM5328mcpjhWQ4ffErWv442CRIHoS1S1Rqg7R8owj80I9GLVL1RGZb 301DKGTjQ4BEVV/CDpx4tAfwr150ZDQ= X-Google-Smtp-Source: ABdhPJz0W0PjLiXXlLKTt1aVC2MFrm+XK/JGGlSrCOxn3w+ug1vvccuO4zPDIPngrWYMxocCTn7sXg== X-Received: by 2002:a7b:c10c:: with SMTP id w12mr3153664wmi.175.1603201272912; Tue, 20 Oct 2020 06:41:12 -0700 (PDT) Received: from [127.0.0.1] ([13.74.141.28]) by smtp.gmail.com with ESMTPSA id a8sm2660262wmj.31.2020.10.20.06.41.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 06:41:12 -0700 (PDT) Message-Id: <6f974399360ef38059dea65b4ffa5a17c615ade1.1603201265.git.gitgitgadget@gmail.com> In-Reply-To: References: Date: Tue, 20 Oct 2020 13:41:04 +0000 Subject: [PATCH v4 7/7] p7519-fsmonitor: add a git add benchmark Fcc: Sent MIME-Version: 1.0 To: git@vger.kernel.org Cc: Derrick Stolee , Utsav Shah , Nipunn Koorapati , Nipunn Koorapati , Taylor Blau , Nipunn Koorapati , Nipunn Koorapati Precedence: bulk List-ID: X-Mailing-List: git@vger.kernel.org From: Nipunn Koorapati From: Nipunn Koorapati Test v2.29.0-rc1 this tree ----------------------------------------------------------------------------------------------------------------- 7519.2: status (fsmonitor=.git/hooks/fsmonitor-watchman) 1.48(0.79+0.67) 1.48(0.79+0.67) +0.0% 7519.3: status -uno (fsmonitor=.git/hooks/fsmonitor-watchman) 0.16(0.11+0.05) 0.17(0.13+0.04) +6.3% 7519.4: status -uall (fsmonitor=.git/hooks/fsmonitor-watchman) 1.36(0.77+0.58) 1.37(0.72+0.63) +0.7% 7519.5: diff (fsmonitor=.git/hooks/fsmonitor-watchman) 0.84(0.21+0.63) 0.14(0.11+0.03) -83.3% 7519.6: diff -- 0_files (fsmonitor=.git/hooks/fsmonitor-watchman) 0.12(0.07+0.05) 0.13(0.09+0.04) +8.3% 7519.7: diff -- 10_files (fsmonitor=.git/hooks/fsmonitor-watchman) 0.12(0.09+0.04) 0.13(0.07+0.06) +8.3% 7519.8: diff -- 100_files (fsmonitor=.git/hooks/fsmonitor-watchman) 0.12(0.08+0.05) 0.12(0.08+0.05) +0.0% 7519.9: diff -- 1000_files (fsmonitor=.git/hooks/fsmonitor-watchman) 0.12(0.08+0.05) 0.13(0.09+0.04) +8.3% 7519.10: diff -- 10000_files (fsmonitor=.git/hooks/fsmonitor-watchman) 0.14(0.08+0.06) 0.13(0.07+0.06) -7.1% 7519.11: add (fsmonitor=.git/hooks/fsmonitor-watchman) 2.75(1.41+1.27) 2.03(1.26+0.70) -26.2% 7519.13: status (fsmonitor=) 1.38(1.03+1.04) 1.37(1.04+1.04) -0.7% 7519.14: status -uno (fsmonitor=) 1.11(0.83+0.98) 1.10(0.89+0.90) -0.9% 7519.15: status -uall (fsmonitor=) 2.30(1.57+1.42) 2.31(1.49+1.50) +0.4% 7519.16: diff (fsmonitor=) 1.43(1.13+1.76) 1.46(1.19+1.72) +2.1% 7519.17: diff -- 0_files (fsmonitor=) 0.10(0.08+0.04) 0.11(0.08+0.04) +10.0% 7519.18: diff -- 10_files (fsmonitor=) 0.10(0.07+0.05) 0.11(0.08+0.04) +10.0% 7519.19: diff -- 100_files (fsmonitor=) 0.10(0.07+0.04) 0.11(0.07+0.05) +10.0% 7519.20: diff -- 1000_files (fsmonitor=) 0.10(0.08+0.03) 0.11(0.08+0.04) +10.0% 7519.21: diff -- 10000_files (fsmonitor=) 0.11(0.08+0.05) 0.12(0.07+0.06) +9.1% 7519.22: add (fsmonitor=) 2.26(1.46+1.49) 2.27(1.42+1.55) +0.4% Signed-off-by: Nipunn Koorapati --- t/perf/p7519-fsmonitor.sh | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/t/perf/p7519-fsmonitor.sh b/t/perf/p7519-fsmonitor.sh index 75a0cef01d..fb20fe0937 100755 --- a/t/perf/p7519-fsmonitor.sh +++ b/t/perf/p7519-fsmonitor.sh @@ -169,6 +169,10 @@ test_fsmonitor_suite() { test_perf_w_drop_caches "diff -- 10000_files (fsmonitor=$INTEGRATION_SCRIPT)" ' git diff -- 10000_files ' + + test_perf_w_drop_caches "add (fsmonitor=$INTEGRATION_SCRIPT)" ' + git add --all + ' } test_fsmonitor_suite