21 const uint8_t *Data2,
size_t Size2,
22 uint8_t *Out,
size_t MaxOutSize) {
24 MaxOutSize = Rand(MaxOutSize) + 1;
28 size_t *InPos = &Pos1;
29 size_t InSize = Size1;
30 const uint8_t *Data = Data1;
31 bool CurrentlyUsingFirstData =
true;
32 while (OutPos < MaxOutSize && (Pos1 < Size1 || Pos2 < Size2)) {
34 size_t OutSizeLeft = MaxOutSize - OutPos;
35 if (*InPos < InSize) {
36 size_t InSizeLeft = InSize - *InPos;
37 size_t MaxExtraSize =
std::min(OutSizeLeft, InSizeLeft);
38 size_t ExtraSize = Rand(MaxExtraSize) + 1;
39 memcpy(Out + OutPos, Data + *InPos, ExtraSize);
41 (*InPos) += ExtraSize;
44 InPos = CurrentlyUsingFirstData ? &Pos2 : &Pos1;
45 InSize = CurrentlyUsingFirstData ? Size2 : Size1;
46 Data = CurrentlyUsingFirstData ? Data2 : Data1;
47 CurrentlyUsingFirstData = !CurrentlyUsingFirstData;
Maximum length of the test input libFuzzer tries to guess a good value based on the corpus and reports it always prefer smaller inputs during the corpus shuffle When libFuzzer itself reports a bug this exit code will be used If indicates the maximal total time in seconds to run the fuzzer minimizes the provided crash input Use with tries to cleanse the provided crash input to make it contain fewer original bytes Use with exact_artifact_path to specify the output Experimental Use value profile to guide fuzzing Number of jobs to run If min(jobs, NumberOfCpuCores()/2)\" is used.") FUZZER_FLAG_INT(reload
size_t CrossOver(const uint8_t *Data1, size_t Size1, const uint8_t *Data2, size_t Size2, uint8_t *Out, size_t MaxOutSize)
Creates a cross-over of two pieces of Data, returns its size.
assert(ImpDefSCC.getReg()==AMDGPU::SCC &&ImpDefSCC.isDef())