System Software and TinyAUTOSAR

Similar documents
Deeply Embedded Real-Time Hypervisors for the Automotive Domain Dr. Gary Morgan, ETAS/ESC

Comparison of Service Call Implementations in an AUTOSAR Multi-core OS

Weighted Total Mark. Weighted Exam Mark

Real-Time Component Software. slide credits: H. Kopetz, P. Puschner

POSIX. RTOSes Part I. POSIX Versions. POSIX Versions (2)

A Hardware/Software Platform for Real-time Ethernet Cluster Simulation in OMNeT++

Achieving Nanosecond Latency Between Applications with IPC Shared Memory Messaging

Implementing AUTOSAR Scheduling and Resource Management on an Embedded SMT Processor

Open Source Implementation of Hierarchical Scheduling for Integrated Modular Avionics

PikeOS: Multi-Core RTOS for IMA. Dr. Sergey Tverdyshev SYSGO AG , Moscow

Notes and terms of conditions. Vendor shall note the following terms and conditions/ information before they submit their quote.

Chapter 19: Real-Time Systems. Overview of Real-Time Systems. Objectives. System Characteristics. Features of Real-Time Systems

XtratuM hypervisor redesign for LEON4 multicore processor

Predictable response times in event-driven real-time systems

Chapter 6, The Operating System Machine Level

ECU State Manager Module Development and Design for Automotive Platform Software Based on AUTOSAR 4.0

Mixed-Criticality: Integration of Different Models of Computation. University of Siegen, Roman Obermaisser

Module 8. Industrial Embedded and Communication Systems. Version 2 EE IIT, Kharagpur 1

White Paper. Real-time Capabilities for Linux SGI REACT Real-Time for Linux

REAL TIME OPERATING SYSTEMS. Lesson-10:

SYSTEM ecos Embedded Configurable Operating System

Chapter 11 I/O Management and Disk Scheduling

2.1 What are distributed systems? What are systems? Different kind of systems How to distribute systems? 2.2 Communication concepts

Safety and Security Features in AUTOSAR

ARINC 653. An Avionics Standard for Safe, Partitioned Systems

Real- Time Mul,- Core Virtual Machine Scheduling in Xen

Do AUTOSAR and functional safety rule each other out?

Performance Comparison of RTOS

The Real-Time Operating System ucos-ii

BMW Car IT GmbH. AUTOSAR - First Experiences and the Migration Strategy of the BMW Group

Java Environment for Parallel Realtime Development Platform Independent Software Development for Multicore Systems

Implementing AUTOSAR Scheduling and Resource Management on an Embedded SMT Processor

Embedded OS. Product Information

AUTOBEST: A United AUTOSAR-OS and ARINC 653 Kernel

Chapter 13 Embedded Operating Systems

Thomas Fahrig Senior Developer Hypervisor Team. Hypervisor Architecture Terminology Goals Basics Details

