draft-ietf-opsawg-mib-floats-02.txt   rfc6340.txt 
Network Working Group R. Presuhn Internet Engineering Task Force (IETF) R. Presuhn
Internet-Draft None Request for Comments: 6340 Independent
Intended status: Standards Track June 15, 2011 Category: Standards Track August 2011
Expires: December 17, 2011 ISSN: 2070-1721
Textual Conventions for the Representation of Floating-Point Numbers Textual Conventions for the Representation of Floating-Point Numbers
draft-ietf-opsawg-mib-floats-02.txt
Abstract Abstract
This memo defines a Management Information Base (MIB) module This memo defines a Management Information Base (MIB) module
containing textual conventions (TCs) to represent floating-point containing textual conventions (TCs) to represent floating-point
numbers. numbers.
Status of this Memo Status of This Memo
This Internet-Draft is submitted in full conformance with the
provisions of BCP 78 and BCP 79.
Internet-Drafts are working documents of the Internet Engineering This is an Internet Standards Track document.
Task Force (IETF). Note that other groups may also distribute
working documents as Internet-Drafts. The list of current Internet-
Drafts is at http://datatracker.ietf.org/drafts/current/.
Internet-Drafts are draft documents valid for a maximum of six months This document is a product of the Internet Engineering Task Force
and may be updated, replaced, or obsoleted by other documents at any (IETF). It represents the consensus of the IETF community. It has
time. It is inappropriate to use Internet-Drafts as reference received public review and has been approved for publication by the
material or to cite them other than as "work in progress." Internet Engineering Steering Group (IESG). Further information on
Internet Standards is available in Section 2 of RFC 5741.
This Internet-Draft will expire on December 17, 2011. Information about the current status of this document, any errata,
and how to provide feedback on it may be obtained at
http://www.rfc-editor.org/info/rfc6340.
Copyright Notice Copyright Notice
Copyright (c) 2011 IETF Trust and the persons identified as the Copyright (c) 2011 IETF Trust and the persons identified as the
document authors. All rights reserved. document authors. All rights reserved.
This document is subject to BCP 78 and the IETF Trust's Legal This document is subject to BCP 78 and the IETF Trust's Legal
Provisions Relating to IETF Documents Provisions Relating to IETF Documents
(http://trustee.ietf.org/license-info) in effect on the date of (http://trustee.ietf.org/license-info) in effect on the date of
publication of this document. Please review these documents publication of this document. Please review these documents
carefully, as they describe your rights and restrictions with respect carefully, as they describe your rights and restrictions with respect
to this document. Code Components extracted from this document must to this document. Code Components extracted from this document must
include Simplified BSD License text as described in Section 4.e of include Simplified BSD License text as described in Section 4.e of
the Trust Legal Provisions and are provided without warranty as the Trust Legal Provisions and are provided without warranty as
described in the Simplified BSD License. described in the Simplified BSD License.
Table of Contents Table of Contents
1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 3 1. Introduction ....................................................2
2. The Internet-Standard Management Framework . . . . . . . . . . 3 2. The Internet-Standard Management Framework ......................3
3. Applicability . . . . . . . . . . . . . . . . . . . . . . . . . 4 3. Applicability ...................................................3
4. Structure of the MIB Module . . . . . . . . . . . . . . . . . . 5 4. Structure of the MIB Module .....................................4
4.1. MIB modules required for IMPORTS . . . . . . . . . . . . . 5 4.1. MIB Modules Required for IMPORTS ...........................4
4.2. Documents required for REFERENCE clauses . . . . . . . . . 5 4.2. Documents Required for REFERENCE Clauses ...................4
5. Definitions . . . . . . . . . . . . . . . . . . . . . . . . . . 5 5. Definitions .....................................................4
6. Security Considerations . . . . . . . . . . . . . . . . . . . . 6 6. Security Considerations .........................................6
7. IANA Considerations . . . . . . . . . . . . . . . . . . . . . . 7 7. IANA Considerations .............................................6
8. Contributors . . . . . . . . . . . . . . . . . . . . . . . . . 7 8. Contributors ....................................................6
9. References . . . . . . . . . . . . . . . . . . . . . . . . . . 7 9. References ......................................................7
9.1. Normative References . . . . . . . . . . . . . . . . . . . 7 9.1. Normative References .......................................7
9.2. Informative References . . . . . . . . . . . . . . . . . . 8 9.2. Informative References .....................................7
Author's Address . . . . . . . . . . . . . . . . . . . . . . . . . 8
1. Introduction 1. Introduction
This memo defines textual conventions for the representation of This memo defines textual conventions for the representation of
floating-point numbers. All of these definitions are in terms of the floating-point numbers. All of these definitions are in terms of the
IEEE Standard for Floating-Point Arithmetic, IEEE 754-2008 IEEE "Standard for Floating-Point Arithmetic", IEEE 754-2008
[IEEE.754.2008]. [IEEE.754.2008].
The IEEE Standard for Floating-Point Arithmetic, IEEE 754-2008 The IEEE "Standard for Floating-Point Arithmetic", IEEE 754-2008
[IEEE.754.2008], provides for a variety of interchange formats for [IEEE.754.2008], provides for a variety of interchange formats for
floating point numbers. The need for three of these, namely floating-point numbers. The need for three of these, namely
o 32-bit, o 32-bit,
o 64-bit, o 64-bit,
o 128-bit, o 128-bit,
has been recognized in network management. For example, Section has been recognized in network management. For example, Section
4.2.3 of the SMIng Objectives [RFC3216] elaborates the need for these 4.2.3 of the SMIng Objectives [RFC3216] elaborates the need for these
three floating-point data types in network management protocols. three floating-point data types in network management protocols.
The selection of a floating-point format involves many considerations The selection of a floating-point format involves many considerations
and trade-offs. For an introduction to the fundamentals of floating- and trade-offs. For an introduction to the fundamentals of floating-
point representations see chapter 4 of [KNUTH], and for a a point representations see Chapter 4 of [KNUTH]; for a discussion of
discussion of these issues specifically with respect to the IEEE these issues specifically with respect to the IEEE formats, see
formats, see [GOLDBERG]. [GOLDBERG].
All of these textual conventions employ the binary interchange format All of these textual conventions employ the binary interchange format
defined in [IEEE.754.2008]. Specifically, this means that for all of defined in [IEEE.754.2008]. Specifically, this means that for all of
them, the highest-order bit of the first byte is the sign bit, with them, the highest-order bit of the first byte is the sign bit, with
the remaining bits of the octet string corresponding to the exponent the remaining bits of the octet string corresponding to the exponent
and fraction parts, in network byte order. and fraction parts, in network byte order.
2. The Internet-Standard Management Framework 2. The Internet-Standard Management Framework
For a detailed overview of the documents that describe the current For a detailed overview of the documents that describe the current
skipping to change at page 4, line 11 skipping to change at page 3, line 26
module that is compliant to the SMIv2, which is described in STD 58, module that is compliant to the SMIv2, which is described in STD 58,
RFC 2578 [RFC2578], STD 58, RFC 2579 [RFC2579] and STD 58, RFC 2580 RFC 2578 [RFC2578], STD 58, RFC 2579 [RFC2579] and STD 58, RFC 2580
[RFC2580]. [RFC2580].
3. Applicability 3. Applicability
The following list highlights some of the issues MIB designers need The following list highlights some of the issues MIB designers need
to consider when deciding whether to employ these textual to consider when deciding whether to employ these textual
conventions: conventions:
o Floating point numbers are useful if the number space needs to o Floating-point numbers are useful if the number space needs to
cover a large dynamic range. For number spaces with a limited cover a large dynamic range. For number spaces with a limited
range, fixed point numbers can be more efficient and more precise. range, fixed-point numbers can be more efficient and more precise.
o Floating point numbers are typically the wrong answer for data o Floating-point numbers are typically the wrong answer for data
that is truly decimal or can be handled adequately by re-thinking that is truly decimal or can be handled adequately by re-thinking
the units and representing the scaled numbers as integers. the units and representing the scaled numbers as integers.
o The SNMP "lexicographical" ordering for INDEX objects using these o The SNMP "lexicographical" ordering for INDEX objects using these
floating point textual conventions will simply be that of the floating-point textual conventions will simply be that of the
octet strings corresponding to the floating point representations, octet strings corresponding to the floating-point representations,
which will not always reflect the numerical ordering of the which will not always reflect the numerical ordering of the
corresponding floating point values. Even if MIB designers take corresponding floating-point values. Even if MIB designers take
this into account, users might still find the results of a MIB this into account, users might still find the results of a MIB
"walk" surprising. Consequently, it is suggested that whenever "walk" surprising. Consequently, it is suggested that whenever
one of these textual conventions is used for an INDEX object, that one of these textual conventions is used for an INDEX object, that
the DESCRIPTION clause should provide some warning. the DESCRIPTION clause should provide some warning.
o Embedded systems sometimes lack floating point support, which can o Embedded systems sometimes lack floating-point support, which can
complicate the implementation of MIB objects using floating point complicate the implementation of MIB objects using floating-point
numbers. numbers.
o In choosing from among the types defined in this memo, MIB o In choosing from among the types defined in this memo, MIB
designers need to consider both the range and the precision designers need to consider both the range and the precision
needed, as well as recognize that it could be inefficient to use, needed, as well as recognize that it could be inefficient to use,
for example, Float128TC when Float64TC would do. for example, Float128TC when Float64TC would do.
o Since these textual conventions are defined in terms of the OCTET o Since these textual conventions are defined in terms of the OCTET
STRING type, the SMI's mechanisms for formally setting range STRING type, the SMI's mechanisms for formally setting range
constraints are not available. MIB designers using these textual constraints are not available. MIB designers using these textual
skipping to change at page 5, line 10 skipping to change at page 4, line 23
associated DESCRIPTION clause will need to clearly specify whether associated DESCRIPTION clause will need to clearly specify whether
denormalized numbers, NaNs ("not a number") or infinities are denormalized numbers, NaNs ("not a number") or infinities are
permitted, along with any special semantics associated with these permitted, along with any special semantics associated with these
cases. This is especially important for writeable objects. cases. This is especially important for writeable objects.
4. Structure of the MIB Module 4. Structure of the MIB Module
This MIB module defines three textual conventions. It defines no MIB This MIB module defines three textual conventions. It defines no MIB
objects. objects.
4.1. MIB modules required for IMPORTS 4.1. MIB Modules Required for IMPORTS
This MIB module employs definitions from [RFC2578] and [RFC2579]. This MIB module employs definitions from [RFC2578] and [RFC2579].
4.2. Documents required for REFERENCE clauses 4.2. Documents Required for REFERENCE Clauses
This MIB module contains REFERENCE clauses making reference to IEEE This MIB module contains REFERENCE clauses making reference to IEEE
754-2008 [IEEE.754.2008]. 754-2008 [IEEE.754.2008].
5. Definitions 5. Definitions
FLOAT-TC-MIB DEFINITIONS ::= BEGIN FLOAT-TC-MIB DEFINITIONS ::= BEGIN
IMPORTS IMPORTS
MODULE-IDENTITY, MODULE-IDENTITY,
mib-2 FROM SNMPv2-SMI -- RFC 2578 mib-2 FROM SNMPv2-SMI -- RFC 2578
TEXTUAL-CONVENTION FROM SNMPv2-TC; -- RFC 2579 TEXTUAL-CONVENTION FROM SNMPv2-TC; -- RFC 2579
floatTcMIB MODULE-IDENTITY floatTcMIB MODULE-IDENTITY
LAST-UPDATED "201106010000Z" -- June 1, 2011 LAST-UPDATED "201107270000Z" -- July 27, 2011
ORGANIZATION "None" ORGANIZATION "IETF OPSAWG Working Group"
CONTACT-INFO "Randy Presuhn CONTACT-INFO "WG Email: opsawg@ietf.org
Email: randy_presuhn@mindspring.com"
Editor: Randy Presuhn
randy_presuhn@mindspring.com"
DESCRIPTION "Textual conventions for the representation DESCRIPTION "Textual conventions for the representation
of floating-point numbers. of floating-point numbers.
Copyright (c) 2010 IETF Trust and the persons Copyright (c) 2011 IETF Trust and the persons
identified as the document authors. All rights identified as authors of the code. All rights
reserved. reserved.
Redistribution and use in source and binary forms, Redistribution and use in source and binary forms,
with or without modification, is permitted pursuant with or without modification, is permitted pursuant
to, and subject to the license terms contained in, to, and subject to the license terms contained in,
the Simplified BSD License set forth in Section the Simplified BSD License set forth in Section
4.c of the IETF Trust's Legal Provisions Relating 4.c of the IETF Trust's Legal Provisions Relating
to IETF Documents to IETF Documents
(http://trustee.ietf.org/license-info). (http://trustee.ietf.org/license-info).
This version of this MIB module is part of RFC XXXX; This version of this MIB module is part of RFC 6340;
see the RFC itself for full legal notices." see the RFC itself for full legal notices."
REVISION "201106010000Z" -- June 1, 2011 REVISION "201107270000Z" -- July 27, 2011
DESCRIPTION "Initial version, published as RFC XXXX." DESCRIPTION "Initial version, published as RFC 6340."
::= { mib-2 XXX } ::= { mib-2 201 }
-- RFC Ed.: replace XXX with IANA-assigned number & remove this note
-- RFC Ed.: replace XXXX with the RFC number & remove this note
Float32TC ::= TEXTUAL-CONVENTION Float32TC ::= TEXTUAL-CONVENTION
STATUS current STATUS current
DESCRIPTION "This type represents a 32-bit (4-octet) IEEE DESCRIPTION "This type represents a 32-bit (4-octet) IEEE
floating-point number in binary interchange format." floating-point number in binary interchange format."
REFERENCE "IEEE Standard for Floating-Point Arithmetic, REFERENCE "IEEE Standard for Floating-Point Arithmetic,
Standard 754-2008" Standard 754-2008"
SYNTAX OCTET STRING (SIZE(4)) SYNTAX OCTET STRING (SIZE(4))
Float64TC ::= TEXTUAL-CONVENTION Float64TC ::= TEXTUAL-CONVENTION
skipping to change at page 7, line 12 skipping to change at page 6, line 22
modules that define management objects. Therefore, this memo has no modules that define management objects. Therefore, this memo has no
impact on the security of the Internet. impact on the security of the Internet.
7. IANA Considerations 7. IANA Considerations
The MIB module in this document uses the following IANA-assigned The MIB module in this document uses the following IANA-assigned
OBJECT IDENTIFIER value recorded in the SMI Numbers registry: OBJECT IDENTIFIER value recorded in the SMI Numbers registry:
Descriptor OBJECT IDENTIFIER value Descriptor OBJECT IDENTIFIER value
---------- ----------------------- ---------- -----------------------
floatTcMIB { mib-2 XXX } floatTcMIB { mib-2 201 }
Editor's Note (to be removed prior to publication): the IANA is
requested to assign a value for "XXX" under the 'mib-2' subtree and
to record the assignment in the SMI Numbers registry. When the
assignment has been made, the RFC Editor is asked to replace "XXX"
(here and in the MIB module) with the assigned value and to remove
this note.
8. Contributors 8. Contributors
The following people provided helpful comments during the development The following people provided helpful comments during the development
of this document: of this document:
o Andy Bierman o Andy Bierman
o Martin Duerst o Martin Duerst
skipping to change at page 7, line 44 skipping to change at page 7, line 9
o Juergen Schoenwaeder o Juergen Schoenwaeder
o Dave Shield o Dave Shield
o Robert Story o Robert Story
9. References 9. References
9.1. Normative References 9.1. Normative References
[IEEE.754.2008] [IEEE.754.2008] Institute of Electrical and Electronics Engineers,
Institute of Electrical and Electronics Engineers, "Standard for Floating-Point Arithmetic",
"Standard for Floating-Point Arithmetic", IEEE Standard IEEE Standard 754, August 2008.
754, August 2008.
[RFC2578] McCloghrie, K., Ed., Perkins, D., Ed., and J. [RFC2578] McCloghrie, K., Ed., Perkins, D., Ed., and J.
Schoenwaelder, Ed., "Structure of Management Information Schoenwaelder, Ed., "Structure of Management
Version 2 (SMIv2)", STD 58, RFC 2578, April 1999. Information Version 2 (SMIv2)", STD 58, RFC 2578,
April 1999.
[RFC2579] McCloghrie, K., Ed., Perkins, D., Ed., and J. [RFC2579] McCloghrie, K., Ed., Perkins, D., Ed., and J.
Schoenwaelder, Ed., "Textual Conventions for SMIv2", Schoenwaelder, Ed., "Textual Conventions for SMIv2",
STD 58, RFC 2579, April 1999. STD 58, RFC 2579, April 1999.
[RFC2580] McCloghrie, K., Perkins, D., and J. Schoenwaelder, [RFC2580] McCloghrie, K., Perkins, D., and J. Schoenwaelder,
"Conformance Statements for SMIv2", STD 58, RFC 2580, "Conformance Statements for SMIv2", STD 58,
April 1999. RFC 2580, April 1999.
9.2. Informative References 9.2. Informative References
[GOLDBERG] [GOLDBERG] Goldberg, D., "What Every Computer Scientist Should
Goldberg, D., "What Every Computer Scientist Should Know Know About Floating-Point Arithmetic", ACM Computing
About Floating-Point Arithmetic", ACM Computing Surveys Volume 23, Issue 1, March 1991.
Surveys Volume 23, Issue 1, March 1991.
[KNUTH] Knuth, D., "Seminumerical Algorithms", The Art of Computer [KNUTH] Knuth, D., "Seminumerical Algorithms", The Art of
Programming (Second Edition) Vol. 2, 1981. Computer Programming (Second Edition) Vol. 2, 1981.
[RFC3216] Elliott, C., Harrington, D., Jason, J., Schoenwaelder, J., [RFC3216] Elliott, C., Harrington, D., Jason, J.,
Strauss, F., and W. Weiss, "SMIng Objectives", RFC 3216, Schoenwaelder, J., Strauss, F., and W. Weiss, "SMIng
December 2001. Objectives", RFC 3216, December 2001.
[RFC3410] Case, J., Mundy, R., Partain, D., and B. Stewart, [RFC3410] Case, J., Mundy, R., Partain, D., and B. Stewart,
"Introduction and Applicability Statements for Internet- "Introduction and Applicability Statements for
Standard Management Framework", RFC 3410, December 2002. Internet-Standard Management Framework", RFC 3410,
December 2002.
Author's Address Author's Address
Randy Presuhn Randy Presuhn
None
San Jose, CA 95120 San Jose, CA 95120
USA USA
Email: randy_presuhn@mindspring.com EMail: randy_presuhn@mindspring.com
 End of changes. 34 change blocks. 
94 lines changed or deleted 81 lines changed or added

This html diff was produced by rfcdiff 1.41. The latest version is available from http://tools.ietf.org/tools/rfcdiff/