wingert a thread migrating os for real time applications
play

WINGERT A Thread Migrating OS for Real-Time Applications Alexander - PowerPoint PPT Presentation

WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke WINGERT A Thread Migrating OS for Real-Time Applications Alexander Zpke alexander.zuepke@hs-rm.de About Me WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Alexander Zpke 1999 2003:


  1. WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke WINGERT A Thread Migrating OS for Real-Time Applications Alexander Züpke alexander.zuepke@hs-rm.de

  2. About Me WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Alexander Züpke 1999 – 2003: Diploma in Computer Engineering University of Applied Sciences Gelsenkirchen 2003 – now: Kernel Hacker on PikeOS SYSGO AG, Klein-Winternheim 2012 – now: PhD Student RheinMain University of Applied Sciences Wiesbaden 2

  3. Wingert WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Win·gert m., Pl: Win·ger·te German word in Rhine-Hessian dialect for a vineyard derived from the Middle High German word wîngarte (wine garden) 3

  4. Wingert OS WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke WI esbaden N ext G eneration E xperimental R eal- T ime O perating S ystem … or: W INGERT I s a N ew G reat E xperimental R eal- T ime O perating S ystem 4

  5. Outline WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke ● Motivation ● System Architecture ● Various Use Cases of Thread Migration ● Resource Management ● Futexes and Locking ● Current Status of the Implementation ● Conclusion ● Outlook 5

  6. Motivation WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Safety Critical Systems … 6

  7. WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke 7

  8. WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke 8

  9. Motivation WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Safety requirements for shared resources ● IEC 61508 “An E/E/PE* safety-related system will usually implement more than one safety function. If the safety integrity requirements for these safety functions differ, unless there is sufficient independence of implementation between them, the requirements applicable to the highest relevant safety integrity level shall apply to the entire E/E/PE safety-related system.” ● ISO 26262 “Freedom of interference” * E/E/PE: electrical / electronic / programmable electronic 9

  10. Motivation WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Mixed-criticality system Separation by Partitioning ARINC 653: P1 P2 P3 P4 – Spatial Partitioning most less least critical critical critical critical – Time Partitioning user mode supervisor mode OS Kernel 10

  11. Motivation WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Own Experience: Micro kernels are nice, but building reliable systems with them is still too painful! Lots of engineering challenges: – bounded WCET when Linux runs on top? – independent analyses of partitions? – more threads + more synchronization = more safety? 11

  12. System Architecture WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke ● Design Choices – Hierarchical system design – Small TCB – Minimalistic kernel P1 P2 P3 P4 ● Address spaces most less least ● Threads critical critical critical critical ● Capabilities ● Resource partitioning shared driver 2 ● Preemptive kernel shared driver 1 ● State of the art scheduling – Thread migration OS Kernel 12

  13. WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Thread Migration 13

  14. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke ● Definition of “thread migration” in literature – a client lends its thread to the server – the server is a passive entity ● Examples P1 P2 P3 P4 – Mach (Ford) – Sun's Spring – Pebble – Composite – … OS Kernel 14

  15. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Decompose a thread into Body and Soul: ● Body: user part of a thread Body – register context ● Entry point ● User Stack – user stack ● TLS ● Soul: kernel part of a thread – scheduling attributes – kernel stack Soul Ghost: soul without a body ● Priority ● Deadline initial state ● Kernel Stack idle threads 15

  16. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Decompose a thread into Body and Soul: ● Body: user part of a thread Body – register context ● Entry point ● User Stack – user stack ● TLS ● Soul: kernel part of a thread – scheduling attributes – kernel stack Soul ● Ghost: soul without a body ● Priority ● Deadline – initial state ● Kernel Stack – idle threads 16

  17. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Synchronous call and return operations: – a soul migrates back and forth between bodies – forms a call chain free body active body soul 17

  18. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Synchronous call and return operations: – a soul migrates back and forth between bodies – forms a call chain free body occupied body active body call soul 18

  19. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Synchronous call and return operations: – a soul migrates back and forth between bodies – forms a call chain occupied body active body call 19

  20. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Synchronous call and return operations: – a soul migrates back and forth between bodies – forms a call chain free body occupied body active body return 20

  21. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Synchronous call and return operations: – a soul migrates back and forth between bodies – forms a call chain free body active body return 21

  22. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke The forward operation: – to call another body – without keeping the caller occupied 22

  23. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke The forward operation: – to call another body – without keeping the caller occupied l l a c 23

  24. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke The forward operation: – to call another body – without keeping the caller occupied forward 24

  25. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke The forward operation: – to call another body – without keeping the caller occupied 25

  26. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke The forward operation: – to call another body – without keeping the caller occupied return 26

  27. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Asynchronous fork / join operations: – fork: tell an idle soul to call a body – join: asynchronous call returns fork go for It! 27

  28. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Asynchronous fork / join operations: – fork: tell an idle soul to call a body – join: asynchronous call returns call 28

  29. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Asynchronous fork / join operations: – fork: tell an idle soul to call a body – join: asynchronous call returns 29

  30. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Asynchronous fork / join operations: – fork: tell an idle soul to call a body – join: asynchronous call returns return 30

  31. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Asynchronous fork / join operations: – fork: tell an idle soul to call a body – join: asynchronous call returns I'm done! join 31

  32. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Signals and Exception Handling: ● Exceptions – implicitly turn exceptions into calls to exception-handlers – pass faulting register context to called body Exception Handler Signals Faulter signal delivery: force a soul call into a (non-voluntary) call software raised exception 32

  33. Thread Migration WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke Signals and Exception Handling: ● Exceptions – implicitly turn exceptions into calls to exception-handlers – pass faulting register context to called body Exception Handler ● Signals Faulter – signal delivery: force a soul call into a (non-voluntary) call – software raised exception force exc. Other 33

  34. Concurrent Access WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke ● Two souls want to enter the same body … – First come, first serve! The other soul has to wait. – Entry wait queue Q – FIFO or priority ordering – Priority inheritance call Q 34

  35. Concurrent Access WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke ● Two souls want to enter the same body … – First come, first serve! The other soul has to wait. – Entry wait queue Q – FIFO or priority ordering – Priority inheritance Q 35

  36. Concurrent Access WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke ● Two souls want to enter the same body … – First come, first serve! The other soul has to wait. – Entry wait queue Q – FIFO or priority ordering – Priority inheritance call Q 36

  37. Concurrent Access WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke ● Two souls want to enter the same body … – First come, first serve! The other soul has to wait. – Entry wait queue Q – FIFO or priority ordering – Priority inheritance Q waiting 37

  38. Concurrent Access WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke ● Two souls want to enter the same body … – First come, first serve! The other soul has to wait. – Entry wait queue Q – FIFO or priority ordering – Priority inheritance n r Q u t e r waiting 38

  39. Concurrent Access WAMOS @ HSRM Wiesbaden 2014-02-13 A. Zuepke ● Two souls want to enter the same body … – First come, first serve! The other soul has to wait. – Entry wait queue Q – FIFO or priority ordering – Priority inheritance Q 39

Download Presentation
Download Policy: The content available on the website is offered to you 'AS IS' for your personal information and use only. It cannot be commercialized, licensed, or distributed on other websites without prior consent from the author. To download a presentation, simply click this link. If you encounter any difficulties during the download process, it's possible that the publisher has removed the file from their server.

Recommend


More recommend