How To Write A Windows Operating System (Windows) (For Linux) (Windows 2) (Programming) (Operating System) (Permanent) (Powerbook) (Unix) (Amd64) (Win2) (X

Enhancing the Monitoring of Real-Time Performance in Linux

Memory Access Control in Multiprocessor for Real-time Systems with Mixed Criticality

Real-time Operating Systems. VO Embedded Systems Engineering Armin Wasicek

Software Stacks for Mixed-critical Applications: Consolidating IEEE AVB and Time-triggered Ethernet in Next-generation Automotive Electronics

Page 1 of 5. IS 335: Information Technology in Business Lecture Outline Operating Systems

Operating Systems Concepts: Chapter 7: Scheduling Strategies

Threads Scheduling on Linux Operating Systems

Real-time KVM from the ground up

Middleware. Peter Marwedel TU Dortmund, Informatik 12 Germany. technische universität dortmund. fakultät für informatik informatik 12

Chapter 11 I/O Management and Disk Scheduling

Linux A multi-purpose executive support for civil avionics applications?

System Software Integration: An Expansive View. Overview

HIPEAC Segregation of Subsystems with Different Criticalities on Networked Multi-Core Chips in the DREAMS Architecture

Operating System Components

Quality of Service su Linux: Passato Presente e Futuro

Multicore scheduling in automotive ECUs

AUTOSAR Runtime Environment and Virtual Function Bus

Hard Real-Time Linux

CSC 2405: Computer Systems II

Aperiodic Task Scheduling

CHAPTER 1: OPERATING SYSTEM FUNDAMENTALS

COS 318: Operating Systems. Virtual Machine Monitors

Real Time Programming: Concepts

Stream Processing on GPUs Using Distributed Multimedia Middleware

Plug and Play Solution for AUTOSAR Software Components

Partition Scheduling in APEX Runtime Environment for Embedded Avionics Software

User-friendly Configuration of AUTOSAR ECUs with Specialized Software Tools

Embedded Systems. 6. Real-Time Operating Systems

Have both hardware and software. Want to hide the details from the programmer (user).

AUTOSAR Software Architecture

BASIC CONCEPTS OF REAL TIME OPERATING SYSTEMS

Virtualization for Hard Real-Time Applications Partition where you can Virtualize where you have to

BLM 413E - Parallel Programming Lecture 3

Red Hat Linux Internals

I/O Management. General Computer Architecture. Goals for I/O. Levels of I/O. Naming. I/O Management. COMP755 Advanced Operating Systems 1

Safety and security related features in AUTOSAR

Chapter 3: Operating-System Structures. System Components Operating System Services System Calls System Programs System Structure Virtual Machines

Seminar Automotive Open Systems Architecture

An Implementation Of Multiprocessor Linux

Hypervisors. Introduction. Introduction. Introduction. Introduction. Introduction. Credits:

In-Memory Databases Algorithms and Data Structures on Modern Hardware. Martin Faust David Schwalb Jens Krüger Jürgen Müller

Deciding which process to run. (Deciding which thread to run) Deciding how long the chosen process can run

First-class User Level Threads

AUTOSAR Safety Solutions for Multicore ECUs and ADAS Systems. Robert Leibinger 5 th June 2015

Processes and Non-Preemptive Scheduling. Otto J. Anshus

Experience with the integration of distribution middleware into partitioned systems

Design Patterns for Packet Processing Applications on Multi-core Intel Architecture Processors

ARINC-653 Inter-partition Communications and the Ravenscar Profile

Control 2004, University of Bath, UK, September 2004

XMOS Programming Guide

Standardized software components will help in mastering the. software should be developed for FlexRay were presented at

HARDWARE ACCELERATION IN FINANCIAL MARKETS. A step change in speed

Runtime Verification for Real-Time Automotive Embedded Software

Today. Intro to real-time scheduling Cyclic executives. Scheduling tables Frames Frame size constraints. Non-independent tasks Pros and cons

Far-western University Central Office, Mahendranagar Operating System

Transcription:

System Software and TinyAUTOSAR Florian Kluge University of Augsburg, Germany parmerasa Dissemination Event, Barcelona, 2014-09-23

Overview parmerasa System Architecture Library RTE Implementations TinyIMA pbios4cm TinyAUTOSAR Parallelisation techniques for AUTOSAR Parallelised Interrupt Handler Synchronisation Buffers Performance Evaluation of Remote Service Calls 2

RTE Requirements Scheduling Com. & Sync. Automotive Avionic Construction Pre-emptive (Earliest Deadline First) Resources, Events, buffered/unbuffered Messages Fixed cyclic + Preemptive Messages; Events, Buffers, Blackboards, Semaphores Round-robin Events, Semaphores, Spin-Locks I/O Low latency Predictability Low latency Protection OS-Application, (Task) Partition Task Blocking sync./com. techniques need interaction with system scheduler different scheduling algorithms 3

System Architecture Application Layer Application Specific Domain Specific Interface User Mode Non-Critical RTE Services Domain Specific Protection Boundary Critical RTE Services Mode Scheduling Protection Communication & Synchronisation I/O Domain Specific Context Management Memory Management Synchronisation Mechanisms Services Interrupt Handling Common Library Simulated Hardware 4

Library Abstraction of underlying hardware Provides RTE-independent services WCET-analysable primitives Synchronisation functions for parallel applications Common base for RTE implementations OS consists of Library RTE-specific isolation-critical services Non-critical RTE services: no influence on other partitions 5

Avionic System Architecture Partition I Partition II APEX APEX User Mode ARINC 653 O/S (Non-Critical Services) Protection Boundary ARINC 653 O/S (Non-Critical Services) ARINC 653 O/S (Critical Services) Mode Library Simulated Hardware 6

TinyIMA Implementation Minimal subset of ARINC 653 API required by Honeywell application to guarantee time isolation Partition and process management Communication and synchronisation primitives Buffers, Queueing Ports, Semaphores ARINC XML system definition replaced with C functions Extend API to support cluster-based many-cores Partitions Clusters CONNECT_SRCDST_QUEUING_PORTS Processes Cores BIND_PROCESS_TO_CORE No parallelisation at TinyIMA level has been provided 7

Construction Machinery System Architecture Parallelized BAUER Application Middleware pbios4cm - Interrupt handling - Thread divided to cores Library Simulated Hardware 8

pbios4cm - Parallel BIOS for Construction Machinery Based on BIOS API of original ECU vendor Single-core TriCore system (ESX-3XL from Sensortechnik Wiedemann) Basic functions for thread scheduling, I/O, timing Modifications: Thread-safe re-design and implementation (sources not available) Simplified thread management: One thread per core Supported I/O functionalities CAN Generic I/O for PWM, digital and analogue input Interrupt and DMA system 9

Automotive System Architecture Application Layer User Mode AUTOSAR Runtime Environment (RTE) Protection Boundary Critical RTE Services (Tiny AUTOSAR) OS System Services Abstraction Layer I/O Hardware Abstraction Microcontroller Abstraction Layer Complex Drivers Mode Library Simulated Hardware 10

TinyAUTOSAR Properties: Evaluation platform for parallelised automotive applications executed in parallel Provide minimum subset of AUTOSAR software architecture Comprise basic functionalities required on any core Provide basic communication and synchronisation features for multi-/many-core processors Implementations: Multicore Implementation according to AUTOSAR 4.x Implementation with optimisations for parallelised applications 11

Optimisations for Parallelised Applications Support for execution of parallelised tasks and runnables Alternative scheduling: time synchronous execution model Synchronisation buffers Extended to support parallelised interrupt handler Communication Comparison of implementation approaches of cross core service calls 12

Time synchronous execution model Time-triggered execution of tasks/runnables Exchange of data only at time synchronisation points no need for explicit synchronisation! For regular tasks: defined in PharOS Sequential Task R2 R3 R5 R2 R3 R2 R5 R2 R3 R2 Parallelised Task R2 R2 R2 R2 R2 R3 R5 R3 R5 R3 0 1 2 3 4 5 6 8 13

Synchronisation Buffer Aim: each runnable execution has time-consistent view of input data buffer data, access relative to TSP Latest possible TSP TSP starting point of R3 TSP R1 R1 R1 2 R1 3 R1 4 R1 R1 R1 R1 R3 0 R3 1 R3 1 R3 2 0 1 2 3 4 5 6 Buffering duration of data from R1 2 7 8 14

Synchronous Execution of a Parallelised Interrupt Handler Exploit time synchronous execution model also for ISRs! TSPs ADV(3) ADV(4) Time Core 1 (TT) A1 A2 A3 A1 IRQ i at t IRQ(i) 0 4 8 ADV abs (t) ADV(2) System Real- Time Clock H Core 2 (ET) IH PH PH Core 3 (ET) ADV abs (t) spawn PH 0 4 ADV(2) PH PH Real-Time Clock H IRQ(i) t = t IRQ(i) + t WCTT = 4 CRP TSP Ax IH PH Agent x (TT domain) Initial Handler (ET domain) Processing Handler (ET domain) CRP ADV abs (t) Clock Reference Point time base for future ADV instructions on corresponding cores Advance Absolute Instruction advances to an absolute point of system real-time clock t IRQ(i) t WCTT Interrupt event i at time t Worst Case Traversal Time 15

Results Actual start time of Processing Handler: 150-200 cycles after elapse of counter Deviation between Processing handlers: <50 cycles ADV(3) ADV(4) Time A1 A2 A3 A1 0 4 8 ADV abs (t) ADV(2) IH PH PH spawn PH 0 4 ADV abs (t) PH ADV(2) PH t = t IRQ(i) + t WCTT = 4 CRP TSP 16

Remote Service Calls General Structure of Service call: Service Call Check passed yes Action Return no Some service calls can affect other cores e.g. ActivateTask Questions: Where should the single parts be executed? How is communication organised? 17

Cross-Core Service Calls: Approaches Message based OS data access across core Lock based direct OS data access across core OS data OS data OS data OS data Core Core Core Core Everything on Target Core Check & Action on Source core, Only Rescheduling on Target Core 18

Experimental Results Advantage for lock based approach Less remote core blocking times Faster execution Message based OS data access across core Lock based direct OS data access across core OS data OS data OS data OS data Core Core Core Core 19

Summary RTE bases for parmerasa applications Avionic: TinyIMA Construction Machinery: pbios4cm Automotive: TinyAUTOSAR Adaption for application parallelisation Automotive RTE: TinyAUTOSAR Minimum evaluation platform Investigations using TinyAUTOSAR: Time-synchronous execution Synchronisation buffers Synchronous execution of parallelised interrupt handler Performance of remote service calls: messages vs. locks 20