Functions that traverse the IProfilingBlockInputStream tree may have performance issues when the tree contains SharedQueryBlockInputStream
#7810
Labels
affects-5.0
affects-5.1
affects-5.2
affects-5.3
affects-5.4
This bug affects the 5.4.x(LTS) versions.
affects-6.0
affects-6.1
This bug affects the 6.1.x(LTS) versions.
affects-6.2
affects-6.3
affects-6.4
affects-6.5
This bug affects the 6.5.x(LTS) versions.
affects-6.6
affects-7.0
affects-7.1
This bug affects the 7.1.x(LTS) versions.
affects-7.2
affects-7.3
component/compute
severity/major
type/bug
The issue is confirmed as a bug.
Bug Report
The same issue as #4494
The root cause is when IProfilingBlockInputStream tree contains
SharedQueryBlockInputStream
, the tree is actually a DAG, and when traverse the DAG as a tree, it need much redundant traverse, at worst case, the time complexity become O(m^n), where n is the number ofSharedQueryBlockInputStream
in the DAG, m is the number of children for the tree node.Currently, the functions that may have this problem inlcudes:
IProfilingBlockInputStream::setProcessListElement
IProfilingBlockInputStream::setProgressCallback
The text was updated successfully, but these errors were encountered: