Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

statistics: use slices.BinarySearchFunc to simple TopN.FindTopN #46996

Merged
merged 2 commits into from
Sep 15, 2023

Conversation

hawkingrei
Copy link
Member

@hawkingrei hawkingrei commented Sep 14, 2023

What problem does this PR solve?

Issue Number: ref #45933

Problem Summary:

What is changed and how it works?

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No code

Side effects

  • Performance regression: Consumes more CPU
  • Performance regression: Consumes more Memory
  • Breaking backward compatibility

Documentation

  • Affects user behaviors
  • Contains syntax changes
  • Contains variable changes
  • Contains experimental features
  • Changes MySQL compatibility

Release note

Please refer to Release Notes Language Style Guide to write a quality release note.

None

Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
@ti-chi-bot ti-chi-bot bot added do-not-merge/needs-linked-issue do-not-merge/needs-tests-checked release-note-none Denotes a PR that doesn't merit a release note. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files. and removed do-not-merge/needs-linked-issue do-not-merge/needs-tests-checked labels Sep 14, 2023
@codecov
Copy link

codecov bot commented Sep 14, 2023

Codecov Report

Merging #46996 (b534a5b) into master (9bfa176) will decrease coverage by 0.5085%.
Report is 4 commits behind head on master.
The diff coverage is 100.0000%.

Additional details and impacted files
@@               Coverage Diff                @@
##             master     #46996        +/-   ##
================================================
- Coverage   73.2462%   72.7377%   -0.5085%     
================================================
  Files          1335       1356        +21     
  Lines        397697     404218      +6521     
================================================
+ Hits         291298     294019      +2721     
- Misses        87749      91577      +3828     
+ Partials      18650      18622        -28     
Flag Coverage Δ
integration 28.6844% <100.0000%> (?)
unit 73.2815% <100.0000%> (+0.0353%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Components Coverage Δ
dumpling 53.9913% <ø> (ø)
parser 85.0060% <ø> (+0.0310%) ⬆️
br 48.6147% <ø> (-4.3057%) ⬇️

Signed-off-by: Weizhen Wang <wangweizhen@pingcap.com>
@hawkingrei
Copy link
Member Author

/retest

1 similar comment
@hawkingrei
Copy link
Member Author

/retest

@hawkingrei
Copy link
Member Author

/test tiprow_fast_test

@ti-chi-bot
Copy link

ti-chi-bot bot commented Sep 15, 2023

@hawkingrei: The specified target(s) for /test were not found.
The following commands are available to trigger required jobs:

  • /test build
  • /test canary-scan-security
  • /test check-dev
  • /test check-dev2
  • /test mysql-test
  • /test pingcap/tidb/canary_ghpr_unit_test
  • /test pull-br-integration-test
  • /test pull-common-test
  • /test pull-e2e-test
  • /test pull-integration-common-test
  • /test pull-integration-copr-test
  • /test pull-integration-ddl-test
  • /test pull-integration-jdbc-test
  • /test pull-integration-mysql-test
  • /test pull-integration-prisma-test
  • /test pull-mysql-connector-test
  • /test pull-sqllogic-test
  • /test pull-tiflash-test
  • /test unit-test

The following commands are available to trigger optional jobs:

  • /test pull-notify-when-compatibility-sections-changed

Use /test all to run the following jobs that were automatically triggered:

  • pingcap/tidb/ghpr_build
  • pingcap/tidb/ghpr_check
  • pingcap/tidb/ghpr_check2
  • pingcap/tidb/ghpr_mysql_test
  • pingcap/tidb/ghpr_unit_test

In response to this:

/test tiprow_fast_test

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@hawkingrei hawkingrei changed the title statistics: use slices.BinarySearchFunc to speed up TopN.FindTopN statistics: use slices.BinarySearchFunc to simple TopN.FindTopN Sep 15, 2023
@ti-chi-bot ti-chi-bot bot added approved needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Sep 15, 2023
@ti-chi-bot
Copy link

ti-chi-bot bot commented Sep 15, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: hi-rustin, time-and-fate

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:
  • OWNERS [hi-rustin,time-and-fate]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@ti-chi-bot ti-chi-bot bot added lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Sep 15, 2023
@ti-chi-bot
Copy link

ti-chi-bot bot commented Sep 15, 2023

[LGTM Timeline notifier]

Timeline:

  • 2023-09-15 03:00:53.915180019 +0000 UTC m=+227219.882768088: ☑️ agreed by time-and-fate.
  • 2023-09-15 03:02:38.049959007 +0000 UTC m=+227324.017547057: ☑️ agreed by hi-rustin.

@ti-chi-bot ti-chi-bot bot merged commit 9ec7872 into pingcap:master Sep 15, 2023
@hawkingrei hawkingrei deleted the better_topn branch September 15, 2023 03:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved lgtm release-note-none Denotes a PR that doesn't merit a release note. size/XS Denotes a PR that changes 0-9 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants