[PATCH] D147652: [symbolizer] Check existence of input file in GNU mode
Fangrui Song via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Jun 21 22:47:10 PDT 2023
MaskRay accepted this revision.
MaskRay added a comment.
There is a time-of-check-to-time-of-use issue that we can ignore (as we may wait on the addresses), but otherwise the new behavior (also GNU's) seems to be what a casual user may expect.
================
Comment at: llvm/include/llvm/DebugInfo/Symbolize/Symbolize.h:193
+ /// Splits binary file name into file and architecture parts. For example,
+ /// the name 'macho-universal:i386', will be split into 'macho-universal' and
----------------
================
Comment at: llvm/lib/DebugInfo/Symbolize/Symbolize.cpp:719
+ std::error_code EC = sys::fs::status(BinaryName, Stat);
+ if (!EC) {
+ if (sys::fs::is_directory(Stat))
----------------
fold the two `if` into one with `&&`
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D147652/new/
https://reviews.llvm.org/D147652
More information about the llvm-commits
mailing list