You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Summary:
The close() and abort() APIs share the same objective: to release
resources held by the operator. However, they are not currently
implemented uniformly across all operators. For example, HashBuild
and HashProbe have abort() implemented, but not close(). This
discrepancy can lead to inconsistencies in the expected effects of
these API calls.
For instance, when a driver is destroyed, it calls close() on all its
operators before detaching itself from its parent task. All operators,
with the exception of HashBuild and HashProbe, would have their
resources released. The latter, however, would rely on their
destructor being called, which could occur at any later point.
The detachment of the driver from the task serves as a synchronization
point. If we now rely on the destructor being called later, this
introduces an element of indeterminism to the state of the resources.
This unpredictability makes it difficult for memory management to
make decisions during arbitration.
This change aims to eliminate the abort() API and consolidate its
functionality into close().
Additionally, it serializer access to HashBuild's internal state
(table and spiller) to handle the case where it can be concurrently
cleared by the task thread closing the operator and the being read by
the last hash build operator attempting to build the hash table by
fetching this internal state from all its peers.
Reviewed By: oerling
Differential Revision: D53818809
0 commit comments