Skip to content

[doc] Add --verify-json to dwarfdump documentation #110909

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged

Conversation

bd1976bris
Copy link
Collaborator

This adds documentation for --verify-json, see: #81762.

Note: GitHub won't seem to allow me add the original author @kevinfrei as a reviewer for some reason.

@llvmbot
Copy link
Member

llvmbot commented Oct 2, 2024

@llvm/pr-subscribers-llvm-binary-utilities

Author: bd1976bris (bd1976bris)

Changes

This adds documentation for --verify-json, see: #81762.

Note: GitHub won't seem to allow me add the original author @kevinfrei as a reviewer for some reason.


Full diff: https://github.com/llvm/llvm-project/pull/110909.diff

1 Files Affected:

  • (modified) llvm/docs/CommandGuide/llvm-dwarfdump.rst (+28)
diff --git a/llvm/docs/CommandGuide/llvm-dwarfdump.rst b/llvm/docs/CommandGuide/llvm-dwarfdump.rst
index 8adccf1c0c0a31..e72bb66d0bf8ad 100644
--- a/llvm/docs/CommandGuide/llvm-dwarfdump.rst
+++ b/llvm/docs/CommandGuide/llvm-dwarfdump.rst
@@ -150,6 +150,12 @@ OPTIONS
             compile unit chains, DIE relationships graph, address
             ranges, and more.
 
+.. option:: --verify-json=<path>
+
+            Output JSON-formatted error summary to the a file specfied by
+            <path>. Implies :option:`--verify`.  The output format is described
+            in the section below (:ref:`verify-json-format`).
+
 .. option:: --version
 
             Display the version of the tool.
@@ -196,6 +202,28 @@ For aggregated values, the following keys are used:
       - `#variables - entry values ...` ==> the number of variables excluding
         the entry values etc.
 
+.. _verify-json-format:
+
+FORMAT OF VERIFY JSON OUTPUT
+----------------------------
+
+The format of the JSON output created by the :option:`--verify-json=<path>` is::
+
+  { 
+    "error-categories": { 
+      "<first category description>": {"count": 1234},
+      "<next category description>": {"count": 4321}
+    },
+    "error-count": 5555
+  }
+
+The following is generated if there are no errors reported::
+
+  { 
+    "error-categories": {},
+    "error-count": 0
+  }
+
 EXIT STATUS
 -----------
 

@kevinfrei
Copy link
Contributor

Not sure what's up with the test doc build, but the change looks good, from a "Yes, you're describing the option accurately" perspective. @clayborg or @dwblaikie can probably approve the diff.

@bd1976bris
Copy link
Collaborator Author

Not sure what's up with the test doc build

I was referencing the option incorrectly. Fixed now.

@bd1976bris bd1976bris merged commit fcdb178 into llvm:main Oct 4, 2024
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants