[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH experiment 00/35] stackless coroutine backend
From: |
Stefan Hajnoczi |
Subject: |
Re: [PATCH experiment 00/35] stackless coroutine backend |
Date: |
Fri, 11 Mar 2022 09:27:52 +0000 |
On Thu, Mar 10, 2022 at 09:14:07PM +0100, Paolo Bonzini wrote:
> On 3/10/22 18:42, Stefan Hajnoczi wrote:
> > There are a lot of details to decide on in the translator tool and
> > runtime to optimize the code. I think the way the stack frames are
> > organized in this patch series is probably for convenience rather than
> > performance.
>
> Yes, sometimes the optimizations are there but mostly because they made my
> job easier.
>
> > Out of curiousity, did you run the perf tests and compare against
> > ucontext?
>
> Not quite voluntarily, but I noticed I had to add one 0 to make them run for
> a decent amount of time. So yeah, it's much faster than siglongjmp.
That's a nice first indication that performance will be good. I guess
that deep coroutine_fn stacks could be less efficient with stackless
coroutines compared to ucontext, but the cost of switching between
coroutines (enter/yield) will be lower with stackless coroutines.
Stefan
signature.asc
Description: PGP signature
- [PATCH 22/35] /perf/function-call, (continued)
- [PATCH 22/35] /perf/function-call, Paolo Bonzini, 2022/03/10
- [PATCH 23/35] /perf/cost, Paolo Bonzini, 2022/03/10
- [PATCH 24/35] /basic/no-dangling-access, Paolo Bonzini, 2022/03/10
- [PATCH 28/35] qemu_co_rwlock_maybe_wake_one, Paolo Bonzini, 2022/03/10
- [PATCH 31/35] qemu_co_rwlock_downgrade, Paolo Bonzini, 2022/03/10
- [PATCH 34/35] /locking/co-rwlock/upgrade, Paolo Bonzini, 2022/03/10
- [PATCH 35/35] /locking/co-rwlock/downgrade, Paolo Bonzini, 2022/03/10
- [PATCH 33/35] qemu_co_rwlock_upgrade, Paolo Bonzini, 2022/03/10
- Re: [PATCH experiment 00/35] stackless coroutine backend, Stefan Hajnoczi, 2022/03/10