Real time operating systems
Download
1 / 26

Real Time Operating Systems - PowerPoint PPT Presentation


  • 351 Views
  • Updated On :

Real Time Operating Systems. Alexandru Andrei Embedded Systems Lab. Computer and Information Science Dept., Linköping University alean@ida.liu.se. QNX (RealTime)Solaris, (RealTime) NT RealTime Java, RealTime Linux. The Question - RealTime Nachos. ?. Why not RealTime Nachos ?

loader
I am the owner, or an agent authorized to act on behalf of the owner, of the copyrighted work described.
capcha
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 l.jpg

Real Time Operating Systems

Alexandru Andrei

Embedded Systems Lab.

Computer and Information Science Dept., Linköping University

alean@ida.liu.se

Alexandru Andrei ESLAB/IDA/LIU


The question realtime nachos l.jpg

QNX

(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 l.jpg

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

But...?

App Specific RTOS ?

Alexandru Andrei ESLAB/IDA/LIU


Rtos training environment l.jpg

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)

But....??

RTOS Training Environment?

Alexandru Andrei ESLAB/IDA/LIU


Focus l.jpg

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

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

To a real Linux system?

To a simulated system as Nachos?

Focus

Alexandru Andrei ESLAB/IDA/LIU


Focus6 l.jpg

Things that matter…. QNX)

Dispatch time

Interrupt handling (NT example)

Scheduling and priority handling(example: NT and Solaris)

Memory management

Program (library) loading

…. and more

Focus

Alexandru Andrei ESLAB/IDA/LIU


Recall dispatch time l.jpg
Recall: Dispatch Time QNX)

Alexandru Andrei ESLAB/IDA/LIU


Example nt interrupts l.jpg
Example: NT Interrupts QNX)

Turn off lower level interrupts...

...perform minimal preparations...

...initiate aDeferred Procedure Call

Alexandru Andrei ESLAB/IDA/LIU


Rt nt nope l.jpg

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 l.jpg
Example: Solaris Priority Classes way and user-level

Alexandru Andrei ESLAB/IDA/LIU


Rules for solaris real time apps l.jpg

Runs in the RT scheduling class way and user-level

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 l.jpg
Example: NT priority classes way and user-level

Alexandru Andrei ESLAB/IDA/LIU


Memory management l.jpg

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 l.jpg

Save memory space (dynamic binding) physical memory

… 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 l.jpg

Right now - there is no such thing... physical memory

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 l.jpg

The clock ticks: physical memory

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


Slide17 l.jpg

What happens when the interrupts are off? physical memory

How much time does it take to execute one instruction?

Other ”Hot spots”:

Scheduler

Memory management

Interrupts

Synchronization

...

Hmm ...

Alexandru Andrei ESLAB/IDA/LIU


The project scenario l.jpg

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 l.jpg

Request to all research divisions: systems....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 http://www.ida.liu.se/~TDDB72/rtproj for CFP and details!

The Project - Scenario

Alexandru Andrei ESLAB/IDA/LIU


The project in parctice l.jpg

Pick one of the following two subjects systems....

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 l.jpg

Teams of 2 students systems....

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 petlo@ida.liu.se 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 l.jpg

All reports will be read and commented, systems....(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 l.jpg

Presentation (cont): systems....

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 l.jpg

Deadlines: systems....

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 l.jpg

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)

www.ida.liu.se/~TDDB72/reading …for more material!

Reading Material

Alexandru Andrei ESLAB/IDA/LIU


Slide26 l.jpg

Good luck ! Environment (Solaris RealTime, SUN tech. paper)

Alexandru Andrei ESLAB/IDA/LIU