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 builtinArithmeticIntDivideDecimalSig #13602

Merged
merged 5 commits into from
Dec 10, 2019

Conversation

pingyu
Copy link
Contributor

@pingyu pingyu commented Nov 19, 2019

PCP #12103

What problem does this PR solve?

Implement vectorized evaluation for builtinArithmeticIntDivideDecimalSig at #12103

What is changed and how it works?

It gets faster about 46%.

Check List

Tests

  • Unit test
 GO111MODULE=on go test -check.f TestVectorizedBuiltinArithmeticFunc
PASS: builtin_arithmetic_vec_test.go:136: testEvaluatorSuite.TestVectorizedBuiltinArithmeticFunc	0.066s
OK: 1 passed
PASS
ok  	github.com/pingcap/tidb/expression	0.090s
  • Benchmark
> go test -v -benchmem -bench=BenchmarkVectorizedBuiltinArithmeticFunc -run=BenchmarkVectorizedBuiltinArithmeticFunc -args builtinArithmeticIntDivideDecimalSig
goos: darwin
goarch: amd64
pkg: github.com/pingcap/tidb/expression
BenchmarkVectorizedBuiltinArithmeticFunc/builtinArithmeticIntDivideDecimalSig-VecBuiltinFunc-12         	    6464	    182849 ns/op	   64048 B/op	    1338 allocs/op
BenchmarkVectorizedBuiltinArithmeticFunc/builtinArithmeticIntDivideDecimalSig-NonVecBuiltinFunc-12      	    4426	    276631 ns/op	   64048 B/op	    1338 allocs/op
BenchmarkVectorizedBuiltinArithmeticFunc/builtinArithmeticIntDivideDecimalSig-VecBuiltinFunc#01-12      	   30837	     38542 ns/op	   30864 B/op	     643 allocs/op
BenchmarkVectorizedBuiltinArithmeticFunc/builtinArithmeticIntDivideDecimalSig-NonVecBuiltinFunc#01-12   	    9626	    128365 ns/op	   30864 B/op	     643 allocs/op
PASS
ok  	github.com/pingcap/tidb/expression	6.341s

@pingyu pingyu requested a review from a team as a code owner November 19, 2019 17:34
@sre-bot
Copy link
Contributor

sre-bot commented Nov 19, 2019

Thanks for your contribution. If your PR get merged, you will be rewarded 50 points.

@sre-bot sre-bot added the contribution This PR is from a community contributor. label Nov 19, 2019
@ghost ghost requested review from qw4990 and XuHuaiyu and removed request for a team November 19, 2019 17:34
@codecov
Copy link

codecov bot commented Nov 19, 2019

Codecov Report

❗ No coverage uploaded for pull request base (master@bb51eba). Click here to learn what that means.
The diff coverage is n/a.

@@             Coverage Diff             @@
##             master     #13602   +/-   ##
===========================================
  Coverage          ?   80.1738%           
===========================================
  Files             ?        481           
  Lines             ?     120649           
  Branches          ?          0           
===========================================
  Hits              ?      96729           
  Misses            ?      16193           
  Partials          ?       7727

@pingyu pingyu force-pushed the expression_vec_int_divide_decimal branch from fd30651 to 7a8f786 Compare November 27, 2019 15:45
@pingyu
Copy link
Contributor Author

pingyu commented Nov 27, 2019

/rebuild

@pingyu pingyu force-pushed the expression_vec_int_divide_decimal branch from 7a8f786 to ef0b29e Compare December 6, 2019 14:22
@qw4990 qw4990 requested a review from XuHuaiyu December 9, 2019 06:21
Copy link
Contributor

@qw4990 qw4990 left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@XuHuaiyu XuHuaiyu left a comment

Choose a reason for hiding this comment

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

LGTM

@qw4990 qw4990 added status/can-merge Indicates a PR has been approved by a committer. status/LGT2 Indicates that a PR has LGTM 2. labels Dec 10, 2019
@sre-bot
Copy link
Contributor

sre-bot commented Dec 10, 2019

/run-all-tests

@sre-bot
Copy link
Contributor

sre-bot commented Dec 10, 2019

/run-all-tests

@qw4990 qw4990 merged commit 18d7d55 into pingcap:master Dec 10, 2019
@sre-bot
Copy link
Contributor

sre-bot commented Dec 10, 2019

@pingyu complete task #12103 and get 50 score, currerent score 450.

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.

5 participants