Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Create CUDA events for CUDAProduct only when needed #292

Conversation

makortel
Copy link

Do not create event if the CUDA stream is idle, i.e. has already
finished all work that was queued, at the point when data products are
wrapped/emplaced for/to edm::Event.

When creating an event, create only a single event per producer, i.e.
all products of a producer share the same event.

Fixes #287.

Do not create event if the CUDA stream is idle, i.e. has already
finished all work that was queued, at the point when data products are
wrapped/emplaced for/to edm::Event.

When creating an event, create only a single event per producer, i.e.
all products of a producer share the same event.

Also include a unit test checking the assumed behavior of CUDA events
and streams.
@makortel
Copy link
Author

nvprof shows that there are less CUDA events created and recorded, but likely that does not lead to visible improvements as the caching allocators record much more events at the moment.

@fwyzard
Copy link

fwyzard commented Mar 21, 2019

No impact on the throughput, running on a P100:

before: 1275.0 ± 2.8 ev/s
after:  1275.0 ± 1.7 ev/s

@fwyzard fwyzard merged commit 4b36e2a into cms-patatrack:CMSSW_10_5_X_Patatrack Mar 21, 2019
@fwyzard fwyzard added this to the CMSSW_10_5_X_Patatrack milestone Mar 26, 2019
fwyzard pushed a commit that referenced this pull request May 15, 2019
Don't leave nCuts in VIDNestedWPBitmapProducer uninitialized
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants