Hacker News new | past | comments | ask | show | jobs | submit | mrkent27's comments login

I came here to comment the same thing. Senders/receivers have the added advantage of not allocating unlike coroutines that have to (usually) allocate on the heap.

I haven't compared performance with the P2300 proposal yet. It seems like it's trying to unify asynchronous and parallel execution for C++, which is much broader in scope than my library.

It's true that coroutines can avoid heap allocation, but I haven't tested when or if that happens in my implementation. From the papers, it's clear that certain conditions must be met for the compiler to optimize this. If you know of any good sources on this, please let me know.

I think it's definitely worth looking into this optimization and possibly using custom allocators for specific cases. I'll also compare performance with the proposal's implementation[1] to see the difference.

Thank you for your feedback.

[1] https://github.com/NVIDIA/stdexec


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: