Static analysis of concurrent avionics software

Similar documents
Towards an industrial use of FLUCTUAT on safety-critical avionics software

AstréeA From Research To Industry

Static Analysis by A. I. of Embedded Critical Software

Safety Manual. for ait, Astrée, StackAnalyzer. AbsInt Angewandte Informatik GmbH

Formal Verification in Aeronautics: Current Practice and Upcoming Standard. Yannick Moy, AdaCore ACSL Workshop, Fraunhofer FIRST

AUTOBEST: A microkernel-based system (not only) for automotive applications. Marc Bommert, Alexander Züpke, Robert Kaiser.

StackAnalyzer Proving the Absence of Stack Overflows

Structuring an Abstract Interpreter through Value and State Abstractions: EVA, an Evolved Value Analysis for Frama C

Automatic Qualification of Abstract Interpretation-based Static Analysis Tools. Christian Ferdinand, Daniel Kästner AbsInt GmbH 2013

Integration of Mixed Criticality Systems on MultiCores: Limitations, Challenges and Way ahead for Avionics

Static Analysis of Embedded Systems

Simulink 모델과 C/C++ 코드에대한매스웍스의정형검증툴소개 The MathWorks, Inc. 1

Différents cas d application de l'analyse Statique avec Frama-C dans un contexte industriel

Deos SafeMCTM. - Flight Software Workshop - Thursday December 7 th, Safety Critical Software Solutions for Mission Critical Systems

WIND RIVER ANSWERS TO 50 QUESTIONS TO ASK YOUR ARINC 653 VENDOR

Certification Authorities Software Team (CAST) Position Paper CAST-25

Technical presentation

User guide - VIM plus AOG & RG - V1. New VIM plus AOG & RG. User guide

Green Hills Software, Inc.

Analyse statique de programmes avioniques

Hierarchical Shape Abstraction of Dynamic Structures in Static Blocks

European Component Oriented Architecture (ECOA ) Collaboration Programme: Architecture Specification Part 2: Definitions

Relational Abstract Domains for the Detection of Floating-Point Run-Time Errors

Foundations of the C++ Concurrency Memory Model

FAA Order Simple And Complex Electronic Hardware Approval Guidance. Federal Aviation Administration

Development Guidance and Certification Considerations

Guidelines for deployment of MathWorks R2010a toolset within a DO-178B-compliant process

Static Analysis and Verification of Aerospace Software

Typed Assembly Language for Implementing OS Kernels in SMP/Multi-Core Environments with Interrupts

Verification and Profiling tools

GNAT Pro Innovations for High-Integrity Development

REDUCING CERTIFICATION GRANULARITY TO INCREASE ADAPTABILITY OF AVIONICS SOFTWARE

Why testing and analysis. Software Testing. A framework for software testing. Outline. Software Qualities. Dependability Properties

Architecture-driven development of Climate Control Software LMS Imagine.Lab Embedded Software Designer Siemens DF PL

Integrated Modular Avionics Development Guidance and Certification Considerations

SafeRiver SME. Added Value Solutions for Embedded Systems. Tools for FuSa and Software Security. Packaged Services. CIR agreed

Incremental Functional Certification (IFC) on Integrated Modular Avionics (IMA)

How much is a mechanized proof worth, certification-wise?

SCADE. SCADE Suite Tailored for Critical Applications EMBEDDED SOFTWARE

Applying MILS to multicore avionics systems

Multicore ARM Processors for Safety Critical Avionics

Synchronous Specification

A Formally-Verified C static analyzer

Model-Based Design for High Integrity Software Development Mike Anthony Senior Application Engineer The MathWorks, Inc.

ANSYS SCADE 17.0 Solutions for ARINC 661-Compliant Systems

DO-330/ED-215 Benefits of the new Tool Qualification

Hierarchical Pointer Analysis

7/6/2015. Motivation & examples Threads, shared memory, & synchronization. Imperative programs

Overview of Potential Software solutions making multi-core processors predictable for Avionics real-time applications

Motivation & examples Threads, shared memory, & synchronization

Deductive Verification in Frama-C and SPARK2014: Past, Present and Future

Applications of Program analysis in Model-Based Design

Fiji VM Safety Critical Java

SCADE. SCADE 19.2 Solutions for ARINC 661 Compliant Systems. The ARINC 661 Standard EMBEDDED SOFTWARE

David R. Mackay, Ph.D. Libraries play an important role in threading software to run faster on Intel multi-core platforms.

UNDERSTANDING PROGRAMMING BUGS IN ANSI-C SOFTWARE USING BOUNDED MODEL CHECKING COUNTER-EXAMPLES

A Model-Based Reference Workflow for the Development of Safety-Related Software

Software architecture in ASPICE and Even-André Karlsson

DO-254 Testing of High Speed FPGA Interfaces by Nir Weintroub, CEO, and Sani Jabsheh, Verisense

Static Analysis methods and tools An industrial study. Pär Emanuelsson Ericsson AB and LiU Prof Ulf Nilsson LiU

Simulink/Stateflow. June 2008

Why Study Assembly Language?

An Overview of the BLITZ System

Intel Parallel Studio 2011

A Context-Sensitive Memory Model for Verification of C/C++ Programs

Evolving Frama-C Value Analysis

Reaching for the sky with certified and safe solutions for the aerospace market

Ensuring Schedulability of Spacecraft Flight Software

Practical introduction to Frama-C (without Mathematical notations ;-) )

CSE 403: Software Engineering, Fall courses.cs.washington.edu/courses/cse403/16au/ Static Analysis. Emina Torlak

Leveraging Formal Methods for Verifying Models and Embedded Code Prashant Mathapati Application Engineering Group

SUCCESSFULL MULTICORE CERTIFICATION WITH SOFTWARE-PARTITIONING Efficient Implementation for DO-178C, EN 50128, ISO 26262

An incremental and multi-supplement compliant process for Autopilot development to make drones safer

S1.1: RESEARCH AND DEVELOPMENT IN EUROPE FOR COMPETITIVE MANUFACTURING. Competitiveness of Industry by means of Cross Fertilisation

Hybrid Verification in SPARK 2014: Combining Formal Methods with Testing

Verasco: a Formally Verified C Static Analyzer

Cloud Programming James Larus Microsoft Research. July 13, 2010

The Apron Library. Bertrand Jeannet and Antoine Miné. CAV 09 conference 02/07/2009 INRIA, CNRS/ENS

MEMORY MANAGEMENT TEST-CASE GENERATION OF C PROGRAMS USING BOUNDED MODEL CHECKING

Formal proofs of code generation and verification tools

3 4

Just-In-Time Certification

Oracle Communications Configuration Management

Characterization of COTS Microkernel-based Systems using MAFALDA

GPM0002 E9171-based Graphics/Compute Engine

Safe Reactive Programming: the FunLoft Proposal

Institut Supérieur de l Aéronautique et de l Espace Ocarina: update and future directions

Outline. Analyse et Conception Formelle. Lesson 7. Program verification methods. Disclaimer. The basics. Definition 2 (Specification)

Using Intel Inspector XE 2011 with Fortran Applications

Concurrency, Thread. Dongkun Shin, SKKU

Static Analysis of Embedded C

ABSTRACT INTERPRETATION

Computer Systems A Programmer s Perspective 1 (Beta Draft)

Data Model Considerations for Radar Systems

From MDD back to basic: Building DRE systems

Synchronization I. Jo, Heeseung

Model Checking Embedded C Software using k-induction and Invariants

Widening Operator. Fixpoint Approximation with Widening. A widening operator 2 L ˆ L 7``! L is such that: Correctness: - 8x; y 2 L : (y) v (x y)

Automatic Code Generation Technology Adoption Lessons Learned from Commercial Vehicle Case Studies

Java Memory Model. Jian Cao. Department of Electrical and Computer Engineering Rice University. Sep 22, 2016

Transcription:

Static analysis of concurrent avionics software with AstréeA Workshop on Static Analysis of Concurrent Software David Delmas Airbus 11 September 2016

Agenda 1 Industrial context Avionics software Formal methods 2 Static analysis of avionics software 3 Concurrent avionics software 4 Perspectives

Avionics Software at Airbus We develop software for cockpit avionics computers Software functions Aircraft Control Domain flight controls, warning, communication systems (C, asm) Airline Information Services Domain administrative functions, maintenance support (Java) Software platforms ATSU LynxOS R -based POSIX Host Platform IMA ARINC 653 Integrated Modular Avionics ASF PikeOS R -based Avionics Server Function x86 PowerPC PowerPC

Agenda 1 Industrial context Avionics software Formal methods 2 Static analysis of avionics software Static analysis of executables in today s industrial processes Static analysis of source code in today s industrial processes Ongoing technology transfers 3 Concurrent avionics software The AstréeA project Case studies and experiments 4 Perspectives

Software inside civil aircraft Avionics software critical components of embedded systems e.g. flight-by-wire control major impact on safety widely used inside modern aircraft

Size (MB) Awareness on ED-12/DO-178 version B and C Software inside civil aircraft Software embedded on Airbus aircraft May 2015 First real use of embedded software : at the beginning of the eighties 120 100 108 80 60 40 20 0 0,004 0,023 2 5 12 Year

Software inside civil aircraft Avionics software critical components of embedded systems e.g. flight-by-wire control major impact on safety widely used inside modern aircraft Certification by third parties on behalf of Authorities Federal Aviation Administration, European Aviation Safety Agency stringent rules on development and verification processes DO-178/ED-12 international standard Software Considerations in Airborne Systems and Equipment Certification

Awareness on ED-12/DO-178 version B and C May 2015 DO-178C/ED-12C Verification Process A-3.2 Accuracy & Consistency A-3.3 HW Compatibility A-3.4 Verifiability A-3.5 Conformance A-3.7 Algorithm Accuracy A-4. 8 Architecture Compatibility A-4.9 Consistency A-4.10 HW Compatibility A-4.11 Verifiability A-4.12 Conformance A-4.13 Partition Integrity System Requirements Software Architecture (A-2: 1, 2) High-Level Requirements (A-2: 3, 4, 5) Low-Level Requirements A-3.1 Compliance A-3.6 Traceability A-4.1 Compliance A-4.6 Traceability A-4.2 Accuracy & Consistency A-4.3 HW Compatibility A-4.4 Verifiability A-4.5 Conformance A-4.7 Algorithm Accuracy Compliance: with requirements Conformance: with standards A7 Verification of verification (Functional & Structural coverage) A-5.2 Compliance A-5.3 Verifiability A-5.4 Conformance A-5.6 Accuracy & Consistency A-5. 7 Complete & Correct (A-2: 6) Source Code (A-2: 7) Executable Object Code A-5.1 Compliance A-5.5 Traceability A-6.5 Compatible With Target A-6.3 Compliance A-6.4 Robustness A-6.1 Compliance A-6.2 Robustness

Awareness on ED-12/DO-178 version B and C May 2015 DO-178C/ED-12C Verification Process Level A A-3.2 Accuracy & Consistency A-3.3 HW Compatibility A-3.4 Verifiability A-3.5 Conformance A-3.7 Algorithm Accuracy A-4. 8 Architecture Compatibility A-4.9 Consistency A-4.10 HW Compatibility A-4.11 Verifiability A-4.12 Conformance A-4.13 Partition Integrity System Requirements Software Architecture (A-2: 1, 2) High-Level Requirements (A-2: 3, 4, 5) Low-Level Requirements A-3.1 Compliance A-3.6 Traceability A-4.1 Compliance A-4.6 Traceability A-4.2 Accuracy & Consistency A-4.3 HW Compatibility A-4.4 Verifiability A-4.5 Conformance A-4.7 Algorithm Accuracy Compliance: with requirements Conformance: with standards With Independence A7 Verification of verification (Functional & Structural coverage) A-5.2 Compliance A-5.3 Verifiability A-5.4 Conformance A-5.6 Accuracy & Consistency A-5. 7 Complete & Correct (A-2: 6) Source Code (A-2: 7) Executable Object Code A-5.1 Compliance A-5.5 Traceability A-6.5 Compatible With Target A-6.3 Compliance A-6.4 Robustness A-6.1 Compliance A-6.2 Robustness

