The Place to Start for Operating System Developers
It is currently Tue May 30, 2023 12:17 pm

All times are UTC - 6 hours

Post new topic Reply to topic  [ 16 posts ]  Go to page Previous  1, 2
Author Message
 Post subject: Re: Non-intterupt driven OS
PostPosted: Sat Feb 04, 2023 4:02 am 
User avatar

Joined: Mon May 22, 2017 5:56 am
Posts: 739
Location: Oscillating between two different potentials
AndrewAPrice wrote:
You could write your code very asynchronosly. e.g. JavaScript style where everything is async/await. You would still get crashes in true infinite loops, but at least your code blocks would be fairly granular.

I evidently need to learn asynchronous coding. I've been held back by a very strong preference for orderly linear languages, but this asynchronous style seems to have some big advantages.

AndrewAPrice wrote:
I also recall an "OS" named GIMI written in QBasic that would achieve multitasking by round-robin interpreting each script.

Oh that takes me back! When my only tool was QBasic, I thought of implementing multitasking in that way too. These days, I'd describe it as overloading termination to function as yielding to the OS. Not necessary if you have control of the language, but it could keep code granular.

Schol-R-LEA wrote:
Niklaus Wirth got a bee in his bonnet about interrupts and determinism in the mid-1980s, so the Oberon OS and language was designed entirely around cooperative multitasking. The language and the OS are tightly interwoven, with the compiler designed to automatically insert passes into the program at regular intervals - specifically, any loop would end by passing to the scheduler, or at least do so after a certain number of iterations. Needless to say, this method is highly dependent on that specific compiler being used for everything.

I've long been planning to use a single compiler for everything, not least because it has some interesting possibilities including inserting passes (or yielding, as I tend to call it). Deciding when to yield still seems to me to be a complex issue, but evidently solvable -- Oberon was very responsive when I tried it.

[Kaph — A set of system ideals] [Pichiciego — A slightly quirky bootable Forth]
"May wisdom, fun, and the greater good shine forth in all your work." — Leo Brodie

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 16 posts ]  Go to page Previous  1, 2

All times are UTC - 6 hours

Who is online

Users browsing this forum: Octocontrabass and 4 guests

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group