From da647f579aa60ad6409021c4786f5878ff0bee1d Mon Sep 17 00:00:00 2001 From: Adrien Leravat Date: Thu, 15 Jun 2023 09:18:16 -0700 Subject: [PATCH] Explorer: readme: clarify fuzzer debugging (#2905) Slightly clarify the debugging process in case of fuzzer crash with Explorer. --- explorer/fuzzing/README.md | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/explorer/fuzzing/README.md b/explorer/fuzzing/README.md index 80168dc5119c..cc6dd5032622 100644 --- a/explorer/fuzzing/README.md +++ b/explorer/fuzzing/README.md @@ -83,11 +83,13 @@ bazel-bin/explorer/fuzzing/explorer_fuzzer.full_corpus ## Investigating a crash -Typically it's going to be easiest to run explorer on directly. You can do this -with: +Typically it's going to be easiest to run explorer on the problematic carbon +program directly. You can do this with: -````bash -# Convert the crash to a source file. +```bash +# Convert a specific fuzzer test to a source file +bazel run //common/fuzzing:proto_to_carbon -- explorer/fuzzing/fuzzer_corpus/abcd1234 > crash.carbon +# Or convert the crash to a source file. bazel run //common/fuzzing:proto_to_carbon -- /tmp/crash.textproto > crash.carbon # Run explorer on the crash. @@ -98,7 +100,7 @@ It's also possible to run the fuzzer on a single input: ```bash bazel-bin/explorer/fuzzing/explorer_fuzzer.full_corpus /tmp/crash.textproto -```` +``` ## Generating new fuzzer corpus entries