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

c_api内存池的几个bug #3817

Closed
wants to merge 3 commits into from
Closed

c_api内存池的几个bug #3817

wants to merge 3 commits into from

Conversation

qiqikit
Copy link
Contributor

@qiqikit qiqikit commented May 21, 2022

  1. 修了一下c_api allocator参数的几个bug
  2. 做了个内存池最大使用内存限制功能,功能比较粗糙
  3. 提升了 allocator 的 emptyCache() 方法,小内存的设备需要

@tencent-adm
Copy link
Member

CLA assistant check
Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@codecov-commenter
Copy link

codecov-commenter commented May 21, 2022

Codecov Report

Merging #3817 (9b917d5) into master (f79073c) will increase coverage by 1.53%.
The diff coverage is 17.36%.

@@            Coverage Diff             @@
##           master    #3817      +/-   ##
==========================================
+ Coverage   91.75%   93.29%   +1.53%     
==========================================
  Files         674      674              
  Lines      171538   172106     +568     
==========================================
+ Hits       157402   160564    +3162     
+ Misses      14136    11542    -2594     
Impacted Files Coverage Δ
src/allocator.h 87.50% <ø> (ø)
src/c_api.cpp 31.72% <2.87%> (-5.19%) ⬇️
src/allocator.cpp 75.75% <56.86%> (-0.13%) ⬇️
src/cpu.cpp 63.81% <0.00%> (-1.71%) ⬇️
src/net.cpp 65.37% <0.00%> (-0.12%) ⬇️
src/layer/vulkan/pooling_vulkan.cpp 98.42% <0.00%> (+<0.01%) ⬆️
src/mat.h 89.87% <0.00%> (+0.05%) ⬆️
src/layer/x86/convolution_3x3_pack8to4_int8.h 99.43% <0.00%> (+0.09%) ⬆️
src/layer/x86/convolution_sgemm_pack8to1_int8.h 99.10% <0.00%> (+0.09%) ⬆️
src/layer/x86/convolution_3x3_pack8to1_int8.h 99.06% <0.00%> (+0.12%) ⬆️
... and 44 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update c2fb93b...9b917d5. Read the comment docs.

@lgtm-com
Copy link

lgtm-com bot commented May 21, 2022

This pull request introduces 2 alerts when merging 9b917d5 into c2fb93b - view on LGTM.com

new alerts:

  • 2 for Virtual call from constructor or destructor

@nihui
Copy link
Member

nihui commented May 21, 2022

emptyCache 看起来就是原来的 clear 嘛?所以直接把 clear 提升到基类也ok?
gpu 那边的 VkAllocator 有 clear 方法

@qiqikit
Copy link
Contributor Author

qiqikit commented May 21, 2022 via email

@qiqikit
Copy link
Contributor Author

qiqikit commented Oct 11, 2022 via email

@nihui
Copy link
Member

nihui commented Nov 20, 2022

move part of this pr to #4360

@qiqikit qiqikit closed this by deleting the head repository Sep 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants