Deutsch English Français Italiano |
<v74cn9$tuk4$2@dont-email.me> View for Bookmarking (what is this?) Look up another Usenet article |
Path: ...!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail From: Lawrence D'Oliveiro <ldo@nz.invalid> Newsgroups: comp.arch Subject: Re: Continuations Date: Mon, 15 Jul 2024 23:52:09 -0000 (UTC) Organization: A noiseless patient Spider Lines: 15 Message-ID: <v74cn9$tuk4$2@dont-email.me> References: <v6tbki$3g9rg$1@dont-email.me> <4j389jlb44kuhi3o5igf8ucnks3q9m3lc8@4ax.com> <v714in$1foh$2@gal.iecc.com> <lfims1Fl57mU1@mid.individual.net> <v71jfh$jko$1@gal.iecc.com> <lfldplF1kmoU1@mid.individual.net> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Injection-Date: Tue, 16 Jul 2024 01:52:09 +0200 (CEST) Injection-Info: dont-email.me; posting-host="55f74b4ae2f116c131f41dc172ef4daf"; logging-data="981636"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19umCVB5bx5aRn9KstYyVtp" User-Agent: Pan/0.158 (Avdiivka; ) Cancel-Lock: sha1:Y13q8rjUUjHJ3TP9WtJPUIVBWEs= Bytes: 1909 On Mon, 15 Jul 2024 23:06:13 +0300, Niklas Holsti wrote: > IMO, for something to qualify as a continuation-passing call, the caller > should select the callee -- the thing to be executed next -- but in > SAGE/SABRE it is the scheduler that selects what to execute next. What you have is that SAGE/SABRE has built a higher-level scheduler abstraction on top of lower-level coroutines/continuations. Python’s asyncio module works in a similar way. Coroutines are a language primitive, that pass control directly to each other via await calls. asyncio is a library module that wraps a coroutine in a higher-level “task” object. When one task awaits another, that doesn’t necessarily mean that control is passed directly from the first task to the second: instead, the scheduler regains control and decides who is to run next.