Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

592
Visualizações
Are Python coroutines stackless or stackful?

I've seen conflicting views on whether Python coroutines (I primarily mean async/await) are stackless or stackful.

Some sources say they're stackful:

  • http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2020/p2074r0.pdf

    'Python coroutines are stackful.'

  • How do coroutines in Python compare to those in Lua?

    Yes, Python coroutines are stackful, first-class and asymmetric.

While others seem to imply they're stackless, e.g. https://gamelisp.rs/reference/coroutines.html

GameLisp's coroutines follow the model set by Rust, Python, C# and C++. Our coroutines are "stackless"

In general my understanding always was that any meaningful async/await implementation implies stackless coroutines, while stackful ones are basically fibers (userspace threads, often switched more or less cooperatively), like goroutines, Boost.Coroutine, apparently those in Lua etc.

Is my understanding correct? Or do Python coroutines somehow fundamentally differ from those in say C++, and are stackful? Or do the authors of the source above mean different things?

over 4 years ago · Santiago Trujillo
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda