[PATCH] D25245: Add quotes for values in the diagnostic remark YAML outputs where necessary

Hal Finkel via llvm-commits llvm-commits at lists.llvm.org
Tue Oct 4 10:10:39 PDT 2016


hfinkel created this revision.
hfinkel added a reviewer: anemet.
hfinkel added a subscriber: llvm-commits.
Herald added a subscriber: mcrosier.

Some of the strings used for the YAML diagnostic remark outputs can be parsed as raw string values in YAML, but many cannot (i.e. anything that has a ':' character, as many of the vectorizer outputs do). Quoting these strings is necessary: otherwise they won't parse correctly. We don't want everything to be a quoted string: numbers should be numbers, etc. but we do need to quote where necessary. This has the side effect of preserving leading/trailing spaces in the output strings, which I think also makes sense.


https://reviews.llvm.org/D25245

Files:
  include/llvm/ADT/StringExtras.h
  lib/Analysis/OptimizationDiagnosticInfo.cpp
  lib/IR/AsmWriter.cpp
  test/Transforms/Inline/optimization-remarks-passed-yaml.ll
  test/Transforms/Inline/optimization-remarks-yaml.ll
  test/Transforms/LoopVectorize/optimization-remarks-yaml.ll

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D25245.73502.patch
Type: text/x-patch
Size: 9344 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20161004/8f35344d/attachment.bin>


More information about the llvm-commits mailing list