]> git.ipfire.org Git - thirdparty/elfutils.git/commitdiff
dwarflint: Add a description to check_debug_info
authorPetr Machata <pmachata@redhat.com>
Thu, 2 Sep 2010 21:58:49 +0000 (23:58 +0200)
committerPetr Machata <pmachata@redhat.com>
Thu, 2 Sep 2010 21:58:49 +0000 (23:58 +0200)
dwarflint/check_debug_info.cc
dwarflint/check_debug_line.cc
dwarflint/check_debug_pub.cc

index a5a0fa056b34813ad3d326c2e85d73bf885afe60..2d510d718770cb8189deb78d1b9e064c7dfd5293 100644 (file)
@@ -62,7 +62,37 @@ check_debug_info::descriptor ()
      .prereq<typeof (*_m_sec_str)> ()
      .prereq<typeof (*_m_abbrevs)> ()
      .prereq<typeof (*_m_cu_headers)> ()
-     );
+     .description (
+
+"Checks for low-level structure of .debug_info.  In addition it\n"
+"checks:\n"
+" - for dangling reference to .debug_abbrev section\n"
+" - that reported CU address sizes are consistent\n"
+" - that rangeptr values are aligned to CU address size\n"
+" - it is checked that DW_AT_low_pc and DW_AT_high_pc are relocated\n"
+"   consistently\n"
+" - that DIE references are well formed (both intra-CU and inter-CU)\n"
+"   and that local reference isn't needlessly formed as global\n"
+" - that .debug_string references are well formed and referred strings\n"
+"   are properly NUL-terminated\n"
+" - that referenced abbreviations actually exist\n"
+" - that DIEs with children have the DW_AT_sibling attribute and that\n"
+"   the sibling actually is at the address reported at that attribute\n"
+" - that the DIE chain is terminated\n"
+" - that the last sibling in chain has no DW_AT_sibling attribute\n"
+" - that the DIE with children actually has children (i.e. that the\n"
+"   chain is not empty)\n"
+" - for format constraints (such as that there are no 64-bit CUs inside\n"
+"   DWARF 2 file)\n"
+" - in 32-bit CUs, that location attributes are not formed with\n"
+"   DW_FORM_data8\n"
+" - all the attribute checks done by check_debug_abbrev are done here\n"
+"   for attributes with DW_FORM_indirect.  Indirect form is forbidden\n"
+"   to be again indirect\n"
+" - that all abbreviations are used\n"
+" - that relocations are valid.  In ET_REL files that certain fields\n"
+"   are relocated\n"
+                  ));
   return cd;
 }
 
index aa72834c5611a2d3c257cbfe5539fe6c20fdb655..92d5a427f7ba07a3a06082c6a05661ecfbb6c23b 100644 (file)
@@ -63,6 +63,8 @@ namespace
         .groups ("@low")
         .prereq<typeof (*_m_sec)> ()
         .description (
+"Checks for low-level structure of .debug_line.  In addition it\n"
+"checks:\n"
 " - for normalized values of certain attributes (such as that\n"
 "   default_is_stmt is 0 or 1, even though technically any non-zero\n"
 "   value is allowed).\n"
@@ -79,7 +81,7 @@ namespace
 "   other instruction\n"
 " - that relocations are valid.  In ET_REL files that certain fields\n"
 "   are relocated\n"
-"Furthermore, if .debug_info is valid, it checks:\n"
+"Furthermore, if .debug_info is valid, it is checked:\n"
 " - that each line table is used by some CU\n"
 " - that the line table references at CUs point to actual line tables\n"
 "TODOs:\n"
index 6dfa0b9dbf53ecbf64027f19a263a7e25fd70245..677eedee16cfa47aae8736ede5b6f9f806fb0a77 100644 (file)
@@ -70,7 +70,7 @@ namespace
 " - for garbage inside padding\n"
 " - that relocations are valid.  In ET_REL files that certain fields\n"
 "   are relocated\n"
-"Furthermore, if .debug_info is valid, it checks:\n"
+"Furthermore, if .debug_info is valid, it is checked:\n"
 " - that references point to actual CUs and DIEs\n"
 " - that there's only one pub section per CU\n"));
       return cd;