[PATCH] D138334: Improve llvm-symbolizer search logic for symlink
Alexandre Ganea via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Nov 22 06:44:00 PST 2022
aganea added a comment.
Changes look good, thanks.
In D138334#3942354 <https://reviews.llvm.org/D138334#3942354>, @dblaikie wrote:
> In D138334#3942293 <https://reviews.llvm.org/D138334#3942293>, @yinghuitan wrote:
>
>> @dblaikie, I did not find any existing test for it. Do you have any suggestion/example how to test this? We need to introduce a crash using this API and get the output and check the symbolication.
>
> Yeah, not sure - I'd try replacing all this code with an `assert(false)` and running lldb's tests to see if anything fails - if not, might be we just assume it's too hard to test/not easy to introduce an intentional crash, or test the crash recovery in isolation - which is unfortunate, but wouldn't be totally surprising.
@yinghuitan I think you can take your inspiration from `llvm/unittests/Support/CrashRecoveryTest.cpp`, L155, `TEST(CrashRecoveryTest, UnixCRCReturnCode)` and one of the tests in `llvm/unittests/Support/Path.cpp`. The test would have to be Unix-only, there's no reliable/safe way to test symlinks on Windows.
Repository:
rG LLVM Github Monorepo
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D138334/new/
https://reviews.llvm.org/D138334
More information about the llvm-commits
mailing list