ISO/IEC DIS 23360-4-2
(Main)Linux Standard Base (LSB)
Linux Standard Base (LSB)
Noyau de base normalisé Linux (LSB)
General Information
RELATIONS
Standards Content (sample)
DRAFT INTERNATIONAL STANDARD
ISO/IEC DIS 23360-4-2
ISO/IEC JTC 1/SC 22 Secretariat: ANSI
Voting begins on: Voting terminates on:
2020-02-14 2020-05-08
Linux Standard Base (LSB) —
Part 4-2:
Core specification for AMD64 (X86-64) architecture
ICS: 35.080
THIS DOCUMENT IS A DRAFT CIRCULATED
FOR COMMENT AND APPROVAL. IT IS
THEREFORE SUBJECT TO CHANGE AND MAY
NOT BE REFERRED TO AS AN INTERNATIONAL
STANDARD UNTIL PUBLISHED AS SUCH.
IN ADDITION TO THEIR EVALUATION AS
BEING ACCEPTABLE FOR INDUSTRIAL,
This document is circulated as received from the committee secretariat.
TECHNOLOGICAL, COMMERCIAL AND
USER PURPOSES, DRAFT INTERNATIONAL
STANDARDS MAY ON OCCASION HAVE TO
BE CONSIDERED IN THE LIGHT OF THEIR
POTENTIAL TO BECOME STANDARDS TO
WHICH REFERENCE MAY BE MADE IN
Reference number
NATIONAL REGULATIONS.
ISO/IEC DIS 23360-4-2:2020(E)
RECIPIENTS OF THIS DRAFT ARE INVITED
TO SUBMIT, WITH THEIR COMMENTS,
NOTIFICATION OF ANY RELEVANT PATENT
RIGHTS OF WHICH THEY ARE AWARE AND TO
PROVIDE SUPPORTING DOCUMENTATION. ISO/IEC 2020
---------------------- Page: 1 ----------------------
ISO/IEC DIS 23360-4-2:2020(E)
COPYRIGHT PROTECTED DOCUMENT
© ISO/IEC 2020
All rights reserved. Unless otherwise specified, or required in the context of its implementation, no part of this publication may
be reproduced or utilized otherwise in any form or by any means, electronic or mechanical, including photocopying, or posting
on the internet or an intranet, without prior written permission. Permission can be requested from either ISO at the address
below or ISO’s member body in the country of the requester.ISO copyright office
CP 401 • Ch. de Blandonnet 8
CH-1214 Vernier, Geneva
Phone: +41 22 749 01 11
Fax: +41 22 749 09 47
Email: copyright@iso.org
Website: www.iso.org
Published in Switzerland
ii © ISO/IEC 2020 – All rights reserved
---------------------- Page: 2 ----------------------
ISO/IEC DIS 23360-4-2:2020(E)
Linux Standard Base Core Specification for X86-64
LSB Core - X86-64 5.0
Copyright © 2015 Linux Foundation
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free
Documentation License, Version 1.1; with no Invariant Sections, with no Front-Cover Texts, and with no Back-
Cover Texts. A copy of the license is included in the section entitled "GNU Free Documentation License".
Portions of the text may be copyrighted by the following parties:• The Regents of the University of California
• Free Software Foundation
• Ian F. Darwin
• Paul Vixie
• BSDI (now Wind River)
• Jean-loup Gailly and Mark Adler
• Massachusetts Institute of Technology
• Apple Inc.
• Easy Software Products
• artofcode LLC
• Till Kamppeter
• Manfred Wassman
• Python Software Foundation
These excerpts are being used in accordance with their respective licenses.
Linux is the registered trademark of Linus Torvalds in the U.S. and other countries.
UNIX is a registered trademark of The Open Group.LSB is a trademark of the Linux Foundation in the United States and other countries.
AMD is a trademark of Advanced Micro Devices, Inc.Intel and Itanium are registered trademarks and Intel386 is a trademark of Intel Corporation.
PowerPC is a registered trademark and PowerPC Architecture is a trademark of the IBM Corporation.
S/390 is a registered trademark of the IBM Corporation.OpenGL is a registered trademark of Silicon Graphics, Inc.
PAM documentation is Copyright (C) Andrew G. Morgan 1996-9. All rights reserved. Used under the following
conditions:1. Redistributions of source code must retain the above copyright notice, and the
entire permission notice in its entirety, including the disclaimer of warranties.
2. Redistributions in binary form must reproduce the above copyright notice, this list
of conditions and the following disclaimer in the documentation and/or othermaterials provided with the distribution.
3. The name of the author may not be used to endorse or promote products derived
from this software without specific prior written permission.© ISO/IEC 2020 – All rights reserved iii
---------------------- Page: 3 ----------------------
ISO/IEC DIS 23360-4-2:2020(E)
Contents
Contents ........................................................................................................................................................... iv
List of Tables .................................................................................................................................................. vi
Foreword ........................................................................................................................................................ xv
Status of this Document ......................................................................................................................... xvii
Introduction ............................................................................................................................................. xviii
I Introductory Elements ............................................................................................................................. 1
1 Scope........................................................................................................................................................................ 2
1.1 General ...................................................................................................................................................... 2
1.2 Module Specific Scope ........................................................................................................................ 2
2 References ............................................................................................................................................................. 3
2.1 Normative References ........................................................................................................................ 3
2.2 Informative References/Bibliography......................................................................................... 5
3 Requirements ...................................................................................................................................................... 8
3.1 Relevant Libraries ................................................................................................................................ 8
3.2 LSB Implementation Conformance............................................................................................... 8
3.3 LSB Application Conformance ........................................................................................................ 9
4 Terms and Definitions .................................................................................................................................... 11
5 Documentation Conventions ...................................................................................................................... 13
II Executable and Linking Format (ELF) ............................................................................................ 14
6 Introduction ....................................................................................................................................................... 15
7 Low Level System Information .................................................................................................................. 16
7.1 Machine Interface ............................................................................................................................... 16
7.2 Function Calling Sequence ............................................................................................................. 17
7.3 Operating System Interface ............................................................................................................ 18
7.4 Process Initialization ........................................................................................................................ 18
7.5 Coding Examples................................................................................................................................. 19
7.6 C Stack Frame ....................................................................................................................................... 19
7.7 Debug Information ............................................................................................................................. 19
8 Object Format .................................................................................................................................................... 20
8.1 Introduction .......................................................................................................................................... 20
8.2 ELF Header ............................................................................................................................................ 20
8.3 Sections ................................................................................................................................................... 20
8.4 Symbol Table ........................................................................................................................................ 21
8.5 Relocation .............................................................................................................................................. 21
9 Program Loading and Dynamic Linking ................................................................................................ 22
9.1 Introduction .......................................................................................................................................... 22
9.2 Program Header .................................................................................................................................. 22
9.3 Program Loading ................................................................................................................................ 22
9.4 Dynamic Linking ................................................................................................................................. 22
III Base Libraries ........................................................................................................................................ 24
10 Libraries ............................................................................................................................................................ 25
10.1 Program Interpreter/Dynamic Linker ................................................................................... 25
10.2 Interfaces for libc ............................................................................................................................. 25
10.3 Data Definitions for libc ................................................................................................................ 49
10.4 Interface Definitions for libc ....................................................................................................... 68
10.5 Interfaces for libm ........................................................................................................................... 69
10.6 Data Definitions for libm .............................................................................................................. 74
10.7 Interface Definitions for libm ..................................................................................................... 76
iv © ISO/IEC 2020 – All rights reserved---------------------- Page: 4 ----------------------
ISO/IEC DIS 23360-4-2:2020(E)
10.8 Interfaces for libpthread ............................................................................................................... 77
10.9 Data Definitions for libpthread .................................................................................................. 82
10.10 Interfaces for libgcc_s .................................................................................................................. 84
10.11 Data Definitions for libgcc_s ..................................................................................................... 84
10.12 Interface Definitions for libgcc_s ............................................................................................ 85
10.13 Interfaces for libdl ........................................................................................................................ 86
10.14 Data Definitions for libdl............................................................................................................ 86
10.15 Interfaces for libcrypt ................................................................................................................. 87
10.16 Data Definitions for libcrypt..................................................................................................... 87
IV Utility Libraries ..................................................................................................................................... 89
11 Libraries ............................................................................................................................................................ 90
11.1 Interfaces for libz ............................................................................................................................. 90
11.2 Data Definitions for libz ................................................................................................................ 90
11.3 Interfaces for libncurses ............................................................................................................... 91
11.4 Data Definitions for libncurses .................................................................................................. 91
11.5 Interfaces for libncursesw ........................................................................................................... 91
11.6 Data Definitions for libncursesw .............................................................................................. 92
11.7 Interfaces for libutil ........................................................................................................................ 93
V Base Libraries .......................................................................................................................................... 94
12 Libraries ............................................................................................................................................................ 95
12.1 Interfaces for libstdcxx .................................................................................................................. 95
12.2 Interface Definitions for libstdcxx ......................................................................................... 228
VI Package Format and Installation ................................................................................................. 229
13 Software Installation................................................................................................................................. 230
13.1 Package Dependencies ............................................................................................................... 230
13.2 Package Architecture Considerations .................................................................................. 230
Annex A Alphabetical Listing of Interfaces by Library .............................................................. 231
A.1 libc ................................................................................................................................................................... 231
A.2 libcrypt .......................................................................................................................................................... 247
A.3 libdl ................................................................................................................................................................. 247
A.4 libgcc_s ........................................................................................................................................................... 247
A.5 libm ................................................................................................................................................................. 248
A.6 libpthread ..................................................................................................................................................... 253
A.7 librt .................................................................................................................................................................. 256
A.8 libutil .............................................................................................................................................................. 257
Annex B GNU Free Documentation License (Informative) ....................................................... 258
B.1 PREAMBLE ................................................................................................................................................... 258
B.2 APPLICABILITY AND DEFINITIONS ................................................................................................. 258
B.3 VERBATIM COPYING ............................................................................................................................... 259
B.4 COPYING IN QUANTITY.......................................................................................................................... 259
B.5 MODIFICATIONS ........................................................................................................................................ 260
B.6 COMBINING DOCUMENTS .................................................................................................................... 262
B.7 COLLECTIONS OF DOCUMENTS ......................................................................................................... 262
B.8 AGGREGATION WITH INDEPENDENT WORKS ........................................................................... 262
B.9 TRANSLATION ............................................................................................................................................ 262
B.10 TERMINATION ......................................................................................................................................... 263
B.11 FUTURE REVISIONS OF THIS LICENSE ........................................................................................ 263
B.12 How to use this License for your documents ............................................................................. 263
© ISO/IEC 2020 – All rights reserved v---------------------- Page: 5 ----------------------
ISO/IEC DIS 23360-4-2:2020(E)
List of Tables
Table 2-1 Normative References ........................................................................................................... 3
Table 2-2 Other References ..................................................................................................................... 6
Table 3-1 Standard Library Names ...................................................................................................... 8
Table 7-1 Non Conforming Instructions .......................................................................................... 16
Table 8-1 ELF Special Sections ............................................................................................................. 20
Table 8-2 Additional Special Sections ............................................................................................... 21
Table 10-1 libc Definition ....................................................................................................................... 25
Table 10-2 libc - RPC Function Interfaces ....................................................................................... 25
Table 10-3 libc - RPC Deprecated Function Interfaces .............................................................. 27
Table 10-4 libc - System Calls Function Interfaces ...................................................................... 27
Table 10-5 libc - System Calls Deprecated Function Interfaces ............................................. 29
Table 10-6 libc - Standard I/O Function Interfaces..................................................................... 29
Table 10-7 libc - Standard I/O Deprecated Function Interfaces ........................................... 31
Table 10-8 Sub Macro1() ........................................................................................................................ 31
Table 10-9 libc - Signal Handling Function Interfaces ............................................................... 35
Table 10-10 libc - Signal Handling Deprecated Function Interfaces ................................... 35
Table 10-11 libc - Signal Handling Data Interfaces ..................................................................... 35
Table 10-12 libc - Localization Functions Function Interfaces .............................................. 36
Table 10-13 libc - Localization Functions Data Interfaces ....................................................... 36
Table 10-14 libc - Posix Spawn Option Function Interfaces ................................................... 36
Table 10-15 libc - Posix Advisory Option Function Interfaces ............................................... 37
Table 10-16 libc - Socket Interface Function Interfaces............................................................ 37
Table 10-17 libc - Socket Interface Data Interfaces .................................................................... 38
Table 10-18 libc - Wide Characters Function Interfaces .......................................................... 38
Table 10-19 libc - String Functions Function Interfaces ........................................................... 39
Table 10-20 libc - String Functions Deprecated Function Interfaces .................................. 41
Table 10-21 libc - IPC Functions Function Interfaces ................................................................ 41
Table 10-22 libc - Regular Expressions Function Interfaces .................................................. 41
Table 10-23 libc - Character Type Functions Function Interfaces........................................ 41
Table 10-24 libc - Time Manipulation Function Interfaces ..................................................... 42
Table 10-25 libc - Time Manipulation Data Interfaces .............................................................. 42
Table 10-26 libc - Terminal Interface Functions Function Interfaces ................................. 43
Table 10-27 libc - System Database Interface Function Interfaces ...................................... 43
Table 10-28 libc - System Database Interface Deprecated Function Interfaces ............. 44
Table 10-29 libc - Language Support Function Interfaces ....................................................... 44
Table 10-30 libc - Large File Support Function Interfaces ...................................................... 44
Table 10-31 libc - Large File Support Deprecated Function Interfaces ............................. 45
Table 10-32 libc - Standard Library Function Interfaces ......................................................... 45
Table 10-33 libc - Standard Library Deprecated Function Interfaces ................................ 48
Table 10-34 libc - Standard Library Data Interfaces .................................................................. 48
Table 10-35 libc - GNU Extensions for libc Function Interfaces ............................................ 49
Table 10-36 libm Definition .................................................................................................................. 69
Table 10-37 libm - Math Function Interfaces ................................................................................ 70
Table 10-38 libm - Math Deprecated Function Interfaces ....................................................... 74
Table 10-39 libm - Math Data Interfaces ......................................................................................... 74
Table 10-40 libpthread Definition ...................................................................................................... 77
Table 10-41 libpthread - Realtime Threads Function Interfaces .......................................... 77
Table 10-42 libpthread - Advanced Realtime Threads Function Interfaces .................... 78
vi © ISO/IEC 2020 – All rights reserved---------------------- Page: 6 ----------------------
ISO/IEC DIS 23360-4-2:2020(E)
Table 10-43 libpthread - Posix Threads Function Interfaces ................................................. 78
Table 10-44 Tableibpthread - Posix Threads Deprecated Function Interfaces .............. 80
Table 10-45 libpthread - Thread aware versions of libc interfaces Function Interfaces
.................................................................................................................................................................. 80
Table 10-46 libpthread - GNU Extensions for libpthread Function Interfaces ............... 80
Table 10-47 libpthread - System Calls Function Interfaces ..................................................... 81
Table 10-48 libpthread - Standard I/O Function Interfaces ................................................... 81
Table 10-49 libpthread - Signal Handling Function Interfaces .............................................. 81
Table 10-50 libpthread - Standard Library Function Interfaces ........................................... 82
Table 10-51 libpthread - Socket Interface Function Interfaces ............................................. 82
Table 10-52 libpthread - Terminal Interface Functions Function Interfaces .................. 82
Table 10-53 libgcc_s Definition ............................................................................................................ 84
Table 10-54 libgcc_s - Unwind Library Function Interfaces.................................................... 84
Table 10-55 libdl Definition .................................................................................................................. 86
Table 10-56 libdl - Dynamic Loader Function Interfaces ......................................................... 86
Table 10-57 libcrypt Definition ........................................................................................................... 87
Table 10-58 Tableibcrypt - Encryption Function Interfaces ................................................... 87
Table 11-1 libz Definition ....................................................................................................................... 90
Table 11-2 libncurses Definition ......................................................................................................... 91
Table 11-3 libncursesw Definition ..................................................................................................... 91
Table 11-4 libutil Definition .................................................................................................................. 93
Table 11-5 libutil - Utility Functions Function Interfaces ........................................................ 93
Table 12-1 libstdcxx Definition ............................................................................................................ 95
Table 12-2 libstdcxx - C++ Runtime Support Function Interfaces ....................................... 95
Table 12-3 typeinfo for type_info ........................................................................................................ 96
Table 12-4 typeinfo for __cxxabiv1::__enum_type_info .............................................................. 96
Table 12-5 typeinfo for __cxxabiv1::__array_type_info ............................................................... 97
Table 12-6 Primary vtable for __cxxabiv1::__class_type_info .................................................. 97
Table 12-7 typeinfo for __cxxabiv1::__class_type_info ................................................................ 98
Table 12-8 libstdcxx - Class __cxxabiv1::__class_type_info Function Interfaces ............. 98
Table 12-9 2-1 Normative References 000 .......................................................................... 99
Table 12-10 typeinfo for __cxxabiv1::__pointer_type_info ..................................................... 115
Table 12-11 typeinfo for __cxxabiv1::__function_type_info ................................................... 115
Table 12-12 Primary vtable for __cxxabiv1::__si_class_type_info ....................................... 116
Table 12-13 typeinfo for __cxxabiv1::__si_class_type_info ..................................................... 117
Table 12-14 libstdcxx - Class __cxxabiv1::__si_class_type_info Function Interfaces .. 117
Table 12-15 Primary vtable for __cxxabiv1::__vmi_class_type_info .................................. 117
Table 12-16 typeinfo for __cxxabiv1::__vmi_class_type_info ................................................ 118
Table 12-17 libstdcxx - Class __cxxabiv1::__vmi_class_type_info Function Interfaces
............................................................................................................................................................... 118
Table 12-18 typeinfo for __cxxabiv1::__fundamental_type_info........
Questions, Comments and Discussion
Ask us and Technical Secretary will try to provide an answer. You can facilitate discussion about the standard in here.