Implement move operations in ReferencedTopDUContext and std::move referenced contexts when possible
Open, NormalPublic

Description

ReferencedTopDUContext's copy constructor and copy assignment operator are slow as they manipulate reference counts under a mutex lock. The new move constructor and move assignment operator can simply copy the m_topContext pointer's value to the moved-to object, and set the moved-from object's pointer to nullptr.

But simply implementing the move operations will likely not bring significant performance gain. One should also std::move ReferencedTopDUContext objects where appropriate.

igorkushnir triaged this task as Normal priority.
arrowd added a subscriber: arrowd.Oct 19 2020, 7:06 AM

AFAIK, Phabricator is being retired in favor of GitLab. Why not create an issue there? https://invent.kde.org/kdevelop/kdevelop/-/issues

From https://community.kde.org/Infrastructure/GitLab: "Task management is transitioning to Invent/GitLab but most projects still use https://phabricator.kde.org for now."

Looks like KDevelop is still using Phabricator. Are you sure that GitLab issues is going to be the eventual replacement for task management?