[PATCH] D115616: [Debugify][OriginalDIMode] Make HTML reporting infrastructure more resilient

Nikola Tesic via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Mon Dec 13 02:46:26 PST 2021


ntesic created this revision.
ntesic added reviewers: Orlando, StephenTozer, djtodoro.
ntesic added a project: debug-info.
Herald added a subscriber: hiraditya.
ntesic requested review of this revision.
Herald added a project: LLVM.
Herald added a subscriber: llvm-commits.

Debugify in OriginalDebugInfo mode (verify-each-debuginfo-preserve), when used in
parallel builds of large projects, can produce incorrect report.
More precisely, simultaneous writes to JSON report file, 
could form incorrect JSON objects, which describe found Debug Info bugs.

This patch uses the lock/unlock mechanism to protect JSON report file and also
makes script llvm/utils/llvm-original-di-preservation.py resilient to corrupted 
lines in the report file. So, it ensures the creation of HTML report.


https://reviews.llvm.org/D115616

Files:
  llvm/lib/Transforms/Utils/Debugify.cpp
  llvm/test/tools/llvm-original-di-preservation/Inputs/corrupted.json
  llvm/test/tools/llvm-original-di-preservation/Inputs/expected-skipped.html
  llvm/test/tools/llvm-original-di-preservation/basic.test
  llvm/utils/llvm-original-di-preservation.py

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D115616.393818.patch
Type: text/x-patch
Size: 11951 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20211213/6355989d/attachment.bin>


More information about the llvm-commits mailing list