[PATCH] D153219: [symbolizer] Exit early if input file is absent

Serge Pavlov via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Sun Jun 18 00:21:20 PDT 2023


sepavloff created this revision.
sepavloff added reviewers: jhenderson, mgorny, MaskRay, dblaikie.
Herald added a project: All.
sepavloff requested review of this revision.
Herald added a project: LLVM.

If binary file specified as input with option --obj or -e was absent,
llvm-symbolizer still tried to process addresses from input stream or
command line. GNU addr2line in this case exits immediately, as no useful
work can be made. llvm-addr2line now behaves similarly. This change
implements the same behavior in llvm-symbolizer as well.

Depends on D147652 <https://reviews.llvm.org/D147652>


Repository:
  rG LLVM Github Monorepo

https://reviews.llvm.org/D153219

Files:
  llvm/test/DebugInfo/symbolize-missing-file.test
  llvm/test/tools/llvm-symbolizer/errors.test
  llvm/test/tools/llvm-symbolizer/invalid-input-address.test
  llvm/test/tools/llvm-symbolizer/output-style-inlined.test
  llvm/test/tools/llvm-symbolizer/output-style-json-code.test
  llvm/test/tools/llvm-symbolizer/sym.test
  llvm/tools/llvm-symbolizer/llvm-symbolizer.cpp

-------------- next part --------------
A non-text attachment was scrubbed...
Name: D153219.532450.patch
Type: text/x-patch
Size: 6417 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20230618/85d581bc/attachment.bin>


More information about the llvm-commits mailing list