We have encountered performance hot issues in vce module. Cpu occupancy rate has been in the alloc_vmap_area function. We found that calling the alloc_vmap_area function mainly occurs in the amdgpu_cs_ib_vm_chunk function. So we removed the main loop judgment logic of amdgpu_cs_ib_vm_chunk. as follows . - if (p->ring->funcs->parse_cs || p->ring->funcs->patch_cs_in_place) { + if (0) If we don't delete, vce will be very slow. Is this the fundamental way to solve the problem? Or there are other ways to solve the problem? 3q very much.
performance hot stack: start_thread -> impl_thrd_routine -> util_queue_thread_func -> amdgpu_cs_submit_ib -> amdgpu_cs_submit_raw -> drmCommandWriteRead -> ioctl -> el0_svc -> el0_svc_handler -> el0_svc_common -> __arm64_sys_ioctl -> ksys_ioctl -> do_vfs_ioctl -> amdgpu_drm_ioctl -> drm_ioctl -> drm_ioctl_kernel -> amdgpu_cs_ioctl -> amdgpu_bo_kmap-> ttm_bo_kmap -> vmap -> __get_vm_area_node -> alloc_vmap_area
(In reply to baopeng from comment #0) > - if (p->ring->funcs->parse_cs || p->ring->funcs->patch_cs_in_place) { > + if (0) > If we don't delete, vce will be very slow. > > Is this the fundamental way to solve the problem? Well certainly not, this code is important for VCE handle management. > Or there are other ways to solve the problem? Well what problem do you have? VCE usually uses less than 100 submissions per second, so that you run into any performance bottleneck here is rather unlikely.
-- GitLab Migration Automatic Message -- This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/drm/amd/issues/756.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.