real time operating systems
Skip this Video
Download Presentation
Real Time Operating Systems

Loading in 2 Seconds...

play fullscreen
1 / 26

Real Time Operating Systems - PowerPoint PPT Presentation

  • Uploaded on

Real Time Operating Systems. Alexandru Andrei Embedded Systems Lab. Computer and Information Science Dept., Linköping University [email protected] QNX (RealTime)Solaris, (RealTime) NT RealTime Java, RealTime Linux. The Question - RealTime Nachos. ?. Why not RealTime Nachos ?

I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
Download Presentation

PowerPoint Slideshow about 'Real Time Operating Systems' - PamelaLan

An Image/Link below is provided (as is) to download presentation

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.

- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -
Presentation Transcript
real time operating systems

Real Time Operating Systems

Alexandru Andrei

Embedded Systems Lab.

Computer and Information Science Dept., Linköping University

[email protected]

Alexandru Andrei ESLAB/IDA/LIU

the question realtime nachos

(RealTime)Solaris, (RealTime) NT

RealTime Java, RealTime Linux

The Question - RealTime Nachos


Why not RealTime Nachos ?

Why not a RT Linux?

Alexandru Andrei ESLAB/IDA/LIU

app specific rtos
Build a RTOS from scratch (QNX)

Better design

Use an existing OS and add RT functionality (Solaris, RT Linux)

Can use already existing tools (compilers)

Easy to operate


App Specific RTOS ?

Alexandru Andrei ESLAB/IDA/LIU

rtos training environment
Use a special purpose RTOS with its development tools (e.g., QNX)

Same env. as in actual development stage

Use an existing OS with added RT functionality

Affordable training equipment (ordinary systems?)

Use a simulator (e.g., RT-Natchos)

Runs on all platforms (potentially)


RTOS Training Environment?

Alexandru Andrei ESLAB/IDA/LIU

Previous two lectures have shown a few “real” RTOS’es

Can we add real-time support to an operating system?

To a real Linux system?

To a simulated system as Nachos?


Alexandru Andrei ESLAB/IDA/LIU

Things that matter….

Dispatch time

Interrupt handling (NT example)

Scheduling and priority handling(example: NT and Solaris)

Memory management

Program (library) loading

…. and more


Alexandru Andrei ESLAB/IDA/LIU

recall dispatch time
Recall: Dispatch Time

Alexandru Andrei ESLAB/IDA/LIU

example nt interrupts
Example: NT Interrupts

Turn off lower level interrupts...

...perform minimal preparations...

...initiate aDeferred Procedure Call

Alexandru Andrei ESLAB/IDA/LIU

rt nt nope
NT does not prioritize device interrupts in any controllable way and user-level

applications execute only after device drivers

The system\'s devices and drivers (not NT) ultimately determine the worst-case delay

NT cannot deterministically forecast maximum delays

RT NT ? Nope …

Alexandru Andrei ESLAB/IDA/LIU

example solaris priority classes
Example: Solaris Priority Classes

Alexandru Andrei ESLAB/IDA/LIU

rules for solaris real time apps
Runs in the RT scheduling class

Locks down all the memory in its process address space

Is from a statically-linked program or from a program in which all dynamic binding is completed early

Acquires the processor within the guaranteed dispatch latency period of becoming runnable

Continues to run for as long as it remains the highest priority runnable process

Rules for Solaris Real-Time Apps

Alexandru Andrei ESLAB/IDA/LIU

example nt priority classes
Example: NT priority classes

Alexandru Andrei ESLAB/IDA/LIU

memory management
lock specified portions of its virtual address space into physical memory

locked pages are exempt from paging until they are unlocked or the process exits

its application’s responsibility to lock a page (or all) using a system call

Memory Management

Memory locking

(SUN, NT …)

… to guarantee continuous memory residence to

reduce latency and to prevent paging and swapping.

Alexandru Andrei ESLAB/IDA/LIU

shared libraries
Save memory space (dynamic binding)

… but introduces nondeterminism at execution time

Solution (Solaris): early binding

dynamic linking to be bound before the program begins execution

Shared Libraries

Alexandru Andrei ESLAB/IDA/LIU

real time nachos
Right now - there is no such thing...

No real-time support built in

Even the notion of time is fuzzy(how to simulate time? In Nachos today? In a RT simulator...?)

”Real-Time” Nachos

Alexandru Andrei ESLAB/IDA/LIU

nachos clock today
The clock ticks:

When the interrupts are restored (reenabled)

When the simulator executes one instruction (ticks=ticks+1)

When the ready list is empty ticks=ticks+time_till_list_is_not_empty

Nachos Clock Today

Alexandru Andrei ESLAB/IDA/LIU

What happens when the interrupts are off?

How much time does it take to execute one instruction?

Other ”Hot spots”:


Memory management




Hmm ...

Alexandru Andrei ESLAB/IDA/LIU

the project scenario
The Big Corporation is building safety critical Real Time systems.......but in order to reduce costs:

Can we train RT-programmers in a simulated environment based on Nachos?

Can we use some RT-Linux in real projects?(instead of, e.g., QNX?)

The Project - Scenario

Alexandru Andrei ESLAB/IDA/LIU

the project scenario19
Request to all research divisions:Investigate and report!

Two tracks:

Simulated environment based on Nachos

Compare two RT-Linuxes for usage in real projects

Conclude with an open hearing of selected reports – where other authors acts as opponents

See also for CFP and details!

The Project - Scenario

Alexandru Andrei ESLAB/IDA/LIU

the project in parctice
Pick one of the following two subjects

Implementing (simulated) real-time on top of Nachos:Possible? Not possible? Good/bad stuff? Meaningful?Show what can be done (speculate!)

Perform a comparison of two alternative RT-Linuxes

Perform literature research and write a technical paper (4-6 pages, 5000-6000 words)

Describe the issues important in a RTOS and how they are handled in your ”system”

The Project – In parctice

Alexandru Andrei ESLAB/IDA/LIU

the project in parctice21
Teams of 2 students

Decide on topic – RT-Nachos or RT-Linux

RT-Linux teams:Select two RT-Linuxes to compare

Register (sign-up) your topic, and for RT-Linux teams, what Linuxes, by sending an email to [email protected] containing:

the words TDDB72 and RTPROJ in the subject

name and email of you and your partner in the group

your selected topic (when applicable: what RT-Linuxes)

The Project – In parctice

Alexandru Andrei ESLAB/IDA/LIU

the project in parctice22
All reports will be read and commented,(at least to some extent)

Too sloppy, erroneous or technically thin reports will be returned for improvement – at most once!

Presentation: We will place you in groups of 2-3 teams with the same topic

One team will present their work (~10min)

The other team will oppose, comment, and/or advocate for their own ideas... (~5min)

And the audience is also invited to ask questions and comment...

The Project – In parctice

Alexandru Andrei ESLAB/IDA/LIU

the project in practice
Presentation (cont):

3 presentations / 45min

3 groups active at each presentation

2 students * 3 groups * 3 presentations * 2h-lessons= 36 students/lesson

All ~80 groups covered in 5 lessons

Each student only participate in one 2h-lesson!

The Project – In practice

Alexandru Andrei ESLAB/IDA/LIU

the project in practice24

Sign up: v46 (before Monday 17/11 at 13.00)

Deadline for submissions: v48 (Friday 28/11)

Response at end of v49

Presentation: v50 (detailed schedule later)

Review Board: All staff in this course...

See names, phones and rooms on the web!

The Project – In practice

Alexandru Andrei ESLAB/IDA/LIU

reading material
Interval response components in the Solaris Operating Environment (Solaris RealTime, SUN tech. paper)

Windows NT as Real-Time OS? (Martin Timmerman)

Nachos lab compendium

RT Mach

Real-Time Systems (Jane Liu) (book)

Software Engineering for Real-Time Systems(Jim Cooling) (book) …for more material!

Reading Material

Alexandru Andrei ESLAB/IDA/LIU

Good luck !

Alexandru Andrei ESLAB/IDA/LIU