Skip to content

Conversation

@houstar
Copy link
Contributor

@houstar houstar commented Dec 18, 2018

Signed-off-by: Leno Hou [email protected]

Ⅰ. Describe what this PR did

In computer architecture, bit operation use less CPU cycle than Div and Mod

Formula:
Val / 2^n   =  Val >> n                (right shift n bit)
Val % 2^n  = Val & (2^n -1)            (only get the low bit)

Ⅱ. Does this pull request fix one issue?

NO

Ⅲ. Why don't you add test cases (unit test/integration test)? (你真的觉得不需要加测试吗?)

NO

Ⅳ. Describe how to verify it

NO

Ⅴ. Special notes for reviews

@codecov
Copy link

codecov bot commented Dec 18, 2018

Codecov Report

Merging #2567 into master will decrease coverage by 0.02%.
The diff coverage is 50%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #2567      +/-   ##
==========================================
- Coverage   69.17%   69.15%   -0.03%     
==========================================
  Files         278      278              
  Lines       18623    18623              
==========================================
- Hits        12883    12879       -4     
- Misses       4268     4270       +2     
- Partials     1472     1474       +2
Flag Coverage Δ
#criv1alpha1test 31.25% <0%> (-0.03%) ⬇️
#criv1alpha2test 35.63% <0%> (+0.14%) ⬆️
#integrationtest 40.66% <50%> (-0.02%) ⬇️
#nodee2etest 32.57% <0%> (-0.09%) ⬇️
#unittest 26.76% <0%> (ø) ⬆️
Impacted Files Coverage Δ
daemon/mgr/spec_linux.go 76.74% <50%> (ø) ⬆️
cri/v1alpha1/cri.go 60.59% <0%> (-0.34%) ⬇️
daemon/mgr/container.go 58.79% <0%> (-0.22%) ⬇️

@houstar
Copy link
Contributor Author

houstar commented Dec 19, 2018

@Ace-Tang Could you help me to take a look this minor changes? Thanks.

@firjest
Copy link

firjest commented Dec 20, 2018

LGTM

@allencloud
Copy link
Collaborator

Thanks a lot for your work. @houstar

@allencloud allencloud merged commit 5302544 into AliyunContainerService:master Dec 20, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants