User Tools

Site Tools


info:c_memory_structure

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revisionBoth sides next revision
info:c_memory_structure [2012/10/15 20:10] – [Obtaining the debug section data] moritzinfo:c_memory_structure [2012/10/16 17:21] – [Obtaining the debug section data] moritz
Line 99: Line 99:
 Here is the output on my machine: Here is the output on my machine:
  
-<code> +<code>struct:     file format elf64-x86-64
- +
-struct:     file format elf64-x86-64+
  
 Contents of the .debug_info section: Contents of the .debug_info section:
Line 244: Line 242:
 This is a lot of output. Let's explain the different parts. This is a lot of output. Let's explain the different parts.
  
-Each line represents either the start of a new entity or adds an attribute to one. All entities and attributes have a unique address, encoded in hex. Each entity has a type, which determines the attributes it has.+Each line represents either the start of a new entity or adds an attribute to one. All entities and attributes have a unique address, encoded in hex. Each entity has a type, which determines the attributes it has. The entity line consists of a nesting level, the unique address followed by the entity's type ID and a human readable name of the type. Attribute definitions start with the unique ID followed by the attribute name to be defined and a colon. After the colon, the actual value of the attribute follows. It can be a number, a string or a pointer to another entity. The pointer is encoded as ''<0x34>'' which references the entity with unique ID ''34''. This way, the debug info tree can be traversed. 
 + 
 +=== Finding the size information === 
  
 Fist, it tells us what format the file has. In this case it is a ''elf64-x86-64''. We know that pointers are 64 bits ling on this platform. Fist, it tells us what format the file has. In this case it is a ''elf64-x86-64''. We know that pointers are 64 bits ling on this platform.
info/c_memory_structure.txt · Last modified: 2012/10/16 17:23 by moritz

Donate Powered by PHP Valid HTML5 Valid CSS Driven by DokuWiki