Skip to content

Conversation

@f3sch
Copy link
Collaborator

@f3sch f3sch commented May 25, 2025

based on #14312 (will rebase if merged)

the pr aims to allow to stop the occasional exponential growth of buffers by using a custom allocator which throws an exception if the configurable memory limit is exceeded by the request. the algorithm then gracefully (before allocating any memory) drops the time slice.
for this to work a switch to tbb had to be done since in omp the exception thrown has to be handled by the throwing thread and is not propagated to the master thread. tbb guarantees this + cancellation of all parallel work.

Validation of getting the same output after modifications:
ptRatioCN

no particular gain/loss for the vertexing:
vtx_tasks_comparison

a >50% gain in findRoads due an optimisation switching away from an atomic variable under heavy contention:
trk_tasks_comparison

before the change:
image

after the change:
image

P.S. Also sorry for these insanely big PRs, this is not nice for reviewers or to other people that work on the code basis.

@github-actions
Copy link
Contributor

REQUEST FOR PRODUCTION RELEASES:
To request your PR to be included in production software, please add the corresponding labels called "async-" to your PR. Add the labels directly (if you have the permissions) or add a comment of the form (note that labels are separated by a ",")

+async-label <label1>, <label2>, !<label3> ...

This will add <label1> and <label2> and removes <label3>.

The following labels are available
async-2023-pbpb-apass4
async-2023-pp-apass4
async-2024-pp-apass1
async-2022-pp-apass7
async-2024-pp-cpass0
async-2024-PbPb-apass1
async-2024-ppRef-apass1
async-2024-PbPb-apass2
async-2023-PbPb-apass5

@f3sch f3sch changed the title ITS: track memory allocations + graceful handling of allocations ITS: track memory allocations + graceful of exceeding limit May 25, 2025
@f3sch f3sch force-pushed the its/gpu_pr2 branch 8 times, most recently from 07c3649 to a11c4bd Compare June 1, 2025 16:35
Signed-off-by: Felix Schlepper <felix.schlepper@cern.ch>
@f3sch f3sch force-pushed the its/gpu_pr2 branch 3 times, most recently from eca3b1e to bf7cbab Compare June 2, 2025 07:05
@f3sch f3sch marked this pull request as ready for review June 2, 2025 07:07
Signed-off-by: Felix Schlepper <felix.schlepper@cern.ch>
Copy link
Contributor

@mpuccio mpuccio left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good to me, thanks a lot!

@mconcas mconcas merged commit f248969 into AliceO2Group:dev Jun 4, 2025
13 checks passed
@f3sch f3sch deleted the its/gpu_pr2 branch June 4, 2025 07:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants