Relational Abstract Domains for the Detection of Floating-Point Run-Time Errors
|
|
- Walter Wilkerson
- 5 years ago
- Views:
Transcription
1 ESOP 2004 Relational Abstract Domains for the Detection of Floating-Point Run-Time Errors Antoine Miné École Normale Supérieure Paris FRANCE This work was partially supported by the ASTRÉE RNTL project
2 Introduction Faults in critical embedded software can cause human and financial cost! Example Ariane 5 launcher failure in June The first property one would expect is: absence of run-time error. Floating-Point Nowadays, embedded software use floating-point numbers instead of fixed-point. Floating-point numbers are complex, not always understood by programmers. Floating-point numbers are wrongly mistaken for perfect real numbers R. = it introduces new classes of run-time errors! What This Talk is About: static detection of floating-point run-time errors We want to be sound and efficient, and as precise as possible. Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 1/22
3 A Few Words on Floating-Point Arithmetics
4 Floating-Point Numbers We consider the IEEE norm because: it is widely implemented in today s hardware (Intel, Motorola); it is supported by the C language (and many others). 32-bit single precision float numbers F Sign Exponent e Fraction b s e 8 e 1 b 1 b 23 The set F of float is composed of: normalized numbers: ( 1) s 2 e b 1 b 23 (1 e 254); But also: denormalized numbers: ( 1) s b 1 b 23 (e = 0, b 0) zeros: +0 and 0 (if e = 0, b = 0); infinities: + and (if e = 255, b = 0); error codes: NaN (if e = 255, b 0). Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 2/22
5 Floating-Point Computations Floating-Point Expressions E V = {V 1,..., V n } is a finite set of variables. E :== V i variable V i V c constant in F E 1 E 2 binary operator {,,, } E opposite Floating-Point Arithmetics Floating-point computation differs from real arithmetics +,,, /: rounding to a representable float occurs; large numbers, division by 0 generate + or (overflow); small numbers round to +0 or 0 (underflow); invalid operations (0/0,(+ ) + ( ), etc.) generate NaN. Several types of rounding: towards +,, 0 or to nearest. Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 3/22
6 Our Floating-Point Semantics We consider programs that use F as approximated reals: rounding and underflow are benign; overflow and invalid operations result in a run-time error Ω; error-free computation live in F F R, assimilated to a finite part of R. Expression Semantics Let ρ (V F ) be a concrete environment. Let e E be a floating-point expression. e evaluated in ρ is denoted by: e (ρ) F {Ω} e (ρ) can be defined by structural induction on e Problem Formalization We wish to know if Ω can be computed by the program. This is a reachability problem. Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 4/22
7 Abstract Interpretation
8 Abstract Reachability Problem: our space state is finite but huge! Solution: we use the Abstract Interpretation framework [Cousot 77]. An abstract domain is defined by: a computer-representable set D that represent elements of P(V F ); sound abstract counterparts in D of all semantics building blocks: assignments: V i e, e E; tests: e 0?, e E; control-flow joins. We perform reachability analysis in D instead of P(V F ). By construction, it computes an over-approximation of the set of concrete reachable states. Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 5/22
9 Already Existing Abstract Domains Classical abstract domains abstract P(V Z) or P(V Q). Intervals Polyhedra Octagons [Cousot 76] [Cousot Halbwachs 78] [Miné 01] Vi [ci; di] i α ivi βi ±Vi ± Vj c Problem: how to adapt them to P(V F )? Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 6/22
10 Interval Domain Adapted to Floating-Point Classical Interval Domain d D associates to each variable an upper and a lower bound; Using interval arithmetics +,,, /, we can define the abstract value e (d ) of an expression in an environment d D. e.g. [a; b]+ [a ; b ] def = [a+a ; b+b ] Abstract assignments and tests are derived from e. Adaptation to Floating-Point Numbers [Goubault 01] Adapting the interval domain to P(V F ) is easy. d now associates to each variable an upper and a lower bound in F. When performing interval arithmetics,,,, we round lower bounds toward and upper bounds toward +. { e.g. [a; b] [a ; b ] = def [a a ; b + b ] if a a Ω and b + b Ω Ω otherwise The interval domain is fast but not very precise. Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 7/22
11 Where Intervals Fail Rate Limiter RLim (in X, in D, out Y) { static S=Y; (last output) R=X S; (actual rate) Y=X; if (R D) Y=S D; (upper clamp) if (R D) Y=S D; (lower clamp) } X RLim D Y We suppose that: the main entry X stays in [ 128; 128]; the rate maximum D stays in [0; 16]. The interval domain finds that, after n calls to RLim, Y [ n; n]. Actually, Y [ 128; 128] independently from n and there is no overflow! To prove this, one would have to be able to: represent the relational invariants R = X S and R D; combine them to deduce X S D, so Y = S D X. Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 8/22
12 Difficulties in Adapting Relational Domains Relational domains cannot manipulate invariants expressed in (F,,,, ). They use properties of Q not true in floating-point arithmetics! e.g. X + Y c Z Y d = X + Z c + d (Octagon propagation) X Y c Z Y d X Z c d = invariant semantics will be expressed using Q,+,,,/. Transfer functions accept linear expressions: α 0 + i α iv i, α i Q. e is not linear due to rounding! = we introduce a new linearization technique Arbitrary precision rationals traditionally used in domain implementation are costly. We wish to use floating-point arithmetics internally to trade precision for efficiency. = such algorithms will be presented for the Octagon domain Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 9/22
13 Linearization
14 Interval Linear Forms Interval Linear Forms We introduce Interval Linear Forms l L: symbolic expressions of the form l = [a; b] + i [a i; b i ] V i where the program variables V i are free variables. Benefits of This Representation Each l L can be viewed as a function concrete environment real interval. l is defined using only operators on real intervals +,, no rounding is used. Interval coefficient can describe non-deterministic relative and absolute errors. L is a linear space; it is stable by: addition multiplication by a constant substraction division by a constant = we will abstract e as an interval linear form Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 10/22
15 Computations on Interval Linear Forms Internal Representation For efficiency purposes we wish to: use floating-point numbers to represent all bounds a, b, a i, b i ; (maybe another floating-point format than the analyzed expression... ) manipulate interval linear forms using only floating-point computations. Approximated Linear Operators Floating-point interval arithmetics round lower bounds toward and upper bounds toward +. Thus,,,, over-approximate real interval arithmetics. We use this to efficiently over-approximate,, and as,, and. e.g. ([a; b] + i [a i; b i ] V i ) ([a ; b ] + i [a i ; b i ] V i) def = { ([a; b] [a ; b ]) + i ([a i; b i ] [a i ; b i ]) V i if no Ω occurs Ω if an interval evaluates to Ω Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 11/22
16 Computations on Interval Linear Forms Rounding Errors on Linear Forms The magnitude of rounding errors is the maximum of: a relative error ε of amplitude 2 23, expressed as a linear form: ε([a; b] + i [a i; b i ] V i ) (normalized numbers) def = max( a, b ) [ 2 23 ; 2 23 ]+ i (max( a i, b i ) [ 2 23 ; 2 23 ]) V i and an absolute error ω def = [ ; ] (denormalized numbers). We sum these two causes of rounding.! Non-Linear Behaviors We can always abstract further an interval linear form to a plain interval. ι(l, d ) flattens a linear form l into an interval, given an interval environment d : ι([a; b] + i [a i; b i ] V i, d ) def = [a; b] ( i [a i; b i ] d (V i )) (any summation order for is sound!) Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 12/22
17 From Expressions to Interval Linear Forms Given an interval abstract environment d, we abstract expressions as an interval linear form by structural induction: l(e 1 e 2, d ) l(e 1 e 2, d ) l([a; b] e 2, d ) l(e 1 [a; b], d ) l(e 1 e 2, d ) l(e 1 [a; b], d ) l(e 1 e 2, d ) l( e, d ) def = l(e 1, d ) l(e 2, d ) ε(e 1 ) ε(e 2 ) ω def = l(e 1, d ) l(e 2, d ) ε(e 1 ) ε(e 2 ) ω def = ([a; b] l(e 2, d )) ([a; b] ε(e 2 )) ω def = l([a; b] e 1, d ) def = l(ι(e 1, d ) e 2, d ) def = (l(e 1, d ) [a; b]) (ε(e 1 ) [a; b]) ω def = l(e 1 ι(e 2, d )) def = l(e, d ) Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 13/22
18 Main Theorem Theorem soundness of l(e, d ) Let d be an interval abstract environment If e (d ) Ω and l(e, d ) Ω then ρ satisfying d, e (ρ) l(e, d )(ρ) One of the following may happen: e (d ) = Ω: there is a potential RTE and l(e, d ) is not sound. e (d ) Ω, l(e, d ) = Ω: there is no RTE, due to over-approximation in F the linearization fails! e (d ) Ω, l(e, d ) Ω: there is no RTE and we can use l(e, d ). Linearization must work in tandem with the interval domain because: run-time errors are detected using solely the interval domain; interval information is used when computing l(e, d ); when the linearization fails, we must fallback to classical interval analysis. Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 14/22
19 Applications of Linearization Improving the Interval Domain Linearization performs simplification. We can replace e (d ) by e (d ) ι(l(e, d ), d ). e.g. l(x (0.25 X), d ) = [0.749 ; ]X [ 1; 1]. when X [ 1; 1], we get [ ; ] instead of [ 1.25 ; 1.25 ] Enabling Relational Analysis To perform relational analysis, we simply need a relational domain that: abstracts P(V F ) as invariants expressed using real arithmetics; has transfer functions for interval linear forms: assignments: V i [a; b] + i [a i; b i ] V i Examples: tests: [a; b] + i [a i; b i ] V i 0? we present next an application to the octagon abstract domain; [Feret 2004] presents an analysis of digital filters. Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 15/22
20 Floating-Point Octagons
21 Floating-Point Octagons Classical Octagons: sets of constraints of the form ±V i ± V j c, c Q. Memory Representation [Miné 2001] use a matrix of upper-bounds, in Q {+ }. For each V i, V j V, α, β {1; 1}, we store an upper bound for αv i + βv j Closure Algorithm It propagates and combines all constraints using O( V 3 ) local transformations: (αv i + βv j c) ( βv j + γv k d) = αv i + γv k c + d (αv i + αv i c) (βv j + βv j d) = αv i + βv j (c + d) / 2 Using Floating-Point Bounds Because bounds may be large, we use F {+ } instead of Q {+ }. Soundness of the closure is ensured by rounding bounds towards +. e.g. αv i + βv j c βv j + γv k d = αv i + γv k c + d Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 16/22
22 Interval Linear Transfer Functions Assignment: V j l We replace all constraints about V j by the constraints, V k V j : Test: l 0? V j V k max(ι(l V k, d )) V j + V k max(ι(l V k, d )) V k V j max(ι(v k l, d )) V j V k max(ι( l V k, d )) V j + V j 2 max(ι(l, d )) V j V j 2 max(ι( l, d )) For each V i, V j that appears in l, V i V j we add the constraints: V j V i max(ι(l V j V i, d )) V j + V i max(ι(l V j V i, d )) V j + V i max(ι(l V j V i, d )) V j V i max(ι(l V j V i, d )) V j + V j 2 max(ι(l V j, d )) V j V j 2 max(ι(l V j, d )) We only use interval information d on the right part of inferred constraints. These are not optimal, but give a good time / precision tradeoff. Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 17/22
23 Example Revisited Rate Limiter Revisited RLim (in X, in D, out Y) { static S=Y; (last output) R=X S; (actual rate) Y=X; if (R D) Y=S D; (upper clamp) if (R D) Y=S D; (lower clamp) } Where X stays in [ 128; 128] and D in [0; 16]. X RLim D Y The octagon domain is not able to represent exactly R = X S. Nevertheless, it can prove that Y [ 136; 136] independently from n. This is not optimal (Y [ 128; 128]) but it is sufficient to prove that there is no overflow. Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 18/22
24 Widenings The analysis of loops requires the computation of a post-fixpoint. Plain iterations converge (our domains are finite) but slowly. We use widenings [Cousot 77] to accelerate the convergence. Staged Widening on the Octagon Domain Let T F be a set of threshold steps. An octagon widening operates point-wise on two matrices m, n of upper-bounds: { def mij if m [m n] ij = ij n ij min{ t T {+ } t n ij } otherwise enlarges unstable bounds to the next step in T. Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 19/22
25 Losses of Precision In this work, we made several abstraction choices that incur a loss of precision: the interval linear forms: treat rounding non-deterministically; the octagon abstract domain: limits invariant expressivity; the octagon transfer functions: not optimal; the octagon staged widening: approximates fixpoints. Orthogonally, we chose an implementation using floating-point arithmetics: due to rounding, each abstract computation incurs an extra loss of precision. Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 20/22
26 Application
27 Experimental Results ASTRÉE Prototype [Blanchet et al. 2003] OCaml prototype, started in See us at Real-World Example primary flight control software of the Airbus A340 fly-by-wire system, 132, 000-line reactive C program, 10, 000 global variables, 5, 000 of which are 32-bit floating-point, one very large loop executed times. Results, on a 1.6 GHz Intel Centrino domains nb. of nb. of linearize octagons filters time iterations memory alarms (1) 3257 s MB 1785 (2) 2667 s MB 1466 (3) 3010 s MB 1371 (4) 7746 s MB 248 (5) 4363 s MB 0 Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 21/22
28 Conclusion Summary In this work we: proposed a sound and efficient,generic framework to design relational abstract domains on floating-point numbers; fully instantiated the framework to the octagon domain; (it could be instanciated to other domains, such as polyhedra) successfully applied it to the RTE analysis of a real-life application. Relational Abstract Domains for the Detection of Floating-Point RTE Antoine Miné 22/22
Relational Abstract Domains for the Detection of Floating-Point Run-Time Errors
Relational Abstract Domains for the Detection of Floating-Point Run-Time Errors Antoine Miné To cite this version: Antoine Miné. Relational Abstract Domains for the Detection of Floating-Point Run-Time
More informationBuilding a specialized static analyzer
Building a specialized static analyzer The Astrée experience Antoine Miné CNRS, École Normale Supérieure Security and Reliability of Software Systems 12 December 2008 Antoine Miné Building a specialized
More informationSymbolic Methods to Enhance the Precision of Numerical Abstract Domains
Symbolic Methods to Enhance the Precision of Numerical Abstract Domains Antoine Miné École Normale Supérieure, Paris, France, mine@di.ens.fr, http://www.di.ens.fr/ mine Abstract We present lightweight
More informationWeakly Relational Domains for Floating-Point Computation Analysis
Weakly Relational Domains for Floating-Point Computation Analysis Eric Goubault, Sylvie Putot CEA Saclay, F91191 Gif-sur-Yvette Cedex, France {eric.goubault,sylvie.putot}@cea.fr 1 Introduction We present
More informationInterval Polyhedra: An Abstract Domain to Infer Interval Linear Relationships
Interval Polyhedra: An Abstract Domain to Infer Interval Linear Relationships Liqian Chen 1,2 Antoine Miné 3,2 Ji Wang 1 Patrick Cousot 2,4 1 National Lab. for Parallel and Distributed Processing, Changsha,
More informationThe Apron Library. Bertrand Jeannet and Antoine Miné. CAV 09 conference 02/07/2009 INRIA, CNRS/ENS
The Apron Library Bertrand Jeannet and Antoine Miné INRIA, CNRS/ENS CAV 09 conference 02/07/2009 Context : Static Analysis What is it about? Discover properties of a program statically and automatically.
More informationWidening 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)
EXPERIENCE AN INTRODUCTION WITH THE DESIGN TOF A SPECIAL PURPOSE STATIC ANALYZER ABSTRACT INTERPRETATION P. Cousot Patrick.Cousot@ens.fr http://www.di.ens.fr/~cousot Biarritz IFIP-WG 2.3 2.4 meeting (1)
More informationStatic Analysis by A. I. of Embedded Critical Software
Static Analysis by Abstract Interpretation of Embedded Critical Software Julien Bertrane ENS, Julien.bertrane@ens.fr Patrick Cousot ENS & CIMS, Patrick.Cousot@ens.fr Radhia Cousot CNRS & ENS, Radhia.Cousot@ens.fr
More informationAbstract Interpretation of Floating-Point. Computations. Interaction, CEA-LIST/X/CNRS. February 20, Presentation at the University of Verona
1 Laboratory for ModElling and Analysis of Systems in Interaction, Laboratory for ModElling and Analysis of Systems in Interaction, Presentation at the University of Verona February 20, 2007 2 Outline
More informationThe ASTRÉE Analyzer Patrick Cousot 2, Radhia Cousot 1,3, Jerôme Feret 2, Laurent Mauborgne 2, Antoine Miné 2, David Monniaux 1,2, and Xavier Rival 2 1 CNRS 2 École Normale Supérieure, Paris, France Firstname.Lastname@ens.fr
More informationThe Apron Library. Antoine Miné. CEA Seminar December the 10th, CNRS, École normale supérieure
Antoine Miné CNRS, École normale supérieure CEA Seminar December the 10th, 2007 CEA December the 10th, 2007 Antoine Miné p. 1 / 64 Outline Introduction Introduction Main goals Theoretical background The
More informationAbstract Interpretation of Floating-Point Computations
Abstract Interpretation of Floating-Point Computations Sylvie Putot Laboratory for ModElling and Analysis of Systems in Interaction, CEA-LIST/X/CNRS Session: Static Analysis for Safety and Performance
More informationWhy does ASTRÉE scale up?
Form Methods Syst Des (2009) 35: 229 264 DOI 10.1007/s10703-009-0089-6 Why does ASTRÉE scale up? Patrick Cousot Radhia Cousot Jérôme Feret Laurent Mauborgne Antoine Miné Xavier Rival Published online:
More informationInterprocStack analyzer for recursive programs with finite-type and numerical variables
InterprocStack analyzer for recursive programs with finite-type and numerical variables Bertrand Jeannet Contents 1 Invoking InterprocStack 1 2 The Simple language 2 2.1 Syntax and informal semantics.........................
More informationScientific Computing. Error Analysis
ECE257 Numerical Methods and Scientific Computing Error Analysis Today s s class: Introduction to error analysis Approximations Round-Off Errors Introduction Error is the difference between the exact solution
More informationA Static Analyzer for Large Safety-Critical Software
A Static Analyzer for Large Safety-Critical Software (Extended Abstract) Bruno Blanchet Patrick Cousot Radhia Cousot Jérôme Feret Laurent Mauborgne Antoine Miné David Monniaux Xavier Rival ABSTRACT We
More information2 Computation with Floating-Point Numbers
2 Computation with Floating-Point Numbers 2.1 Floating-Point Representation The notion of real numbers in mathematics is convenient for hand computations and formula manipulations. However, real numbers
More informationMathematical preliminaries and error analysis
Mathematical preliminaries and error analysis Tsung-Ming Huang Department of Mathematics National Taiwan Normal University, Taiwan August 28, 2011 Outline 1 Round-off errors and computer arithmetic IEEE
More informationSendmail crackaddr - Static Analysis strikes back
Sendmail crackaddr - Static Analysis strikes back Bogdan Mihaila Technical University of Munich, Germany December 6, 2014 Name Lastname < name@mail.org > ()()()()()()()()()... ()()() 1 / 25 Abstract Interpretation
More informationStructuring an Abstract Interpreter through Value and State Abstractions: EVA, an Evolved Value Analysis for Frama C
Structuring an Abstract Interpreter through Value and State Abstractions: EVA, an Evolved Value Analysis for Frama C David Bühler CEA LIST, Software Safety Lab Frama-C & SPARK Day 2017 May 30th, 2017 David
More informationFloating-Point Arithmetic
Floating-Point Arithmetic Raymond J. Spiteri Lecture Notes for CMPT 898: Numerical Software University of Saskatchewan January 9, 2013 Objectives Floating-point numbers Floating-point arithmetic Analysis
More informationTowards an industrial use of FLUCTUAT on safety-critical avionics software
Towards an industrial use of FLUCTUAT on safety-critical avionics software David Delmas 1, Eric Goubault 2, Sylvie Putot 2, Jean Souyris 1, Karim Tekkal 3 and Franck Védrine 2 1. Airbus Operations S.A.S.,
More information1.2 Round-off Errors and Computer Arithmetic
1.2 Round-off Errors and Computer Arithmetic 1 In a computer model, a memory storage unit word is used to store a number. A word has only a finite number of bits. These facts imply: 1. Only a small set
More information2 Computation with Floating-Point Numbers
2 Computation with Floating-Point Numbers 2.1 Floating-Point Representation The notion of real numbers in mathematics is convenient for hand computations and formula manipulations. However, real numbers
More informationRepresenting and Manipulating Floating Points. Jo, Heeseung
Representing and Manipulating Floating Points Jo, Heeseung The Problem How to represent fractional values with finite number of bits? 0.1 0.612 3.14159265358979323846264338327950288... 2 Fractional Binary
More informationRepresenting and Manipulating Floating Points
Representing and Manipulating Floating Points Jin-Soo Kim (jinsookim@skku.edu) Computer Systems Laboratory Sungkyunkwan University http://csl.skku.edu The Problem How to represent fractional values with
More informationRepresenting and Manipulating Floating Points
Representing and Manipulating Floating Points Jin-Soo Kim (jinsookim@skku.edu) Computer Systems Laboratory Sungkyunkwan University http://csl.skku.edu The Problem How to represent fractional values with
More informationFast Algorithms for Octagon Abstract Domain
Research Collection Master Thesis Fast Algorithms for Octagon Abstract Domain Author(s): Singh, Gagandeep Publication Date: 2014 Permanent Link: https://doi.org/10.3929/ethz-a-010154448 Rights / License:
More informationComputational Economics and Finance
Computational Economics and Finance Part I: Elementary Concepts of Numerical Analysis Spring 2016 Outline Computer arithmetic Error analysis: Sources of error Error propagation Controlling the error Rates
More informationRepresenting and Manipulating Floating Points. Computer Systems Laboratory Sungkyunkwan University
Representing and Manipulating Floating Points Jin-Soo Kim (jinsookim@skku.edu) Computer Systems Laboratory Sungkyunkwan University http://csl.skku.edu The Problem How to represent fractional values with
More informationFinite arithmetic and error analysis
Finite arithmetic and error analysis Escuela de Ingeniería Informática de Oviedo (Dpto de Matemáticas-UniOvi) Numerical Computation Finite arithmetic and error analysis 1 / 45 Outline 1 Number representation:
More informationState of Practice. Automatic Verification of Embedded Control Software with ASTRÉE and beyond
Automatic Verification of Embedded Control Software with ASTRÉE and beyond Patrick Cousot Jerome C. Hunsaker Visiting Professor Department of Aeronautics and Astronautics, MIT cousot mit edu www.mit.edu/~cousot
More informationCS321. Introduction to Numerical Methods
CS31 Introduction to Numerical Methods Lecture 1 Number Representations and Errors Professor Jun Zhang Department of Computer Science University of Kentucky Lexington, KY 40506 0633 August 5, 017 Number
More informationFloating-point representations
Lecture 10 Floating-point representations Methods of representing real numbers (1) 1. Fixed-point number system limited range and/or limited precision results must be scaled 100101010 1111010 100101010.1111010
More informationIterative Program Analysis Abstract Interpretation
Iterative Program Analysis Abstract Interpretation Summary by Ben Riva & Ofri Ziv Soundness Theorem Theorem: If a computation fixed-point is sound, then its least-fixed-point is sound. More precisely,
More informationRepresenting and Manipulating Floating Points
Representing and Manipulating Floating Points Jinkyu Jeong (jinkyu@skku.edu) Computer Systems Laboratory Sungkyunkwan University http://csl.skku.edu SSE23: Introduction to Computer Systems, Spring 218,
More informationFloating-point representations
Lecture 10 Floating-point representations Methods of representing real numbers (1) 1. Fixed-point number system limited range and/or limited precision results must be scaled 100101010 1111010 100101010.1111010
More informationAlgebraic Program Analysis
Introduction to Algebraic Program Analysis Zachary Kincaid 1 Thomas Reps 2,3 1 Princeton University 2 University of Wisconsin-Madison 3 GrammaTech, Inc. January 8, 2018 1 Program analysis Design algorithms
More informationMAT128A: Numerical Analysis Lecture Two: Finite Precision Arithmetic
MAT128A: Numerical Analysis Lecture Two: Finite Precision Arithmetic September 28, 2018 Lecture 1 September 28, 2018 1 / 25 Floating point arithmetic Computers use finite strings of binary digits to represent
More informationFloating-point representation
Lecture 3-4: Floating-point representation and arithmetic Floating-point representation The notion of real numbers in mathematics is convenient for hand computations and formula manipulations. However,
More informationComputational Economics and Finance
Computational Economics and Finance Part I: Elementary Concepts of Numerical Analysis Spring 2015 Outline Computer arithmetic Error analysis: Sources of error Error propagation Controlling the error Rates
More informationFloating point. Today! IEEE Floating Point Standard! Rounding! Floating Point Operations! Mathematical properties. Next time. !
Floating point Today! IEEE Floating Point Standard! Rounding! Floating Point Operations! Mathematical properties Next time! The machine model Chris Riesbeck, Fall 2011 Checkpoint IEEE Floating point Floating
More informationVerasco: a Formally Verified C Static Analyzer
Verasco: a Formally Verified C Static Analyzer Jacques-Henri Jourdan Joint work with: Vincent Laporte, Sandrine Blazy, Xavier Leroy, David Pichardie,... June 13, 2017, Montpellier GdR GPL thesis prize
More informationFloating point. Today. IEEE Floating Point Standard Rounding Floating Point Operations Mathematical properties Next time.
Floating point Today IEEE Floating Point Standard Rounding Floating Point Operations Mathematical properties Next time The machine model Fabián E. Bustamante, Spring 2010 IEEE Floating point Floating point
More informationCS321 Introduction To Numerical Methods
CS3 Introduction To Numerical Methods Fuhua (Frank) Cheng Department of Computer Science University of Kentucky Lexington KY 456-46 - - Table of Contents Errors and Number Representations 3 Error Types
More informationTrace Partitioning in Abstract Interpretation Based Static Analyzers
Trace Partitioning in Abstract Interpretation Based Static Analyzers DI, Laurent Mauborgne and Xavier Rival École Normale Supérieure, 45 rue d Ulm, 75 230 Paris cedex 05, France Emails: Laurent.Mauborgne@ens.fr
More informationFloating Point (with contributions from Dr. Bin Ren, William & Mary Computer Science)
Floating Point (with contributions from Dr. Bin Ren, William & Mary Computer Science) Floating Point Background: Fractional binary numbers IEEE floating point standard: Definition Example and properties
More informationRoundoff Errors and Computer Arithmetic
Jim Lambers Math 105A Summer Session I 2003-04 Lecture 2 Notes These notes correspond to Section 1.2 in the text. Roundoff Errors and Computer Arithmetic In computing the solution to any mathematical problem,
More informationSystems I. Floating Point. Topics IEEE Floating Point Standard Rounding Floating Point Operations Mathematical properties
Systems I Floating Point Topics IEEE Floating Point Standard Rounding Floating Point Operations Mathematical properties IEEE Floating Point IEEE Standard 754 Established in 1985 as uniform standard for
More informationStatic Analysis and Verification of Aerospace Software
Static Analysis and Verification of Aerospace Software by Abstract Interpretation joint work with: Patrick Cousot Julien Bertrane and Radhia Cousot École normale supérieure, Paris Patrick Cousot, Courant
More informationData Representation Floating Point
Data Representation Floating Point CSCI 2400 / ECE 3217: Computer Architecture Instructor: David Ferry Slides adapted from Bryant & O Hallaron s slides via Jason Fritts Today: Floating Point Background:
More informationFloating Point Puzzles. Lecture 3B Floating Point. IEEE Floating Point. Fractional Binary Numbers. Topics. IEEE Standard 754
Floating Point Puzzles Topics Lecture 3B Floating Point IEEE Floating Point Standard Rounding Floating Point Operations Mathematical properties For each of the following C expressions, either: Argue that
More informationThe Verification Grand Challenge and Abstract Interpretation
The Verification Grand Challenge and Abstract Interpretation Patrick Cousot École normale supérieure, 45 rue d Ulm 75230 Paris cedex 05, France Patrick.Cousot ens fr Visiting the Aeronautics and Astronautics
More informationData Representation Floating Point
Data Representation Floating Point CSCI 2400 / ECE 3217: Computer Architecture Instructor: David Ferry Slides adapted from Bryant & O Hallaron s slides via Jason Fritts Today: Floating Point Background:
More informationScientific Computing: An Introductory Survey
Scientific Computing: An Introductory Survey Chapter 1 Scientific Computing Prof. Michael T. Heath Department of Computer Science University of Illinois at Urbana-Champaign Copyright c 2002. Reproduction
More informationFloating Point Puzzles. Lecture 3B Floating Point. IEEE Floating Point. Fractional Binary Numbers. Topics. IEEE Standard 754
Floating Point Puzzles Topics Lecture 3B Floating Point IEEE Floating Point Standard Rounding Floating Point Operations Mathematical properties For each of the following C expressions, either: Argue that
More informationComputational Methods. Sources of Errors
Computational Methods Sources of Errors Manfred Huber 2011 1 Numerical Analysis / Scientific Computing Many problems in Science and Engineering can not be solved analytically on a computer Numeric solutions
More informationDesign and Implementation of a Special-Purpose Static Program Analyzer for Safety-Critical Real-Time Embedded Software
Design and Implementation of a Special-Purpose Static Program Analyzer for Safety-Critical Real-Time Embedded Software Bruno Blanchet 1, Patrick Cousot 1, Radhia Cousot 2, Jérôme Feret 1, Laurent Mauborgne
More informationCODE ANALYSES FOR NUMERICAL ACCURACY WITH AFFINE FORMS: FROM DIAGNOSIS TO THE ORIGIN OF THE NUMERICAL ERRORS. Teratec 2017 Forum Védrine Franck
CODE ANALYSES FOR NUMERICAL ACCURACY WITH AFFINE FORMS: FROM DIAGNOSIS TO THE ORIGIN OF THE NUMERICAL ERRORS NUMERICAL CODE ACCURACY WITH FLUCTUAT Compare floating point with ideal computation Use interval
More informationFloating Point Considerations
Chapter 6 Floating Point Considerations In the early days of computing, floating point arithmetic capability was found only in mainframes and supercomputers. Although many microprocessors designed in the
More informationHierarchical Shape Abstraction of Dynamic Structures in Static Blocks
Hierarchical Shape Abstraction of Dynamic Structures in Static Blocks Pascal Sotin and Xavier Rival INRIA 4 novembre 2013 P. Sotin, X. Rival (INRIA) Hierarchical Shape Abstraction 4 novembre 2013 1 / 29
More informationFloating Point January 24, 2008
15-213 The course that gives CMU its Zip! Floating Point January 24, 2008 Topics IEEE Floating Point Standard Rounding Floating Point Operations Mathematical properties class04.ppt 15-213, S 08 Floating
More informationarxiv: v1 [cs.pl] 1 Dec 2016
NSAD 2016 arxiv:1612.00277v1 [cs.pl] 1 Dec 2016 Sparsity Preserving Algorithms for Octagons Abstract Jacques-Henri Jourdan MPI-SWS, Inria Paris Known algorithms for manipulating octagons do not preserve
More informationAutomatic Qualification of Abstract Interpretation-based Static Analysis Tools. Christian Ferdinand, Daniel Kästner AbsInt GmbH 2013
Automatic Qualification of Abstract Interpretation-based Static Analysis Tools Christian Ferdinand, Daniel Kästner AbsInt GmbH 2013 2 Functional Safety Demonstration of functional correctness Well-defined
More informationCS429: Computer Organization and Architecture
CS429: Computer Organization and Architecture Dr. Bill Young Department of Computer Sciences University of Texas at Austin Last updated: September 18, 2017 at 12:48 CS429 Slideset 4: 1 Topics of this Slideset
More informationSTATIC ANALYSIS OF RUN-TIME ERRORS IN EMBEDDED REAL-TIME PARALLEL C PROGRAMS ANTOINE MINÉ
Logical Methods in Computer Science Vol. 8 (1:26) 2012, pp. 1 63 www.lmcs-online.org Submitted Sep. 7, 2011 Published Mar. 23, 2012 STATIC ANALYSIS OF RUN-TIME ERRORS IN EMBEDDED REAL-TIME PARALLEL C PROGRAMS
More informationLecture 6. Abstract Interpretation
Lecture 6. Abstract Interpretation Wei Le 2014.10 Outline Motivation History What it is: an intuitive understanding An example Steps of abstract interpretation Galois connection Narrowing and Widening
More informationConstraint solving on modular integers
Constraint solving on modular integers Arnaud Gotlieb*, Michel Leconte**, Bruno Marre*** * INRIA Research center of Bretagne Rennes Atlantique ** ILOG Lab, IBM France *** CEA List ModRef 10 Workshop, 6/09/10
More informationInterprocedurally Analysing Linear Inequality Relations
Interprocedurally Analysing Linear Inequality Relations Helmut Seidl, Andrea Flexeder and Michael Petter Technische Universität München, Boltzmannstrasse 3, 85748 Garching, Germany, {seidl, flexeder, petter}@cs.tum.edu,
More informationFloating Point Puzzles The course that gives CMU its Zip! Floating Point Jan 22, IEEE Floating Point. Fractional Binary Numbers.
class04.ppt 15-213 The course that gives CMU its Zip! Topics Floating Point Jan 22, 2004 IEEE Floating Point Standard Rounding Floating Point Operations Mathematical properties Floating Point Puzzles For
More informationLecture 10. Floating point arithmetic GPUs in perspective
Lecture 10 Floating point arithmetic GPUs in perspective Announcements Interactive use on Forge Trestles accounts? A4 2012 Scott B. Baden /CSE 260/ Winter 2012 2 Today s lecture Floating point arithmetic
More informationWhat Every Programmer Should Know About Floating-Point Arithmetic
What Every Programmer Should Know About Floating-Point Arithmetic Last updated: October 15, 2015 Contents 1 Why don t my numbers add up? 3 2 Basic Answers 3 2.1 Why don t my numbers, like 0.1 + 0.2 add
More informationGiving credit where credit is due
CSCE 230J Computer Organization Floating Point Dr. Steve Goddard goddard@cse.unl.edu http://cse.unl.edu/~goddard/courses/csce230j Giving credit where credit is due Most of slides for this lecture are based
More informationSystem Programming CISC 360. Floating Point September 16, 2008
System Programming CISC 360 Floating Point September 16, 2008 Topics IEEE Floating Point Standard Rounding Floating Point Operations Mathematical properties Powerpoint Lecture Notes for Computer Systems:
More informationFloating Point Numbers
Floating Point Numbers Summer 8 Fractional numbers Fractional numbers fixed point Floating point numbers the IEEE 7 floating point standard Floating point operations Rounding modes CMPE Summer 8 Slides
More informationGiving credit where credit is due
JDEP 284H Foundations of Computer Systems Floating Point Dr. Steve Goddard goddard@cse.unl.edu Giving credit where credit is due Most of slides for this lecture are based on slides created by Drs. Bryant
More informationSemantics and Validation Lecture 1. Informal Introduction
Semantics and Validation Lecture 1. Informal Introduction Laboratoire Modélisation et Analyse de Systèmes en Interaction, CEA-LIST and Ecole Polytechnique Eric Goubault and Sylvie Putot November 26, 2013
More informationCO212 Lecture 10: Arithmetic & Logical Unit
CO212 Lecture 10: Arithmetic & Logical Unit Shobhanjana Kalita, Dept. of CSE, Tezpur University Slides courtesy: Computer Architecture and Organization, 9 th Ed, W. Stallings Integer Representation For
More informationFloating-Point Data Representation and Manipulation 198:231 Introduction to Computer Organization Lecture 3
Floating-Point Data Representation and Manipulation 198:231 Introduction to Computer Organization Instructor: Nicole Hynes nicole.hynes@rutgers.edu 1 Fixed Point Numbers Fixed point number: integer part
More informationClasses of Real Numbers 1/2. The Real Line
Classes of Real Numbers All real numbers can be represented by a line: 1/2 π 1 0 1 2 3 4 real numbers The Real Line { integers rational numbers non-integral fractions irrational numbers Rational numbers
More informationAbstract Acceleration of General Linear Loops
Abstract Acceleration of General Linear Loops Bertrand Jeannet, Peter Schrammel, Sriram Sankaranarayanan Principles of Programming Languages, POPL 14 San Diego, CA Motivation and Challenge Motivation Inferring
More informationComputer Organization: A Programmer's Perspective
A Programmer's Perspective Representing Numbers Gal A. Kaminka galk@cs.biu.ac.il Fractional Binary Numbers 2 i 2 i 1 4 2 1 b i b i 1 b 2 b 1 b 0. b 1 b 2 b 3 b j 1/2 1/4 1/8 Representation Bits to right
More informationFloating-Point Numbers in Digital Computers
POLYTECHNIC UNIVERSITY Department of Computer and Information Science Floating-Point Numbers in Digital Computers K. Ming Leung Abstract: We explain how floating-point numbers are represented and stored
More informationFloating Point Square Root under HUB Format
Floating Point Square Root under HUB Format Julio Villalba-Moreno Dept. of Computer Architecture University of Malaga Malaga, SPAIN jvillalba@uma.es Javier Hormigo Dept. of Computer Architecture University
More informationFloating-Point Numbers in Digital Computers
POLYTECHNIC UNIVERSITY Department of Computer and Information Science Floating-Point Numbers in Digital Computers K. Ming Leung Abstract: We explain how floating-point numbers are represented and stored
More informationNumerical Methods 5633
Numerical Methods 5633 Lecture 2 Marina Krstic Marinkovic mmarina@maths.tcd.ie School of Mathematics Trinity College Dublin Marina Krstic Marinkovic 1 / 15 5633-Numerical Methods Organisational Assignment
More informationLecture Objectives. Structured Programming & an Introduction to Error. Review the basic good habits of programming
Structured Programming & an Introduction to Error Lecture Objectives Review the basic good habits of programming To understand basic concepts of error and error estimation as it applies to Numerical Methods
More informationComputational Mathematics: Models, Methods and Analysis. Zhilin Li
Computational Mathematics: Models, Methods and Analysis Zhilin Li Chapter 1 Introduction Why is this course important (motivations)? What is the role of this class in the problem solving process using
More informationData Representation Floating Point
Data Representation Floating Point CSCI 224 / ECE 317: Computer Architecture Instructor: Prof. Jason Fritts Slides adapted from Bryant & O Hallaron s slides Today: Floating Point Background: Fractional
More informationAM205: lecture 2. 1 These have been shifted to MD 323 for the rest of the semester.
AM205: lecture 2 Luna and Gary will hold a Python tutorial on Wednesday in 60 Oxford Street, Room 330 Assignment 1 will be posted this week Chris will hold office hours on Thursday (1:30pm 3:30pm, Pierce
More informationFoundations of Computer Systems
18-600 Foundations of Computer Systems Lecture 4: Floating Point Required Reading Assignment: Chapter 2 of CS:APP (3 rd edition) by Randy Bryant & Dave O Hallaron Assignments for This Week: Lab 1 18-600
More informationFloating Point Arithmetic
Floating Point Arithmetic Clark N. Taylor Department of Electrical and Computer Engineering Brigham Young University clark.taylor@byu.edu 1 Introduction Numerical operations are something at which digital
More informationSplitting the Control Flow with Boolean Flags
École Normale Supérieure, Paris, France A.Simon@ens.fr July 2008 Good States are Usually Convex Declare C variable int array[12];. 0 1 2 3 4 5 6 7 8 9 10 11 i Access array[i] within bound if 0 i and i
More informationFloating-point numbers. Phys 420/580 Lecture 6
Floating-point numbers Phys 420/580 Lecture 6 Random walk CA Activate a single cell at site i = 0 For all subsequent times steps, let the active site wander to i := i ± 1 with equal probability Random
More informationStatic Analysis of Finite Precision Computations
Static Analysis of Finite Precision Computations Eric Goubault and Sylvie Putot CEA LIST, Laboratory for the Modelling and Analysis of Interacting Systems, Point courrier 94, Gif-sur-Yvette, F-91191 France,
More informationFloating Point Numbers
Floating Point Floating Point Numbers Mathematical background: tional binary numbers Representation on computers: IEEE floating point standard Rounding, addition, multiplication Kai Shen 1 2 Fractional
More informationComputer Architecture Chapter 3. Fall 2005 Department of Computer Science Kent State University
Computer Architecture Chapter 3 Fall 2005 Department of Computer Science Kent State University Objectives Signed and Unsigned Numbers Addition and Subtraction Multiplication and Division Floating Point
More informationIEEE Standard 754 Floating Point Numbers
IEEE Standard 754 Floating Point Numbers Steve Hollasch / Last update 2005-Feb-24 IEEE Standard 754 floating point is the most common representation today for real numbers on computers, including Intel-based
More informationSection 1.4 Mathematics on the Computer: Floating Point Arithmetic
Section 1.4 Mathematics on the Computer: Floating Point Arithmetic Key terms Floating point arithmetic IEE Standard Mantissa Exponent Roundoff error Pitfalls of floating point arithmetic Structuring computations
More informationA New Abstraction Framework for Affine Transformers
A New Abstraction Framework for Affine Transformers Tushar Sharma and Thomas Reps SAS 17 Motivations Prove Program Assertions Function and loop summaries Sound with respect to bitvectors A NEW ABSTRACTION
More information