NVIDIA / NVIDIA/stdexec

`async_scope::spawn` cost a lot in ref counting and heap alloc, how to optimize?

Open
#1,748 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C++
Stars
2.4k
Forks
270
Avg merge
3d 6h
Merged PRs (30d)
39

Description

Hi everyone, I'm using async_scope::spawn in a very hot code path. And I find it's very slow due to the reference counting and heap allocation.

the senders I'm spawning have different scheduelrs(unique scheudler per sender). So ex::bulk doesn't apply here.

I wonder is there any way to optimize or workaround?

can anyone help me? thanks in advance!

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No files or tests are named. Begin by examining the implementation and usage of async_scope::spawn, then measure the reference-counting and heap-allocation costs for senders with unique schedulers. Done would require an agreed optimization or workaround, with evidence that it addresses the reported hot-path cost.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
performance
Issue type
Refactor
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.