pytorch
cacab7e9 - [vulkan] Reduce submission rate to save CPU cycles (#60758)

Commit
3 years ago
[vulkan] Reduce submission rate to save CPU cycles (#60758) Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/60758 Further tweak the submission rate of ops. Before in D28293756 (https://github.com/pytorch/pytorch/commit/bc0965ac853f616b068a18add828fa794877775c), the submission rate was set as high as possible in order to prioritize performance. However, in practice (i.e. when running the model in an app) the high rate of submission increases CPU usage and increases GPU contention which may regress fps. In the future it would be beneficial to devise a scheme to adaptively set the GPU submission rate. ## Perf Improvements This change doesn't really affect benchmark latency. However, through systraces it can be observed that CPU usage is reduced without too much impact on FPS/model latency. Test Plan: Test vulkan ops: ``` cd ~/fbsource buck build -c ndk.custom_libcxx=false -c pt.enable_qpl=0 //xplat/caffe2:pt_vulkan_api_test_binAndroid\#android-arm64 --show-output adb push buck-out/gen/xplat/caffe2/pt_vulkan_api_test_binAndroid\#android-arm64 /data/local/tmp/vulkan_api_test adb shell "/data/local/tmp/vulkan_api_test" cd - ``` Reviewed By: IvanKobzarev Differential Revision: D29062836 fbshipit-source-id: 1a0f42b49fecb80baee08cb3f1048bb35a1b5d5c
Author
Parents
Loading