\addtoindexx{name attribute}
whose value is a null-terminated
string, containing the data object name as it appears in the
-source program. If a variable entry describes
-an
+source program.
+
+If a variable entry describes an
\addtoindex{anonymous union},
the name attribute is omitted or consists of a single
zero byte.
\addtoindexx{external attribute}
is a \livelink{chap:flag}{flag}, if the name
of a variable is visible outside of its enclosing compilation
-unit. The definitions of C++ static data members of structures
+unit.
+
+\textit{The definitions of C++ static data members of structures
or classes are represented by variable entries \nolink{flagged} as
external. Both file static and local variables in C and C++
are represented by non-external variable entries.
+}
\item A \livelink{chap:DWATdeclaration}{DW\-\_AT\-\_declaration} attribute,
\addtoindexx{declaration attribute}
\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.
+
If no location attribute is present in a variable
entry representing the definition of a variable (that is,
\addtoindexx{declaration attribute}
reference to the debugging information entry representing the
declaration of this data member. The referenced entry has the
tag \livelink{chap:DWTAGmember}{DW\-\_TAG\-\_member} and will be a child of some class, structure
-or union type entry. If the variable entry represents a
+or union type entry.
+
+If the variable entry represents a
non-defining declaration, \livelink{chap:DWATspecification}{DW\-\_AT\-\_specification} may be used
to reference the defining declaration of the variable. If
no \livelink{chap:DWATspecification}{DW\-\_AT\-\_specification} attribute is present, the defining
declaration may be found as a global definition either in the
current compilation unit or in another compilation unit with
-the \livelink{chap:DWATexternal}{DW\-\_AT\-\_external} attribute. Variable entries containing
+the \livelink{chap:DWATexternal}{DW\-\_AT\-\_external} attribute.
+
+Variable entries containing
the \livelink{chap:DWATspecification}{DW\-\_AT\-\_specification} attribute do not need to duplicate
information provided by the declaration entry referenced by
the specification attribute. In particular, such variable
as appropriate for the representation
of the variable’s value. The value is the actual constant
value of the variable, represented as it would be on the
-target architecture. One way in which a formal parameter
+target architecture.
+
+\textit{One way in which a formal parameter
with a constant value and no location can arise is for a
formal parameter of an inlined subprogram that corresponds
to a constant actual parameter of a call that is inlined.
+}
\item A \livelink{chap:DWATstartscope}{DW\-\_AT\-\_start\-\_scope} attribute if the scope of
\addtoindexx{start scope attribute}
this attribute specifies an ABI\dash defined
byte ordering \addtoindexx{ordering attribute} for
the value of the object. If omitted, the default endianity
-of data for the given type is assumed. The set of values
+of data for the given type is assumed.
+
+The set of values
and their meaning for this attribute is given in
-Figure \refersec{fig:endianityattributevalues}.
+Figure \ref{fig:endianityattributevalues}.
\begin{figure}[here]
\centering
These represent the default encoding formats as defined by
-the target architecture’s ABI or processor definition. The
+the target architecture's ABI or processor definition. The
exact definition of these formats may differ in subtle ways
for different architectures.
showspaces=false, % show spaces adding particular underscores
showstringspaces=false, % underline spaces within strings
showtabs=false, % show tabs within strings adding particular underscores
-frame=single, % adds a frame around the code
-tabsize=2, % sets default tabsize to 2 spaces
-captionpos=b, % sets the caption-position to bottom
-breaklines=true, % sets automatic line breaking
-breakatwhitespace=false,% sets if automatic breaks should only happen at whitespace
-escapeinside={\%*}{*)} % if you want to add a comment within your code
+frame=single, % adds a frame around the code
+tabsize=2, % sets default tabsize to 2 spaces
+captionpos=b, % sets the caption-position to bottom
+breaklines=true, % sets automatic line breaking
+breakatwhitespace=false, % sets if automatic breaks should only happen at whitespace
+escapeinside={\%*}{*)} % if you want to add a comment within your code
}
-\usepackage{amsmath} % Provides \nobreakdash
-\usepackage{graphicx} % For pictures
+\usepackage{amsmath} % Provides \nobreakdash
+\usepackage{graphicx} % For pictures
\usepackage{longtable}
+\usepackage{varioref} % defines \vref
% \textregistered is the trademark symbol
\usepackage[headheight=16pt,paper=letterpaper]{geometry}
\setlength{\headheight}{15pt} % avoids warning from latex
\usepackage[plainpages=false,pdfpagelabels,pagebackref]{hyperref} % Lets us generate colored active links inside a pdf.
\makeindex % This and the makeidx package allow \index to create index entries.
-\newcommand{\docdate}{17 December 2012}
+\newcommand{\docdate}{18 December 2012}
\newcommand{\dwf}{DWARF Debugging Information Format}
\newenvironment{myindentpara}[1]%
% Generate a page ref.
% use like \refersec{chap:registerbasedaddressing}
\newcommand{\refersec}[1]{\ref{#1} on page \pageref{#1}}
+%\newcommand{\refersec}[1]{\vref{#1}} % beware possible rerun loop
% Generate a live link in the document
% use like \livelink{chap:DWOPdup}{DW\-\_OP\-\_dup}
\newcommand{\addtoindexi}[2]{#1\index{#2}}
\newcommand{\addtoindexx}[1]{\index{#1}}
+\newcommand{\subsubsubsection}[1]{\paragraph{#1}}
\begin{document}
+\pagenumbering{roman}
\pagestyle{empty}
\nonzeroparskip
\setlength{\headheight}{6cm}
\setlength{\uppermargin}{6cm}
-
-
\begin{centering}
\LARGE
\textbf{\dwf}
\includegraphics[keepaspectratio=true,scale=1.0]{DWlogo}
\centering
-\href{http://www.dwarfstd.org}{\dwf\ Committee}
-
+\vspace{1in}
+\href{http://www.dwarfstd.org}{\dwf\ Committee}
+
\url{http://www.dwarfstd.org}
\large
+\vspace{1in}
\textbf{\docdate}
\end{centering}
-\openany
-\clearpage
+
+%\clearpage
\openany
\frontmatter
\makeoddfoot{plain}{\docdate}{}{Page \thepage}
\openany
-\pagenumbering{roman}
+
\nonzeroparskip
\setlength{\parindent}{0pt}
+\flushleft
\include{copyright}
\include{foreword}
\include{foreword4.1}
+\cleardoublepage
\tableofcontents
-\newpage
+\cleardoublepage
\listoffigures
-\newpage
+\cleardoublepage
\listoftables
-\newpage
+
\mainmatter
+\pagenumbering{arabic}
% Define the levels of sectionality that are numbered.
\setcounter{secnumdepth}{5}
\chapterstyle{section}
-\pagenumbering{arabic}
+
\aliaspagestyle{chapter}{fragFirstChPage}
The tag specifies the class to which an entry belongs
and the attributes define the specific characteristics of the entry.
-The set of
+The set of tag names
\addtoindexx{tag names|see{debugging information entry}}
-tag names
-is listed in Figure 1.
+is listed in Figure \refersec{fig:tagnames}.
The debugging information entries they identify are
described in Sections 3, 4 and 5.
-The debugging information entry descriptions
-in Sections 3, 4 and 5 generally include mention of
-most, but not necessarily all, of the attributes
-that are normally or possibly used with the entry.
-Some attributes, whose applicability tends to be
-pervasive and invariant across many kinds of
-debugging information entries, are described in
-this section and not necessarily mentioned in all
-contexts where they may be appropriate.
-Examples include \livelink{chap:DWATartificial}{DW\-\_AT\-\_artificial}, the declaration
-coordinates, and
-\livelink{chap:DWATdescription}{DW\-\_AT\-\_description}, among others.
-
-The debugging information entries are contained
-in the \addtoindex{.debug\_info} and
-\addtoindex{.debug\_types}
-sections of an object file.
-
-
-\section{Attribute Types}
-\label{chap:attributetypes}
-Each attribute value is characterized by an attribute name.
-\addtoindexx{attribute duplication}
-No more than one attribute with a given name may appear in any
-debugging information entry.
-There are no limitations on the
-\addtoindexx{attribute ordering}
-ordering of attributes within a debugging information entry.
-
-The attributes are listed in Figure 2.
-
-The permissible values
-\addtoindexx{attribute value classes}
-for an attribute belong to one or more classes of attribute
-value forms.
-Each form class may be represented in one or more ways.
-For example, some attribute values consist
-of a single piece of constant data.
-``Constant data''
-is the class of attribute value that those attributes may have.
-There are several representations of constant data,
-however (one, two, ,four, or eight bytes, and variable length
-data).
-The particular representation for any given instance
-of an attribute is encoded along with the attribute name as
-part of the information that guides the interpretation of a
-debugging information entry.
-
-Attribute value forms belong
-\addtoindexx{tag names!list of}
-to one of the classes shown in Figure \refersec{tab:classesofattributevalue}.
-\addtoindex{attributes!list of}
-
% These each need to link to definition page: FIXME
\begin{figure}[here]
\autorows[0pt]{c}{2}{l}{
\caption{Tag names}\label{fig:tagnames}
\end{figure}
-\label{tab:attributenames}
+
+The debugging information entry descriptions
+in Sections 3, 4 and 5 generally include mention of
+most, but not necessarily all, of the attributes
+that are normally or possibly used with the entry.
+Some attributes, whose applicability tends to be
+pervasive and invariant across many kinds of
+debugging information entries, are described in
+this section and not necessarily mentioned in all
+contexts where they may be appropriate.
+Examples include \livelink{chap:DWATartificial}{DW\-\_AT\-\_artificial}, the declaration
+coordinates, and
+\livelink{chap:DWATdescription}{DW\-\_AT\-\_description}, among others.
+
+The debugging information entries are contained
+in the \addtoindex{.debug\_info} and
+\addtoindex{.debug\_types}
+sections of an object file.
+
+
+\section{Attribute Types}
+\label{chap:attributetypes}
+Each attribute value is characterized by an attribute name.
+\addtoindexx{attribute duplication}
+No more than one attribute with a given name may appear in any
+debugging information entry.
+There are no limitations on the
+\addtoindexx{attribute ordering}
+ordering of attributes within a debugging information entry.
+
+The attributes are listed in Table \refersec{tab:attributenames}.
+
+The permissible values
+\addtoindexx{attribute value classes}
+for an attribute belong to one or more classes of attribute
+value forms.
+Each form class may be represented in one or more ways.
+For example, some attribute values consist
+of a single piece of constant data.
+``Constant data''
+is the class of attribute value that those attributes may have.
+There are several representations of constant data,
+however (one, two, ,four, or eight bytes, and variable length
+data).
+The particular representation for any given instance
+of an attribute is encoded along with the attribute name as
+part of the information that guides the interpretation of a
+debugging information entry.
+
+Attribute value forms belong
+\addtoindexx{tag names!list of}
+to one of the classes shown in Figure \refersec{tab:classesofattributevalue}.
+
\setlength{\extrarowheight}{0.1cm}
+\addtoindexx{attributes!list of}
\begin{longtable}{l|p{9cm}}
- \caption{Attribute names} \\
- \hline \\ \bfseries Attribute&\bfseries Identifies or Specifies \\ \hline
+ \caption{Attribute names} \label{tab:attributenames} \\
+ \hline \bfseries Attribute&\bfseries Identifies or Specifies \\ \hline
\endfirsthead
\bfseries Attribute&\bfseries Identifies or Specifies \\ \hline
\endhead
\livetarg{chap:DWAThighpc}{DW\-\_AT\-\_high\-\_pc}
&\livelinki{chap:DWAThighpccontiguousrangeofcodeaddresses}{Contiguous range of code addresses}{contiguous range of code addresses} \\
\livetarg{chap:DWATidentifiercase}{DW\-\_AT\-\_identifier\-\_case}
-&\livelinki{chap:DWATidentifiercaseidentifiercaserule}{Identifier case rule}{identifier case rule} {identifier case rule}{identifier case rule}\\
+&\livelinki{chap:DWATidentifiercaseidentifiercaserule}{Identifier case rule}{identifier case rule} \\
\livetarg{chap:DWATimport}{DW\-\_AT\-\_import}
&\livelinki{chap:DWATimportimporteddeclaration}{Imported declaration}{imported declaration} \\
&\livelinki{chap:DWATimportimportedunit}{Imported unit}{imported unit} \\
(non\dash null) bytes. Data in this class are generally
printable strings. Strings may be represented directly in
the debugging information entry or as an offset in a separate
-string table.
+string table.
+
\end{tabular}
\caption{Classes of Attribute value}
\end{figure}
+
% It is difficult to get the above table to appear before
% the end of the chapter without a clearpage here.
\clearpage
top of the stack after ``executing'' the
\addtoindex{DWARF expression}
is
-\addtoindex{DWARF expression|see{location description}}
+\addtoindexx{DWARF expression|see{location description}}
taken to be the result (the address of the object, the
value of the array bound, the length of a dynamic string,
the desired value itself, and so on).
target machine before being pushed onto the expression stack.
\item \livetarg{chap:DWOPpushobjectaddress}{DW\-\_OP\-\_push\-\_object\-\_address}\\
-The \livelink{chap:DWOPpushobjectaddress}{DW\-\_OP\-\_push\-\_object\-\_address} operation pushes the address
+The \livelink{chap:DWOPpushobjectaddress}{DW\-\_OP\-\_push\-\_object\-\_address}
+operation pushes the address
of the object currently being evaluated as part of evaluation
of a user presented expression. This object may correspond
to an independent variable described by its own debugging
information entry or it may be a component of an array,
structure, or class whose address has been dynamically
determined by an earlier step during user expression
-evaluation. This operator provides explicit functionality
+evaluation.
+
+\textit{This operator provides explicit functionality
(especially for arrays involving descriptors) that is analogous
to the implicit push of the base
\addtoindexi{address}{address!implicit push of base}
of a structure prior
to evaluation of a \livelink{chap:DWATdatamemberlocation}{DW\-\_AT\-\_data\-\_member\-\_location} to access a
data member of a structure. For an example, see
-Appendix \refersec{app:aggregateexamples}.
+Appendix \refersec{app:aggregateexamples}.}
\item \livetarg{chap:DWOPformtlsaddress}{DW\-\_OP\-\_form\-\_tls\-\_address} \\
The \livelink{chap:DWOPformtlsaddress}{DW\-\_OP\-\_form\-\_tls\-\_address} operation pops a value from the
DWARF info, then it uses that shared library's
\addtoindexx{thread-local storage}
thread\dash local storage \nolink{block}.
-Some implementations of
+
+\textit{Some implementations of
\addtoindex{C} and \addtoindex{C++} support a
\_\_thread storage class. Variables with this storage class
have distinct values and addresses in distinct threads, much
compiler emits a function call to do it), and difficult
to describe using ordinary DWARF location descriptions.
\livelink{chap:DWOPformtlsaddress}{DW\-\_OP\-\_form\-\_tls\-\_address} leaves the computation to the
-consumer.
+consumer.}
\item \livetarg{chap:DWOPcallframecfa}{DW\-\_OP\-\_call\-\_frame\-\_cfa} \\
The \livelink{chap:DWOPcallframecfa}{DW\-\_OP\-\_call\-\_frame\-\_cfa} operation pushes the value of the
CFA, obtained from the Call Frame Information
(see Section \refersec{chap:callframeinformation}).
-Although the value of \livelink{chap:DWATframebase}{DW\-\_AT\-\_frame\-\_base}
+
+\textit{Although the value of \livelink{chap:DWATframebase}{DW\-\_AT\-\_frame\-\_base}
can be computed using other DWARF expression operators,
in some cases this would require an extensive location list
because the values of the registers used in computing the
CFA change during a subroutine. If the
Call Frame Information
is present, then it already encodes such changes, and it is
-space efficient to reference that.
+space efficient to reference that.}
\end{enumerate}
\subsubsection{Arithmetic and Logical Operations}
\item \livetarg{chap:DWOPplusuconst}{DW\-\_OP\-\_plus\-\_uconst} \\
The \livelink{chap:DWOPplusuconst}{DW\-\_OP\-\_plus\-\_uconst} operation pops the top stack entry,
adds it to the unsigned LEB128 constant operand and pushes
-the result. This operation is supplied specifically to be
+the result.
+
+\textit{This operation is supplied specifically to be
able to encode more field offsets in two bytes than can be
-done with “\livelink{chap:DWOPlit}{DW\-\_OP\-\_lit\textit{n}} \livelink{chap:DWOPplus}{DW\-\_OP\-\_plus}”.
+done with “\livelink{chap:DWOPlit}{DW\-\_OP\-\_lit\textit{n}} \livelink{chap:DWOPplus}{DW\-\_OP\-\_plus}”.}
\item \livetarg{chap:DWOPshl}{DW\-\_OP\-\_shl} \\
The \livelink{chap:DWOPshl}{DW\-\_OP\-\_shl} operation pops the top two stack entries,
contiguous piece or all of an object or value.
-\paragraph{Memory Location Descriptions}
+\subsubsubsection{Memory Location Descriptions}
A
\addtoindexx{location description!memory}
), whose value is the address of
a piece or all of an object or other entity in memory.
-\paragraph{Register Location Descriptions}
+\subsubsubsection{Register Location Descriptions}
A register location description consists of a register name
operation, which represents a piece or all of an object
“contents” of an otherwise anonymous location.
\end{myindentpara}
-\livelink{chap:DWOPlit1}{DW\-\_OP\-\_lit1} \livelink{chap:DWOPstackvalue}{DW\-\_OP\-\_stack\-\_value} \livelink{chap:DWOPpiece}{DW\-\_OP\-\_piece} a \\
+\livelink{chap:DWOPlit1}{DW\-\_OP\-\_lit1} \livelink{chap:DWOPstackvalue}{DW\-\_OP\-\_stack\-\_value} \livelink{chap:DWOPpiece}{DW\-\_OP\-\_piece} 4 \\
\livetarg{chap:DWOPbreg3}{DW\-\_OP\-\_breg3} 0 \livetarg{chap:DWOPbreg4}{DW\-\_OP\-\_breg4} 0 \livelink{chap:DWOPplus}{DW\-\_OP\-\_plus} \livelink{chap:DWOPstackvalue}{DW\-\_OP\-\_stack\-\_value} \livelink{chap:DWOPpiece}{DW\-\_OP\-\_piece} 4
\begin{myindentpara}{1cm}
The object value is found in an anonymous (virtual) location whose
A
\addtoindexx{location list!entry}
location list entry consists of:
-
\begin{enumerate}[1]
\item A beginning address offset.
This address offset has the \addtoindex{size of an address} and is
no such selection entry, then the applicable base address
defaults to the base address of the compilation unit (see
Section \refersec{chap:normalandpartialcompilationunitentries}).
-In the case of a compilation unit where all of
+
+\textit{In the case of a compilation unit where all of
the machine code is contained in a single contiguous section,
-no base address selection entry is needed.
+no base address selection entry is needed.}
Address ranges may overlap. When they do, they describe a
situation in which an object exists simultaneously in more than
A base
\addtoindexi{address}{address selection|see{base address selection}}
selection
-\addtoindexi{entry}{base address selection entry!in location list}:
+\addtoindexi{entry}{base address selection entry!in location list}
+consists of:
\begin{enumerate}[1]
\item The value of the largest representable
address offset (for example, 0xffffffff when the size of
and representation.}
-
-
-
-
\section{Types of Program Entities}
\label{chap:typesofprogramentities}
Any
the like, may have
\begin{itemize}
+\item A \livelink{chap:DWATlowpc}{DW\-\_AT\-\_low\-\_pc} attribute for
+a single address,
+
\item A \livelink{chap:DWATlowpc}{DW\-\_AT\-\_low\-\_pc} and
\livelink{chap:DWAThighpc}{DW\-\_AT\-\_high\-\_pc} pair of
attributes
When there is a single address associated with an entity,
such as a label or alternate entry point of a subprogram,
the entry has a \livelink{chap:DWATlowpc}{DW\-\_AT\-\_low\-\_pc} attribute whose value is the
-relocated address for the entity. While the \livelink{chap:DWATentrypc}{DW\-\_AT\-\_entry\-\_pc}
+relocated address for the entity.
+
+\textit{While the \livelink{chap:DWATentrypc}{DW\-\_AT\-\_entry\-\_pc}
attribute might also seem appropriate for this purpose,
historically the \livelink{chap:DWATlowpc}{DW\-\_AT\-\_low\-\_pc} attribute was used before the
\livelink{chap:DWATentrypc}{DW\-\_AT\-\_entry\-\_pc} was introduced
(in \addtoindex{DWARF Version 3}). There is
-insufficient reason to change this.
+insufficient reason to change this.}
\subsection{Continuous Address Range}
\label{chap:contiguousaddressranges}
associated with the entity; if it is of class constant, the
value is an unsigned integer offset which when added to the
low PC gives the address of the first location past the last
-instruction associated with the entity. The high PC value
-may be beyond the last valid instruction in the executable.
+instruction associated with the entity.
+
+\textit{The high PC value
+may be beyond the last valid instruction in the executable.}
+
The presence of low and high PC attributes for an entity
implies that the code generated for the entity is contiguous
and exists totally within the boundaries specified by those
Some attributes that apply to types specify a property (such
as the lower bound of an array) that is an integer value,
where the value may be known during compilation or may be
-computed dynamically during execution. The value of these
+computed dynamically during execution.
+
+The value of these
attributes is determined based on the class as follows:
\begin{itemize}
typically compilers, debuggers and other tools that need to
interpret a binary program in terms of its original source.
-\section{Overview}
+\section{Overview}
There are two major pieces to the description of the DWARF
format in this document. The first piece is the informational
\item Add additional support for template parameters in instantiations.
\item Add support for strongly typed enumerations in languages (such as C++) that have two
kinds of enumeration declarations.
+\end{itemize}
\addtoindex{DWARF Version 4} is compatible with
\addtoindex{DWARF Version 3} except as follows:
+\begin{itemize}
\item DWARF attributes that use any of the new forms of attribute value representation (for
section offsets, flag compression, type signature references, and so on) cannot be read by
\addtoindex{DWARF Version 3}
and interpretation of other data in the section.
\end{itemize}
-
-Contents needed.
\section{Changes from Version 2 to Version 3}
The following is a list of the major differences between
Version 2 and Version 3 of the DWARF Debugging Information
file section, \addtoindex{.debug\_info}.
\textit{
-A summary of the major changes
-made in
+A summary of the major changes made in
\addtoindex{DWARF Version 2}
-compared to the DWARF Version 1 may
-be found in the
+compared to the DWARF Version 1 may be found in the
\addtoindex{DWARF Version 2}
-document
+document.
}
Compilation unit entries may have the following
attributes:
-
\begin{enumerate}[1]
\item Either a \livelink{chap:DWATlowpc}{DW\-\_AT\-\_low\-\_pc} and
\livelink{chap:DWAThighpc}{DW\-\_AT\-\_high\-\_pc} pair of
contiguous or
non\dash contiguous address ranges, respectively,
of the machine instructions generated for the compilation
-unit (see Section {chap:codeaddressesandranges}).
+unit (see Section \refersec{chap:codeaddressesandranges}).
+
A \livelink{chap:DWATlowpc}{DW\-\_AT\-\_low\-\_pc} attribute
may also
be specified
\end{tabular}
\end{figure}
-\item A \livelink{chap:DWATstmtlist}{DW\-\_AT\-\_stmt\-\_list} attribute whose value is
+\item A \livelink{chap:DWATstmtlist}{DW\-\_AT\-\_stmt\-\_list}
+attribute whose value is
\addtoindexx{statement list attribute}
a
\addtoindexx{section offset!in statement list attribute}
section
\hypertarget{chap:DWATstmtlistlinenumberinformationforunit}
-offset
-to the line number information for this compilation
-unit. This information is placed in a separate object file
+offset to the line number information for this compilation
+unit.
+
+This information is placed in a separate object file
section from the debugging information entries themselves. The
value of the statement list attribute is the offset in the
\addtoindex{.debug\_line} section of the first byte of the line number
normal or partial compilation unit whose declarations logically
belong at the place of the imported unit entry.
-An imported unit entry does not necessarily correspond to
+\textit{An imported unit entry does not necessarily correspond to
any entity or construct in the source program. It is merely
“glue” used to relate a partial unit, or a compilation
unit used as a partial unit, to a place in some other
-compilation unit.
+compilation unit.}
\subsection{Separate Type Unit Entries}
\label{chap:separatetypeunitentries}
entries may be shared among the additional types and between
T and the additional types.
-Types are not required to be placed in type units. In general,
+\textit{Types are not required to be placed in type units. In general,
only large types such as structure, class, enumeration, and
union types included from header files should be considered
for separate type units. Base types and other small types
are not usually worth the overhead of placement in separate
type units. Types that are unlikely to be replicated, such
as those defined in the main source file, are also better
-left in the main compilation unit.
+left in the main compilation unit.}
\section{Module, Namespace and Importing Entries}
\textit{Modules and namespaces provide a means to collect related
may be represented by an imported declaration entry that refers
to the original debugging information entry. For example, given
}
+
\begin{lstlisting}
module A
integer X, Y, Z
end module
\end{lstlisting}
-the imported declaration entry for Q within module C refers
+\textit{the imported declaration entry for Q within module C refers
directly to the variable declaration entry for A in module A
because there is no explicit representation for X in module B.
+}
-A similar situation arises for a \addtoindex{C++} using declaration
+\textit{A similar situation arises for a \addtoindex{C++} using declaration
\addtoindexx{namespace (C++)!using declaration}
\addtoindexx{using declaration|see {namespace (C++), using declaration}}
that imports an entity in terms of a namespace alias. See
Appendix \refersec{app:namespaceexample}
for an example.
-
+}
\section{Subroutine and Entry Point Entries}
\label{chap:subroutineandentrypointentries}
an
\addtoindexx{thrown exception|see{thrown type entry}}
exception for one or more types, each such type is
-
represented by a debugging information entry with
\addtoindexx{thrown type entry}
the tag
\livelink{chap:DWATinline}{DW\-\_AT\-\_inline} attribute whose value is \livelink{chap:DWINLinlined}{DW\-\_INL\-\_inlined}.}
-\paragraph{Abstract Instances}
+\subsubsection{Abstract Instances}
\label{chap:abstractinstances}
Any debugging information entry that is owned (either
\hypertarget{chap:DWATinlineabstracttinstance}
member entries, and so on, all apply regardless of whether
or not a given entry is abstract.
-\paragraph{Concrete Inlined Instances}
+\subsubsection{Concrete Inlined Instances}
\label{chap:concreteinlinedinstances}
Each inline expansion of a subroutine is represented
declaration column attributes, respectively (see
Section \refersec{chap:declarationcoordinates}).
-The call file, call line and call column coordinates do not
+\textit{The call file, call line and call column coordinates do not
describe the coordinates of the subroutine declaration that
was inlined, rather they describe the coordinates of the call.
+}
An inlined subroutine entry
\hypertarget{chap:DWATconstexprcompiletimeconstantfunction}
\end{enumerate}
-\paragraph{Out-of-Line Instances of Inlined Subroutines}
+\subsubsection{Out-of-Line Instances of Inlined Subroutines}
\label{chap:outoflineinstancesofinlinedsubroutines}
Under some conditions, compilers may need to generate concrete
executable instances of inlined subroutines other than at
\end{enumerate}
-\paragraph{Nested Inlined Subroutines}
+\subsubsection{Nested Inlined Subroutines}
\label{nestedinlinedsubroutines}
Some languages and compilers may permit the logical nesting of
a subroutine within another subroutine, and may permit either
tag \livetarg{chap:DWTAGlexicalblock}{DW\-\_TAG\-\_lexical\-\_block}.
The lexical \livetargi{chap:lexicalblockentry}{block}{lexical block entry}
-entry
-may have
+entry may have
either a \livelink{chap:DWATlowpc}{DW\-\_AT\-\_low\-\_pc} and
\livelink{chap:DWAThighpc}{DW\-\_AT\-\_high\-\_pc} pair of
attributes
\section{Label Entries}
\label{chap:labelentries}
-
-A label is a way of identifying a source statement. A labeled
+\textit{A label is a way of identifying a source statement. A labeled
statement is usually the target of one or more ``go to''
statements.
+}
A label is represented by a debugging information entry with
\addtoindexx{label entry}
least one child entry, an
entry representing the type of exception accepted by
that catch \livelink{chap:catchblock}{block}.
-
This child entry has one of
\addtoindexx{formal parameter entry!in catch block}
the
DWARF Versions 3
\addtoindexx{DWARF Version 3}
and
-\addtoindexx{DWARF Version 4} and
-4, note that DWARF V4
+\addtoindexx{DWARF Version 4} and 4, note that DWARF V4
defines the following combinations of attributes:}
\begin{itemize}
\livelink{chap:DWATbitsize}{DW\-\_AT\-\_bit\-\_size}
and optionally \livelink{chap:DWATdatabitoffset}{DW\-\_AT\-\_data\-\_bit\-\_offset}}
\end{itemize}
-DWARF V3
+\textit{DWARF V3 defines the following combinations:}
\addtoindexx{DWARF Version 3}
-defines the following combinations:
% FIXME: the figure below interferes with the following
% bullet list, which looks horrible as a result.
\begin{itemize}
\addtoindexx{type modifier entry}
A base or user\dash defined type may be modified in different ways
+in different languages. A type modifier is represented in
+DWARF by a debugging information entry with one of the tags
+given in Figure \refersec{fig:typemodifiertags}.
\addtoindexx{type modifier|see{constant type entry}}
\addtoindexx{type modifier|see{reference type entry}}
\addtoindexx{type modifier|see{restricted type entry}}
\addtoindexx{type modifier|see{pointer type entry}}
\addtoindexx{type modifier|see{shared type entry}}
\addtoindexx{type modifier|see{volatile type entry}}
-in different languages.
-A type modifier is represented in
-DWARF by a debugging information entry with one of the tags
-given in
-Figure \refersec{fig:typemodifiertags}.
If a name has been given to the modified type in the source
program, then the corresponding modified type entry has
the type being modified \addtoindexx{pointer qualified type entry} \\
\livetarg{chap:DWTAGreferencetype}{DW\-\_TAG\-\_reference\-\_type}& C++ (lvalue) reference
to an object of the type
-\addtoindexx{reference type entry} \\
-being modified
+\addtoindexx{reference type entry}
+being modified
\addtoindexx{reference qualified type entry} \\
\livetarg{chap:DWTAGrestricttype}{DW\-\_TAG\-\_restrict\-\_type}& \addtoindex{C}
restrict
-\addtoindexx{restricted type entry} \\
+\addtoindexx{restricted type entry}
qualified type
\addtoindexx{restrict qualified type} \\
\livetarg{chap:DWTAGrvaluereferencetype}{DW\-\_TAG\-\_rvalue\-\_reference\-\_type} & C++
\section{Array Type Entries}
\label{chap:arraytypeentries}
-Many languages share the concept of an ``array,'' which is
+\textit{Many languages share the concept of an ``array,'' which is
\addtoindexx{array type entry}
-a table of components of identical type.
+a table of components of identical type.}
An array type is represented by a debugging information entry
with the tag \livetarg{chap:DWTAGarraytype}{DW\-\_TAG\-\_array\-\_type}.
-If a name has been
-given to
+If a name has been given to
\addtoindexx{array!declaration of type}
the array type in the source program, then the corresponding
array type entry has a \livelink{chap:DWATname}{DW\-\_AT\-\_name} attribute
the dimensions in the source program (i.e., leftmost dimension
first, next to leftmost second, and so on).
-In languages, such as C, in which there is no concept of
+\textit{In languages, such as C, in which there is no concept of
a “multidimensional array”, an array of arrays may
be represented by a debugging information entry for a
-multidimensional array.
+multidimensional array.}
Other attributes especially applicable to arrays are
\livelink{chap:DWATallocated}{DW\-\_AT\-\_allocated},
(see Section \refersec{chap:byteandbitsizes}),
whose value is the amount of storage needed
to hold an instance of the structure, union or class type,
-including any padding.
+including any padding.
+
An incomplete structure, union or class type
\addtoindexx{incomplete structure/union/class}
is
\section{Subroutine Type Entries}
\label{chap:subroutinetypeentries}
-It is possible in \addtoindex{C}
+\textit{It is possible in \addtoindex{C}
to declare pointers to subroutines
that return a value of a specific type. In both
\addtoindex{C} and \addtoindex{C++},
only return a value of a specific type, but accept only
arguments of specific types. The type of such pointers would
be described with a ``pointer to'' modifier applied to a
-user\dash defined type.
+user\dash defined type.}
A subroutine type is represented by a debugging information
entry with the
order that the corresponding argument types appear in the
source program.
-In \addtoindex{C} there
+\textit{In \addtoindex{C} there
is a difference between the types of functions
declared using function prototype style declarations and
-those declared using non\dash prototype declarations.
+those declared using non\dash prototype declarations.}
A
\hypertarget{chap:DWATprototypedsubroutineprototype}
\section{String Type Entries}
\label{chap:stringtypeentries}
-
-A ``string'' is a sequence of characters that have specific
+\textit{A ``string'' is a sequence of characters that have specific
\addtoindexx{string type entry}
semantics and operations that separate them from arrays of
characters.
\addtoindex{Fortran} is one of the languages that has a string
type. Note that ``string'' in this context refers to a target
machine concept, not the class string as used in this document
-(except for the name attribute).
+(except for the name attribute).}
A string type is represented by a debugging information entry
with the tag \livetarg{chap:DWTAGstringtype}{DW\-\_TAG\-\_string\-\_type}.
integer value of the attribute (see below) indicates whether
an object of the type is currently associated or not.
-While these attributes are defined specifically with
+\textit{While these attributes are defined specifically with
\addtoindex{Fortran 90} ALLOCATABLE and POINTER types
in mind, usage is not limited
-to just that language.
+to just that language.}
The value of these attributes is determined as described in
Section \refersec{chap:staticanddynamicvaluesofattributes}.