Conversion to Docbook based of version 1.2 of the IBM contributed document,

"Power Architecture: 64-bit ELF V2 ABI Specification".

Signed-off-by: Jeff Scheel <scheel@us.ibm.com>
pull/92/head 1.2b
Jeff Scheel 8 years ago
parent d2d3872796
commit 5de854880b

2
.gitignore vendored

@ -0,0 +1,2 @@
*~
*target*

@ -0,0 +1,452 @@

GNU Free Documentation License
Version 1.3, 3 November 2008


Copyright (C) 2000, 2001, 2002, 2007, 2008 Free Software Foundation, Inc.
<http://fsf.org/>
Everyone is permitted to copy and distribute verbatim copies
of this license document, but changing it is not allowed.

0. PREAMBLE

The purpose of this License is to make a manual, textbook, or other
functional and useful document "free" in the sense of freedom: to
assure everyone the effective freedom to copy and redistribute it,
with or without modifying it, either commercially or noncommercially.
Secondarily, this License preserves for the author and publisher a way
to get credit for their work, while not being considered responsible
for modifications made by others.

This License is a kind of "copyleft", which means that derivative
works of the document must themselves be free in the same sense. It
complements the GNU General Public License, which is a copyleft
license designed for free software.

We have designed this License in order to use it for manuals for free
software, because free software needs free documentation: a free
program should come with manuals providing the same freedoms that the
software does. But this License is not limited to software manuals;
it can be used for any textual work, regardless of subject matter or
whether it is published as a printed book. We recommend this License
principally for works whose purpose is instruction or reference.


1. APPLICABILITY AND DEFINITIONS

This License applies to any manual or other work, in any medium, that
contains a notice placed by the copyright holder saying it can be
distributed under the terms of this License. Such a notice grants a
world-wide, royalty-free license, unlimited in duration, to use that
work under the conditions stated herein. The "Document", below,
refers to any such manual or work. Any member of the public is a
licensee, and is addressed as "you". You accept the license if you
copy, modify or distribute the work in a way requiring permission
under copyright law.

A "Modified Version" of the Document means any work containing the
Document or a portion of it, either copied verbatim, or with
modifications and/or translated into another language.

A "Secondary Section" is a named appendix or a front-matter section of
the Document that deals exclusively with the relationship of the
publishers or authors of the Document to the Document's overall
subject (or to related matters) and contains nothing that could fall
directly within that overall subject. (Thus, if the Document is in
part a textbook of mathematics, a Secondary Section may not explain
any mathematics.) The relationship could be a matter of historical
connection with the subject or with related matters, or of legal,
commercial, philosophical, ethical or political position regarding
them.

The "Invariant Sections" are certain Secondary Sections whose titles
are designated, as being those of Invariant Sections, in the notice
that says that the Document is released under this License. If a
section does not fit the above definition of Secondary then it is not
allowed to be designated as Invariant. The Document may contain zero
Invariant Sections. If the Document does not identify any Invariant
Sections then there are none.

The "Cover Texts" are certain short passages of text that are listed,
as Front-Cover Texts or Back-Cover Texts, in the notice that says that
the Document is released under this License. A Front-Cover Text may
be at most 5 words, and a Back-Cover Text may be at most 25 words.

A "Transparent" copy of the Document means a machine-readable copy,
represented in a format whose specification is available to the
general public, that is suitable for revising the document
straightforwardly with generic text editors or (for images composed of
pixels) generic paint programs or (for drawings) some widely available
drawing editor, and that is suitable for input to text formatters or
for automatic translation to a variety of formats suitable for input
to text formatters. A copy made in an otherwise Transparent file
format whose markup, or absence of markup, has been arranged to thwart
or discourage subsequent modification by readers is not Transparent.
An image format is not Transparent if used for any substantial amount
of text. A copy that is not "Transparent" is called "Opaque".

Examples of suitable formats for Transparent copies include plain
ASCII without markup, Texinfo input format, LaTeX input format, SGML
or XML using a publicly available DTD, and standard-conforming simple
HTML, PostScript or PDF designed for human modification. Examples of
transparent image formats include PNG, XCF and JPG. Opaque formats
include proprietary formats that can be read and edited only by
proprietary word processors, SGML or XML for which the DTD and/or
processing tools are not generally available, and the
machine-generated HTML, PostScript or PDF produced by some word
processors for output purposes only.

The "Title Page" means, for a printed book, the title page itself,
plus such following pages as are needed to hold, legibly, the material
this License requires to appear in the title page. For works in
formats which do not have any title page as such, "Title Page" means
the text near the most prominent appearance of the work's title,
preceding the beginning of the body of the text.

The "publisher" means any person or entity that distributes copies of
the Document to the public.

A section "Entitled XYZ" means a named subunit of the Document whose
title either is precisely XYZ or contains XYZ in parentheses following
text that translates XYZ in another language. (Here XYZ stands for a
specific section name mentioned below, such as "Acknowledgements",
"Dedications", "Endorsements", or "History".) To "Preserve the Title"
of such a section when you modify the Document means that it remains a
section "Entitled XYZ" according to this definition.

The Document may include Warranty Disclaimers next to the notice which
states that this License applies to the Document. These Warranty
Disclaimers are considered to be included by reference in this
License, but only as regards disclaiming warranties: any other
implication that these Warranty Disclaimers may have is void and has
no effect on the meaning of this License.

2. VERBATIM COPYING

You may copy and distribute the Document in any medium, either
commercially or noncommercially, provided that this License, the
copyright notices, and the license notice saying this License applies
to the Document are reproduced in all copies, and that you add no
other conditions whatsoever to those of this License. You may not use
technical measures to obstruct or control the reading or further
copying of the copies you make or distribute. However, you may accept
compensation in exchange for copies. If you distribute a large enough
number of copies you must also follow the conditions in section 3.

You may also lend copies, under the same conditions stated above, and
you may publicly display copies.


3. COPYING IN QUANTITY

If you publish printed copies (or copies in media that commonly have
printed covers) of the Document, numbering more than 100, and the
Document's license notice requires Cover Texts, you must enclose the
copies in covers that carry, clearly and legibly, all these Cover
Texts: Front-Cover Texts on the front cover, and Back-Cover Texts on
the back cover. Both covers must also clearly and legibly identify
you as the publisher of these copies. The front cover must present
the full title with all words of the title equally prominent and
visible. You may add other material on the covers in addition.
Copying with changes limited to the covers, as long as they preserve
the title of the Document and satisfy these conditions, can be treated
as verbatim copying in other respects.

If the required texts for either cover are too voluminous to fit
legibly, you should put the first ones listed (as many as fit
reasonably) on the actual cover, and continue the rest onto adjacent
pages.

If you publish or distribute Opaque copies of the Document numbering
more than 100, you must either include a machine-readable Transparent
copy along with each Opaque copy, or state in or with each Opaque copy
a computer-network location from which the general network-using
public has access to download using public-standard network protocols
a complete Transparent copy of the Document, free of added material.
If you use the latter option, you must take reasonably prudent steps,
when you begin distribution of Opaque copies in quantity, to ensure
that this Transparent copy will remain thus accessible at the stated
location until at least one year after the last time you distribute an
Opaque copy (directly or through your agents or retailers) of that
edition to the public.

It is requested, but not required, that you contact the authors of the
Document well before redistributing any large number of copies, to
give them a chance to provide you with an updated version of the
Document.


4. MODIFICATIONS

You may copy and distribute a Modified Version of the Document under
the conditions of sections 2 and 3 above, provided that you release
the Modified Version under precisely this License, with the Modified
Version filling the role of the Document, thus licensing distribution
and modification of the Modified Version to whoever possesses a copy
of it. In addition, you must do these things in the Modified Version:

A. Use in the Title Page (and on the covers, if any) a title distinct
from that of the Document, and from those of previous versions
(which should, if there were any, be listed in the History section
of the Document). You may use the same title as a previous version
if the original publisher of that version gives permission.
B. List on the Title Page, as authors, one or more persons or entities
responsible for authorship of the modifications in the Modified
Version, together with at least five of the principal authors of the
Document (all of its principal authors, if it has fewer than five),
unless they release you from this requirement.
C. State on the Title page the name of the publisher of the
Modified Version, as the publisher.
D. Preserve all the copyright notices of the Document.
E. Add an appropriate copyright notice for your modifications
adjacent to the other copyright notices.
F. Include, immediately after the copyright notices, a license notice
giving the public permission to use the Modified Version under the
terms of this License, in the form shown in the Addendum below.
G. Preserve in that license notice the full lists of Invariant Sections
and required Cover Texts given in the Document's license notice.
H. Include an unaltered copy of this License.
I. Preserve the section Entitled "History", Preserve its Title, and add
to it an item stating at least the title, year, new authors, and
publisher of the Modified Version as given on the Title Page. If
there is no section Entitled "History" in the Document, create one
stating the title, year, authors, and publisher of the Document as
given on its Title Page, then add an item describing the Modified
Version as stated in the previous sentence.
J. Preserve the network location, if any, given in the Document for
public access to a Transparent copy of the Document, and likewise
the network locations given in the Document for previous versions
it was based on. These may be placed in the "History" section.
You may omit a network location for a work that was published at
least four years before the Document itself, or if the original
publisher of the version it refers to gives permission.
K. For any section Entitled "Acknowledgements" or "Dedications",
Preserve the Title of the section, and preserve in the section all
the substance and tone of each of the contributor acknowledgements
and/or dedications given therein.
L. Preserve all the Invariant Sections of the Document,
unaltered in their text and in their titles. Section numbers
or the equivalent are not considered part of the section titles.
M. Delete any section Entitled "Endorsements". Such a section
may not be included in the Modified Version.
N. Do not retitle any existing section to be Entitled "Endorsements"
or to conflict in title with any Invariant Section.
O. Preserve any Warranty Disclaimers.

If the Modified Version includes new front-matter sections or
appendices that qualify as Secondary Sections and contain no material
copied from the Document, you may at your option designate some or all
of these sections as invariant. To do this, add their titles to the
list of Invariant Sections in the Modified Version's license notice.
These titles must be distinct from any other section titles.

You may add a section Entitled "Endorsements", provided it contains
nothing but endorsements of your Modified Version by various
parties--for example, statements of peer review or that the text has
been approved by an organization as the authoritative definition of a
standard.

You may add a passage of up to five words as a Front-Cover Text, and a
passage of up to 25 words as a Back-Cover Text, to the end of the list
of Cover Texts in the Modified Version. Only one passage of
Front-Cover Text and one of Back-Cover Text may be added by (or
through arrangements made by) any one entity. If the Document already
includes a cover text for the same cover, previously added by you or
by arrangement made by the same entity you are acting on behalf of,
you may not add another; but you may replace the old one, on explicit
permission from the previous publisher that added the old one.

The author(s) and publisher(s) of the Document do not by this License
give permission to use their names for publicity for or to assert or
imply endorsement of any Modified Version.


5. COMBINING DOCUMENTS

You may combine the Document with other documents released under this
License, under the terms defined in section 4 above for modified
versions, provided that you include in the combination all of the
Invariant Sections of all of the original documents, unmodified, and
list them all as Invariant Sections of your combined work in its
license notice, and that you preserve all their Warranty Disclaimers.

The combined work need only contain one copy of this License, and
multiple identical Invariant Sections may be replaced with a single
copy. If there are multiple Invariant Sections with the same name but
different contents, make the title of each such section unique by
adding at the end of it, in parentheses, the name of the original
author or publisher of that section if known, or else a unique number.
Make the same adjustment to the section titles in the list of
Invariant Sections in the license notice of the combined work.

In the combination, you must combine any sections Entitled "History"
in the various original documents, forming one section Entitled
"History"; likewise combine any sections Entitled "Acknowledgements",
and any sections Entitled "Dedications". You must delete all sections
Entitled "Endorsements".


6. COLLECTIONS OF DOCUMENTS

You may make a collection consisting of the Document and other
documents released under this License, and replace the individual
copies of this License in the various documents with a single copy
that is included in the collection, provided that you follow the rules
of this License for verbatim copying of each of the documents in all
other respects.

You may extract a single document from such a collection, and
distribute it individually under this License, provided you insert a
copy of this License into the extracted document, and follow this
License in all other respects regarding verbatim copying of that
document.


7. AGGREGATION WITH INDEPENDENT WORKS

A compilation of the Document or its derivatives with other separate
and independent documents or works, in or on a volume of a storage or
distribution medium, is called an "aggregate" if the copyright
resulting from the compilation is not used to limit the legal rights
of the compilation's users beyond what the individual works permit.
When the Document is included in an aggregate, this License does not
apply to the other works in the aggregate which are not themselves
derivative works of the Document.

If the Cover Text requirement of section 3 is applicable to these
copies of the Document, then if the Document is less than one half of
the entire aggregate, the Document's Cover Texts may be placed on
covers that bracket the Document within the aggregate, or the
electronic equivalent of covers if the Document is in electronic form.
Otherwise they must appear on printed covers that bracket the whole
aggregate.


8. TRANSLATION

Translation is considered a kind of modification, so you may
distribute translations of the Document under the terms of section 4.
Replacing Invariant Sections with translations requires special
permission from their copyright holders, but you may include
translations of some or all Invariant Sections in addition to the
original versions of these Invariant Sections. You may include a
translation of this License, and all the license notices in the
Document, and any Warranty Disclaimers, provided that you also include
the original English version of this License and the original versions
of those notices and disclaimers. In case of a disagreement between
the translation and the original version of this License or a notice
or disclaimer, the original version will prevail.

If a section in the Document is Entitled "Acknowledgements",
"Dedications", or "History", the requirement (section 4) to Preserve
its Title (section 1) will typically require changing the actual
title.


9. TERMINATION

You may not copy, modify, sublicense, or distribute the Document
except as expressly provided under this License. Any attempt
otherwise to copy, modify, sublicense, or distribute it is void, and
will automatically terminate your rights under this License.

However, if you cease all violation of this License, then your license
from a particular copyright holder is reinstated (a) provisionally,
unless and until the copyright holder explicitly and finally
terminates your license, and (b) permanently, if the copyright holder
fails to notify you of the violation by some reasonable means prior to
60 days after the cessation.

Moreover, your license from a particular copyright holder is
reinstated permanently if the copyright holder notifies you of the
violation by some reasonable means, this is the first time you have
received notice of violation of this License (for any work) from that
copyright holder, and you cure the violation prior to 30 days after
your receipt of the notice.

Termination of your rights under this section does not terminate the
licenses of parties who have received copies or rights from you under
this License. If your rights have been terminated and not permanently
reinstated, receipt of a copy of some or all of the same material does
not give you any rights to use it.


10. FUTURE REVISIONS OF THIS LICENSE

The Free Software Foundation may publish new, revised versions of the
GNU Free Documentation License from time to time. Such new versions
will be similar in spirit to the present version, but may differ in
detail to address new problems or concerns. See
http://www.gnu.org/copyleft/.

Each version of the License is given a distinguishing version number.
If the Document specifies that a particular numbered version of this
License "or any later version" applies to it, you have the option of
following the terms and conditions either of that specified version or
of any later version that has been published (not as a draft) by the
Free Software Foundation. If the Document does not specify a version
number of this License, you may choose any version ever published (not
as a draft) by the Free Software Foundation. If the Document
specifies that a proxy can decide which future versions of this
License can be used, that proxy's public statement of acceptance of a
version permanently authorizes you to choose that version for the
Document.

11. RELICENSING

"Massive Multiauthor Collaboration Site" (or "MMC Site") means any
World Wide Web server that publishes copyrightable works and also
provides prominent facilities for anybody to edit those works. A
public wiki that anybody can edit is an example of such a server. A
"Massive Multiauthor Collaboration" (or "MMC") contained in the site
means any set of copyrightable works thus published on the MMC site.

"CC-BY-SA" means the Creative Commons Attribution-Share Alike 3.0
license published by Creative Commons Corporation, a not-for-profit
corporation with a principal place of business in San Francisco,
California, as well as future copyleft versions of that license
published by that same organization.

"Incorporate" means to publish or republish a Document, in whole or in
part, as part of another Document.

An MMC is "eligible for relicensing" if it is licensed under this
License, and if all works that were first published under this License
somewhere other than this MMC, and subsequently incorporated in whole or
in part into the MMC, (1) had no cover texts or invariant sections, and
(2) were thus incorporated prior to November 1, 2008.

The operator of an MMC Site may republish an MMC contained in the site
under CC-BY-SA on the same site at any time before August 1, 2009,
provided the MMC is eligible for relicensing.


ADDENDUM: How to use this License for your documents

To use this License in a document you have written, include a copy of
the License in the document and put the following copyright and
license notices just after the title page:

Copyright (c) YEAR YOUR NAME.
Permission is granted to copy, distribute and/or modify this document
under the terms of the GNU Free Documentation License, Version 1.3
or any later version published by the Free Software Foundation;
with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts.
A copy of the license is included in the section entitled "GNU
Free Documentation License".

If you have Invariant Sections, Front-Cover Texts and Back-Cover Texts,
replace the "with...Texts." line with this:

with the Invariant Sections being LIST THEIR TITLES, with the
Front-Cover Texts being LIST, and with the Back-Cover Texts being LIST.

If you have Invariant Sections without Cover Texts, or some other
combination of the three, merge those two alternatives to suit the
situation.

If your document contains nontrivial examples of program code, we
recommend releasing these examples in parallel under your choice of
free software license, such as the GNU General Public License,
to permit their use in free software.

@ -1,2 +1,92 @@
# ELFv2-ABI # Power Architecture 64-Bit ELF V2 ABI Specification
Power Architecture 64-Bit ELF V2 ABI Specification This repository hold the source for the Power Architecture 64-bit ELF Version 2
ABI specification for the OpenPOWER Foundation. The PDF and HTML generated from the specification/
directory build a document that describe the ABI used by Linux on Power systems when
running in little endian mode.

To build this project, one must ensure that the Docs-Master project has
also been cloned at the same directory level as the ELFv2-ABI project.
This can be accomplished with the following steps:

1. Clone the master documentation project (Docs-Master) using the following command:

```
$ git clone https://github.com/OpenPOWERFoundation/Docs-Master.git
```
2. Clone this project (ELFv2-ABI) using the following command:

```
$ git clone https://github.com/OpenPOWERFoundation/ELFv2-ABI.git
```
3. Build the project with these commands:
```
$ cd ELFv2-ABI
$ mvn clean generate-sources
```

The online version of the document can be found in the OpenPOWER Foundation
Document library at [TBD](http://openpowerfoundation.org/?resource_lib=tbd)

The project which control the look and feel of the document is the
[Docs-Maven-Plugin project](https://github.com/OpenPOWERFoundation/Docs-Maven-Plugin).

## License
This project is licensed under the Apache V2 license. More information
can be found in the LICENSE file or online at

http://www.apache.org/licenses/LICENSE-2.0

## Contributions
To contribute to the OpenPOWER Foundation template document project, contact Jeff Scheel \([scheel@us.ibm.com](mailto://scheel@us.ibm.com)\) or
Jeff Brown \([jeffdb@us.ibm.com](mailto://jeffdb@us.ibm.com)\).

Contributions to this project should conform to the `Developer Certificate
of Origin` as defined at http://elinux.org/Developer_Certificate_Of_Origin.
Commits to this project need to contain the following line to indicate
the submitter accepts the DCO:
```
Signed-off-by: Your Name <your_email@domain.com>
```
By contributing in this way, you agree to the terms as follows:
```
Developer Certificate of Origin
Version 1.1

Copyright (C) 2004, 2006 The Linux Foundation and its contributors.
660 York Street, Suite 102,
San Francisco, CA 94110 USA

Everyone is permitted to copy and distribute verbatim copies of this
license document, but changing it is not allowed.


Developer's Certificate of Origin 1.1

By making a contribution to this project, I certify that:

(a) The contribution was created in whole or in part by me and I
have the right to submit it under the open source license
indicated in the file; or

(b) The contribution is based upon previous work that, to the best
of my knowledge, is covered under an appropriate open source
license and I have the right under that license to submit that
work with modifications, whether created in whole or in part
by me, under the same open source license (unless I am
permitted to submit under a different license), as indicated
in the file; or

(c) The contribution was provided directly to me by some other
person who certified (a), (b) or (c) and I have not modified
it.

(d) I understand and agree that this project and the contribution
are public and that a record of the contribution (including all
personal information I submit with it, including my sign-off) is
maintained indefinitely and may be redistributed consistent with
this project or the open source license(s) involved.
```



@ -0,0 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">

<parent>
<groupId>org.openpowerfoundation.docs</groupId>
<artifactId>master-pom</artifactId>
<version>1.0.0-SNAPSHOT</version>
<relativePath>../Docs-Master/pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>

<artifactId>workgroup-pom</artifactId>
<packaging>pom</packaging>

<modules>
<!-- Add new documents are build in the project, add their directories to this list to
enable all document builds from the top level -->
<module>specification</module>
</modules>
</project>

File diff suppressed because it is too large Load Diff

@ -0,0 +1,851 @@
<appendix xmlns="http://docbook.org/ns/docbook"
xmlns:xl="http://www.w3.org/1999/xlink" version="5.0" xml:lang="en"
xml:id="dbdoclet.50655245_pgfId-1450875">
<title>Binary-Coded Decimal Built-In Functions</title>
<para>Binary-coded decimal (BCD) values are compressed; each decimal digit
and sign bit occupies 4 bits. Digits are ordered right-to-left in the order
of significance. The final 4 bits encode the sign. A valid encoding must
have a value in the range 0 - 9 in each of its 31 digits, and a value in
the range 10 - 15 for the sign field.</para>
<para>Source operands with sign codes of 0b1010, 0b1100, 0b1110, or 0b1111
are interpreted as positive values. Source operands with sign codes of
0b1011 or 0b1101 are interpreted as negative values.</para>
<para>BCD arithmetic operations encode the sign of their result as follows:
A value of 0b1101 indicates a negative value, while 0b1100 and 0b1111
indicate positive values or zero, depending on the value of the positive
sign (PS) bit.</para>
<para>These built-in functions can operate on values of at most 31 digits.
BCD values are stored in memory as contiguous arrays of 1 - 16
bytes.</para>
<note>
<para>BCD built-in functions are valid only when -
<emphasis>march</emphasis> or -
<emphasis>qarch</emphasis> is set to target POWER8 processors or
later.</para>
</note>
<para>
<xref linkend="dbdoclet.50655245_77606" /> summarizes the BCD built-in
functions. Functions are grouped by type. Within type, functions are listed
alphabetically. Prototypes are provided for each function.</para>
<para> </para>
<table frame="all" pgwide="1" xml:id="dbdoclet.50655245_77606">
<title>Binary-Coded Decimal Built-In Functions</title>
<tgroup cols="2">
<colspec colname="c1" colwidth="30*" />
<colspec colname="c2" colwidth="70*" />
<thead>
<row>
<entry align="center">
<para>
<emphasis role="bold">Group</emphasis>
</para>
</entry>
<entry align="center">
<para>
<emphasis role="bold">Description of Binary-Coded Decimal
Built-In Functions (with Prototypes)</emphasis>
</para>
</entry>
</row>
</thead>
<tbody>
<row>
<entry nameend="c2" namest="c1">
<para>
<emphasis role="bold">BCD Add and Subtract</emphasis>
</para>
</entry>
</row>
<row>
<entry>
<para>___BUILTIN_BCDADD (a, b, ps)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>Returns the result of the addition of the BCD values a and
b.</para>
<para>The sign of the result is determined as follows:</para>
<itemizedlist>
<listitem>
<para>If the result is a nonnegative value and
<emphasis>ps</emphasis> is 0, the sign is set to 0b1100
(0xC).</para>
</listitem>
<listitem>
<para>If the result is a nonnegative value and
<emphasis>ps</emphasis> is 1, the sign is set to 0b1111
(0xF).</para>
</listitem>
<listitem>
<para>If the result is a negative value, the sign is set to
0b1101 (0xD).</para>
</listitem>
</itemizedlist>
<para>Parameters:</para>
<para>The ps parameter selects the numeric format for the
positive-signed BCD numbers. It must be set to one of the values
defined in
<xref linkend="dbdoclet.50655245_32368" />.</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>vector unsigned char __builtin_bcdadd (vector unsigned
char, vector unsigned char, const int);</para>
</entry>
</row>
<row>
<entry>
<para>__BUILTIN_BCDSUB (a, b, ps)</para>
</entry>
<entry>
<para>Purpose</para>
<para>Returns the result of the subtraction of the BCD values a
and b. Sets the sign of the nonnegative result to 0b1100 if
<emphasis>ps</emphasis> is 0. Otherwise, sets the sign of the
nonnegative result to 0b1111.</para>
<para>The sign of the result is determined as follows:</para>
<itemizedlist>
<listitem>
<para>If the result is a nonnegative value and
<emphasis>ps</emphasis> is 0, the sign is set to 0b1100
(0xC).</para>
</listitem>
<listitem>
<para>If the result is a nonnegative value and
<emphasis>L</emphasis> is 1, the sign is set to 0b1111
(0xF).</para>
</listitem>
<listitem>
<para>If the result is a negative value, the sign is set to
0b1101 (0xD).</para>
</listitem>
</itemizedlist>
<para>Parameters:</para>
<para>The ps parameter selects the numeric format for the
positive-signed BCD numbers. It must be set to one of the values
defined in
<xref linkend="dbdoclet.50655245_32368" /></para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>vector unsigned char __builtin_bcdsub (vector unsigned
char, vector unsigned char, long);</para>
</entry>
</row>
<row>
<entry nameend="c2" namest="c1">
<para>
<emphasis role="bold">BCD Predicates</emphasis>
</para>
</entry>
</row>
<row>
<entry>
<para>__BUILTIN_BCDADD_OFL (a, b)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>Returns one if the corresponding BCD add operation results
in an overflow. Otherwise, returns zero.</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>int __ builtin_bcdadd_ofl (vector unsigned char, vector
unsigned char);</para>
</entry>
</row>
<row>
<entry>
<para>__BUILTIN_BCDSUB_OFL (a, b)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>Returns one if the corresponding BCD subtract operation
results in an overflow. Otherwise, returns zero.</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>int __ builtin_bcdsub_ofl (vector unsigned char, vector
unsigned char
<emphasis>)</emphasis>;</para>
</entry>
</row>
<row>
<entry>
<para>__ BUILTIN_BCD_INVALID (a)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>Returns one if
<emphasis>a</emphasis> is an invalid encoding of a BCD value.
Otherwise, returns zero.</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>int __ builtin_bcd_invalid (vector unsigned char);</para>
</entry>
</row>
<row>
<entry nameend="c2" namest="c1">
<para>
<emphasis role="bold">BCD Comparison</emphasis>
</para>
</entry>
</row>
<row>
<entry>
<para>__ BUILTIN_BCDCMPEQ (a, b)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>Returns one if the BCD value
<emphasis>a</emphasis> is equal to
<emphasis>b</emphasis>. Otherwise, returns zero.</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>int __ builtin_bcdcmpeq (vector unsigned char, vector
unsigned char);</para>
</entry>
</row>
<row>
<entry>
<para>__ BUILTIN_BCDCMPGE (a, b)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>Returns one if the BCD value
<emphasis>a</emphasis> is greater than or equal to
<emphasis>b</emphasis>. Otherwise, returns zero.</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>int __ builtin_bcdcmpge (vector unsigned char, vector
unsigned char);</para>
</entry>
</row>
<row>
<entry>
<para>__BUILTIN_BCDCMPGT (a, b)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>Returns one if the BCD value
<emphasis>a</emphasis> is greater than
<emphasis>b</emphasis>. Otherwise, returns zero.</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>int __ builtin_bcdcmpgt (vector unsigned char, vector
unsigned char);</para>
</entry>
</row>
<row>
<entry>
<para>__BUILTIN_BCDCMPLE (a, b)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>Returns one if the BCD value
<emphasis>a</emphasis> is less than or equal to
<emphasis>b</emphasis>. Otherwise, returns zero.</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>int __ builtin_bcdcmple (vector unsigned char, vector
unsigned char);</para>
</entry>
</row>
<row>
<entry>
<para>__ BUILTIN_BCDCMPLT (a, b)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>Returns one if the BCD value
<emphasis>a</emphasis> is less than
<emphasis>b</emphasis>. Otherwise, returns zero.</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>int __ builtin_bcdcmplt (vector unsigned char, vector
unsigned char);</para>
</entry>
</row>
<row>
<entry>
<para>
<emphasis>BCD Load and Store</emphasis>
</para>
</entry>
<entry>
<para> </para>
</entry>
</row>
<row>
<entry>
<para>__ BUILTIN_BCD2DFP (a)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>Converts a signed BCD value stored as a vector of unsigned
characters to a 128-bit decimal floating-point format.</para>
<itemizedlist>
<listitem>
<para>Parameter value a is a 128-bit vector that is treated
as a signed BCD 31-digit value.</para>
</listitem>
<listitem>
<para>The return value is a doubleword floating-point pair in
a decimal 128 floating-point format.</para>
</listitem>
</itemizedlist>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>_Decimal128 __ builtin_bcd2dfp (vector unsigned
char);</para>
</entry>
</row>
<row>
<entry>
<para>__ BUILTIN_BCDMUL10 (ARG1)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>Multiplies the BCD number in ARG1 by 10. The sign indicator
remains unmodified.</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>vector unsigned char __builtin_bcdmul10 (vector unsigned
char);</para>
</entry>
</row>
<row>
<entry>
<para>__ BUILTIN_BCDDIV10 (ARG1)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>Divides the BCD number in ARG1 by 10. The sign indicator
remains unmodified.</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>vector unsigned char __builtin_bcddiv10 (vector unsigned
char);</para>
</entry>
</row>
</tbody>
</tgroup>
</table>
<para> </para>
<section xml:id="dbdoclet.50655245_25759">
<title>BCD Header Functions</title>
<note>
<para>These functions are being phased in for POWER8, and might
not be available on all implementations. Phased-in functions are
optional for the current generation of compliant systems.</para>
</note>
<para>The bcd.h header file defines a BCD data type and the interfaces to
efficiently compute the BCD functions listed in
<xref linkend="dbdoclet.50655245_12427" />. These interfaces can be
implemented as macros or by another method, such as static inline
functions.
<xref linkend="dbdoclet.50655245_12427" /> shows one suggested
implementation using macros and the built-in operators shown in
<xref linkend="dbdoclet.50655245_77606" />. A sample bcd.h listing is shown
in
<xref linkend="dbdoclet.50655245_48437" />.</para>
<para>The bcd data type is defined as follows in the bcd.h:</para>
<para><literal>typedef bcd vector unsigned char;</literal></para>
<para>The header file also defines a bcd_default_format as follows:</para>
<para><literal>#ifndef bcd_default_format</literal></para>
<para><literal>#define bcd_default_format __BCD_SIGN_IBM</literal></para>
<para><literal>#endif</literal></para>
<para> </para>
<table frame="all" pgwide="1" xml:id="dbdoclet.50655245_12427">
<title>BCD Functions Defined by bcd.h</title>
<tgroup cols="2">
<colspec colname="c1" colwidth="30*" />
<colspec colname="c2" colwidth="80*" />
<thead>
<row>
<entry align="center">
<para>
<emphasis role="bold">Macro
<footnote xml:id="tabb2fna"><para>Or static inline function.</para></footnote></emphasis>
</para>
</entry>
<entry>
<para>
<emphasis role="bold">Macro Definition</emphasis>
</para>
</entry>
</row>
</thead>
<tbody>
<row>
<entry>
<para>bcd_add(a,b)</para>
</entry>
<entry>
<para>(bcd)__builtin_bcdadd (a,b, bcd_default_format)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_sub(a,b)</para>
</entry>
<entry>
<para>(bcd)__builtin_bcdsub (a,b, bcd_default_format)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_add_ofl(a,b)</para>
</entry>
<entry>
<para>(_Bool)__builtin_bcdadd_ofl (a,b)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_sub_ofl(a,b)</para>
</entry>
<entry>
<para>(_Bool)__builtin_bcdsub_ofl (a,b)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_invalid(a)</para>
</entry>
<entry>
<para>(_Bool)__builtin_bcd_invalid (a)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_cmpeq(a,b)</para>
</entry>
<entry>
<para>(_Bool)__builtin_bcdcmpeq (a,b)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_cmpge(a,b)</para>
</entry>
<entry>
<para>(_Bool)__builtin_bcdcmpge (a,b)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_cmpgt(a,b)</para>
</entry>
<entry>
<para>(_Bool)__builtin_bcdcmpgt (a,b)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_cmple(a,b)</para>
</entry>
<entry>
<para>(_Bool)__builtin_bcdcmple (a,b)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_cmplt(a,b)</para>
</entry>
<entry>
<para>(_Bool)__builtin_bcdcmplt (a,b)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_cmpne(a,b)</para>
</entry>
<entry>
<para>!(_Bool)__builtin_bcdcmpeq (a,b)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_xl(a,b)</para>
</entry>
<entry>
<para>(bcd)vec_xl_len_r(a,b)
<footnote xml:id="tabb2fnb"><para>Optionaly, __builtin_ldrmb (a,b) for previous
generations of XL compilers.</para></footnote>
</para>
</entry>
</row>
<row>
<entry>
<para>bcd_xst(a,b)</para>
</entry>
<entry>
<para>(bcd)vec_xst_len_r(a,b)
<footnote xml:id="tabb2fnc"><para>Optionaly, __builti_strmb (a,b) for previous
generatoin f XL compilers.</para></footnote>
</para>
</entry>
</row>
<row>
<entry>
<para>bcd_quantize(d)</para>
</entry>
<entry>
<para>__builtin_bcdquantize (d)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_dfp(a)</para>
</entry>
<entry>
<para>__builtin_bcd2dfp (a)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_dfp2bcd(dfp)</para>
</entry>
<entry>
<para>(bcd)__builtin_vec_DFP2BCD (_Decimal128 dfp)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_string2bcd(string)</para>
</entry>
<entry>
<para>(bcd) __bcd_string2bcd (string, bcd_default_format)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_mul10(a)</para>
</entry>
<entry>
<para>(bcd) __builtin_bcdmul10 (a)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_div10(a)</para>
</entry>
<entry>
<para>(bcd) __builtin_bcddiv10 (a)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_mul(a,b)</para>
</entry>
<entry>
<para>(bcd) __bcd_mul (a,b,bcd_default_format)</para>
</entry>
</row>
<row>
<entry>
<para>bcd_div(a,b)</para>
</entry>
<entry>
<para>(bcd) __bcd_div (a,b,bcd_default_format)</para>
</entry>
</row>
</tbody>
</tgroup>
</table>
<para>In addition, the bcd.h file provides access to the library functions
shown in
<xref linkend="dbdoclet.50655245_92773" />. These functions may be provided
either as a static inline function by bcd.h or in a system library that is
linked with an application which uses such functions.</para>
<para> </para>
<table frame="all" pgwide="1" xml:id="dbdoclet.50655245_92773">
<title>BCD Support Functions</title>
<tgroup cols="2">
<colspec colname="c1" colwidth="30*" align="center"/>
<colspec colname="c2" colwidth="80*" />
<thead>
<row>
<entry>
<para>
<emphasis role="bold">Function Name</emphasis>
</para>
</entry>
<entry align="center">
<para>
<emphasis role="bold">Description of BCD Support Functions
(with Prototypes)</emphasis>
</para>
</entry>
</row>
</thead>
<tbody>
<row>
<entry>
<para>__BCD_MUL (A,B,F)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>Two signed 31-digit values are multiplied, and the lower 31
digits of the product are returned. Overflow is ignored.</para>
<itemizedlist>
<listitem>
<para>Parameter A is a 128-bit vector that is treated as a
signed BCD 31-digit value.</para>
</listitem>
<listitem>
<para>Parameter B is a 128-bit vector that is treated as a
signed BCD 31-digit value.</para>
</listitem>
<listitem>
<para>Parameter F specifies the format of the BCD number
result.</para>
</listitem>
</itemizedlist>
<para>This function returns a 128-bit vector that is the lower 31
digits of (a × b).</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>bcd __bcd_mul (bcd, bcd, long)</para>
</entry>
</row>
<row>
<entry>
<para>__BCD_DIV (A,B,F)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>One signed 31-digit value is divided by a second 31-digit
value. The quotient is returned.</para>
<itemizedlist>
<listitem>
<para>Parameter A is a 128-bit vector that is treated as a
signed BCD 31-digit value.</para>
</listitem>
<listitem>
<para>Parameter B is a 128-bit vector that is treated as a
signed BCD 31-digit value.</para>
</listitem>
<listitem>
<para>Parameter F specifies the format of the BCD number
result.</para>
</listitem>
</itemizedlist>
<para>This function returns a 128-bit vector that is the lower 31
digits of (a / b).</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>bcd __builtin_bcddiv (bcd, bcd, long);</para>
</entry>
</row>
<row>
<entry>
<para>__BCD_STRING2BCD(S,F)</para>
</entry>
<entry>
<para>Purpose:</para>
<para>The received ASCII string is converted to a BCD number and
returned as a BCD type.</para>
<itemizedlist>
<listitem>
<para>Parameter S is the string to be converted.</para>
</listitem>
<listitem>
<para>Parameter F specifies the format of the BCD number
result.</para>
</listitem>
</itemizedlist>
<para>This function returns a 128-bit vector that consists of 31
BCD digits and a sign.</para>
</entry>
</row>
<row>
<entry>
<para> </para>
</entry>
<entry>
<para>bcd __bcd_string2bcd (char *, long);</para>
</entry>
</row>
</tbody>
</tgroup>
</table>
<para> </para>
<section xml:id="dbdoclet.50655245_32368">
<title>BCD API Named Constants</title>
<para>The BCD header file, bcd.h, defines named constants.
<xref linkend="dbdoclet.50655245_46767" /> defines constants for use in
conjunction with the BCD format representation. They can be used for
format specification and to set the bcd_default_format.</para>
<para> </para>
<table frame="all" pgwide="1" xml:id="dbdoclet.50655245_46767">
<title>Constants Used with BCD_FORMAT</title>
<tgroup cols="1">
<colspec colname="c1" colwidth="100*" />
<thead>
<row>
<entry>
<para>
<emphasis role="bold">Constants</emphasis>
</para>
</entry>
</row>
</thead>
<tbody>
<row>
<entry>
<para>#define BCD_FORMAT_IBM 0</para>
</entry>
</row>
<row>
<entry>
<para>#define BCD_FORMAT_Z 0</para>
</entry>
</row>
<row>
<entry>
<para>#define BCD_FORMAT_POWER 0</para>
</entry>
</row>
<row>
<entry>
<para>#define BCD_FORMAT_IBMi 1</para>
</entry>
</row>
<row>
<entry>
<para>#define BCD_FORMAT_I 1</para>
</entry>
</row>
<row>
<entry>
<para>#define BCD_FORMAT_NCR 1</para>
</entry>
</row>
</tbody>
</tgroup>
</table>
</section>
<section xml:id="dbdoclet.50655245_48437">
<title>Exemplary Implementation for bcd.h</title>
<para>
<xref linkend="dbdoclet.50655245_52184" /> shows an exemplary
implementation of the bcd.h with the interfaces shown in
<xref linkend="dbdoclet.50655245_12427" />, using the macros and the
built-in operators shown in
<xref linkend="dbdoclet.50655245_77606" />, and the functions shown in
<xref linkend="dbdoclet.50655245_92773" />.</para>
</section>
<section xml:id="dbdoclet.50655245_52184">
<title>Sample bcd.h Listing</title>
<programlisting>
#ifndef __BCD_H
#define __BCD_H
typedef bcd vector unsigned char;
#define BCD_FORMAT_IBM 0
#define BCD_FORMAT_Z 0
#define BCD_FORMAT_POWER 0
#define BCD_FORMAT_IBMi 1
#define BCD_FORMAT_I 1
#define BCD_FORMAT_NCR 1
#ifndef bcd_default_format
#define bcd_default_format __BCD_SIGN_IBM
#endif
#define bcd_add(a,b) ((bcd)__builtin_bcdadd (a,b,bcd_default_format))
#define bcd_sub(A,b) ((bcd)__builtin_bcdsub (a,b,bcd_default_format))
#define bcd_add_ofl(a,b) ((_Bool)__builtin_bcdadd_ofl (a,b))
#define bcd_add_ofl(a,b) ((_Bool)__builtin_bcdsub_ofl (a,b))
#define bcd_invalid(a) ((_Bool)__builtin_bcd_invalid (a))
#define bcd_cmpeq(a,b) ((_Bool)__builtin_bcdcmpeq (a,b))
#define bcd_cmpge(a,b) ((_Bool)__builtin_bcdcmpge (a,b))
#define bcd_cmpgt(a,b) ((_Bool)__builtin_bcdcmpgt (a,b))
#define bcd_cmple(a,b) ((_Bool)__builtin_bcdcmple (a,b))
#define bcd_cmplt(a,b) ((_Bool)__builtin_bcdcmplt (a,b))
#define bcd_cmpne(a,b) (!(_Bool)__builtin_bcdcmpeq (a,b))
#define bcd_xl(a,b) ((bcd)vec_xl_len_r(a,b))
#define bcd_xst(a,b) ((bcd)vec_xst_len_r(a,b))
#define bcd_quantize(d) (__builtin_bcdquantize(d))
#define bcd_dfp(a) (__builtin_bcd2dfp (a))
#define bcd_dfp2bcd(DFP) ((bcd)__builtin_vec_DFP2BCD (_Decimal128 dfp))
#define bcd_string2bcd(string) ((bcd) __bcd_string2bcd (string, bcd_default_format)
#define bcd_mul10(a) ((bcd) __builtin_bcdmul10 (a))
#define bcd_div10(a) ((bcd) __builtin_bcddiv10 (a))
#define bcd_mul(a,b) ((bcd) __bcd_mul (a,b,bcd_default_format))
#define bcd_div(a,b) ((bcd) __bcd_div (a,b,bcd_default_format))
#endif /* __BCD_H */
</programlisting>
</section>
</section>
</appendix>

@ -0,0 +1,623 @@
<appendix xmlns="http://docbook.org/ns/docbook"
xmlns:xl="http://www.w3.org/1999/xlink" version="5.0" xml:lang="en"
xml:id="dbdoclet.50655246_33489">
<title>Glossary</title>

<informaltable frame="none" rowsep='0' colsep='0'>
<tgroup cols="2">
<colspec colname="c1" colwidth="20*" />
<colspec colname="c2" colwidth="80*" />
<tbody>
<row>
<entry>
<para>ABI</para>
</entry>
<entry>
<para>Application binary interface</para>
</entry>
</row>
<row>
<entry>
<para>AES</para>
</entry>
<entry>
<para>Advanced Encryption Standard</para>
</entry>
</row>
<row>
<entry>
<para>API</para>
</entry>
<entry>
<para>Application programming interface</para>
</entry>
</row>
<row>
<entry>
<para>ASCII</para>
</entry>
<entry>
<para>American Standard Code for Information Interchange</para>
</entry>
</row>
<row>
<entry>
<para>BCD</para>
</entry>
<entry>
<para>Binary-coded decimal</para>
</entry>
</row>
<row>
<entry>
<para>BE</para>
</entry>
<entry>
<para>Big-endian</para>
</entry>
</row>
<row>
<entry>
<para>COBOL</para>
</entry>
<entry>
<para>Common Business Oriented Language</para>
</entry>
</row>
<row>
<entry>
<para>CR</para>
</entry>
<entry>
<para>Condition Register</para>
</entry>
</row>
<row>
<entry>
<para>CTR</para>
</entry>
<entry>
<para>Count Register</para>
</entry>
</row>
<row>
<entry>
<para>DFP</para>
</entry>
<entry>
<para>Decimal floating-point</para>
</entry>
</row>
<row>
<entry>
<para>DP</para>
</entry>
<entry>
<para>Double precision</para>
</entry>
</row>
<row>
<entry>
<para>DRN</para>
</entry>
<entry>
<para>The DFP Rounding Control field [DRN] of the 64-bit FPSCR
register.</para>
</entry>
</row>
<row>
<entry>
<para>DSCR</para>
</entry>
<entry>
<para>Data Stream Control Register</para>
</entry>
</row>
<row>
<entry>
<para>DSO</para>
</entry>
<entry>
<para>Dynamic shared object</para>
</entry>
</row>
<row>
<entry>
<para>DTV</para>
</entry>
<entry>
<para>Dynamic thread vector</para>
</entry>
</row>
<row>
<entry>
<para>DWARF</para>
</entry>
<entry>
<para>Debug with arbitrary record format</para>
</entry>
</row>
<row>
<entry>
<para>EA</para>
</entry>
<entry>
<para>Effective address</para>
</entry>
</row>
<row>
<entry>
<para>ELF</para>
</entry>
<entry>
<para>Executable and Linking Format</para>
</entry>
</row>
<row>
<entry>
<para>EOS</para>
</entry>
<entry>
<para>End-of-string</para>
</entry>
</row>
<row>
<entry>
<para>FPR</para>
</entry>
<entry>
<para>Floating-Point Register</para>
</entry>
</row>
<row>
<entry>
<para>FPSCR</para>
</entry>
<entry>
<para>Floating-Point Status and Control Register</para>
</entry>
</row>
<row>
<entry>
<para>GCC</para>
</entry>
<entry>
<para>GNU Compiler Collection</para>
</entry>
</row>
<row>
<entry>
<para>GEP</para>
</entry>
<entry>
<para>Global entry point</para>
</entry>
</row>
<row>
<entry>
<para>GOT</para>
</entry>
<entry>
<para>Global offset table</para>
</entry>
</row>
<row>
<entry>
<para>GPR</para>
</entry>
<entry>
<para>General Purpose Register</para>
</entry>
</row>
<row>
<entry>
<para>HTM</para>
</entry>
<entry>
<para>Hardware trace monitor</para>
</entry>
</row>
<row>
<entry>
<para>ID</para>
</entry>
<entry>
<para>Identification</para>
</entry>
</row>
<row>
<entry>
<para>IEC</para>
</entry>
<entry>
<para>International Electrotechnical Commission</para>
</entry>
</row>
<row>
<entry>
<para>IEEE</para>
</entry>
<entry>
<para>Institute of Electrical and Electronics Engineers</para>
</entry>
</row>
<row>
<entry>
<para>INF</para>
</entry>
<entry>
<para>Infinity</para>
</entry>
</row>
<row>
<entry>
<para>ISA</para>
</entry>
<entry>
<para>Instruction Set Architecture</para>
</entry>
</row>
<row>
<entry>
<para>ISO</para>
</entry>
<entry>
<para>International Organization for Standardization</para>
</entry>
</row>
<row>
<entry>
<para>KB</para>
</entry>
<entry>
<para>Kilobyte</para>
</entry>
</row>
<row>
<entry>
<para>LE</para>
</entry>
<entry>
<para>Little-endian</para>
</entry>
</row>
<row>
<entry>
<para>LEP</para>
</entry>
<entry>
<para>Local entry point</para>
</entry>
</row>
<row>
<entry>
<para>LR</para>
</entry>
<entry>
<para>Link Register</para>
</entry>
</row>
<row>
<entry>
<para>LSB</para>
</entry>
<entry>
<para>Least-significant byte</para>
</entry>
</row>
<row>
<entry>
<para>MB</para>
</entry>
<entry>
<para>Megabyte</para>
</entry>
</row>
<row>
<entry>
<para>MSB</para>
</entry>
<entry>
<para>Most-significant byte</para>
</entry>
</row>
<row>
<entry>
<para>MSR</para>
</entry>
<entry>
<para>Machine State Register</para>
</entry>
</row>
<row>
<entry>
<para>N/A</para>
</entry>
<entry>
<para>Not applicable</para>
</entry>
</row>
<row>
<entry>
<para>NaN</para>
</entry>
<entry>
<para>Not-a-Number</para>
</entry>
</row>
<row>
<entry>
<para>NOP</para>
</entry>
<entry>
<para>No operation. A single-cycle operation that does not
affect registers or generate bus activity.</para>
</entry>
</row>
<row>
<entry>
<para>NOR</para>
</entry>
<entry>
<para>In Boolean logic, the negation of a logical OR.</para>
</entry>
</row>
<row>
<entry>
<para>OE</para>
</entry>
<entry>
<para>The Floating-Point Overflow Exception Enable bit of the
FPSCR register.</para>
</entry>
</row>
<row>
<entry>
<para>PIC</para>
</entry>
<entry>
<para>Position-independent code</para>
</entry>
</row>
<row>
<entry>
<para>PIE</para>
</entry>
<entry>
<para>Position-independent executable</para>
</entry>
</row>
<row>
<entry>
<para>PIM</para>
</entry>
<entry>
<para>Programming Interface Manual</para>
</entry>
</row>
<row>
<entry>
<para>PLT</para>
</entry>
<entry>
<para>Procedure linkage table</para>
</entry>
</row>
<row>
<entry>
<para>PMR</para>
</entry>
<entry>
<para>Performance Monitor Registers</para>
</entry>
</row>
<row>
<entry>
<para>POSIX</para>
</entry>
<entry>
<para>Portable Operating System Interface</para>
</entry>
</row>
<row>
<entry>
<para>PS</para>
</entry>
<entry>
<para>Positive sign</para>
</entry>
</row>
<row>
<entry>
<para>RN</para>
</entry>
<entry>
<para>The Binary Floating-Point Rounding Control field [of the
FPSCR register.</para>
</entry>
</row>
<row>
<entry>
<para>RPG</para>
</entry>
<entry>
<para>Report Program Generator</para>
</entry>
</row>
<row>
<entry>
<para>SHA</para>
</entry>
<entry>
<para>Secure Hash Algorithm</para>
</entry>
</row>
<row>
<entry>
<para>SIMD</para>
</entry>
<entry>
<para>Single instruction, multiple data</para>
</entry>
</row>
<row>
<entry>
<para>SP</para>
</entry>
<entry>
<para>Stack pointer</para>
</entry>
</row>
<row>
<entry>
<para>SPR</para>
</entry>
<entry>
<para>Special Purpose Register</para>
</entry>
</row>
<row>
<entry>
<para>SVID</para>
</entry>
<entry>
<para>System V Interface Definition</para>
</entry>
</row>
<row>
<entry>
<para>TCB</para>
</entry>
<entry>
<para>Thread control block</para>
</entry>
</row>
<row>
<entry>
<para>TLS</para>
</entry>
<entry>
<para>Thread local storage</para>
</entry>
</row>
<row>
<entry>
<para>TOC</para>
</entry>
<entry>
<para>Table of contents</para>
</entry>
</row>
<row>
<entry>
<para>TP</para>
</entry>
<entry>
<para>Thread pointer</para>
</entry>
</row>
<row>
<entry>
<para>UE</para>
</entry>
<entry>
<para>The Floating-Point Underflow Exception Enable bit [of the
FPSCR register.</para>
</entry>
</row>
<row>
<entry>
<para>ULP</para>
</entry>
<entry>
<para>Unit of least precision</para>
</entry>
</row>
<row>
<entry>
<para>VDSO</para>
</entry>
<entry>
<para>Virtual dynamic shared object</para>
</entry>
</row>
<row>
<entry>
<para>VE</para>
</entry>
<entry>
<para>The Floating-Point Invalid Operation Exception Enable bit
of the FPSCR register.</para>
</entry>
</row>
<row>
<entry>
<para>VMX</para>
</entry>
<entry>
<para>Vector multimedia extension</para>
</entry>
</row>
<row>
<entry>
<para>VSCR</para>
</entry>
<entry>
<para>Vector Status and Control Register</para>
</entry>
</row>
<row>
<entry>
<para>VSX</para>
</entry>
<entry>
<para>Vector scalar extension</para>
</entry>
</row>
<row>
<entry>
<para>XE</para>
</entry>
<entry>
<para>The Floating-Point Inexact Exception Enable bit of the
FPSCR register.</para>
</entry>
</row>
<row>
<entry>
<para>XER</para>
</entry>
<entry>
<para>Fixed-Point Exception Register</para>
</entry>
</row>
<row>
<entry>
<para>XNOR</para>
</entry>
<entry>
<para>Exclusive NOR</para>
</entry>
</row>
<row>
<entry>
<para>XOR</para>
</entry>
<entry>
<para>Exclusive OR</para>
</entry>
</row>
<row>
<entry>
<para>ZE</para>
</entry>
<entry>
<para>The Floating-Point Zero Divide Exception Enable bit of
the FPSCR register.</para>
</entry>
</row>
</tbody>
</tgroup>
</informaltable>

</appendix>

@ -0,0 +1,121 @@
<?xml version="1.0" encoding="UTF-8"?>
<book xmlns="http://docbook.org/ns/docbook"
xmlns:xi="http://www.w3.org/2001/XInclude"
xmlns:xlink="http://www.w3.org/1999/xlink"
version="5.0"
status="draft"
xml:id="bk_main">

<!-- TODO: When ready to publish document, remove the 'status="draft"' statement from the book object above. -->

<title>64-Bit ELF V2 ABI Specification</title>
<subtitle>Power Architecture </subtitle>

<info>
<author>
<personname>
System Software Work Group
</personname>
<!-- TODO: Set correct email address of document author -->
<email>syssw-chair@openpowerfoundation.org</email>
<affiliation>
<!-- TODO: Insert appropriate orgname -->
<orgname>IBM</orgname>
</affiliation>
</author>
<copyright>
<!-- TODO: Keep second year accurate for latest publish -->
<year>2014,2016</year>
<holder>OpenPOWER Foundation</holder>
</copyright>
<copyright>
<year>1999,2003, 2004, 2013, 2014</year>
<holder>IBM Corporation</holder>
</copyright>
<copyright>
<year>2011</year>
<holder>Power.org</holder>
</copyright>
<copyright>
<year>2003, 2004</year>
<holder>Free Standards Group</holder>
</copyright>
<copyright>
<year>2002</year>
<holder>Freescale Semiconductor, Inc</holder>
</copyright>
<!-- TODO: Set the correct document releaseinfo -->
<releaseinfo>Revision 1.2b</releaseinfo>
<productname>OpenPOWER</productname>
<pubdate/>

<!-- TODO: Change license to "gnuFreeDoc" when JAR 1.5 becomes available. -->
<!--legalnotice role="gnuFreeDoc"-->
<legalnotice role="apache2">

<annotation>
<remark>Copyright details are filled in by the template.</remark>
</annotation>
</legalnotice>
<abstract>
<para>The Executable and Linking Format (ELF) defines a linking interface for executables
and shared objects in two parts: the first part is the generic System V ABI, the second part
is a processor-specific supplement.</para>
<para>This document, the OpenPOWER ABI for Linux Supplement for the Power Architecture 64-bit ELF
V2 ABI, is the OpenPOWER-compliant processor-specific supplement for use with ELF V2 on 64-bit
IBM Power Architecture® systems. This is not a complete System V ABI supplement because it
does not define any library interfaces.</para>
<para>This document establishes both big-endian and little-endian application binary
interfaces. OpenPOWER-compliant processors in the 64-bit Power Architecture can execute
in either big-endian or little-endian mode. Executables and executable-generated
data (in general) that subscribes to either byte ordering is not portable to a system running in the
other mode.</para>
<para>This document is a Standards Track, Work Group work product owned by the
System Software Workgroup and handled in compliance with the requirements outlined in the
<citetitle>OpenPOWER Foundation Work Group (WG) Process</citetitle> document. It was
created using the <citetitle>Master Template Guide</citetitle> version 1.0. Comments,
questions, etc. can be submitted to the public mailing list for this document at
<link xlink:href="http://tbd.openpowerfoundation.org">TBD</link>.</para>
</abstract>

<revhistory>
<!-- TODO: Set the initial version information and clear any old information out -->
<revision>
<date>2016-08-29</date>
<revdescription>
<itemizedlist spacing="compact">
<listitem>
<para>Revision 1.1b - initial conversion from framemaker</para>
</listitem>
</itemizedlist>
</revdescription>
</revision>
</revhistory>
</info>

<!-- The ch_preface.xml file is required by all documents -->
<xi:include href="../../Docs-Master/common/ch_preface.xml"/>
<xi:include href="ch_preface.xml"/>

<!-- TODO: Add your chapter heading files here. Remove both files and insert your own. -->
<!-- See the template document for naming conventions and location of files. -->


<xi:include href="ch_1.xml"/>
<xi:include href="ch_2.xml"/>
<xi:include href="ch_3.xml"/>
<xi:include href="ch_4.xml"/>
<xi:include href="ch_5.xml"/>
<xi:include href="ch_6.xml"/>
<xi:include href="app_a.xml"/>
<xi:include href="app_b.xml"/>
<xi:include href="app_glossary.xml"/>

<!-- The app_foundation.xml appendix file is required by all documents. -->
<xi:include href="../../Docs-Master/common/app_foundation.xml"/>

<!-- TODO: The following template document may be modified to create additional appendices as needed. -->
<!--xi:include href="app_template.xml"/ -->

</book>

@ -0,0 +1,193 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xl="http://www.w3.org/1999/xlink" version="5.0" xml:lang="en">
<title>Introduction</title>
<section xml:id="dbdoclet.50655239_pgfId-1101854">
<title>Introduction</title>
<para>The Executable and Linking Format (ELF) defines a linking interface
for executables and shared objects in two parts.</para>
<itemizedlist>
<listitem>
<para>The first part is the generic System V ABI (
<emphasis>
<link xl:href="http://refspecs.linuxfoundation.org/LSB_4.1.0/LSB-Core-generic/LSB-Core-generic/normativerefs.html#NORMATIVEREFSSECT">

<citetitle>
http://refspecs.linuxfoundation.org/LSB_4.1.0/LSB-Core-generic/LSB-Core-generic/normativerefs.html#NORMATIVEREFSSECT</citetitle>
</link>
</emphasis>).</para>
</listitem>
<listitem>
<para>The second part is a processor-specific supplement.</para>
</listitem>
</itemizedlist>
<para>This document, the OpenPOWER ABI for Linux Supplement for the Power
Architecture 64-bit ELF V2 ABI, is the OpenPOWER-compliant
processor-specific supplement for use with ELF V2 on 64-bit IBM Power
Architecture® systems. This is not a complete System V ABI supplement
because it does not define any library interfaces.</para>
<para>This document establishes both big-endian and little-endian
application binary interfaces (see
<xref linkend="dbdoclet.50655240___RefHeading___Toc377640574" />).
OpenPOWER-compliant processors in the 64-bit Power Architecture can execute
in either big-endian or little-endian mode. Executables and
executable-generated data (in general) that subscribes to either byte
ordering is not portable to a system running in the other mode.</para>
<itemizedlist>
<listitem>
<para>Note:
<link xl:href="http://www.power.org/">
<citetitle>http://www.power.org/</citetitle>
</link></para>
</listitem>
</itemizedlist>
<para>The OpenPOWER ELF V2 ABI is not the same as either the Power
Architecture 32-bit ABI supplement or the 64-bit IBM PowerPC® ELF ABI (ELF
V1).</para>
<para>The Power Architecture 64-bit OpenPOWER ELF V2 ABI supplement is
intended to use the same structural layout now followed in practice by
other processor-specific ABIs.</para>
</section>
<section xml:id="dbdoclet.50655239___RefHeading___Toc377640569">
<title>Reference Documentation</title>
<para>The archetypal ELF ABI is described by the System V ABI.
Supersessions and addenda that are specific to OpenPOWER ELF V2 Power
Architecture (64-bit) processors are described in this document.</para>
<para>The following documents are complementary to this document and
equally binding:</para>
<itemizedlist>
<listitem>
<para>
<emphasis>Power Instruction Set Architecture,</emphasis> Version 3.0,
IBM, 2016.
<emphasis>
<link xl:href="http://www.power.org">
<citetitle>http://www.power.org</citetitle>
</link>
</emphasis></para>
</listitem>
<listitem>
<para>
<emphasis>DWARF Debugging Information Format,</emphasis> Version 4,
DWARF Debugging Information Format Workgroup, 2010.
<emphasis>
<link xl:href="http://dwarfstd.org/Dwarf4Std.php">
<citetitle>http://dwarfstd.org/Dwarf4Std.php</citetitle>
</link>
</emphasis></para>
</listitem>
<listitem>
<para>
<emphasis>ISO/IEC 9899:2011: Programming languages—C</emphasis>.
<emphasis>
<link xl:href="http://www.iso.org/iso/home/store/catalogue_tc/catalogue_detail.htm?csnumber=57853">

<citetitle>
http://www.iso.org/iso/home/store/catalogue_tc/catalogue_detail.htm?csnumber=57853</citetitle>
</link>
</emphasis></para>
</listitem>
<listitem xml:id="dbdoclet.50655239_page12">
<para>Itanium C++ ABI: Exception Handling. Rev 1.22, CodeSourcery,
2001.
<emphasis>
<link xl:href="http://www.codesourcery.com/public/cxx-abi/abi-eh.html">

<citetitle>
http://www.codesourcery.com/public/cxx-abi/abi-eh.html</citetitle>
</link>
</emphasis></para>
</listitem>
<listitem>
<para>
<emphasis>ISO/IEC TR 24732:2009 - Programming languages, their
environments and system software interfaces - Extension for the
programming language C to support decimal floating-point
arithmetic</emphasis>, ISO/IEC, January 05, 2009. Available from ISO.
<emphasis>
<link xl:href="http://www.iso.org/iso/home/store/catalogue_tc/catalogue_tc_browse.htm?commid=45202">

<citetitle>
http://www.iso.org/iso/home/store/catalogue_tc/catalogue_tc_browse.htm?commid=45202</citetitle>
</link>
</emphasis></para>
</listitem>
<listitem>
<para>
<emphasis>ELF Handling for Thread-Local Storage</emphasis>, Version
0.20, Ulrich Drepper, Red Hat Inc., December 21, 2005.
<emphasis>
<link xl:href="http://people.redhat.com/drepper/tls.pdf">
<citetitle>http://people.redhat.com/drepper/tls.pdf</citetitle>
</link>
</emphasis></para>
</listitem>
</itemizedlist>
<para>The following documents are of interest for their historical
information but are not normative in any way.</para>
<itemizedlist>
<listitem>
<para>
<emphasis>64-bit PowerPC ELF Application Binary Interface Supplement
1.9.</emphasis>
<emphasis>
<link xl:href="http://refspecs.linuxfoundation.org/ELF/ppc64/PPC-elf64abi.html">

<citetitle>
http://refspecs.linuxfoundation.org/ELF/ppc64/PPC-elf64abi.html</citetitle>
</link>
</emphasis>
</para>
</listitem>
<listitem>
<para>
<emphasis>IBM PowerOpen™ ABI Application Binary Interface Big-Endian
32-Bit Hardware Implementation.</emphasis>
<emphasis>
<link xl:href="ftp://www.sourceware.org/pub/binutils/ppc-docs/ppc-poweropen/">

<citetitle>
ftp://www.sourceware.org/pub/binutils/ppc-docs/ppc-poweropen/</citetitle>
</link>
</emphasis>
</para>
</listitem>
<listitem>
<para>
<emphasis>Power Architecture 32-bit ABI Supplement 1.0
Embedded/Linux/Unified.</emphasis>
<emphasis>
<link xl:href="https://www.power.org/documentation/power-architecture-32-bit-abi-supplement-1-0-embeddedlinuxunified/">

<citetitle>
https://www.power.org/documentation/power-architecture-32-bit-abi-supplement-1-0-embeddedlinuxunified/</citetitle>
</link>
</emphasis>
</para>
</listitem>
<listitem>
<para>
<emphasis>ALTIVEC PIM: AltiVec™ Technology Programming Interface
Manual</emphasis>, Freescale Semiconductor, 1999.
<emphasis>
<link xl:href="http://www.freescale.com/files/32bit/doc/ref_manual/ALTIVECPIM.pdf">

<citetitle>
http://www.freescale.com/files/32bit/doc/ref_manual/ALTIVECPIM.pdf</citetitle>
</link>
</emphasis></para>
</listitem>
<listitem>
<para>ELF Assembly Users Guide, Fourth edition, IBM, 2000.</para>
<para>
<emphasis>
<link xl:href="https://www-03.ibm.com/technologyconnect/tgcm/TGCMFileServlet.wss/assem_um.pdf?id=109917A251EFD64C872569D900656D07&amp;linkid=1h3000&amp;c_t=md515o6ntgh671shz9ioar20oyfp1grs">

<citetitle>
https://www-03.ibm.com/technologyconnect/tgcm/TGCMFileServlet.wss/assem_um.pdf?id=109917A251EFD64C872569D900656D07&amp;linkid=1h3000&amp;c_t=md515o6ntgh671shz9ioar20oyfp1grs</citetitle>
</link>
</emphasis>
</para>
</listitem>
</itemizedlist>
</section>
</chapter>

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

@ -0,0 +1,369 @@
<chapter xmlns="http://docbook.org/ns/docbook"
xmlns:xl="http://www.w3.org/1999/xlink" version="5.0"
xml:lang="en"
xml:id="dbdoclet.50655243_pgfId-1099317">
<title>Libraries</title>
<section xml:id="dbdoclet.50655243___RefHeading___Toc377640665">
<title>Library Requirements</title>
<para>This ABI does not specify any additional interfaces for
general-purpose libraries. However, certain processor-specific support
routines are defined to ensure portability between ABI-conforming
implementations.</para>
<para>Such processor-specific support definitions concern vector and
floating-point alignment, register save and restore routines, variable
argument list layout, and a limited set of data definitions.</para>
<section xml:id="dbdoclet.50655243___RefHeading___Toc377640666">
<title>C Library Conformance with Generic ABI</title>
<para />
<section xml:id="dbdoclet.50655243___RefHeading___Toc377640667">
<title>Malloc Routine Return Pointer Alignment</title>
<para>The malloc() routine must always return a pointer with the
alignment of the largest alignment needed for loads and stores of the
built-in data types. This is currently 16 bytes.</para>
</section>
<section xml:id="dbdoclet.50655243___RefHeading___Toc377640668">
<title>Library Handling of Limited-Access Bits in Registers</title>
<para>Requirements for the handling of limited-access bits in certain
registers by standard library functions are defined in
<xref linkend="dbdoclet.50655240___RefHeading___Toc377640581" />.</para>
</section>
</section>
<section xml:id="dbdoclet.50655243_49403">
<title>Save and Restore Routines</title>
<para>All of the save and restore routines described in
<xref linkend="dbdoclet.50655240_24141" /> are required. These routines
use unusual calling conventions due to their special purpose. Parameters
for these functions are described in
<xref linkend="dbdoclet.50655240_41483" />,
<xref linkend="dbdoclet.50655240_56788" />, and
<xref linkend="dbdoclet.50655240_96790" />.</para>
<para>The symbols for these functions shall be hidden and locally
resolved within each module. The symbols so created shall not be
exported.</para>
<para>These functions can either be provided in a utility library that is
linked by the linker to each module, or the functions can be synthesized
by the linker as necessary to resolve symbols.</para>
</section>
<section xml:id="dbdoclet.50655243_page131">
<title>Types Defined in the Standard Header
<anchor xml:id="dbdoclet.50655243___RefHeading___Toc377640670"
xreflabel="" /> Types Defined in the Standard Header</title>
<para>The type va_list shall be defined as follows:</para>
<para><literal>typedef void * va_list;</literal></para>
<para>The following integer types are defined in headers, which must be
provided by freestanding implementations, or have their limits defined in
such headers. They shall have the following definitions:</para>
<itemizedlist spacing="compact">
<listitem>
<para>typedef long ptrdiff_t;</para>
</listitem>
<listitem>
<para>typedef unsigned long size_t;</para>
</listitem>
<listitem>
<para>typedef int wchar_t;</para>
</listitem>
<listitem>
<para>typedef int sig_atomic_t;</para>
</listitem>
<listitem>
<para>typedef unsigned int wint_t;</para>
</listitem>
<listitem>
<para>typedef signed char int8_t;</para>
</listitem>
<listitem>
<para>typedef short int16_t;</para>
</listitem>
<listitem>
<para>typedef int int32_t;</para>
</listitem>
<listitem>
<para>typedef long int64_t;</para>
</listitem>
<listitem>
<para>typedef unsigned char uint8_t;</para>
</listitem>
<listitem>
<para>typedef unsigned short uint16_t;</para>
</listitem>
<listitem>
<para>typedef unsigned int uint32_t;</para>
</listitem>
<listitem>
<para>typedef unsigned long uint64_t;</para>
</listitem>
<listitem>
<para>typedef signed char int_least8_t;</para>
</listitem>
<listitem>
<para>typedef short int_least16_t;</para>
</listitem>
<listitem xml:id="dbdoclet.50655243_page136">
<para>typedef int int_least32_t;</para>
</listitem>
<listitem>
<para>typedef long int_least64_t;</para>
</listitem>
<listitem>
<para>typedef unsigned char uint_least8_t;</para>
</listitem>
<listitem>
<para>typedef unsigned short uint_least16_t;</para>
</listitem>
<listitem>
<para>typedef unsigned int uint_least32_t;</para>
</listitem>
<listitem>
<para>typedef unsigned long uint_least64_t;</para>
</listitem>
<listitem>
<para>typedef signed char int_fast8_t;</para>
</listitem>
<listitem>
<para>typedef int int_fast16_t;</para>
</listitem>
<listitem>
<para>typedef int int_fast32_t;</para>
</listitem>
<listitem>
<para>typedef long int_fast64_t;</para>
</listitem>
<listitem>
<para>typedef unsigned char uint_fast8_t;</para>
</listitem>
<listitem>
<para>typedef unsigned int uint_fast16_t;</para>
</listitem>
<listitem>
<para>typedef unsigned int uint_fast32_t;</para>
</listitem>
<listitem>
<para>typedef unsigned long uint_fast64_t;</para>
</listitem>
<listitem>
<para>typedef long intptr_t;</para>
</listitem>
<listitem>
<para>typedef unsigned long uintptr_t;</para>
</listitem>
<listitem>
<para>typedef long intmax_t;</para>
</listitem>
<listitem>
<para>typedef unsigned long uintmax_t;</para>
</listitem>
</itemizedlist>
</section>
<section xml:id="dbdoclet.50655243_75216">
<title>Predefined Macros</title>
<para>A C preprocessor that conforms to this ABI shall predefine the
macro _CALL_ELF to have a value of 2.</para>
<para>The macros listed in
<xref linkend="dbdoclet.50655243_37910" /> are based on environment
characteristics. They shall be predefined to a value of 1 by conforming C
preprocessors when the corresponding condition applies.</para>
<para> </para>
<table frame="all" pgwide="1" xml:id="dbdoclet.50655243_37910">
<title>Predefined Target Architecture Macros</title>
<tgroup cols="2">
<colspec colname="c1" colwidth="20*" align="center"/>
<colspec colname="c2" colwidth="80*" />
<thead>
<row>
<entry>
<para>
<emphasis role="bold">Macro</emphasis>
</para>
</entry>
<entry align="center">
<para>
<emphasis role="bold">Condition</emphasis>
</para>
</entry>
</row>
</thead>
<tbody>
<row>
<entry>
<para>__PPC__</para>
<para>__powerpc__</para>
</entry>
<entry>
<para>The target is a Power Architecture processor.</para>
</entry>
</row>
<row>
<entry>
<para>__PPC64__</para>
<para>__powerpc64__</para>
<para>__64BIT__
<footnote xml:id="pgfId-1101811">
<para>Phased in.</para>
</footnote></para>
</entry>
<entry>
<para>The target is a Power Architecture processor running in
64-bit mode.</para>
</entry>
</row>
<row>
<entry>
<para>__BIG_ENDIAN__</para>
</entry>
<entry>
<para>The target processor is big endian.</para>
</entry>
</row>
<row>
<entry>
<para>__LITTLE_ENDIAN__</para>
</entry>
<entry>
<para>The target processor is little endian.</para>
</entry>
</row>
<row>
<entry>
<para>ARCH_PWRn</para>
</entry>
<entry>
<para>Indicates that the target processor supports the Power
ISA level for POWERn or higher. For example, ARCH_PWR8 supports
the Power ISA for a POWER8 processor.</para>
</entry>
</row>
</tbody>
</tgroup>
</table>
<para> </para>
<para> </para>
<para>The macros in listed
<xref linkend="dbdoclet.50655243_98814" /> are based on the order of the
data elements. They shall be predefined to one of the allowable values by
conforming C preprocessors when the corresponding condition
applies.</para>
<para> </para>
<table frame="all" pgwide="1" xml:id="dbdoclet.50655243_98814">
<title>Predefined Target Data Order Macros</title>
<tgroup cols="3">
<colspec colname="c1" colwidth="30*" align="center"/>
<colspec colname="c2" colwidth="25*" align="center"/>
<colspec colname="c3" colwidth="45*" />
<thead>
<row>
<entry>
<para>
<emphasis role="bold">Macro</emphasis>
</para>
</entry>
<entry>
<para>
<emphasis role="bold">Value</emphasis>
</para>
</entry>
<entry align="center">
<para>
<emphasis role="bold">Condition</emphasis>
</para>
</entry>
</row>
</thead>
<tbody>
<row>
<entry morerows="1">
<para>__BYTE_ORDER__</para>
</entry>
<entry>
<para>__ORDER_BIG_ENDIAN__</para>
</entry>
<entry>
<para>The target processor is big endian.</para>
</entry>
</row>
<row>
<entry>
<para>__ORDER_LITTLE_ENDIAN__</para>
</entry>
<entry>
<para>The target processor is little endian.</para>
</entry>
</row>
<row>
<entry morerows="1">
<para>__FLOAT_WORD_ORDER__</para>
</entry>
<entry>
<para>__ORDER_BIG_ENDIAN__</para>
</entry>
<entry>
<para>The target processor is big endian.</para>
</entry>
</row>
<row>
<entry>
<para>__ORDER_LITTLE_ENDIAN__</para>
</entry>
<entry>
<para>The target processor is little endian.</para>
</entry>
</row>
<row>
<entry morerows="1">
<para>__VEC_ELEMENT_REG_ORDER__</para>
<para>For more information, see
<xref linkend="dbdoclet.50655244_25365" />.</para>
</entry>
<entry>
<para>__ORDER_BIG_ENDIAN__</para>
</entry>
<entry>
<para>The target processor is big endian, or big-endian vector
element order has been requested.</para>
</entry>
</row>
<row>
<entry>
<para>__ORDER_LITTLE_ENDIAN__</para>
</entry>
<entry>
<para>The target processor is little endian, and big-endian
vector element order has not been requested.</para>
</entry>
</row>
</tbody>
</tgroup>
</table>
<para> </para>
<para> </para>
</section>
</section>
<section>
<title>POWER ISA-Specific API and ABI Extensions</title>
<para>The Data Stream Control Register (DSCR) affects how the processor
handles data streams that are detected by the hardware and defined by the
software. For more information, see “Data Stream Control Overview, ABI, and
API” at the following link:</para>
<para>
<emphasis>
<link xl:href="https://github.com/paflib/paflib/wiki/Data-Stream-Control-Overview,-ABI,-and-API">

<citetitle>
https://github.com/paflib/paflib/wiki/Data-Stream-Control-Overview,-ABI,-and-API</citetitle>
</link>
</emphasis>
</para>
<para>The event-based branching facility generates exceptions when certain
criteria are met. For more information, see the “Event Based Branching
Overview, ABI, and API” section at the following link:</para>
<para>
<emphasis>
<link xl:href="https://github.com/paflib/paflib/wiki/Event-Based-Branching----Overview,-ABI,-and-API">

<citetitle>
https://github.com/paflib/paflib/wiki/Event-Based-Branching----Overview,-ABI,-and-API</citetitle>
</link>
</emphasis>
</para>
</section>
</chapter>

File diff suppressed because it is too large Load Diff

@ -0,0 +1,74 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Copyright (c) 2016 OpenPOWER Foundation
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
-->
<preface xmlns="http://docbook.org/ns/docbook"
xmlns:xi="http://www.w3.org/2001/XInclude"
xmlns:xlink="http://www.w3.org/1999/xlink"
version="5.0"
xml:id="ch_PAPR_preface">
<title>Notices</title>
<?dbhtml stop-chunking?>

<para>This document is based on the following publications:</para>
<para><citetitle>Power Architecture 32-bit Application Binary Interface Supplement 1.0</citetitle>
by Ryan S. Arnold, Greg Davis, Brian Deitrich, Michael Eager, Emil Medve, Steven J. Munroe,
Joseph S. Myers, Steve Papacharalambous, Anmol P. Paralkar, Katherine Stewart, and Edmar Wienskoski,
1.0 Edition. Published April 19, 2011. Copyright © 1999, 2003, 2004 IBM Corporation. Copyright © 2002
Freescale Semiconductor, Inc. Copyright © 2003, 2004 Free Standards Group. Copyright © 2011 Power.org
</para>
<para>Portions of <citetitle>Power Architecture 32-bit Application Binary Interface Supplement 1.0</citetitle>
are derived from the 64-bit PowerPC® ELF Application Binary Interface Supplement 1.8, originally written by
Ian Lance Taylor under contract for IBM, with later revisions by: David Edelsohn, Torbjorn Granlund,
Mark Mendell, Kristin Thomas, Alan Modra, Steve Munroe, and Chris Lorenze.
</para>
<para>The Thread Local Storage section of this document is an original contribution of IBM written by
Alan Modra and Steven Munroe.
</para>

<para>IBM, the IBM logo, and ibm.com are trademarks or registered trademarks of International Business
Machines Corp., registered in many jurisdictions worldwide. Other product and service names might be
trademarks of IBM or other companies. A current list of IBM trademarks is available on the Web at
“Copyright and trademark information” at
<link xlink:href="http://www.ibm.com/legal/copytrade.shtml">www.ibm.com/legal/copytrade.shtml</link>.
</para>

<para>The following terms are trademarks or registered trademarks licensed by Power.org in the
United States and/or other countries: Power ISA<superscript>TM</superscript>, Power Architecture®.
Information on the list of U.S. trademarks licensed by Power.org may be found at
<link xlink:href="http://www.power.org/about/brand-center/">www.power.org/about/brand-center/</link>.
</para>

<para>The following terms are trademarks or registered trademarks of Freescale Semiconductor
in the United States and/or other countries: AltiVec<superscript>TM</superscript>, e500<superscript>TM</superscript>.
Information on the list of U.S. trademarks owned by Freescale Semiconductor may be found at
<link xlink:href="http://www.freescale.com/files/abstract/help_page/TERMSOFUSE.html">www.freescale.com/files/abstract/help_page/TERMSOFUSE.html</link>.
</para>

<para>Linux is a trademark of Linus Torvalds in the United States, other countries, or both.
</para>

<para>Java, and all Java-based trademarks and logos are trademarks or registered trademarks of
Oracle and/or its affiliates.
</para>

<para>Other company, product, and service names may be trademarks or service marks of others.
</para>

</preface>

Binary file not shown.

After

Width:  |  Height:  |  Size: 981 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 877 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 873 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 12 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.4 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.2 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 875 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 6.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 7.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 25 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 28 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 51 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 34 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 88 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 80 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 53 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 35 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 63 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 131 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 74 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 72 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 73 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 11 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 48 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 56 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 76 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 8.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 67 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 30 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 47 KiB

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save