[PATCH] D65661: [compiler-rt] Move FDP to include/fuzzer/FuzzedDataProvider.h for easier use.
Max Moroz via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Aug 2 09:04:49 PDT 2019
Dor1s added a comment.
> the terminology here means those are 2 separate inputs, right?
Yes! Can you think of a better name for that? I thought "argument" or "parameter" could work, but what if those values are used somehow else (e.g. a number of iterations) and not passed to any function explicitly, then they are not technically arguments or parameters :/ "input" sounds pretty abstract to me, but any better suggestions are totally welcome.
> And while span would act like a light-weight view with no extra allocations,
> this would allocate a *separate* buffer for each of these "inputs"?
I don't see a sane way to use `span` in your example. Most likely it'll end up with two integer variable on stack, which is what FDP would do as well.
But if you interpret the buffer like `int32_t*[2]` and pass the address to the target API, you may miss some bugs because of the way how instrumentation works. We had cases like this, when e.g. off-by-one bugs were not detected. Educating every fuzzer developer on that matter doesn't scale. Providing an API that solves the problem does :)
Repository:
rCRT Compiler Runtime
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D65661/new/
https://reviews.llvm.org/D65661
More information about the llvm-commits
mailing list