[libunwind] r275997 - libunwind: sync some coments with NetBSD's version

Ed Maste via cfe-commits cfe-commits at lists.llvm.org
Tue Jul 19 10:28:42 PDT 2016


Author: emaste
Date: Tue Jul 19 12:28:38 2016
New Revision: 275997

URL: http://llvm.org/viewvc/llvm-project?rev=275997&view=rev
Log:
libunwind: sync some coments with NetBSD's version

NetBSD's system unwinder is a modified version of LLVM's libunwind.
Slightly reduce diffs by updating comments to match theirs where
appropriate.

Modified:
    libunwind/trunk/src/DwarfParser.hpp

Modified: libunwind/trunk/src/DwarfParser.hpp
URL: http://llvm.org/viewvc/llvm-project/libunwind/trunk/src/DwarfParser.hpp?rev=275997&r1=275996&r2=275997&view=diff
==============================================================================
--- libunwind/trunk/src/DwarfParser.hpp (original)
+++ libunwind/trunk/src/DwarfParser.hpp Tue Jul 19 12:28:38 2016
@@ -138,23 +138,23 @@ const char *CFI_Parser<A>::decodeFDE(A &
   if (err != NULL)
     return err;
   p += 4;
-  // parse pc begin and range
+  // Parse pc begin and range.
   pint_t pcStart =
       addressSpace.getEncodedP(p, nextCFI, cieInfo->pointerEncoding);
   pint_t pcRange =
       addressSpace.getEncodedP(p, nextCFI, cieInfo->pointerEncoding & 0x0F);
-  // parse rest of info
+  // Parse rest of info.
   fdeInfo->lsda = 0;
-  // check for augmentation length
+  // Check for augmentation length.
   if (cieInfo->fdesHaveAugmentationData) {
     pint_t augLen = (pint_t)addressSpace.getULEB128(p, nextCFI);
     pint_t endOfAug = p + augLen;
     if (cieInfo->lsdaEncoding != DW_EH_PE_omit) {
-      // peek at value (without indirection).  Zero means no lsda
+      // Peek at value (without indirection).  Zero means no LSDA.
       pint_t lsdaStart = p;
       if (addressSpace.getEncodedP(p, nextCFI, cieInfo->lsdaEncoding & 0x0F) !=
           0) {
-        // reset pointer and re-parse lsda address
+        // Reset pointer and re-parse LSDA address.
         p = lsdaStart;
         fdeInfo->lsda =
             addressSpace.getEncodedP(p, nextCFI, cieInfo->lsdaEncoding);
@@ -192,23 +192,23 @@ bool CFI_Parser<A>::findFDE(A &addressSp
       return false; // end marker
     uint32_t id = addressSpace.get32(p);
     if (id == 0) {
-      // skip over CIEs
+      // Skip over CIEs.
       p += cfiLength;
     } else {
-      // process FDE to see if it covers pc
+      // Process FDE to see if it covers pc.
       pint_t nextCFI = p + cfiLength;
       uint32_t ciePointer = addressSpace.get32(p);
       pint_t cieStart = p - ciePointer;
-      // validate pointer to CIE is within section
+      // Validate pointer to CIE is within section.
       if ((ehSectionStart <= cieStart) && (cieStart < ehSectionEnd)) {
         if (parseCIE(addressSpace, cieStart, cieInfo) == NULL) {
           p += 4;
-          // parse pc begin and range
+          // Parse pc begin and range.
           pint_t pcStart =
               addressSpace.getEncodedP(p, nextCFI, cieInfo->pointerEncoding);
           pint_t pcRange = addressSpace.getEncodedP(
               p, nextCFI, cieInfo->pointerEncoding & 0x0F);
-          // test if pc is within the function this FDE covers
+          // Test if pc is within the function this FDE covers.
           if ((pcStart < pc) && (pc <= pcStart + pcRange)) {
             // parse rest of info
             fdeInfo->lsda = 0;
@@ -217,11 +217,11 @@ bool CFI_Parser<A>::findFDE(A &addressSp
               pint_t augLen = (pint_t)addressSpace.getULEB128(p, nextCFI);
               pint_t endOfAug = p + augLen;
               if (cieInfo->lsdaEncoding != DW_EH_PE_omit) {
-                // peek at value (without indirection).  Zero means no lsda
+                // Peek at value (without indirection).  Zero means no LSDA.
                 pint_t lsdaStart = p;
                 if (addressSpace.getEncodedP(
                         p, nextCFI, cieInfo->lsdaEncoding & 0x0F) != 0) {
-                  // reset pointer and re-parse lsda address
+                  // Reset pointer and re-parse LSDA address.
                   p = lsdaStart;
                   fdeInfo->lsda = addressSpace
                       .getEncodedP(p, nextCFI, cieInfo->lsdaEncoding);
@@ -239,7 +239,7 @@ bool CFI_Parser<A>::findFDE(A &addressSp
             // pc is not in begin/range, skip this FDE
           }
         } else {
-          // malformed CIE, now augmentation describing pc range encoding
+          // Malformed CIE, now augmentation describing pc range encoding.
         }
       } else {
         // malformed FDE.  CIE is bad




More information about the cfe-commits mailing list