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

expression: implement vectorized evaluation for builtinAtan2ArgsSig #12228

Merged
merged 5 commits into from
Sep 17, 2019

Conversation

jacklightChen
Copy link
Contributor

What problem does this PR solve?

implement vectorized evaluation for builtinAtan2ArgsSig, for #12105

What is changed and how it works?

according to benchmark, about 3 times faster than before:

BenchmarkVectorizedBuiltinMathFunc/builtinAtan2ArgsSig-VecBuiltinFunc-8           100000             18738 ns/op            0 B/op          0 allocs/op
BenchmarkVectorizedBuiltinMathFunc/builtinAtan2ArgsSig-NonVecBuiltinFunc-8         30000             40375 ns/op            0 B/op          0 allocs/op

Check List

Tests

  • Unit test

@sre-bot sre-bot added the contribution This PR is from a community contributor. label Sep 17, 2019
return err
}

result.ResizeFloat64(n, false)
Copy link
Member

Choose a reason for hiding this comment

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

we can use the result variable to store one of it's parameter's result. Thus the vectors used in the calculation can be reduced from 3 to 2.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

got it!

@codecov
Copy link

codecov bot commented Sep 17, 2019

Codecov Report

Merging #12228 into master will decrease coverage by 0.1306%.
The diff coverage is 62.9629%.

@@               Coverage Diff               @@
##            master     #12228        +/-   ##
===============================================
- Coverage   81.225%   81.0943%   -0.1307%     
===============================================
  Files          454        454                
  Lines        99260      98447       -813     
===============================================
- Hits         80624      79835       -789     
+ Misses       12864      12850        -14     
+ Partials      5772       5762        -10

Copy link
Member

@zz-jason zz-jason left a comment

Choose a reason for hiding this comment

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

LGTM

@zz-jason zz-jason added the status/LGT1 Indicates that a PR has LGTM 1. label Sep 17, 2019
Copy link
Contributor

@Reminiscent Reminiscent left a comment

Choose a reason for hiding this comment

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

LGTM

@Reminiscent Reminiscent added status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Sep 17, 2019
@sre-bot
Copy link
Contributor

sre-bot commented Sep 17, 2019

Your auto merge job has been accepted, waiting for 12227

@Reminiscent Reminiscent removed the request for review from qw4990 September 17, 2019 12:23
@sre-bot
Copy link
Contributor

sre-bot commented Sep 17, 2019

/run-all-tests

@sre-bot
Copy link
Contributor

sre-bot commented Sep 17, 2019

@jacklightChen merge failed.

@zz-jason
Copy link
Member

/run-unit-test

@zz-jason zz-jason merged commit b669640 into pingcap:master Sep 17, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/expression contribution This PR is from a community contributor. status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants