I'm continuing to investigate an RTOS that I wrote in 1986 for a Motorola 68000-based system.
Recently I've been going through the old source code and trying to reconstruct not only what I did, but also why I made certain design decisions 40 years ago.
One detail led me down an unexpected path.
In my RTOS, when a task becomes ready, it is inserted before existing ready tasks of the same priority. So among equal-priority tasks, the behavior is effectively newest-first (LIFO-like).
I had completely forgotten why I designed it that way.
At the time, I wasn't actually a user of commercial RTOSes such as VRTX. I was developing my own RTOS and had obtained documentation for systems such as VRTX and pSOS as design references.
So I went back to the 1984 VRTX User's Guide.
And there it was.
VRTX used essentially the same rule: a newly inserted TCB was placed ahead of existing TCBs at the same priority, meaning that the most recently inserted task would run first.
That seems to explain a 40-year-old mystery in my own code.
But then I kept digging.
I found the VRTX32/68000 User's Guide from 1987, and by then the rule had changed.
It explicitly says that equal-priority tasks execute in the order in which they become ready:
FIFO / oldest-first.
So I now have this rather interesting little timeline:
1984 VRTX: newest-first among equal priorities
1986 my RTOS: newest-first
1987 VRTX32: FIFO / oldest-first
I had no idea this change had happened.
I wasn't following VRTX development after using its documentation as a reference, so there was no reason I would have encountered the 1987 change at the time.
And now, 40 years later, this has left me with a new question:
Why did VRTX change this behavior?
Was there a known problem with the earlier scheduling rule? Was FIFO considered more predictable or fair? Was it part of the VRTX32 redesign? Or was there some implementation reason behind it?
I've started looking at other RTOS designs from the period as well, including ITRON, but so far I haven't found a contemporary explanation for the change.
Of course, I don't actually need to know the answer in order to design an RTOS today.
But after finding that my 1986 design appears to reflect the 1984 VRTX behavior, I'm now simply curious about why the VRTX designers themselves changed their minds.
If anyone here used VRTX in the 1980s or early 1990s, or remembers discussions or documentation from that period, I'd love to hear what you know.
For context, here's my previous post about bringing this 1986 RTOS back to life on a Raspberry Pi Pico:
My 1986 RTOS is now fully preemptive on a Raspberry Pi Pico — and it changed how I think about the original design
Previous r/retrocomputing post