1、 Reference numberISO/IEC 10967-1:2012(E)ISO/IEC 2012 INTERNATIONAL STANDARD ISO/IEC10967-1Second edition2012-07-15Information technology Language independent arithmetic Part 1:Integer and floating point arithmetic Technologies de linformation Arithmtique indpendante de langage Partie 1:Arithmtique d
2、e nombres entiers et en virgule flottante ISO/IEC 10967-1:2012(E)COPYRIGHT PROTECTED DOCUMENT ISO/IEC 2012 All rights reserved.Unless otherwise specified,no part of this publication may be reproduced or utilized in any form or by any means,electronic or mechanical,including photocopying and microfil
3、m,without permission in writing from either ISO at the address below or ISOs member body in the country of the requester.ISO copyright office Case postale 56 CH-1211 Geneva 20 Tel.+41 22 749 01 11 Fax +41 22 749 09 47 E-mail copyrightiso.org Web www.iso.org Published in Switzerland ii ISO/IEC 2012 A
4、ll rights reserved ContentsForewordviiIntroductionviii1Scope11.1Inclusions.11.2Exclusions.22Conformity33Normative references44Symbols and definitions44.1Symbols.44.1.1Operators and relations.44.1.2Sets and intervals.54.1.3Exceptional values.54.1.4Special values.64.1.5The Boolean datatype.64.1.6Opera
5、tion specification framework.64.2Definitions of terms.75Specifications for integer and floating point datatypes and operations125.1Integer datatypes and operations.135.1.1Integer result function.145.1.2Integer operations.145.1.2.1Comparisons.145.1.2.2Basic arithmetic.155.2Floating point datatypes an
6、d operations.175.2.1Conformity to IEC 60559.195.2.2Range and granularity constants.195.2.3Approximate operations.195.2.4Rounding and rounding constants.205.2.5Floating point result function.215.2.6Floating point operations.225.2.6.1Comparisons.225.2.6.2Basic arithmetic.245.2.6.3Value dissection.275.
7、2.6.4Value splitting.295.3Operations for conversion between numeric datatypes.295.3.1Integer to integer conversions.305.3.2Floating point to integer conversions.315.3.3Integer to floating point conversions.315.3.4Floating point to floating point conversions.325.3.5Floating point to fixed point conve
8、rsions.325.3.6Fixed point to floating point conversions.345.4Numerals as operations in a programming language.34iiiISO/IEC 10967-1:2012(E)ISO/IEC 2012 All rights reserved5.4.1Numerals for integer datatypes.345.4.2Numerals for floating point datatypes.356Notification356.1Model for handling of notific
9、ations.356.2Notification alternatives.366.2.1Notification by recording in indicators.366.2.2Notification by alteration of control flow.386.2.3Notification by termination with message.386.3Delays in notification.396.4User selection of alternative for notification.397Relationship with language standar
10、ds398Documentation requirements41Annex A(informative)Partial conformity43A.1 Integer overflow notification relaxation.44A.2 Infinitary notification relaxation.44A.3 Inexact notification relaxation.44A.4 Underflow notification relaxation.45A.5 Subnormal values relaxation.45A.6 Accuracy relaxation for
11、 add,subtract,multiply,and divide.45A.7 Accuracy relaxation for floating point conversion.47Annex B(informative)IEC 60559 bindings51B.1Summary.51B.2Notification.55Annex C(informative)Rationale57C.1Scope.57C.1.1Inclusions.57C.1.2Exclusions.57C.1.3Companion parts to this part.58C.2Conformity.58C.2.1Va
12、lidation.59C.3Normative references.59C.4Symbols and definitions.59C.4.1Symbols.60C.4.2Definitions of terms.60C.5Specifications for integer and floating point datatypes and operations.61C.5.1Integer datatypes and operations.62C.5.1.0.1Unbounded integers.62C.5.1.0.2Bounded non-modulo integers.63C.5.1.
13、0.3Modulo integers.64C.5.1.1Integer result function.64C.5.1.2Integer operations.64C.5.1.2.1Comparisons.64C.5.1.2.2Basic arithmetic.65ivISO/IEC 10967-1:2012(E)ISO/IEC 2012 All rights reservedC.5.2Floating point datatypes and operations.65C.5.2.0.1Constraints on the floating point parameters.66C.5.2.0
14、.2Radix complement floating point.68C.5.2.1Conformity to IEC 60559.68C.5.2.1.1Subnormal numbers.69C.5.2.1.2Signed zero.69C.5.2.1.3Infinities and NaNs.69C.5.2.2Range and granularity constants.70C.5.2.2.1Relations among floating point datatypes.70C.5.2.3Approximate operations.71C.5.2.4Rounding and rou
15、nding constants.71C.5.2.5Floating point result function.73C.5.2.6Floating point operations.73C.5.2.6.1Comparisons.73C.5.2.6.2Basic arithmetic.73C.5.2.6.3Value dissection.74C.5.2.6.4Value splitting.74C.5.2.7Levels of predictability.75C.5.2.8Identities.76C.5.2.9Precision,accuracy,and error.78C.5.2.9.1
16、LIA-1 and error.79C.5.2.9.2Empirical and modelling errors.80C.5.2.9.3Propagation of errors.80C.5.2.10 Extra precision.81C.5.3Operations for conversion between numeric datatypes.82C.5.4Numerals as operations in a programming language.83C.5.4.1Numerals for integer datatypes.83C.5.4.2Numerals for floating point datatypes.83C.6Notification.83C.6.1Model handling of notifications.84C.6.2Notification alternatives.84C.6.2.1Notification by recording in indicators.84C.6.2.2Notification by alteration of co