Awareness on ED-12/DO-178 version B and C May 2015 DO-178C/ED-12C Verification Process Level B A-3.2 Accuracy & Consistency A-3.3 HW Compatibility A-3.4 Verifiability A-3.5 Conformance A-3.7 Algorithm Accuracy A-4. 8 Architecture Compatibility A-4.9 Consistency A-4.10 HW Compatibility A-4.11 Verifiability A-4.12 Conformance A-4.13 Partition Integrity System Requirements Software Architecture (A-2: 1, 2) High-Level Requirements (A-2: 3, 4, 5) Low-Level Requirements A-3.1 Compliance A-3.6 Traceability A-4.1 Compliance A-4.6 Traceability A-4.2 Accuracy & Consistency A-4.3 HW Compatibility A-4.4 Verifiability A-4.5 Conformance A-4.7 Algorithm Accuracy Compliance: with requirements Conformance: with standards With Independence A7 Verification of verification (Functional & Structural coverage) A-5.2 Compliance A-5.3 Verifiability A-5.4 Conformance A-5.6 Accuracy & Consistency A-5. 7 Complete & Correct (A-2: 6) Source Code (A-2: 7) Executable Object Code A-5.1 Compliance A-5.5 Traceability A-6.5 Compatible With Target A-6.3 Compliance A-6.4 Robustness A-6.1 Compliance A-6.2 Robustness

Awareness on ED-12/DO-178 version B and C May 2015 DO-178C/ED-12C Verification Process Level C A-3.2 Accuracy & Consistency A-3.3 HW Compatibility A-3.4 Verifiability A-3.5 Conformance A-3.7 Algorithm Accuracy A-4. 8 Architecture Compatibility A-4.9 Consistency A-4.10 HW Compatibility A-4.11 Verifiability A-4.12 Conformance A-4.13 Partition Integrity System Requirements Software Architecture (A-2: 1, 2) High-Level Requirements (A-2: 3, 4, 5) Low-Level Requirements A-3.1 Compliance A-3.6 Traceability A-4.1 Compliance A-4.6 Traceability A-4.2 Accuracy & Consistency A-4.3 HW Compatibility A-4.4 Verifiability A-4.5 Conformance A-4.7 Algorithm Accuracy Compliance: with requirements Conformance: with standards No more Independence for Verifications No more required A7 Verification of verification (Functional & Structural coverage) A-5.2 Compliance A-5.3 Verifiability A-5.4 Conformance A-5.6 Accuracy & Consistency A-5. 7 Complete & Correct (A-2: 6) Source Code (A-2: 7) Executable Object Code A-5.1 Compliance A-5.5 Traceability A-6.5 Compatible With Target A-6.3 Compliance A-6.4 Robustness A-6.1 Compliance A-6.2 Robustness

Awareness on ED-12/DO-178 version B and C May 2015 DO-178C/ED-12C Verification Process Level D A-3.2 Accuracy & Consistency A-3.3 HW Compatibility A-3.4 Verifiability A-3.5 Conformance A-3.7 Algorithm Accuracy A-4. 8 Architecture Compatibility A-4.9 Consistency A-4.10 HW Compatibility A-4.11 Verifiability A-4.12 Conformance A-4.13 Partition Integrity System Requirements Software Architecture (A-2: 1, 2) High-Level Requirements (A-2: 3, 4, 5) Low-Level Requirements A-3.1 Compliance A-3.6 Traceability A-4.1 Compliance A-4.6 Traceability Compliance: with requirements Conformance: with standards No more Independence for Verifications No more required A7 Verification of verification (Only Functional coverage) A-4.2 Accuracy & Consistency A-4.3 HW Compatibility A-4.4 Verifiability A-4.5 Conformance A-4.7 Algorithm Accuracy A-5.2 Compliance A-5.3 Verifiability A-5.4 Conformance A-5.6 Accuracy & Consistency A-5. 7 Complete & Correct (A-2: 6) Source Code (A-2: 7) Executable Object Code A-5.1 Compliance A-5.5 Traceability A-6.5 Compatible With Target A-6.3 Compliance A-6.4 Robustness A-6.1 Compliance A-6.2 Robustness

Awareness on ED-12/DO-178 version B and C May 2015 DO-178C/ED-12C Verification Process Level E No safety requirements when level E is accepted by the certification authority" Executable Object Code But, industrial constraints has to be satisfied => specific requirements are set up by aircraft manufacturer or suppliers (e.g. ABD 100 for Airbus)!

Agenda 1 Industrial context Avionics software Formal methods 2 Static analysis of avionics software Static analysis of executables in today s industrial processes Static analysis of source code in today s industrial processes Ongoing technology transfers 3 Concurrent avionics software The AstréeA project Case studies and experiments 4 Perspectives

The need for formal verification Verification legacy methods: tests, reviews, and analyses more than half of avionics software development costs no longer scale within reasonable costs

The need for formal verification Verification legacy methods: tests, reviews, and analyses more than half of avionics software development costs no longer scale within reasonable costs Some formal verification techniques are useable on real-world industrial software mostly AI-based static analysis some WP-based program proof increasingly used in Airbus verification processes to replace legacy methods

The requirement for soundness DO-333 Formal Methods Supplement to DO-178C guidance on the use of formal techniques emphasizes soundness as the key criterion The soundness of each formal analysis method should be justified. A sound method never asserts that a property is true when it may not be true.

The requirement for soundness DO-333 Formal Methods Supplement to DO-178C guidance on the use of formal techniques emphasizes soundness as the key criterion The soundness of each formal analysis method should be justified. A sound method never asserts that a property is true when it may not be true. DO-333 acknowledges FM may be used to achieve

The requirement for soundness DO-333 Formal Methods Supplement to DO-178C guidance on the use of formal techniques emphasizes soundness as the key criterion The soundness of each formal analysis method should be justified. A sound method never asserts that a property is true when it may not be true. DO-333 acknowledges FM may be used to achieve The objectives of by static analysis of source code reviews and analyses of source code provided a formal semantics is well-defined at source code level

The requirement for soundness DO-333 guidance on the use of formal techniques emphasizes soundness as the key criterion Formal Methods Supplement to DO-178C DO-333 acknowledges FM may be used to achieve The objectives of by static analysis of source code reviews and analyses of source code provided a formal semantics is well-defined at source code level Part of the objectives of 1 by static analysis of binary code testing 2 by static analysis of source code provided property preservation between source and executable code can be demonstrated

Industrial context Static analysis of avionics software Concurrent avionics software Perspectives Summary of industrial and regulatory requirements for static analysis tools in the avionics domain Soundness because human expertise cannot be replaced with unsound methods in safety-critical domains. Tools must undergo stringent qualification processes before they can be used for certification credit. Automation and precision to replace legacy methods cost-efficiently. Scalability because we deal with large industrial software.

Agenda 1 Industrial context 2 Static analysis of avionics software Static analysis of executables in today s industrial processes Static analysis of source code in today s industrial processes Ongoing technology transfers 3 Concurrent avionics software 4 Perspectives

Agenda 1 Industrial context Avionics software Formal methods 2 Static analysis of avionics software Static analysis of executables in today s industrial processes Static analysis of source code in today s industrial processes Ongoing technology transfers 3 Concurrent avionics software The AstréeA project Case studies and experiments 4 Perspectives

AbsInt binary static analyzers used for certification WCET Analysis on DAL A time-critical software products AI-based static analysis of executable code deployed on A330/A340/A380/A400M/A350 e.g. PowerPC MPC755 and 7448, TI TMS320C33 sequential/synchronous programs, up to 650 kloc ait WCET qualified wrt. DO-178B Stack Analysis on all embedded software products AI-based static analysis of executable code deployed on all aircraft types e.g. x86, PowerPC 755, 7448, 8610, TI TMS320C3x also multithreaded asynchronous programs with complex data structures up to 2 MloC StackAnalyzer qualified wrt. DO-178B

Agenda 1 Industrial context Avionics software Formal methods 2 Static analysis of avionics software Static analysis of executables in today s industrial processes Static analysis of source code in today s industrial processes Ongoing technology transfers 3 Concurrent avionics software The AstréeA project Case studies and experiments 4 Perspectives

Run-time error analysis of synchronous C programs Run-time errors overflows in float, integer, enum arithmetic and cast division, modulo by 0 on integers and floats invalid pointer arithmetic or dereferencing violation of user-specified assertions

Run-time error analysis of synchronous C programs Run-time errors overflows in float, integer, enum arithmetic and cast division, modulo by 0 on integers and floats invalid pointer arithmetic or dereferencing violation of user-specified assertions The ASTRÉE static analyzer developed by CNRS/ENS (from 2002) and AbsInt GmbH commercialised by AbsInt since 2010

Run-time error analysis of synchronous C programs Run-time errors overflows in float, integer, enum arithmetic and cast division, modulo by 0 on integers and floats invalid pointer arithmetic or dereferencing violation of user-specified assertions The ASTRÉE static analyzer developed by CNRS/ENS (from 2002) and AbsInt GmbH commercialised by AbsInt since 2010 Deployment at Airbus DAL A A380/A400M fly-by-wire successful proofs of absence of run-time error 8 hours for 650,000 lines of C (A350 soon)

Industrial context Static analysis of avionics software Concurrent avionics software Perspectives Local static analyses on small subsets of the call graph Data & control flow analyses AI-based static analysis of C code first deployments on A350 Fan-C (Airbus), a Frama-C (CEA-INRIA) plugin qualified wrt. DO-178B Unit Proof on DAL A software subsets WP-based program proof at C function level deployed on A380/A400M/A350 Caveat (CEA) + Alt-Ergo SMT-solver (INRIA) qualified wrt. DO-178B on-going effort to 1 migrate to Frama-C/WP 2 enlarge the scope of the deployment

Agenda 1 Industrial context Avionics software Formal methods 2 Static analysis of avionics software Static analysis of executables in today s industrial processes Static analysis of source code in today s industrial processes Ongoing technology transfers 3 Concurrent avionics software The AstréeA project Case studies and experiments 4 Perspectives

Numerical accuracy assessment of basic floating-point operators AI-based static analysis of C source code experimental deployment on A350 automates (manual) accuracy analyses FLUCTUAT (CEA) Certified compilation from source to assembly CompCert (INRIA) certified compiler formally verified semantic equivalence complementary to formal verification of C code Security/reliability analysis of Java software AI-based static analysis of Java bytecode Julia (Julia srl) DAL E airline information service software

Agenda 1 Industrial context 2 Static analysis of avionics software 3 Concurrent avionics software The AstréeA project Case studies and experiments 4 Perspectives

Trend towards concurrency The most safety-critical software DAL A-B e.g. bare-metal synchronous fly-by-wire sequential/synchronous safety-critical software increasingly addressed by sound static analysis

Trend towards concurrency The most safety-critical software e.g. bare-metal synchronous fly-by-wire sequential/synchronous safety-critical software increasingly addressed by sound static analysis DAL A-B Less critical software DAL C-D-E e.g. flight management, warning, communication, maintenance 1 increasingly integrated into generic avionics computers IMA Integrated Modular Avionics replaces buses with shared memory communications RTOS provides robust time and space partitioning (preemptive) single-core real-time scheduling static resource allocation 2 implemented in asynchronous software A380/A400M/A350 ARINC 653 standard POSIX threads real-time threads, locks, memory

Issues Verification test: ineffective due the huge number of thread interleavings human reviews and analyses: costly and error-prone source-level formal methods: lacking

Issues Verification test: ineffective due the huge number of thread interleavings human reviews and analyses: costly and error-prone source-level formal methods: lacking Available sound techniques WCET Analysis Stack Analysis Data & control flow analyses Unit Proof Numerical accuracy assessment Certified compilation Security analysis for Java Run-time error analysis with ASTRÉEA memory abstracted as assuming shared variables given

Agenda 1 Industrial context Avionics software Formal methods 2 Static analysis of avionics software Static analysis of executables in today s industrial processes Static analysis of source code in today s industrial processes Ongoing technology transfers 3 Concurrent avionics software The AstréeA project Case studies and experiments 4 Perspectives

Static analysis of parallel C programs Concrete semantics and specification Model: real-time operating system fixed set of concurrent threads on a single processor shared memory synchronisation primitives real-time scheduling with fixed priorities (implicit communications) (fixed set of mutexes) (priority-based) e.g. A380/A400M/A350 IMA, A350 ASF, A320/A330/A340 ATSU mono-threaded startup multi-threaded run (restriction)

Static analysis of parallel C programs Concrete semantics and specification Model: real-time operating system fixed set of concurrent threads on a single processor shared memory synchronisation primitives real-time scheduling with fixed priorities (implicit communications) (fixed set of mutexes) (priority-based) e.g. A380/A400M/A350 IMA, A350 ASF, A320/A330/A340 ATSU mono-threaded startup multi-threaded run (restriction) Run-time errors classic C run-time errors unprotected data-races deadlocks incorrect system calls (overflows, invalid pointers, etc.) (report & factor in the analysis)

ASTRÉEA Analyseur Statique de logiciels Temps-RÉel Embarqués Asynchrones The ASTRÉEA static analyser prototype extension of ASTRÉE developed by CNRS/ENS/INRIA since 2009 industrialized by AbsInt since october 2015 see next talk

ASTRÉEA Analyseur Statique de logiciels Temps-RÉel Embarqués Asynchrones The ASTRÉEA static analyser prototype extension of ASTRÉE developed by CNRS/ENS/INRIA since 2009 industrialized by AbsInt since october 2015 see next talk The ASTRÉEA project 2012 2016 cooperation between CNRS/ENS/INRIA and Airbus supported by French ANR ANR-11-INSE-014 Goal based on industrial case studies, specialise the analyser to make it precise for a family of large, complex multithreaded avionics software products

Agenda 1 Industrial context Avionics software Formal methods 2 Static analysis of avionics software Static analysis of executables in today s industrial processes Static analysis of source code in today s industrial processes Ongoing technology transfers 3 Concurrent avionics software The AstréeA project Case studies and experiments 4 Perspectives

Industrial context Static analysis of avionics software Concurrent avionics software Perspectives Main case study Performed in an academic settings while specialising the analyzer A. Miné a large ARINC 653 application: monitors aircraft functions and relays them to the pilots embedded avionics software (DAL C) 2.1 Mloc (2 Mloc generated) 15 threads, shared memory, locks preemptive real-time scheduling on a single processor reactive code + network code + lists, strings, pointers many variables, large arrays many (nested) loops no dynamic memory allocation, no recursivity

Industrial context Static analysis of avionics software Concurrent avionics software Perspectives Main case study Performed in an academic settings while specialising the analyzer A. Miné

Analysis context Concrete execution context: Target application, in C Other applications ARINC 653 operating system, in C+asm Hardware The target application: runs concurrently with other applications (memory separation) interacts dynamically with an ARINC 653 operating system (thread control, mutex lock and unlock, communication services) interacts with other applications through the OS creates system objects only during an initialization phase (the set of objects is inferred by the analysis)

Analysis context Abstract analysis context: Target application, in C ARINC 653 model, in C + built-ins The target application is enriched with hand-written model of the OS 2.6 Kloc of C + low-level AstréeA built-ins stub and simulate all OS system calls manage (fat) OS objects, mapped to (thin) AstréeA objects (e.g., AstréeA s locks are simple integers, ARINC 653 s locks have a string name) = analyze stand-alone C programs, with no undefined symbol

Results Precision: achieved through specialization 2010: 12, 257 alarms 2015: 1, 195 alarms (60% on hand-written code) 99.94% selectivity (% of lines without alarm) 2302 directives added (to improve precision) Efficiency: on an intel i7 2.90 GHz workstation computation time: 24h analysis iterations: 6 27 GB RAM (1 core used) (no widening needed on interferences)

Industrial context Static analysis of avionics software Concurrent avionics software Perspectives Second case study Performed in an industrial settings a large ARINC 653 application from the same family after analyzer specialisation 11 threads, similar structure 20% common hand-written code 2 (non-consecutive) revisions analysed S2.1 1.9 Mloc (1.8 Mloc generated) S3.2 2.1 Mloc (2 Mloc generated) Airbus Analysis adaptation ARINC 653 model reused (8% adaptation + 7 new primitives) S2.1 2178 directives (adapted from main case study) S3.2 5% adaptation wrt S2.1 Results S2.1 8573 alarms (99.56% selectivity) S3.2 10735 alarms (99.52% selectivity)

Industrial context Static analysis of avionics software Concurrent avionics software Perspectives Third case study Performed in an industrial settings a subset of a POSIX threads real-time application after analyzer specialisation Airbus monitoring/correlation of maintenance related-information 7 threads, 32 Kloc (DAL E, 100% hand-written) pervasive string processing large arrays of structures, (nested) loops, pointer arithmetics Analysis preparation 790 loc of stubs to abstract away the unanalysed (parts of) threads of the application development of a library of stubs for a subset of POSIX threads real-time 45 API functions, 1.2 Kloc 197 AstréeA directives to improve precision Results 865 alarms (97.28% selectivity)

Industrial context Static analysis of avionics software Concurrent avionics software Perspectives Fourth case study Performed in an industrial settings after analyzer specialisation Airbus a subset of a POSIX threads real-time middleware data-link communication cockpit displays 1 process (4 threads), 33 Kloc (100% hand-written) filesystem, named pipes, shared memories very old version of POSIX Analysis preparation important adaptations of stub library 228 AstréeA directives to improve precision 70 API functions, 1 Kloc Results 932 alarms (94.5% selectivity)

Summary Main case study (academic settings) analyser specialisation Case studies in industrial settings enrich ARINC 653 stubs with newly used functions design a full set of POSIX threads stubs analysis precision tuning through end-user directives no modification of the analyzer constrained adaptation effort (1 to 4 man-month) reproduced with commercial ASTRÉE see next talk Case Size RTOS Stubs Selectivity Time Memory Setting 1 2.1 M A 653 5.2 K 99.94% 24 h 27 GB acad 2.a 1.9 M A 653 2.4 K 99.56% 154 h 18 GB indus 2.b 2.2 M A 653 2.3 K 99.52% 160 h 23 GB indus 3 31.8 K POSIX 2.2 K 97.28% 50 mn 0.6 GB indus 4 33.1 K POSIX 1.2 K 97.18% 35 h 2.5 GB indus selectivity only slightly worse than for the main case study = towards a cost-effective industrial use of AstréeA

Agenda 1 Industrial context 2 Static analysis of avionics software 3 Concurrent avionics software 4 Perspectives

On-going work Towards zero alarm Precision target for cost-efficient deployment (avionics domain) 99.80% selectivity on hand-written code (currently: 95.97% to 99.2%) 99.99% selectivity on automatically generated code (currently: 99.78% to 99.98%) = not quite there yet, but reasonable goal Multicore Sound and precise analysis for weak consistency memory models

Industrial deployment First scope: automate reviews and analyses of source code 1 Accuracy and consistency DO-333 FM.6.3.4.f absence of run-time error probably on a subset-basis for huge applications 2 Compliance with the software architecture DO-333 FM.6.3.4.b check the set of threads, locks, and shared objects access modes by each thread This will require qualification wrt DO-178C/DO-333. Longer term: alleviate robustness testing this will require 1 a more demanding qualification level 2 a formal proof that the semantics is preserved on the compiled code extension of CompCert s proof?

This document and all information contained herein is the sole property of AIRBUS Operations S.A.S. No intellectual property rights are granted by the delivery of this document or the disclosure of its content. This document shall not be reproduced or disclosed to a third party without the express written consent of AIRBUS Operations S.A.S. This document and its content shall not be used for any purpose other than that for which it is supplied. The statements made herein do not constitute an offer. They are based on the mentioned assumptions and are expressed in good faith. Where the supporting grounds for these statements are not shown, AIRBUS Operations S.A.S will be pleased to explain the basis thereof. AIRBUS, its logo, A300, A310, A318, A319, A320, A321, A330, A340, A350, A380, A400M are registered trademarks. Thank you for your attention. Questions?