From f5af6ada3b0570db1afc19029cad8fb8320676ef Mon Sep 17 00:00:00 2001 From: NAKAMURA Takumi Date: Sat, 23 Apr 2011 00:30:22 +0000 Subject: docs: Introduce cascading style
and

continued on .

Section Example

Section preamble.

Subsection Example

Subsection body

FIXME: Care H5 better. git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@130040 91177308-0d34-0410-b5e6-96231b3b80d8 --- docs/SourceLevelDebugging.html | 104 ++++++++++++++++++++--------------------- 1 file changed, 52 insertions(+), 52 deletions(-) (limited to 'docs/SourceLevelDebugging.html') diff --git a/docs/SourceLevelDebugging.html b/docs/SourceLevelDebugging.html index e4566179ea..c9ae0202de 100644 --- a/docs/SourceLevelDebugging.html +++ b/docs/SourceLevelDebugging.html @@ -71,7 +71,7 @@ height="369">

Introduction

-
+

This document is the central repository for all information pertaining to debug information in LLVM. It describes the actual format @@ -80,14 +80,12 @@ height="369"> Further, this document provides specific examples of what debug information for C/C++ looks like.

-
-

Philosophy behind LLVM debugging information

-
+

The idea of the LLVM debugging information is to capture how the important pieces of the source-language's Abstract Syntax Tree map onto LLVM code. @@ -137,7 +135,7 @@ height="369"> Debug information consumers -

+

The role of debug information is to provide meta information normally stripped away during the compilation process. This meta information provides @@ -161,7 +159,7 @@ height="369"> Debugging optimized code -

+

An extremely high priority of LLVM debugging information is to make it interact well with optimizations and analysis. In particular, the LLVM debug @@ -226,13 +224,15 @@ height="369">

+
+

Debugging information format

-
+

LLVM debugging information has been carefully designed to make it possible for the optimizer to optimize the program and debugging information without @@ -265,14 +265,12 @@ height="369"> common to any source-language. The next section describes the data layout conventions used by the C and C++ front-ends.

-
-

Debug information descriptors

-
+

In consideration of the complexity and volume of debug information, LLVM provides a specification for well formed debug descriptors.

@@ -312,14 +310,12 @@ height="369">

The details of the various descriptors follow.

-
-

Compile unit descriptors

-
+
@@ -355,7 +351,7 @@ height="369">
   File descriptors
 
 
-
+
@@ -384,7 +380,7 @@ height="369">
   Global variable descriptors
 
 
-
+
@@ -417,7 +413,7 @@ global variables are collected by named metadata !llvm.dbg.gv.

Subprogram descriptors -
+
@@ -461,7 +457,7 @@ global variables are collected by named metadata !llvm.dbg.gv.

Block descriptors -
+
@@ -487,7 +483,7 @@ global variables are collected by named metadata !llvm.dbg.gv.

Basic type descriptors -
+
@@ -539,7 +535,7 @@ DW_ATE_unsigned_char = 8
   Derived type descriptors
 
 
-
+
@@ -611,7 +607,7 @@ DW_TAG_restrict_type    = 55
   Composite type descriptors
 
 
-
+
@@ -698,7 +694,7 @@ DW_TAG_inheritance      = 28
   Subrange descriptors
 
 
-
+
@@ -724,7 +720,7 @@ DW_TAG_inheritance      = 28
   Enumerator descriptors
 
 
-
+
@@ -748,7 +744,7 @@ DW_TAG_inheritance      = 28
   Local variables
 
 
-
+
@@ -787,24 +783,24 @@ DW_TAG_return_variable = 258
 
 
+
+

Debugger intrinsic functions

-
+

LLVM uses several intrinsic functions (name prefixed with "llvm.dbg") to provide debug information at various points in generated code.

-
-

llvm.dbg.declare

-
+
   void %llvm.dbg.declare(metadata, metadata)
 
@@ -819,7 +815,7 @@ DW_TAG_return_variable = 258 llvm.dbg.value -
+
   void %llvm.dbg.value(metadata, i64, metadata)
 
@@ -831,12 +827,14 @@ DW_TAG_return_variable = 258 user source variable.

+
+

Object lifetimes and scoping

-
+

In many languages, the local variables in functions can have their lifetimes or scopes limited to a subset of a function. In the C family of languages, for example, variables are only live (readable and writable) within the @@ -994,13 +992,15 @@ call void @llvm.dbg.declare(metadata, metadata !12), !dbg !14

+
+

C/C++ front-end specific debug information

-
+

The C and C++ front-ends represent information about the program in a format that is effectively identical @@ -1021,14 +1021,12 @@ call void @llvm.dbg.declare(metadata, metadata !12), !dbg !14

The following sections provide examples of various C/C++ constructs and the debug information that would best describe those constructs.

-
-

C/C++ source file information

-
+

Given the source files MySource.cpp and MyHeader.h located in the directory /Users/mine/sources, the following code:

@@ -1106,7 +1104,7 @@ using Instruction::getMetadata() and C/C++ global variable information -
+

Given an integer global variable declared as follows:

@@ -1176,7 +1174,7 @@ int MyGlobal = 100; C/C++ function information -
+

Given a function declared as follows:

@@ -1233,18 +1231,16 @@ define i32 @main(i32 %argc, i8** %argv) { C/C++ basic types -
+

The following are the basic type descriptors for C/C++ core types:

-
-

bool

-
+
@@ -1270,7 +1266,7 @@ define i32 @main(i32 %argc, i8** %argv) {
   char
 
 
-
+
@@ -1296,7 +1292,7 @@ define i32 @main(i32 %argc, i8** %argv) {
   unsigned char
 
 
-
+
@@ -1322,7 +1318,7 @@ define i32 @main(i32 %argc, i8** %argv) {
   short
 
 
-
+
@@ -1348,7 +1344,7 @@ define i32 @main(i32 %argc, i8** %argv) {
   unsigned short
 
 
-
+
@@ -1374,7 +1370,7 @@ define i32 @main(i32 %argc, i8** %argv) {
   int
 
 
-
+
@@ -1399,7 +1395,7 @@ define i32 @main(i32 %argc, i8** %argv) {
   unsigned int
 
 
-
+
@@ -1425,7 +1421,7 @@ define i32 @main(i32 %argc, i8** %argv) {
   long long
 
 
-
+
@@ -1451,7 +1447,7 @@ define i32 @main(i32 %argc, i8** %argv) {
   unsigned long long
 
 
-
+
@@ -1477,7 +1473,7 @@ define i32 @main(i32 %argc, i8** %argv) {
   float
 
 
-
+
@@ -1503,7 +1499,7 @@ define i32 @main(i32 %argc, i8** %argv) {
   double
 
 
-
+
@@ -1524,12 +1520,14 @@ define i32 @main(i32 %argc, i8** %argv) {
 
 
+
+

C/C++ derived types

-
+

Given the following as an example of C/C++ derived type:

@@ -1614,7 +1612,7 @@ typedef const int *IntPtr; C/C++ struct/union types -
+

Given the following as an example of C/C++ struct type:

@@ -1727,7 +1725,7 @@ struct Color { C/C++ enumeration types -
+

Given the following as an example of C/C++ enumeration type:

@@ -1788,6 +1786,8 @@ enum Trees {
+
+
-- cgit v1.2.3