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: avoid copy twice when to decode the topn #47563

Merged
merged 3 commits into from
Oct 12, 2023

Conversation

hawkingrei
Copy link
Member

@hawkingrei hawkingrei commented Oct 11, 2023

What problem does this PR solve?

Issue Number: ref #47275

Problem Summary:

What is changed and how it works?

the first one is in the DecodeTopN. DecodeTopN called TopNFromProto. it will copy again.

Check List

Tests

  • Unit test
  • Integration test
  • Manual test (add detailed scripts or steps below)
  • No need to test
    • I checked and no code files have been changed.

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

@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/M Denotes a PR that changes 30-99 lines, ignoring generated files. and removed do-not-merge/needs-tests-checked labels Oct 11, 2023
@codecov
Copy link

codecov bot commented Oct 11, 2023

Codecov Report

Merging #47563 (f9299b8) into master (7f9ab7f) will increase coverage by 0.8897%.
Report is 12 commits behind head on master.
The diff coverage is 100.0000%.

Additional details and impacted files
@@               Coverage Diff                @@
##             master     #47563        +/-   ##
================================================
+ Coverage   71.9972%   72.8870%   +0.8897%     
================================================
  Files          1352       1375        +23     
  Lines        400957     407989      +7032     
================================================
+ Hits         288678     297371      +8693     
+ Misses        92920      91904      -1016     
+ Partials      19359      18714       -645     
Flag Coverage Δ
integration 40.5847% <100.0000%> (?)
unit 72.1403% <100.0000%> (+0.1431%) ⬆️

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

Components Coverage Δ
dumpling 53.9913% <ø> (ø)
parser 84.7472% <ø> (+0.0107%) ⬆️
br 49.2037% <ø> (-4.1682%) ⬇️

@ti-chi-bot ti-chi-bot bot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Oct 11, 2023
@hawkingrei
Copy link
Member Author

/retest

Copy link
Contributor

@elsa0520 elsa0520 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ti-chi-bot ti-chi-bot bot added the needs-1-more-lgtm Indicates a PR needs 1 more LGTM. label Oct 12, 2023
@hawkingrei
Copy link
Member Author

/test all

@ti-chi-bot
Copy link

ti-chi-bot bot commented Oct 12, 2023

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: elsa0520, 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:

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 approved lgtm and removed needs-1-more-lgtm Indicates a PR needs 1 more LGTM. labels Oct 12, 2023
@ti-chi-bot
Copy link

ti-chi-bot bot commented Oct 12, 2023

[LGTM Timeline notifier]

Timeline:

  • 2023-10-12 04:06:49.974721533 +0000 UTC m=+1284407.561831675: ☑️ agreed by elsa0520.
  • 2023-10-12 05:34:14.672441745 +0000 UTC m=+1289652.259551889: ☑️ agreed by time-and-fate.

@hawkingrei
Copy link
Member Author

/retest

2 similar comments
@hawkingrei
Copy link
Member Author

/retest

@hawkingrei
Copy link
Member Author

/retest

@ti-chi-bot ti-chi-bot bot merged commit 6842efd into pingcap:master Oct 12, 2023
@hawkingrei hawkingrei deleted the better_topn_1012 branch October 12, 2023 13:08
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/S Denotes a PR that changes 10-29 lines, ignoring generated files.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants