indicates whether this entry represents a non-defining
declaration of an object.
-\item A \livelink{chap:DWATlocation}{DW\-\_AT\-\_location} attribute, whose value describes the
+\item A \livelink{chap:DWATlocation}{DW\-\_AT\-\_location} attribute,
+\addtoindexx{location attribute}
+whose value describes the
location of a variable or parameter at run-time. In a variable
entry representing the definition of a variable (that is,
\addtoindexx{declaration attribute}
\livelink{chap:DWATlinkagename}{DW\-\_AT\-\_linkage\-\_name} attribute as described in
Section \refersec{chap:linkagenames}.
It
-also has a \livelink{chap:DWATlocation}{DW\-\_AT\-\_location} attribute whose value describes the
+also has a \livelink{chap:DWATlocation}{DW\-\_AT\-\_location} attribute
+\addtoindexx{location attribute}
+whose value describes the
location of the beginning of the common \nolink{block}. The common
\nolink{block} entry owns debugging information entries describing
the variables contained within the common \nolink{block}.
and which are given a common interpretation according to the
attribute in which the form is used.
-Form \livelink{chap:DWFORMsecoffset}{DW\-\_FORM\-\_sec\-\_offset} is a member of more than one class,
-namely \livelink{chap:lineptr}{lineptr}, \livelink{chap:loclistptr}{loclistptr}, \livelink{chap:macptr}{macptr} or \livelink{chap:rangelistptr}{rangelistptr}; the list
+Form \livelink{chap:DWFORMsecoffset}{DW\-\_FORM\-\_sec\-\_offset}
+is a member of more
+\addtoindexx{rangelistptr class}
+than
+\addtoindexx{macptr class}
+one
+\addtoindexx{loclistptr class}
+class,
+\addtoindexx{lineptr class}
+namely \livelink{chap:lineptr}{lineptr},
+\livelink{chap:loclistptr}{loclistptr},
+\livelink{chap:macptr}{macptr} or
+\livelink{chap:rangelistptr}{rangelistptr}; the list
of classes allowed by the applicable attribute in
Table \refersec{tab:attributeencodings}
determines the class of the form.
\textit{In DWARF V3 the forms \livelink{chap:DWFORMdata4}{DW\-\_FORM\-\_data4} and \livelink{chap:DWFORMdata8}{DW\-\_FORM\-\_data8} were
-members of either class constant or one of the classes \livelink{chap:lineptr}{lineptr},
-\livelink{chap:loclistptr}{loclistptr}, \livelink{chap:macptr}{macptr} or \livelink{chap:rangelistptr}{rangelistptr}, depending on context. In
-DWARF V4 \livelink{chap:DWFORMdata4}{DW\-\_FORM\-\_data4} and \livelink{chap:DWFORMdata8}{DW\-\_FORM\-\_data8} are members of class
-constant in all cases. The new \livelink{chap:DWFORMsecoffset}{DW\-\_FORM\-\_sec\-\_offset} replaces
+\addtoindexx{lineptr class}
+members
+\addtoindexx{rangelistptr class}
+of
+\addtoindexx{macptr class}
+either
+\addtoindexx{loclistptr class}
+class constant \addtoindexx{constant class}
+or one of the classes
+\livelink{chap:lineptr}{lineptr},
+\livelink{chap:loclistptr}{loclistptr},
+\livelink{chap:macptr}{macptr} or
+\livelink{chap:rangelistptr}{rangelistptr}, depending on context. In
+DWARF V4
+\livelink{chap:DWFORMdata4}{DW\-\_FORM\-\_data4} and
+\livelink{chap:DWFORMdata8}{DW\-\_FORM\-\_data8} are members of class
+constant in all cases.
+The new
+\livelink{chap:DWFORMsecoffset}{DW\-\_FORM\-\_sec\-\_offset} replaces
their usage for the other classes.}
Each possible form belongs to one or more of the following classes:
beginning of the
\addtoindex{.debug\_loc}
section to the first byte of
-the data making up the location list for the compilation
+the data making up the
+\addtoindex{location list} for the compilation
unit.
It is relocatable in a relocatable object file, and
relocated in an executable or shared object. In the 32\dash bit
\section{Variable Length Data}
\label{datarep:variablelengthdata}
\addtoindexx{variable length data|see {LEB128}}
-\addtoindexx{LEB128 encoding}
-Integers may be encoded using ``Little Endian Base 128''
-(LEB128) numbers. LEB128 is a scheme for encoding integers
+Integers may be
+\addtoindexx{Little Endian Base 128|see{LEB128}}
+encoded using ``Little Endian Base 128''
+\addtoindexx{little-endian encoding|see{endian attribute}}
+(LEB128) numbers.
+\addtoindexx{LEB128}
+LEB128 is a scheme for encoding integers
densely that exploits the assumption that most integers are
small in magnitude.
extension bits.
Unsigned LEB128 (ULEB128) numbers are encoded as follows:
+\addtoindexx{LEB128!unsigned, encoding as}
start at the low order end of an unsigned integer and chop
it into 7\dash bit chunks. Place each chunk into the low order 7
bits of a byte. Typically, several of the high order bytes
The encoding for signed, two’s complement LEB128 (SLEB128)
+\addtoindexx{LEB128!signed, encoding as}
numbers is similar, except that the criterion for discarding
high order bytes is not whether they are zero, but whether
they consist entirely of sign extension bits. Consider the
Table \refersec{tab:examplesofunsignedleb128encodings}
gives some examples of unsigned LEB128 numbers and
Table \refersec{tab:examplesofsignedleb128encodings}
-gives some examples of signed LEB128 numbers.
+gives some examples of signed LEB128
+numbers.
Appendix \refersec{app:variablelengthdataencodingdecodinginformative}
+\addtoindexx{LEB128!examples}
gives algorithms for encoding and decoding these forms.
\subsection{Location Lists}
\label{datarep:locationlists}
-Each entry in a location list is either a location list entry,
+Each entry in a \addtoindex{location list} is either a location list entry,
a base address selection entry, or an
\addtoindex{end of list entry!in location list}
end of list entry.
-A location list entry consists of two address offsets followed
+A \addtoindex{location list} entry consists of two address offsets followed
by a 2\dash byte length, followed by a block of contiguous bytes
that contains a DWARF location description. The length
specifies the number of bytes in that block. The two offsets
consist of two (constant or relocated) address offsets. The two
offsets are the same size as an address on the target machine.
-For a location list to be specified, the base address of
+For a \addtoindex{location list} to be specified, the base address of
\addtoindexx{base address selection entry!in location list}
the corresponding compilation unit must be defined
(see Section \refersec{chap:normalandpartialcompilationunitentries}).
\section{Source Languages}
\label{datarep:sourcelanguages}
-The encodings of the constants used in the \livelink{chap:DWATlanguage}{DW\-\_AT\-\_language}
+The encodings of the constants used
+\addtoindexx{language attribute, encoding}
+in
+\addtoindexx{language name encoding}
+the
+\livelink{chap:DWATlanguage}{DW\-\_AT\-\_language}
attribute are given in
Table \refersec{tab:languageencodings}.
Names marked with
and their associated values are reserved, but the
languages they represent are not well supported.
Table \refersec{tab:languageencodings}
-also shows the default lower bound, if any, assumed for
+also shows the
+\addtoindexx{lower bound attribute!default}
+default lower bound, if any, assumed for
an omitted \livelink{chap:DWATlowerbound}{DW\-\_AT\-\_lower\-\_bound} attribute in the context of a
\livelink{chap:DWTAGsubrangetype}{DW\-\_TAG\-\_subrange\-\_type} debugging information entry for each
defined language.
for ``false,'' and a non-zero value for ``true.''
The encodings for the standard opcodes are given in
+\addtoindexx{line number opcodes!standard opcode encoding}
Table \refersec{tab:linenumberstandardopcodeencodings}.
% Odd that the 'Name' field captalized here, it is not caps elsewhere.
The encodings for the extended opcodes are given in
+\addtoindexx{line number opcodes!extended opcode encoding}
Table \refersec{tab:linenumberextendedopcodeencodings}.
\begin{centering}
identical across compilation units.}
\item \textit{The entry has an attribute whose value refers
-to a code location or a location list.}
+to a code location or a \addtoindex{location list}.}
\item \textit{The entry has an attribute whose value refers
to another debugging information entry that does not represent
%f
\item \addtoindex{.debug\_info} \\
An attribute value of class \livelink{chap:loclistptr}{loclistptr} (specifically form
-\livelink{chap:DWFORMsecoffset}{DW\-\_FORM\-\_sec\-\_offset}) is an offset within the \addtoindex{.debug\_loc} section of a
-location list.
+\livelink{chap:DWFORMsecoffset}{DW\-\_FORM\-\_sec\-\_offset}) is an offset within the \addtoindex{.debug\_loc}
+section of a
+\addtoindex{location list}.
%g
\item \addtoindex{.debug\_info} \\
Here are algorithms expressed in a C-like pseudo-code to
encode and decode signed and unsigned numbers in LEB128
+\addtoindexx{LEB128!unsigned, encoding as}
representation.
\begin{figure}[here]
} while (value != 0);
\end{lstlisting}
\end{figure}
+
+\addtoindexx{LEB128!signed, encoding as}
+
\begin{figure}[here]
\caption{Algorithm to encode a signed integer}
\begin{lstlisting}
}
\end{lstlisting}
\end{figure}
+
+
+
+\addtoindexx{LEB128!unsigned, decoding of}
+
\begin{figure}[here]
\caption{Algorithm to decode an unsigned LEB128 integer}
\begin{lstlisting}
}
\end{lstlisting}
\end{figure}
+
+\addtoindexx{LEB128!signed, decoding of}
+
\begin{figure}[here]
\caption{Algorithm to decode a signed LEB128 integer}
\begin{lstlisting}
\end{figure}
Suppose the line number program header includes the following
-(header fields not needed below are not shown):
-
+(header fields not
+needed
+\addtoindexx{line\_base}
+below
+\addtoindexx{line\_range}
+are
+\addtoindexx{opcode\_base}
+not
+\addtoindexx{minumum\_instruction\_length}
+shown):
\begin{alltt}
}
These operations transfer
-control of DWARF expression evaluation to the
+control of DWARF expression evaluation to
+\addtoindexx{location attribute}
+the
\livelink{chap:DWATlocation}{DW\-\_AT\-\_location}
attribute of the referenced debugging information entry. If
there is no such attribute, then there is no effect. Execution
-of the DWARF expression of a \livelink{chap:DWATlocation}{DW\-\_AT\-\_location} attribute may add
+of the DWARF expression of
+\addtoindexx{location attribute}
+a
+\livelink{chap:DWATlocation}{DW\-\_AT\-\_location} attribute may add
to and/or remove from values on the stack. Execution returns
to the point following the call when the end of the attribute
is reached. Values on the stack at the time of the call may be
\section{Location Descriptions}
\label{chap:locationdescriptions}
-\textit{Debugging information must provide consumers a way to find
+\textit{Debugging information
+\addtoindexx{location description}
+\addtoindexx{location description}
+must
+%FIXME: should be 'see also' somehow.
+\addtoindexx{location description|see{DWARF expression}}
+provide consumers a way to find
the location of program variables, determine the bounds
of dynamic arrays and strings, and possibly to find the
base address of a subroutine’s stack frame or the return
by location descriptions. Location descriptions can be either
of two forms:
\begin{enumerate}[1]
-\item \textit{Single location descriptions}, which are a language independent representation of
+\item \textit{Single location descriptions},
+which
+\addtoindexx{location description!single}
+are a language independent representation of
addressing rules of arbitrary complexity built from
DWARF expressions (See Section \refersec{chap:dwarfexpressions})
and/or other
Single location descriptions are of two kinds:
\begin{enumerate}[a]
\item Simple location descriptions, which describe the location
+\addtoindexx{location description!simple}
of one contiguous piece (usually all) of an object. A simple
location description may describe a location in addressable
memory, or in a register, or the lack of a location (with or
without a known value).
\item Composite location descriptions, which describe an
+\addtoindexx{location description!composite}
object in terms of pieces each of which may be contained in
part of a register or stored in a memory location unrelated
to other pieces.
\end{enumerate}
-\item \textit{Location lists}, which are used to describe
+\item \textit{Location lists}, which are used to
+\addtoindexx{location list}
+describe
+\addtoindexx{location description!use in location list}
objects that have a limited lifetime or change their location
during their lifetime. Location lists are more completely
described below.
\addtoindexx{exprloc class}
class \livelink{chap:exprloc}{exprloc}
and a location list is encoded
-using class \livelink{chap:loclistptr}{loclistptr} (which serves as an offset into a
-separate location list table).
+using class \livelink{chap:loclistptr}{loclistptr}
+(which
+\addtoindex{loclistptr}
+serves as an offset into a
+separate
+\addtoindexx{location list}
+location list table).
\subsection{Single Location Descriptions}
\begin{enumerate}[1]
\item A simple location description, representing an object
+\addtoindexx{location description!simple}
which exists in one contiguous piece at the given location, or
\item A composite location description consisting of one or more
+\addtoindexx{location description!composite}
simple location descriptions, each of which is followed by
one composition operation. Each simple location description
describes the location of one piece of the object; each
\subsubsection{Simple Location Descriptions}
-A simple location description consists of one
+A
+\addtoindexx{location description!simple}
+simple location description consists of one
contiguous piece or all of an object or value.
\paragraph{Memory Location Descriptions}
-A memory location description consists of a non\dash empty DWARF
+A
+\addtoindexx{location description!memory}
+memory location description consists of a non\dash empty DWARF
expression (see
Section \refersec{chap:dwarfexpressions}
), whose value is the address of
An \addtoindex{implicit location description}
represents a piece or all
+\addtoindexx{location description!implicit}
of an object which has no actual location but whose contents
are nonetheless either known or known to be undefined.
An \addtoindex{empty location description}
consists of a DWARF expression
+\addtoindexx{location description!empty}
containing no operations. It represents a piece or all of an
object that is present in the source but not in the object code
(perhaps due to optimization).
\subsection{Location Lists}
\label{chap:locationlists}
-Location lists are used in place of location expressions
+Location lists
+\addtoindexx{location list}
+are used in place of location expressions
whenever the object whose location is being described
-can change location during its lifetime. Location lists
+can change location during its lifetime.
+Location lists
+\addtoindexx{location list}
are contained in a separate object file section called
\addtoindex{.debug\_loc}. A location list is indicated by a location
attribute whose value is an offset from the beginning of
entry,
a
\addtoindexi{base}{base address selection entry!in location list}
-address selection entry, or an
+address selection entry,
+\addtoindexx{location list!base address selection entry}
+or an
\addtoindexx{end of list entry!in location list}
end of list entry.
-A location list entry consists of:
+A
+\addtoindexx{location list!entry}
+location list entry consists of:
\begin{enumerate}[1]
\item A beginning address offset.
the beginning and end addresses.
\end{enumerate}
-The applicable base address of a location list entry is
+The applicable base address of a
+location list entry is
+\addtoindexx{location list!base address selection entry}
determined by the closest preceding base address selection
entry (see below) in the same location list. If there is
no such selection entry, then the applicable base address
\textit{A base address selection entry
affects only the list in which it is contained.}
-The end of any given location list is marked by an end of
-list entry, which consists of a 0 for the beginning address
+The end of any given location list is marked by an
+\addtoindexx{location list!enf of list entry}
+end of list entry, which consists of a 0 for the beginning address
offset and a 0 for the ending address offset. A location list
containing only an
\addtoindexx{end of list entry!in location list}
representing
\hypertarget{chap:DWATdeclcolumncolumnpositionofsourcedeclaration}
the
+\addtoindexx{line number of declaration}
declaration of an object, module, subprogram or
\addtoindex{declaration column attribute}
type
\hypertarget{chap:DWATlocationdataobjectlocation}
includes variables and parameters) or
common \livelink{chap:commonblockentry}{block}
-may have a
-\livelink{chap:DWATlocation}{DW\-\_AT\-\_location} attribute, whose value is a location description
+may have
+\addtoindexx{location attribute}
+a
+\livelink{chap:DWATlocation}{DW\-\_AT\-\_location} attribute
+\addtoindexx{location attribute}
+, whose value is a location description
(see Section \refersec{chap:locationdescriptions}).
A
\addtoindex{DWARF procedure}
is represented by any
-kind of debugging information entry that has a
+kind of debugging information entry that has
+\addtoindexx{location attribute}
+a
\livelink{chap:DWATlocation}{DW\-\_AT\-\_location}
attribute.
+\addtoindexx{location attribute}
If a suitable entry is not otherwise available,
a DWARF procedure can be represented using a debugging
\addtoindexx{DWARF procedure entry}
information entry with the
tag \livetarg{chap:DWTAGdwarfprocedure}{DW\-\_TAG\-\_dwarf\-\_procedure}
-together with a \livelink{chap:DWATlocation}{DW\-\_AT\-\_location} attribute.
+together with
+\addtoindexx{location attribute}
+a \livelink{chap:DWATlocation}{DW\-\_AT\-\_location} attribute.
A DWARF procedure
is called by a \livelink{chap:DWOPcall2}{DW\-\_OP\-\_call2},
\label{chap:linkagenames}
\textit{Some language implementations, notably
\addtoindex{C++} and similar
-languages, make use of implementation defined names within
+languages,
+make use of implementation defined names within
object files that are different from the identifier names
(see Section \refersec{chap:identifiernames}) of entities as they appear in the
source. Such names, sometimes known as mangled names,
% Some trouble maybe with hbox full, so we try optional word breaks.
A debugging
-information entry may have a
+information entry may have
+\addtoindexx{linkage name attribute}
+a
\livelink{chap:DWATlinkagename}{DW\-\_AT\-\_linkage\-\_name}
attribute
whose value is a null-terminated string describing the object
\subsection{Lookup by Name}
-For lookup by name, two tables are maintained in separate
+For lookup by name,
+\addtoindexx{lookup!by name}
+two tables are maintained in separate
\addtoindex{accelerated access!by name}
object file sections named
\addtoindex{.debug\_pubnames} for objects and
\subsection{Lookup by Address}
-For lookup by address, a table is maintained in a separate
+For
+\addtoindexx{lookup!by address}
+lookup by address, a table is maintained in a separate
\addtoindex{accelerated access!by address}
object file section called
\addtoindex{.debug\_aranges}. The table consists
\section{Line Number Information}
\label{chap:linenumberinformation}
\textit{A source\dash level debugger will need to know how to
+%FIXME: the see here is not 'see also'. Fix?
+\addtoindexx{line number information|see{statement list attribute}}
associate locations in the source files with the corresponding
machine instruction addresses in the executable object or
the shared objects used by that executable object. Such an
used as part of support for debugging optimized code.}
\item line\_base (sbyte) \\
+\addtoindexx{line\_base}
This parameter affects the meaning of the special opcodes. See below.
\item line\_range (ubyte) \\
+\addtoindexx{line\_range}
This parameter affects the meaning of the special opcodes. See below.
\item opcode\_base (ubyte) \\
opcode (not inclusive) are used for vendor specific extensions.}
\item standard\_opcode\_lengths (array of ubyte) \\
+\addtoindexx{standard\_opcode\_lengths}
This array specifies the number of LEB128 operands for each
of the standard opcodes. The first element of the array
corresponds to the opcode whose value is 1, and the last
way to decrease the line number) in return for the ability
to add larger positive values to the address register. To
permit this variety of strategies, the line number program
-header defines a line\_base field that specifies the minimum
+header defines a
+\addtoindexx{line\_base}
+field that specifies the minimum
value which a special opcode can add to the line register
and a line\_range field that defines the range of values it
can add to the line register.}
A special opcode value is chosen based on the amount that needs
to be added to the line, address and op\_index registers. The
maximum line increment for a special opcode is the value
-of the line\_base field in the header, plus the value of
+of the
+\addtoindexx{line\_base}
+field in the header, plus the value of
the line\_range field, minus 1 (line base +
line range - 1).
If the desired line increment is greater than the maximum
The special opcode is then calculated using the following formula:
- opcode = ( \textit{desired line increment} - line\_base) +
-(line\_range * \textit{operation advance} ) + opcode\_base
+ opcode = ( \textit{desired line increment} - \addtoindex{line\_base}) +
+(\addtoindex{line\_range} * \textit{operation advance} ) + \addtoindex{opcode\_base}
If the resulting opcode is greater than 255, a standard opcode
must be used instead.
given for addresses in
\addtoindex{DWARF Version 3}.}
-The amount to increment the line register is the line\_base plus
-the result of the adjusted opcode modulo the line\_range. That
+The amount to increment the line register is the
+\addtoindex{line\_base} plus
+the result of the
+\addtoindex{adjusted opcode} modulo the
+\addtoindex{line\_range}. That
is,
\begin{myindentpara}{1cm}
-line increment = line\_base + (adjusted opcode \% line\_range)
+line increment = \addtoindex{line\_base} + (adjusted opcode \% \addtoindex{line\_range})
\end{myindentpara}
-\textit{As an example, suppose that the opcode\_base is 13, line\_base
-is -3, line\_range is 12, minimum\_instruction\_length is 1
-and maximum\_operations\_per\_instruction is 1. This means that
+\textit{As an example, suppose that the opcode\_base is 13,
+\addtoindex{line\_base}
+is -3, \addtoindex{line\_range} is 12,
+\addtoindex{minimum\_instruction\_length} is 1
+and
+\addtoindex{maximum\_operations\_per\_instruction} is 1.
+This means that
we can use a special opcode whenever two successive rows in
the matrix have source line numbers differing by any value
within the range [-3, 8] and (because of the limited number
\textit{There is no requirement that the expression
-255 - line\_base + 1 be an integral multiple of
-line\_range. }
+255 - \addtoindex{line\_base} + 1 be an integral multiple of
+\addtoindex{line\_range}. }
\subsubsection{Standard Opcodes}
\label{chap:standardopcodes}
with
\livelink{chap:DWATranges}{DW\-\_AT\-\_ranges} to specify the
\addtoindexx{ranges attribute}
-default base address for use in location lists (see Section
+default base address for use in
+\addtoindexx{location list}
+location lists (see Section
\refersec{chap:locationlists}) and range lists
(see Section \refersec{chap:noncontiguousaddressranges}).
containing the full or relative path name of the primary
source file from which the compilation unit was derived.
-\item A \livelink{chap:DWATlanguage}{DW\-\_AT\-\_language} attribute whose constant value is an
+\item A \livelink{chap:DWATlanguage}{DW\-\_AT\-\_language} attribute
+\addtoindexx{language attribute}
+whose constant value is an
\hypertarget{chap:DWATlanguageprogramminglanguage}
-integer code indicating the source language of the compilation
+integer code
+\addtoindexx{language attribute}
+indicating the source language of the compilation
unit. The set of language names and their meanings are given
in
Figure \refersec{fig:languagenames}.
type, plus additional debugging information entries that may
be necessary to include as part of the definition of the type.
-A type unit entry may have a \livelink{chap:DWATlanguage}{DW\-\_AT\-\_language} attribute, whose
+A type unit entry may have a
+\livelink{chap:DWATlanguage}{DW\-\_AT\-\_language} attribute,
+whose
+\addtoindexx{language attribute}
constant value is an integer code indicating the source
language used to define the type. The set of language names
and their meanings are given in Figure \refersec{fig:languagenames}.
a simple register location description, the given register
contains the frame base address. If the location description is
a DWARF expression, the result of evaluating that expression
-is the frame base address. Finally, for a location list,
+is the frame base address. Finally, for a
+\addtoindex{location list},
this interpretation applies to each location description
-contained in the list of location list entries.
+contained in the list of \addtoindex{location list} entries.
\textit{The use of one of the \livelink{chap:DWOPreg}{DW\-\_OP\-\_reg}~\textless~n~\textgreater
operations in this
can be used in several ways:}
\begin{enumerate}[1.]
-\item \textit{In procedures that need location lists to locate local
+\item \textit{In procedures that need
+\addtoindexx{location list}
+location lists to locate local
variables, the \livelink{chap:DWATframebase}{DW\-\_AT\-\_frame\-\_base} can hold the needed location
list, while all variables’ location descriptions can be
simpler ones involving the frame base.}
\livelink{chap:DWATentrypc}{DW\-\_AT\-\_entry\-\_pc},
\livelink{chap:DWATlocation}{DW\-\_AT\-\_location},
\livelink{chap:DWATreturnaddr}{DW\-\_AT\-\_return\-\_addr}, \livelink{chap:DWATstartscope}{DW\-\_AT\-\_start\-\_scope}, and
-\livelink{chap:DWATsegment}{DW\-\_AT\-\_segment}
-attributes typically should be omitted; however, this list
+\livelink{chap:DWATsegment}{DW\-\_AT\-\_segment!and abstract instance}
+attributes
+\addtoindexx{location attribute!and abstract instance}
+typically
+\addtoindexx{ranges attribute!and abstract instance}
+should
+\addtoindexx{high PC attribute!and abstract instance}
+be
+\addtoindexx{low PC attribute!and abstract instance}
+omitted;
+however,
+\addtoindexx{return address attribute!and abstract instance}
+this
+\addtoindexx{segment attribute!and abstract instance}
+list
+\addtoindexx{start scope attribute!and abstract instance}
is not exhaustive.
\textit{It would not make sense normally to put these attributes into
\section{Lexical Block Entries}
\label{chap:lexicalblockentries}
-\textit{A lexical \livetargi{chap:lexicalblock}{block}{lexical block} is a bracketed sequence of source statements
+\textit{A
+lexical \livetargi{chap:lexicalblock}{block}{lexical block}
+is
+\addtoindexx{lexical block}
+a bracketed sequence of source statements
that may contain any number of declarations. In some languages
(including \addtoindex{C} and \addtoindex{C++}),
\nolink{blocks} can be nested within other
entry with the
tag \livetarg{chap:DWTAGlexicalblock}{DW\-\_TAG\-\_lexical\-\_block}.
-The lexical \livetargi{chap:lexicalblockentry}{block}{lexical block entry} entry
+The lexical \livetargi{chap:lexicalblockentry}{block}{lexical block entry}
+entry
may have
either a \livelink{chap:DWATlowpc}{DW\-\_AT\-\_low\-\_pc} and
\livelink{chap:DWAThighpc}{DW\-\_AT\-\_high\-\_pc} pair of
statements.
A label is represented by a debugging information entry with
+\addtoindexx{label entry}
the
tag \livetarg{chap:DWTAGlabel}{DW\-\_TAG\-\_label}.
The entry for a label should be owned by
The with statement entry has a \livelink{chap:DWATtype}{DW\-\_AT\-\_type} attribute, denoting
the type of record whose fields may be referenced without full
qualification within the body of the statement. It also has
+\addtoindexx{location attribute}
a \livelink{chap:DWATlocation}{DW\-\_AT\-\_location} attribute, describing how to find the base
address of the record object referenced within the body of
the with statement.
Figure \refersec{fig:arrayordering}.
If no
ordering attribute is present, the default ordering for the
-source language (which is indicated by the \livelink{chap:DWATlanguage}{DW\-\_AT\-\_language}
-attribute of the enclosing compilation unit entry) is assumed.
+source language (which is indicated by the
+\livelink{chap:DWATlanguage}{DW\-\_AT\-\_language}
+attribute
+\addtoindexx{language attribute}
+of the enclosing compilation unit entry) is assumed.
\begin{figure}[here]
\autorows[0pt]{c}{1}{l}{
the inherited type. Otherwise, the value must be a location
description. In this latter case, the beginning address of
the derived class is pushed on the expression stack before
-the location description is evaluated and the result of the
+the \addtoindex{location description}
+is evaluated and the result of the
evaluation is the location of the inherited type.
\textit{The interpretation of the value of this attribute for
\textit{For a \addtoindex{C++} virtual base, the
\addtoindex{data member location attribute}
-will usually consist of a non-trivial location description.}
+will usually consist of a non-trivial
+\addtoindex{location description}.}
\subsection{Access Declarations}
\label{chap:accessdeclarations}
is required.
For a \livelink{chap:DWATdatamemberlocation}{DW\-\_AT\-\_data\-\_member\-\_location} attribute
-
\addtoindexx{data member location attribute}
there are two cases:
offset then the beginning of the member entry has that same
bit offset as well.
-\item Otherwise, the value must be a location description. In
+\item Otherwise, the value must be a \addtoindex{location description}.
+In
this case, the beginning of the containing entity must be byte
aligned. The beginning address is pushed on the DWARF stack
-before the location description is evaluated; the result of
+before the \addtoindex{location} description is evaluated; the result of
the evaluation is the base address of the member entry.
\textit{The push on the DWARF expression stack of the base address of
(see Section \refersec{chap:stackoperations});
\livelink{chap:DWOPpushobjectaddress}{DW\-\_OP\-\_push\-\_object\-\_address} therefore
is not needed at the
-beginning of a location description for a data member. The
+beginning of a \addtoindex{location description} for a data member.
+The
result of the evaluation is a location--either an address or
the name of a register, not an offset to the member.}
attribute
\addtoindexx{data member location attribute}
that has the form of a
-location description is not valid for a data member contained
+\addtoindex{location description} is not valid for a data member contained
in an entity that is not byte aligned because DWARF operations
do not allow for manipulating or computing bit offsets.}
\end{itemize}
-\textit{The location description for a bit field calculates the address
+\textit{The
+\addtoindex{location description} for a bit field calculates the address
of an anonymous object containing the bit field. The address
is relative to the structure, union, or class that most closely
encloses the bit field declaration. The number of bytes in this
entry for a virtual function also has a
\livelink{chap:DWATvtableelemlocation}{DW\-\_AT\-\_vtable\-\_elem\-\_location}
\addtoindexi{attribute}{vtable element location attribute} whose value contains
-a location description yielding the address of the slot
+a \addtoindex{location description}
+yielding the address of the slot
for the function within the virtual function table for the
enclosing class. The address of an object of the enclosing
type is pushed onto the expression stack before the location
\section{Condition Entries}
\label{chap:conditionentries}
-\textit{COBOL has the notion of a ``level\dash 88 condition'' that
+\textit{COBOL has the notion of
+\addtoindexx{level-88 condition, COBOL}
+a ``level\dash 88 condition'' that
associates a data item, called the conditional variable, with
a set of one or more constant values and/or value ranges.
Semantically, the condition is ‛true’ if the conditional
\hypertarget{chap:DWATstringlengthstringlengthofstringtype}
string type entry may have a
\livelink{chap:DWATstringlength}{DW\-\_AT\-\_string\-\_length} attribute
-whose value is a location description yielding the location
+whose value is a
+\addtoindex{location description} yielding the location
where the length of the string is stored in the program. The
string type entry may also have a \livelink{chap:DWATbytesize}{DW\-\_AT\-\_byte\-\_size} attribute
or \livelink{chap:DWATbitsize}{DW\-\_AT\-\_bit\-\_size} attribute, whose value
Section \refersec{chap:staticanddynamicvaluesofattributes}.
If the lower bound value is missing, the value is assumed to
-be a language\dash dependent default constant. The default lower
+be a language\dash dependent default constant.
+\addtoindexx{lower bound attribute!default}
+The default lower
bound is 0 for
\addtoindex{C}, \addtoindex{C++},
\addtoindex{D},
\hypertarget{chap:DWATuselocationmemberlocationforpointertomembertype}
pointer to member entry has a
\livelink{chap:DWATuselocation}{DW\-\_AT\-\_use\-\_location} attribute
-whose value is a location description that computes the
+whose value is a
+\addtoindex{location description} that computes the
address of the member of the class to which the pointer to
member entry points.
\addtoindexx{hidden indirection|see{data location attribute}}
hidden indirection
and/or run\dash time parameters in its representation. Its value
-is a location description. The result of evaluating this
+is a \addtoindex{location description}.
+The result of evaluating this
description yields the location of the data for an object.
When this attribute is omitted, the address of the data is
the same as the address of the object.